{{ scope.row.inspectImage }}
@@ -248,7 +257,7 @@ export default {
deptCode: this.$store.getters.locDeptCode,
invCode: null,
code: null,
- statusList: [0,1,2],
+ statusList: [2,3,4],
page: 1,
limit: 20,
},
@@ -264,9 +273,9 @@ export default {
loading: false,
formVisible: false,
statusMap: {
- 0: "未巡检",
- 1: "巡检中",
- 2: "已巡检",
+ 2: "未巡检",
+ 3: "巡检中",
+ 4: "已巡检",
},
statusdetailMap: {
1: "未开始",
@@ -404,7 +413,7 @@ export default {
deptCode: this.$store.getters.locDeptCode,
invCode: null,
code: null,
- statusList: [0,1,2],
+ statusList: [2,3,4],
page: 1,
limit: 20,
};
@@ -488,6 +497,7 @@ export default {
},
startOrder(row,type) {
this.formVisible = true;
+ //3是开始 4是结束 5是详情
this.type = type
this.deviceInspectTake = row;
},
diff --git a/src/views/inventory/DeviceInspectTakeAdd.vue b/src/views/inventory/DeviceInspectTakeAdd.vue
index 9c52a440..098497c6 100644
--- a/src/views/inventory/DeviceInspectTakeAdd.vue
+++ b/src/views/inventory/DeviceInspectTakeAdd.vue
@@ -2,14 +2,13 @@
-
+
选择设备
- 提交
+ 提交
@@ -66,7 +65,7 @@
@@ -145,10 +144,10 @@
- 选入
+ 选入
-
+
新增
@@ -170,7 +169,7 @@
-
+
编辑
详情
@@ -399,7 +398,11 @@ export default {
});
},
submit() {
- this.inspectTake.status = 1
+ if(this.formName == "add"){
+ this.inspectTake.status = 1
+ }else{
+ this.inspectTake.status = 2
+ }
uploadDeviceTake(this.inspectTake).then((res) => {
if (res.code === 20000) {
this.$message.success("提交成功");
diff --git a/src/views/inventory/DeviceInspectTakeAuditModify.vue b/src/views/inventory/DeviceInspectTakeAuditModify.vue
index f203c2fc..8c70a186 100644
--- a/src/views/inventory/DeviceInspectTakeAuditModify.vue
+++ b/src/views/inventory/DeviceInspectTakeAuditModify.vue
@@ -3,7 +3,7 @@
- 提交
+ 提交
@@ -53,7 +53,7 @@
-
+
+
+
+
+
+
+
+
+
+
+
+
-
@@ -100,10 +111,11 @@
+
+ 选入
+
-
- 新增
-
+ 新增
@@ -123,7 +135,7 @@
-
+
编辑
详情
@@ -148,6 +160,23 @@
:closeDialog="inspectTakeSetCloseDialog"
>
+
+
+
+
+
@@ -160,9 +189,14 @@ import {getDeptListByUser} from "@/api/auth/authDept";
import {getInvListByUser, warehouseUserList} from "@/api/system/invWarehouse";
import {saveDeviceInspectPlan, updateStatus} from "@/api/inventory/deviceInspectPlan";
import DeviceInspectTakeProjectSet from "@/views/inventory/DeviceInspectTakeProjectSet"
-import {selectDeviceInspecTakeDetail, uploadDeviceInspecTake} from "@/api/inventory/deviceInspectTake";
+import {
+ saveDeviceInspectTake,
+ selectDeviceInspecTakeDetail,
+ uploadDeviceInspecTake
+} from "@/api/inventory/deviceInspectTake";
import {previewImage, previewFile} from "@/api/purchase/supCompany";
import ElImageViewer from "element-ui/packages/image/src/image-viewer";
+import DeviceProjectSelectTake from "@/views/inventory/DeviceProjectSelectTake"
export default {
props: {
@@ -187,6 +221,7 @@ export default {
userList: [],
imgList: [],
name:'',
+ isColse: false,
BASE_URL: process.env.VUE_APP_BASE_API,
editType: null,
deviceDialogVisible: false,
@@ -218,6 +253,7 @@ export default {
selectRow: null,
imgViewerVisible: false,
inspectTakeSetVisible: false,
+ inspectSelectPlanSetVisible: false,
statusMap: {
1: "未开始",
2: "已检查",
@@ -250,8 +286,7 @@ export default {
},
submit(status) {
//判断状态
- var falg = true
- if (this.type == 2) {
+ if (this.type == 4) {
for (var i = 0; i < this.delectList.length; i++) {
if (this.delectList[i].status != 2) {
return this.$message.error("还有任务未检查!");
@@ -331,7 +366,30 @@ export default {
this.inspectTakeSetVisible = true;
}
},
-
+ selectPlanFunction(row){
+ if (this.inspectTake.orderId != null) { //edit
+ if(isBlank(row)){
+ this.inputQuery = {
+ id: null,
+ projectCode: null,
+ projectContent: null,
+ status: null,
+ result: null,
+ inspectImage: null,
+ inspectUser: null,
+ updateTime: null,
+ taskOrderIdFk: null
+ },
+ this.inputQuery.inspectUser = this.inspectTake.inspectUser
+ this.inputQuery.taskOrderIdFk = this.inspectTake.orderId
+ }else{
+ this.inputQuery = row
+ }
+ }else{
+ this.inputQuery.taskOrderIdFk = this.inspectTake.orderId
+ }
+ this.inspectSelectPlanSetVisible = true;
+ },
editDialog(row, type) {
this.inputQuery = row;
this.inspectTakeSetVisible = true
@@ -376,18 +434,29 @@ export default {
},
inspectTakeSetCloseDialog() {
this.inspectTakeSetVisible = false
+ this.inspectSelectPlanSetVisible = false
+ var count=0;
+ if (this.type == 4) {
+ for (var i = 0; i < this.delectList.length; i++) {
+ if (this.delectList[i].status != 2) {
+ count++;
+ }
+ }
+ if(count == 0){
+ return this.$message.success("任务已全部完成")
+ }
+ }
this.selectDeviceInspecTakeDetail({taskOrderIdFk: this.inspectTake.orderId});
}
}
,
components: {
- DeviceInspectTakeProjectSet, ElImageViewer
+ DeviceInspectTakeProjectSet, ElImageViewer ,DeviceProjectSelectTake
}
,
created() {
this.getDeptList();
this.getUserBus();
- console.log(this.type)
if (!isBlank(this.inspectTake.id)) {
this.selectDeviceInspecTakeDetail({taskOrderIdFk: this.inspectTake.orderId});
}
diff --git a/src/views/inventory/DeviceInspectTakeProjectSet.vue b/src/views/inventory/DeviceInspectTakeProjectSet.vue
index 1c596c2c..be2fa002 100644
--- a/src/views/inventory/DeviceInspectTakeProjectSet.vue
+++ b/src/views/inventory/DeviceInspectTakeProjectSet.vue
@@ -34,7 +34,7 @@