| 
					
				 | 
			
			
				@@ -200,29 +200,47 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <el-table-column type="index" width="40"></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <el-table-column prop="partNo" label="零件编号" width="150" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <el-table-column prop="partName" label="零件名称" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column prop="partLife" label="寿命次数" width="100" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column prop="isVulnerable" label="易损件" width="100" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column prop="partLife" label="寿命次数" align="center" width="100" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column prop="isVulnerable" label="易损件" align="center" width="100" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                             <template slot-scope="scope">{{scope.row.isVulnerable==0?'否':'是'}}</template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         </el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column prop="part3dFile" label="3D图档" width="200" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column prop="part2dFile" label="2D图档" width="200" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column prop="indate" label="上传时间" width="200" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column label="状态" width="120" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column prop="part3dFile.fileName" label="3D图档" width="200" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column prop="part2dFile.fileName" label="2D图档" width="200" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column prop="indate" label="上传时间" width="200" align="center" sortable></el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column label="状态" width="120" align="center" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                             <template slot-scope="scope"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-if="scope.row.state == -2">生产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-else-if="scope.row.state == -1">资产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-else-if="scope.row.state == 0">待双方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-else-if="scope.row.state == 1">待生产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-else-if="scope.row.state == 2">待资产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <span v-else-if="scope.row.state == 3">审核通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                <span v-if="scope.row.part3dFile != null && scope.row.part2dFile == null"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-if="scope.row.part3dFile.state == -2">生产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part3dFile.state == -1">资产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part3dFile.state == 0">待双方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part3dFile.state == 1">待生产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part3dFile.state == 2">待资产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part3dFile.state == 3">审核通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                </span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                <span v-if="scope.row.part3dFile == null && scope.row.part2dFile != null"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-if="scope.row.part2dFile.state == -2">生产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == -1">资产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 0">待双方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 1">待生产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 2">待资产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 3">审核通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                </span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                <span v-if="scope.row.part3dFile != null && scope.row.part2dFile != null"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-if="scope.row.part2dFile.state == -2">生产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == -1">资产方审核不通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 0">待双方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 1">待生产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 2">待资产方审核</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    <span v-else-if="scope.row.part2dFile.state == 3">审核通过</span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                </span> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                             </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         </el-table-column> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <el-table-column label="操作" width="200" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-table-column label="操作" width="200" align="center" sortable> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                             <template slot-scope="scope"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                 <el-button size="small"  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                     v-if="approve == 1 && (scope.row.state == 0 || (scope.row.state == 1 && user.subordinateType == 1) || (scope.row.state == 2 && user.subordinateType == 0))"  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                     @click="checkOpen(scope.row.id, scope.row.fileName)">审批</el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                                <el-button size="small" @click="dowloadfile(scope.row.id)" v-if="download == 1 && scope.row.state == 3"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                <el-button size="small" @click="editPort(scope.row)" v-if="scope.row.creatorId == user.id"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                     修改 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                 </el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                                 <el-button size="small" @click="dowloadfile(scope.row.id)" v-if="download == 1 && scope.row.state == 3"> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -431,7 +449,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         </el-dialog> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         <!-- 单个新增零件弹窗 --> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        <el-dialog title="编辑模具" v-if="centerDialog3Visible" :visible.sync="centerDialog3Visible" :close-on-click-modal="false" customClass="customWidth"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <el-dialog title="新增零件" v-if="centerDialog3Visible" :visible.sync="centerDialog3Visible" :close-on-click-modal="false" customClass="customWidth"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             <el-form :model="newParts" label-width="100px" :rules="formRules" ref="newParts" :inline="true" class="demo-form-inline"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 <el-form-item label="零件编号" prop="number"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <el-input v-model="newParts.number" autocomplete="off" placeholder="请输入零件编号"></el-input> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -449,6 +467,25 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             </div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         </el-dialog> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <!-- 单个编辑零件弹窗 --> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        <el-dialog title="编辑零件" v-if="editPortVisible" :visible.sync="editPortVisible" :close-on-click-modal="false" customClass="customWidth"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <el-form :model="editParts" label-width="100px" :rules="formRules" ref="editParts" :inline="true" class="demo-form-inline"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-form-item label="零件编号" prop="number"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <el-input v-model="editParts.number" autocomplete="off" placeholder="请输入零件编号"></el-input> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                </el-form-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-form-item label="零件名称" prop="name"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <el-input v-model="editParts.name" autocomplete="off" placeholder="请输入零件名称"></el-input> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                </el-form-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-form-item label="零件寿命" prop="life"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <el-input v-model="editParts.life" autocomplete="off" placeholder="请输入零件寿命"></el-input> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                </el-form-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </el-form> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            <div slot="footer" class="dialog-footer"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-button @click.native="editPortVisible = false">取消</el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-button type="primary" @click.native="editPartVisible" :loading="editLoading">提交</el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            </div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        </el-dialog> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         <!--编辑界面--> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         <el-dialog title="编辑模具" v-if="editFormVisible" :visible.sync="editFormVisible" :close-on-click-modal="false" customClass="customWidth"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             <el-form :model="editForm" label-width="100px" :rules="formRules" ref="editForm" :inline="true" class="demo-form-inline"> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -472,6 +509,11 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 <el-form-item label="RIFD码"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <el-input v-model="editForm.rfid" autocomplete="off" placeholder="请输入RIFD码"></el-input> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 </el-form-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                <el-form-item label="保养次数"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <el-select v-model="editForm.maintainCount" clearable multiple allow-create filterable default-first-option placeholder="请选择保养次数" style="width:202px"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <el-option v-for="item in maintainCount" :key="item" :label="item" :value="item"></el-option> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    </el-select> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                </el-form-item> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 <el-form-item label="所属生产方" v-if="moldDetail.projectId != null"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <el-select v-model="editForm.produceCompanyId" clearable filterable placeholder="请选择所属生产方" style="width:202px"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <el-option v-for="item in customCompany" :key="item.companyId" :label="item.companyName" :value="item.companyId"></el-option> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -502,6 +544,14 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     name: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     life: "" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                editParts: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    id: 0, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    number: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    name: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    life: "" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                maintainCount: [5000,10000], 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 formRules: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     modelNo: [ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         { required: true, message: "请输入模具编号", trigger: "blur" } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -556,6 +606,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 centerDialog2Visible: false, //模具界面 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 centerDialog3Visible: false, //创建零件界面 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 centerDialog4Visible: false, //零件文档上传界面 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                editPortVisible: false,//编辑零件界面 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 listLoading: false, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 activeTab: 0, 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -575,6 +626,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     settingLife: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     rfid: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     produceCompanyId: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    maintainCount: [], 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     flag: 1 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -664,6 +716,9 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //打开编辑 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             edit() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 this.editFormVisible = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                var maintainCount = this.moldDetail.maintainCount; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                maintainCount = maintainCount.split(","); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 this.editForm = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     id: this.moldDetail.id, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     modelName: this.moldDetail.modelName, 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -673,6 +728,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     settingLife: this.moldDetail.settingLife, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     rfid: this.moldDetail.rfid, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     produceCompanyId: this.moldDetail.produceCompanyId, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    maintainCount: maintainCount, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     flag: 1 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 }; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             }, 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -681,6 +737,15 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 this.$refs.editForm.validate(valid => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     if (valid) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         this.editLoading = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        var maintainCount = this.editForm.maintainCount , str = ""; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        for(var i in maintainCount) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            if(i == maintainCount.length-1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                str += maintainCount[i] 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                str += maintainCount[i] + "," 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        this.editForm.maintainCount = str; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         this.http.post( this.port.mold.addMold, this.editForm, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         res => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                             this.editLoading = false; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -904,32 +969,91 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //零件新建 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             subPart() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                this.editLoading = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                this.http.post( this.port.mold.moulds, { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    belongCompanyId: this.user.companyId, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    mouldId: this.detailId 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                res => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if (res.code == "ok") { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                            message: "新建成功", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                            type: "success" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                this.$refs.newParts.validate(valid => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (valid) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        this.editLoading = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        this.http.post( this.port.mold.addPart, { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partNo: this.newParts.number, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partName: this.newParts.name, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partLife: this.newParts.life, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            mouldId: this.detailId 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        res => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            if (res.code == "ok") { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.centerDialog3Visible = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    message: "新建成功", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    type: "success" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.getPartList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    message: res.msg, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        error => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.centerDialog3Visible = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                message: error, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                            message: res.msg, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                            type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                }) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            //打开零件修改 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            editPort(row) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                this.editPortVisible = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                this.editParts = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    id: row.id, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    number: row.partNo, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    name: row.partName, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    life: row.partLife 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            editPartVisible() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                this.$refs.editParts.validate(valid => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (valid) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        this.editLoading = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        this.http.post( this.port.mold.addPart, { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partNo: this.editParts.number, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partName: this.editParts.name, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            partLife: this.editParts.life, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            mouldId: this.detailId 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        res => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            if (res.code == "ok") { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.editPortVisible = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    message: "新建成功", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    type: "success" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.getPartList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    message: res.msg, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                    type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        error => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.editPortVisible = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                message: error, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                                type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                            }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                error => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    this.editLoading = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    this.$message({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        message: error, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        type: "error" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                }) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //零件列表 
			 |