diff --git a/.env.development b/.env.development index a6cf54bb..f4fb12a1 100644 --- a/.env.development +++ b/.env.development @@ -7,9 +7,9 @@ VUE_APP_TITLE = '曲阳金隅安全智能管控平台' # 接口地址 #VUE_APP_API_BASEURL = http://1.203.161.103:2800/api #VUE_APP_WS_API = 'ws://localhost:8000' -# VUE_APP_API_BASEURL = http://222.222.144.147:6013/api +VUE_APP_API_BASEURL = http://222.222.144.147:6013/api #VUE_APP_API_BASEURL = http://10.99.5.79:20309/api -VUE_APP_API_BASEURL = http://49.232.14.174:2226/api +# VUE_APP_API_BASEURL = http://49.232.14.174:2226/api # VUE_APP_API_BASEURL = http://127.0.0.1:2226/api #VUE_APP_BASEURL = http://127.0.0.1:8000 diff --git a/src/views/home/widgets/components/about.vue b/src/views/home/widgets/components/about.vue index fff74111..167a7652 100644 --- a/src/views/home/widgets/components/about.vue +++ b/src/views/home/widgets/components/about.vue @@ -13,6 +13,22 @@ {{ scope.row.employee_.belong_dept_name }} + + + + + {{scope.row.employee_.location.area_fix_name }} + 厂区内 + + + + + + + + {{ scope.row.code }} + + - - + + 工单待办 - - + + {{ item.workflow__name }} + + 暂无待办工单 + - + @@ -111,45 +114,7 @@ export default { }; }, created() { - var craeteTime = this.$TOOL.dateFormat( - new Date().toLocaleDateString(), - "yyyy-MM-dd" - ); - - this.postOptions = []; - this.$API.ecm.event.cateAgg - .req({ completed: false, start_create: craeteTime }) - .then((res) => { - res.details.forEach((itemI, indexI) => { - this.postOptions.push({ value: itemI.count, name: itemI.cate__name }); - }); - }); - this.option3 = { - title: {}, - tooltip: { - trigger: "item", - }, - legend: { - // orient: 'vertical', - left: 'center' - }, - series: [ - { - name: "事件分类", - type: "pie", - radius: ["40%", "70%"], - center: ["50%", "60%"], - label: { - formatter: '{c}', - position: 'inside', - color: 'white' - }, - data: this.postOptions, - }, - ], - }; - - this.params.start_create = craeteTime; + this.apiObj = this.$API.ecm.event.list; this.getdutyAgg(); }, @@ -241,10 +206,10 @@ export default { .card-body { display: flex; flex-wrap: wrap; - justify-content: space-around; height: 340px; overflow-y: scroll; padding-top: 10px; + align-content:flex-start } .workItemImg{ diff --git a/src/views/opm/clear.vue b/src/views/opm/clear.vue index c640f0eb..7504ae39 100644 --- a/src/views/opm/clear.vue +++ b/src/views/opm/clear.vue @@ -164,7 +164,8 @@ > - + + * @@ -609,6 +610,9 @@ measures_checked: [ {required: true, message: '请选择'} ], + fileurl2:[ + {required: true, message: '请选择'} + ] } }; }, @@ -720,11 +724,14 @@ }, //组件点击下一步 handleNextStep() { - if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { - this.isSaving = true; //如果是创建许可证书 + this.isSaving = true; + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } //如果是创建许可证书 if (this.oplId == "") { //基本信息提交 // debugger; diff --git a/src/views/opm/cooler.vue b/src/views/opm/cooler.vue index 6bca02e1..c82a36ed 100644 --- a/src/views/opm/cooler.vue +++ b/src/views/opm/cooler.vue @@ -163,7 +163,8 @@ > - + + * @@ -721,7 +722,12 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { - this.issaving = true; //如果是创建许可证书 + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } + this.issaving = true; + //如果是创建许可证书 if (this.oplId == "") { //基本信息提交 debugger; diff --git a/src/views/opm/fire.vue b/src/views/opm/fire.vue index 63ed8c4a..bbdfad6b 100644 --- a/src/views/opm/fire.vue +++ b/src/views/opm/fire.vue @@ -176,7 +176,8 @@ > - + + * @@ -735,6 +736,10 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issaving = true; //如果是创建许可证书 if (this.oplId == "") { //基本信息提交 diff --git a/src/views/opm/high.vue b/src/views/opm/high.vue index 60362c29..b6601aeb 100644 --- a/src/views/opm/high.vue +++ b/src/views/opm/high.vue @@ -172,7 +172,8 @@ > - + + * @@ -559,39 +560,43 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issave = true; //如果是创建许可证书 - if (this.oplId == "") { - //基本信息提交 - debugger; - this.form.cate = this.oplcateId; - this.form.operation = this.operationId; - console.log(this.form); - this.$API.opm.opl.create - .req(this.form) - .then((res) => { - this.$emit("success", this.form); - this.$message.success("创建成功"); + if (this.oplId == "") { + //基本信息提交 + debugger; + this.form.cate = this.oplcateId; + this.form.operation = this.operationId; + console.log(this.form); + this.$API.opm.opl.create + .req(this.form) + .then((res) => { + this.$emit("success", this.form); + this.$message.success("创建成功"); + this.active = 1; + this.issave = false; + this.oplId = res.id; + this.getworkerList(); + this.getgasList(); + return res; + }) + .catch((err) => { + this.issave = false; + return err; + }); + } else if (this.oplId != "") { + this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { + this.$message.success("基本修改成功!"); this.active = 1; this.issave = false; - this.oplId = res.id; - this.getworkerList(); this.getgasList(); - return res; - }) - .catch((err) => { - this.issave = false; - return err; - }); - } else if (this.oplId != "") { - this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { - this.$message.success("基本修改成功!"); - this.active = 1; - this.issave = false; - this.getgasList(); - this.getworkerList(); + this.getworkerList(); - }); - } + }); + } } }) } diff --git a/src/views/opm/hoisting.vue b/src/views/opm/hoisting.vue index 877329a7..3e9dab27 100644 --- a/src/views/opm/hoisting.vue +++ b/src/views/opm/hoisting.vue @@ -172,7 +172,8 @@ > - + + * @@ -561,40 +562,44 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { - this.issave = true; //如果是创建许可证书 - if (this.oplId == "") { - //基本信息提交 - debugger; - this.form.cate = this.oplcateId; - this.form.operation = this.operationId; - console.log(this.form); - this.$API.opm.opl.create - .req(this.form) - .then((res) => { - this.$emit("success", this.form); - this.$message.success("创建成功"); + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } + this.issave = true; //如果是创建许可证书 + if (this.oplId == "") { + //基本信息提交 + debugger; + this.form.cate = this.oplcateId; + this.form.operation = this.operationId; + console.log(this.form); + this.$API.opm.opl.create + .req(this.form) + .then((res) => { + this.$emit("success", this.form); + this.$message.success("创建成功"); + this.active = 1; + this.issave = false; + this.oplId = res.id; + this.getworkerList(); + this.getgasList(); + return res; + }) + .catch((err) => { + return err; + }); + } else if (this.oplId != "") { + + this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { + this.$message.success("基本修改成功!"); this.active = 1; this.issave = false; - this.oplId = res.id; - this.getworkerList(); this.getgasList(); - return res; - }) - .catch((err) => { - return err; + this.getworkerList(); }); - } else if (this.oplId != "") { - - this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { - this.$message.success("基本修改成功!"); + } else { this.active = 1; - this.issave = false; - this.getgasList(); - this.getworkerList(); - }); - } else { - this.active = 1; - } + } } }) } diff --git a/src/views/opm/normal.vue b/src/views/opm/normal.vue index ae2846a4..fd82c0e6 100644 --- a/src/views/opm/normal.vue +++ b/src/views/opm/normal.vue @@ -137,7 +137,8 @@ - + + * @@ -541,6 +542,10 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issave = true; //如果是创建许可证书 if (this.oplId == "") { diff --git a/src/views/opm/preheat.vue b/src/views/opm/preheat.vue index 3e48d2c5..71ab88be 100644 --- a/src/views/opm/preheat.vue +++ b/src/views/opm/preheat.vue @@ -161,7 +161,8 @@ > - + + * @@ -540,45 +541,48 @@ }, //组件点击下一步 handleNextStep() { - if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issave = true; //如果是创建许可证书 - if (this.oplId == "") { - //基本信息提交 - this.form.cate = this.oplcateId; - this.form.operation = this.operationId; - console.log(this.form); - this.$API.opm.opl.create - .req(this.form) - .then((res) => { - this.$emit("success", this.form); - this.$message.success("创建成功"); + if (this.oplId == "") { + //基本信息提交 + this.form.cate = this.oplcateId; + this.form.operation = this.operationId; + console.log(this.form); + this.$API.opm.opl.create + .req(this.form) + .then((res) => { + this.$emit("success", this.form); + this.$message.success("创建成功"); + this.active = 1; + this.issave = false; + this.oplId = res.id; + this.getworkerList(); + this.getgasList(); + return res; + }) + .catch((err) => { + this.issave = false; + return err; + }); + } else if (this.oplId != "") { + this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { + this.$message.success("基本修改成功!"); this.active = 1; this.issave = false; - this.oplId = res.id; - this.getworkerList(); this.getgasList(); - return res; - }) - .catch((err) => { - this.issave = false; - return err; + this.getworkerList(); + }); - } else if (this.oplId != "") { - this.$API.opm.opl.update.req(this.oplId, this.form).then(() => { - this.$message.success("基本修改成功!"); + } else { this.active = 1; this.issave = false; - this.getgasList(); - this.getworkerList(); - - }); - } else { - this.active = 1; - this.issave = false; - } + } } }) } diff --git a/src/views/opm/soil.vue b/src/views/opm/soil.vue index 7c4c9c40..e903a72e 100644 --- a/src/views/opm/soil.vue +++ b/src/views/opm/soil.vue @@ -174,7 +174,8 @@ > - + + * @@ -565,6 +566,10 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issave = true; //如果是创建许可证书 if (this.oplId == "") { //基本信息提交 diff --git a/src/views/opm/space.vue b/src/views/opm/space.vue index 7d6ff020..facc03ff 100644 --- a/src/views/opm/space.vue +++ b/src/views/opm/space.vue @@ -179,7 +179,8 @@ > - + + * @@ -743,6 +744,10 @@ if (this.active == 0) { this.$refs.dialogForm.validate((valid) => { if (valid) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } this.issave = true; //如果是创建许可证书 if (this.oplId == "") { //基本信息提交 diff --git a/src/views/opm/usecl.vue b/src/views/opm/usecl.vue index 6f337033..99c159fa 100644 --- a/src/views/opm/usecl.vue +++ b/src/views/opm/usecl.vue @@ -232,8 +232,9 @@ > - - + + * + @@ -599,6 +600,10 @@ export default { //组件点击下一步 handleNextStep() { if (this.active == 0) { + if(this.form.create_imgs.length>0){}else{ + this.$message.error('请上传作业前照片'); + return; + } //如果是创建许可证书 if (this.oplId == "") { //基本信息提交