工艺管理-生产工序-设备绑定

yangwl
A0010407 1 year ago
parent aef81d62c1
commit cf922d1545

@ -255,14 +255,6 @@
<el-form ref="form" :model="form" :rules="rules" label-width="120px">
<el-row>
<el-col :span="6">
<!-- <el-input
v-model="equipmentTypeName"
clearable
placeholder="请输入设备类别"
prefix-icon="el-icon-search"
size="small"
:props="defaultProps"
/> -->
<el-tree
ref="tree"
:check-strictly="true"
@ -300,7 +292,7 @@
<el-button icon="el-icon-refresh" size="mini" @click="resetEquipmentQuery"></el-button>
</el-form-item>
</el-form>
<el-table v-loading="loading" :data="equipmentList" @selection-change="handleEquipmentSelectionChange">
<el-table v-loading="loading" :data="equipmentList" @selection-change="handleEquipmentSelectionChange" ref="myTable">
<el-table-column type="selection" width="55" align="center" />
<!-- 序号 -->
<el-table-column type="index" width="90" align="center" :index="indexMethod" label="序号"></el-table-column>
@ -320,16 +312,17 @@
/>
</el-col>
</el-row>
</el-form>
<el-tabs type="border-card" v-if="form.equipmentCode != null">
<!-- <el-tabs type="border-card" v-if="form.equipmentCode != null">
<el-tab-pane label="设备绑定物料">
<EquipmentBoundMaterials v-if="form.equipmentCode != null" :optType="optType" :equipmentCode="form.equipmentCode"></EquipmentBoundMaterials>
</el-tab-pane>
</el-tabs>
</el-tabs> -->
<div slot="footer" class="dialog-footer">
<el-table-column label="操作">
<el-button type="primary" @click="submitEquipmentForm"> </el-button>
<el-button @click="cancel"> </el-button>
</el-table-column>
</div>
</el-dialog>
</div>
@ -522,6 +515,12 @@ export default {
this.reset();
},
//
equipmentCancel() {
this.boundeEuipmentOpen = false;
this.reset();
},
//
reset() {
this.form = {
@ -536,7 +535,7 @@ export default {
updateTime: null,
fileList:'',
equipmentTypeName:'',
equipmentId :this.equipmentId,
equipmentId :null,
equipmentTypeName :null,
equipmentTypeCode:null,
equipmentName :null,
@ -638,33 +637,15 @@ export default {
});
},
submitEquipmentForm(row) {
//
// this.reset();
// const processId = row.processId;
// this.form.processId = processId;
// const equipmentId = row.equipmentId || this.ids;
// console.log(equipmentId,1);
// if (equipmentId != null) {
// this.form.equipmentId = equipmentId.toString();
// updateProcess(this.form,processId).then(response => {
// this.$modal.msgSuccess("");
// });
// }
//this.reset();
const processId = this.ids1;
this.queryEquipmentParams.processId = processId;
const equipmentId = row.equipmentId || this.ids;
console.log(equipmentId,1);
if (equipmentId != null) {
this.queryEquipmentParams.processId = processId.toString();
this.queryEquipmentParams.equipmentId = equipmentId.toString();
updateProcess(this.queryEquipmentParams).then(response => {
this.$modal.msgSuccess("关联成功");
//
submitEquipmentForm() {
const table = this.$refs.myTable;
const data = table.data;
console.log(data);
for (const one of data) {
const equipmentCode = one.equipmentCode;
this.form.workCenter = this.form.workCenter + ','+ equipmentCode;
this.boundeEuipmentOpen = false;
this.activated();
this.getList();
});
}
},

Loading…
Cancel
Save