Quellcode durchsuchen

Merge branch 'demo_' of http://123.60.19.203:8088/hitch/hitch-antd into demo_

408249787 vor 2 Jahren
Ursprung
Commit
1cf10cb19f

+ 9 - 2
src/views/repair/application-form/modules/DetailRepair.vue

@@ -260,7 +260,7 @@
         <a-button v-if="$auth('repair-application-forms-dispatch') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.RECEIVED === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.MM_DISPATCH === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.DISPATCH_REPAIR === model.status)" style="margin-left: 16px" type="default" @click="handleAssign">派单</a-button>
         <a-button v-if="(DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REPAIR_FAIL === model.status)" style="margin-left: 16px" type="default" @click="reportRepair">维修上报</a-button>
         <a-button v-if="(DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REPAIR_FAIL === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.MM_REPAIR_FAIL === model.status)" style="margin-left: 16px" type="default" @click="handleReportRepair">处理维修上报</a-button>
-        <a-button v-if="$auth('repair-application-forms-finish') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.WAIT_SUBMIT === model.status)" style="margin-left: 8px" type="default" @click="handleTransfer()">转派</a-button>
+        <a-button v-if="$auth('repair-application-forms-finish') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.WAIT_SUBMIT === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REPAIR_FAIL === model.status)" style="margin-left: 8px" type="default" @click="handleTransfer()">转派</a-button>
         <a-button v-if="$auth('repair-application-forms-examine') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status" style="margin-left: 8px" type="default" @click="handleFinish()">完成维修</a-button>
         <a-button v-if="DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status" style="margin-left: 8px" type="default" @click="handleViewTicket()">维修票证</a-button>
         <a-popconfirm v-if="$auth('repair-application-forms-finish') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.WAIT_SUBMIT === model.status)" title="是否要结单?" @confirm="handleExamine">
@@ -298,7 +298,7 @@
     <transfer-form ref="transferForm" @ok="handleOk"/>
     <detail-check-new ref='detailCheckNew' @ok='handleVerifyRecordOk'/>
     <repair-record-form ref='repairRecordForm' @ok='handleRepairRecordOk' />
-    <report-up-form ref='reportUpForm' @ok='handleOk' />
+    <report-up-form ref='reportUpForm' @ok='handleOk' @okk='handleCancel' />
     <ticket-form ref='ticketForm' @ok='handleOk' />
   </div>
 </template>
@@ -831,6 +831,13 @@ export default {
       this.confirmLoading = false
       this.$emit('ok')
     },
+    handleOkUp (num) {
+      if (num === 1) {
+        this.handleOk()
+      } else {
+        this.handleCancel()
+      }
+    },
     handleAddSpare () {
       const id = this.model.sbId
       const routeUrl = this.$router.resolve({ path: '/spare/used/record', query: { id: id } })

+ 11 - 6
src/views/repair/application-form/modules/ReportUpForm.vue

@@ -157,7 +157,7 @@ export default {
         }
         // 日期处理
         this.model.reportLeaderId = values.reportLeaderId
-        if (this.model.reportHandleType === 1) { // 维修上报
+        if (this.model.reportHandleType === 1) { // 维修上报处理
           // 维修上报处理
           if (this.model.roleType === 2 || this.model.roleType === 3) {
             this.model.repairUserId = values.reportLeaderId
@@ -168,10 +168,10 @@ export default {
         this.model.remark = values.remark
         reportRepair(this.model).then(() => {
           this.$message.info('操作成功')
-          if (this.model.reportHandleType !== 1) {
-            this.$router.push({ path: '/repair/form/mine' })
+          if (this.model.reportHandleType === 2) {
+            this.handleCancel(2)
           } else {
-            this.handleCancel(values)
+            this.handleCancel(1)
           }
         }).catch(() => {
           this.confirmLoading = false
@@ -182,11 +182,16 @@ export default {
       this.visible = false
       this.confirmLoading = false
       this.form.resetFields()
-      if (this.BaseTool.Object.isNotBlank(values)) {
+      if (values === 1) {
         this.$emit('ok')
       } else {
-        this.$emit('ok')
+        this.$emit('okk')
       }
+      /*if (this.BaseTool.Object.isNotBlank(values)) {
+        this.$emit('ok')
+      } else {
+        this.$emit('ok')
+      }*/
     }
   }
 }