工单分配,维修人员,报修详情
This commit is contained in:
@@ -153,8 +153,12 @@
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
import { onLoad, onUnload } from '@dcloudio/uni-app'
|
||||
import { getCurrentVillage,getTodayInspection,getNewNoticeData,getBannarList} from '../../api/api.js'
|
||||
|
||||
import {
|
||||
getCurrentVillage,
|
||||
getTodayInspection,
|
||||
getNewNoticeData,
|
||||
getBannarList
|
||||
} from '../../api/api.js'
|
||||
|
||||
// 列表数据状态
|
||||
const current = ref(0)
|
||||
@@ -242,17 +246,19 @@ const currentVillageData = () => {
|
||||
.catch(() => {})
|
||||
}
|
||||
// 获取今日巡检数据
|
||||
const getInspectionData = () =>{
|
||||
getTodayInspection().then(res =>{
|
||||
if(res.code === 200){
|
||||
if(res.data){
|
||||
allCount.value = res.data.totalTasks
|
||||
pendingCount.value = res.data.unfinishedTasks
|
||||
InspectedCount.value = res.data.completedTasks
|
||||
}else{
|
||||
const getInspectionData = () => {
|
||||
getTodayInspection()
|
||||
.then(res => {
|
||||
if (res.code === 200) {
|
||||
if (res.data) {
|
||||
allCount.value = res.data.totalTasks
|
||||
pendingCount.value = res.data.unfinishedTasks
|
||||
InspectedCount.value = res.data.completedTasks
|
||||
} else {
|
||||
allCount.value = 0
|
||||
pendingCount.value = 0
|
||||
InspectedCount.value = 0
|
||||
pendingCount.value = 0
|
||||
InspectedCount.value = 0
|
||||
}
|
||||
}
|
||||
})
|
||||
.catch(err => {
|
||||
@@ -272,14 +278,16 @@ const getNoticeData = () => {
|
||||
.catch(() => {})
|
||||
}
|
||||
// 获取bannar图
|
||||
function getbannarData(){
|
||||
getBannarList().then(res => {
|
||||
if (res.code === 200 && res.data) {
|
||||
bannerList.value = res.data
|
||||
}else{
|
||||
bannerList.value = []
|
||||
}
|
||||
}).catch(() => {})
|
||||
function getbannarData() {
|
||||
getBannarList()
|
||||
.then(res => {
|
||||
if (res.code === 200 && res.data) {
|
||||
bannerList.value = res.data
|
||||
} else {
|
||||
bannerList.value = []
|
||||
}
|
||||
})
|
||||
.catch(() => {})
|
||||
}
|
||||
|
||||
// 接收选择小区返回的参数
|
||||
|
||||
Reference in New Issue
Block a user