Преглед изворни кода

Merge remote-tracking branch 'origin/zdsz3.0' into zdsz3.0

JX.Li пре 1 година
родитељ
комит
0a6a9350ad

+ 7 - 5
src/components/ConstructionDetails/index.vue

@@ -186,13 +186,13 @@
                   :disabled="status == 'read-only' "
                 ></ObsImageUpload>
               </div>
-              
+
             <!-- </el-form-item> -->
             <hr>
           </el-collapse-item>
         </el-collapse>
       </el-tab-pane>
-      <button class="check" @click="checkWorking" v-if="currentStatus == 'check' && reviewStatus && isChecking " style="width: 80px;border: none;">审核</button>
+      <button class="check" @click="checkWorking" v-show="currentStatus == 'check' && reviewStatus && isChecking " style="width: 80px;border: none;">审核</button>
       <button class="check" @click="updateNodeOption" style="width: 94px;border: none;cursor: pointer;" v-if="currentStatus != 'check' && status != 'read-only'  ">修改</button>
     </el-tabs>
     </el-dialog>
@@ -332,8 +332,9 @@ export default {
       try {
         this.currentCollapses[0].zEngineeringReviewBo.reviewStatus != 1 ? this.isChecking = true : false
       } catch (error) {
-        this.isChecking = false
+        this.isChecking = true
       }
+      console.log('isChecking',this.isChecking)
       let materialQuality = []
       try {
         materialQuality = this.currentCollapses[0].zEngineeringMaterialBo[0].materialQuality
@@ -352,7 +353,7 @@ export default {
     // 提交审核
     checkingSubmit(){
       try {
-        console.log(this.currentCollapses[0])
+        console.log("this.zEngineeringNodeBo",this.zEngineeringNodeBo)
         this.checkingInfo.engInfoId = this.zEngineeringNodeBo.id
       } catch (error) {
         this.checkingInfo.engInfoId = null
@@ -387,6 +388,7 @@ export default {
     open(dicts, type = null,currentStatus = null,kind = null) {
       this.currentStatus = currentStatus
       this.checkingVisible = false
+      console.log(this.reviewStatus,this.currentStatus,this.isChecking)
       if (type == '1' || type == '2') {
         // 工业 市政
         this.$parent.viewNodeSource()
@@ -408,7 +410,7 @@ export default {
         console.log(dicts)
         this.dialogVisible = true
         if (type=='check'&&kind=='基建'){
-            dicts=dicts.filter(item=>['水电施工','防水'].includes(item.value))
+          dicts=dicts.filter(item=>['水电施工','防水'].includes(item.value))
         }
         this.currentDicts = dicts
       }

+ 21 - 7
src/views/zdsz/engineeringInfrastructure/index.vue

@@ -224,6 +224,7 @@
     <ConstructionDetails
       ref="ConstructionDetails"
       :currentCollapses="currentCollapses"
+      :zEngineeringNodeBo="zEngineeringNodeBo"
       :type="nodeDetailType"
       :status="status"
       @updateNodeOption="updateNodeOption"
@@ -685,7 +686,10 @@ export default {
       enginId:null,
       updateParams:{},
       status:null,
-      createTime:''
+      createTime:'',
+      zEngineeringNodeBo:{
+
+      },
 
     };
   },
@@ -738,17 +742,26 @@ export default {
   viewSource(e,type = null){
     let params = this.dict.type.engineering_infrastructure
     if(type == 'check'){
+      // 审核
+      let checkingParams = []
       getDictList({enginType:['engineering_infrastructure']}).then(res => {
-        params = res.data.filter(e => {
+        checkingParams = res.data.filter(e => {
           return e.label == '水电施工' || e.label == '防水'
         })
-        return this.$refs.ConstructionDetails.open(params,_,type)
+        setTimeout(() => {
+          console.log('___',checkingParams)
+          this.zEngineeringNodeBo = e
+          this.currentId = e.id
+          this.status = 'read-only'
+          this.$refs.ConstructionDetails.open(checkingParams,_,type)
+        })
       })
+    } else{
+      this.zEngineeringNodeBo = e
+      this.currentId = e.id
+      this.$refs.ConstructionDetails.open(params,_,type)
+      this.status = 'read-only'
     }
-    console.log(e)
-    this.currentId = e.id
-    this.$refs.ConstructionDetails.open(params,_,type)
-    this.status = 'read-only'
   },
   // 填写节点信息
   updateNodeOption(zEngineeringInfoBoList){
@@ -778,6 +791,7 @@ export default {
       try {
         this.updateParams = res.data
         this.currentCollapses = res.data.zEngineeringNodeBo.zEngineeringInfoBoList
+        this.zEngineeringNodeBo=res.data.zEngineeringNodeBo
       } catch (error) {
         this.currentCollapses = [];
       }