tupian
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
<template>
|
||||
<view class="page padding">
|
||||
<view class="padding bg-white radius flex justify-between">
|
||||
<view>危化品使用安全专题检查</view>
|
||||
<view class="padding bg-white radius flex justify-between margin-bottom" v-for="item in list" :key="item.id">
|
||||
<view>{{ item.name }}</view>
|
||||
<view>
|
||||
<button class="bg-blue cu-btn margin-right-xs" @click="edit()">编辑</button>
|
||||
<button class="bg-red cu-btn">删除</button>
|
||||
</view>
|
||||
</view>
|
||||
<button class="lg cuIcon-add bg-blue round margin-top-xl">新增检查表</button>
|
||||
<button class="lg cuIcon-add bg-blue round margin-top-xl" @click="edit()">新增检查表</button>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
@@ -15,12 +15,22 @@
|
||||
import { ref } from 'vue'
|
||||
import { onLoad } from '@dcloudio/uni-app'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { getCheckTableList } from '@/request/api.js'
|
||||
const router = useRouter()
|
||||
const list = ref([])
|
||||
const edit = () => {
|
||||
uni.navigateTo({
|
||||
url: '/pages/editchecklist/editchecklist'
|
||||
})
|
||||
}
|
||||
onLoad(() => {
|
||||
getCheckTableList().then(res => {
|
||||
if (res.code === 0) {
|
||||
list.value = res.data.records
|
||||
}
|
||||
})
|
||||
})
|
||||
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
|
||||
Reference in New Issue
Block a user