| 
					
				 | 
			
			
				@@ -5,6 +5,25 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         width="70%" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         :close-on-click-modal="false" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         :visible.sync="visible"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <!-- 工作流 --> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <div v-show="display && dataForm.workFlowBusinessExt"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+          <el-steps :active="dataForm.workFlowBusinessExt?dataForm.workFlowBusinessExt.workFlowProcessStepList.length + 2:0" align-center style="margin-bottom: 20px"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <template v-for="(item, i) in stepList"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              <el-step :icon="item.icon" :title="item.title" :description="item.description"></el-step> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+          </el-steps> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+          <el-collapse style="margin-bottom: 20px"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <el-collapse-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              <template slot="title"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <span style="color: red">审批日志(展开查看更多):</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              <template v-for="(item, i) in logList"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <div>{{++i}}:{{item.approverName}}  {{item.createTime}}  {{item.approvalValue}}</div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </el-collapse-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+          </el-collapse> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <!-- 表单 --> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         <el-form :model="dataForm" :rules="dataRule" ref="dataForm" label-width="auto"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				           <el-row class="my-row"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             <el-col :span="8"> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -206,6 +225,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   import { getProductDetail, getTechList, getDrawList } from '@/api/product' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   import { getCusList } from '@/api/cus' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   import UploadComponent from '../common/upload-component' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+  import { dealStepData, dealStepLogs } from '@/api/util' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   export default { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     name: 'product-add-or-update', 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -244,12 +264,16 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				           productType: [{ required: true, message: '产品类别不能为空', trigger: 'change' }], 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				           source: [{ required: true, message: '产品来源不能为空', trigger: 'change' }], 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				           drawingIdList: [{ required: true, message: '产品图纸不能为空', trigger: 'blur' }] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        stepList: [], 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        logList: [] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				       } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     methods: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				       async init (id, display) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         this.fileList = [] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        this.stepList = [] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        this.logList = [] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         this.dataForm = {} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         this.productDetails = [] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         this.materialList = [] 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -270,6 +294,11 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         await getProductDetail(this.id).then(({data}) => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				           if (data && data.code === '200') { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             this.dataForm = data.data 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            // 流程图展示 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (data.data.workFlowBusinessExt) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              dealStepData(data.data.workFlowBusinessExt.workFlowProcessStepList, this.stepList) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+              dealStepLogs(data.data.workFlowBusinessExt.processLogList, this.logList) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 组合小产品 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             data.data.composeProductMaterialList.forEach((item) => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				               this.productDetails.push(item) 
			 |