This commit is contained in:
java110 2023-04-06 17:22:17 +08:00
parent 1e83de6e57
commit 26d44d2490

View File

@ -4,10 +4,10 @@
巡检任务补检
</view>
<view class="cu-form-group arrow" >
<view class="title">补检日期</view>
<view class="title" style="width: 200upx;">补检日期</view>
<uni-datetime-picker type="date" :clear-icon="false" v-model="planInsTime" @change="maskClick" :border="false"/>
</view>
<view v-if="noData==false">
<view v-if="tasks && tasks.length>0" class="margin-top">
<view v-for="(item,index) in tasks" :key="index" class="bg-white margin-bottom margin-right-xs radius margin-left-xs padding-top padding-left padding-right">
<view class="flex padding-bottom-xs solid-bottom justify-between">
<view>{{item.taskId}}</view>
@ -82,13 +82,6 @@
},
methods: {
_startInspection:function(_item){
// if(dateUtil.compareDate(_item.planInsTime.replace(/-/g, '/'), dateUtil.getCurrentDateTime().replace(/-/g, '/'))){
// uni.showToast({
// title: "",
// icon: "none"
// });
// return;
// }
console.log('开始巡检',_item);
uni.navigateTo({
url:'/pages/excuteInspection/excuteInspection?taskId='+_item.taskId+'&inspectionPlanName='+_item.inspectionPlanName
@ -96,7 +89,6 @@
},
_queryInstpectionTasks: function() {
let _that = this;
_that.java110Context.request({
header: _that.java110Context.getHeaders(),
url: url.listInspectionTasks,
@ -104,17 +96,17 @@
data: {
communityId: _that.communityId,
page: 1,
row: 10,
row: 20,
planUserId: _that.userId,
moreState:'20200405,20200406',
canReexamine:'2000',
planInsTime: _that.planInsTime,
isToday: 1
//isToday: 1
},
success: function(res) {
// TODO
console.log(res);
res.data.inspectionTasks.forEach(function(item, index) {
res.data.inspectionTasks.forEach(item => {
item.timeStr = item.planInsTime.replace(/:\d{1,2}$/, ' ');
});
_that.tasks = res.data.inspectionTasks;