|
@@ -717,6 +717,11 @@
|
|
|
ref="selectPlanRulesRef"
|
|
ref="selectPlanRulesRef"
|
|
|
@chooseRules="chooseRules"
|
|
@chooseRules="chooseRules"
|
|
|
></selectPlanRules>
|
|
></selectPlanRules>
|
|
|
|
|
+
|
|
|
|
|
+ <PlanRulesDialog
|
|
|
|
|
+ ref="planRulesDialogRef"
|
|
|
|
|
+ @reload="reload"
|
|
|
|
|
+ ></PlanRulesDialog>
|
|
|
</ele-modal>
|
|
</ele-modal>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
@@ -755,6 +760,7 @@
|
|
|
import selectWorkOrder from '@/views/checklistManagement/components/selectWorkOrder.vue';
|
|
import selectWorkOrder from '@/views/checklistManagement/components/selectWorkOrder.vue';
|
|
|
import selectPlanRules from '@/components/selectPlanRules/selectPlanRules.vue';
|
|
import selectPlanRules from '@/components/selectPlanRules/selectPlanRules.vue';
|
|
|
import { getEamInfoByMesWorkOrderIdAndPlanConfigId } from '@/api/ruleManagement/plan';
|
|
import { getEamInfoByMesWorkOrderIdAndPlanConfigId } from '@/api/ruleManagement/plan';
|
|
|
|
|
+ import PlanRulesDialog from '@/views/produce/components/prenatalExamination/PlanRulesDialog.vue';
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
name: 'editModal',
|
|
name: 'editModal',
|
|
@@ -775,7 +781,8 @@
|
|
|
material,
|
|
material,
|
|
|
statistics,
|
|
statistics,
|
|
|
selectWorkOrder,
|
|
selectWorkOrder,
|
|
|
- selectPlanRules
|
|
|
|
|
|
|
+ selectPlanRules,
|
|
|
|
|
+ PlanRulesDialog
|
|
|
},
|
|
},
|
|
|
props: {
|
|
props: {
|
|
|
// 1-产前准备,2-过程控制,3-产后检查 4-生产统计
|
|
// 1-产前准备,2-过程控制,3-产后检查 4-生产统计
|
|
@@ -1412,14 +1419,7 @@
|
|
|
|
|
|
|
|
if (this.form.executeMethod == 1) {
|
|
if (this.form.executeMethod == 1) {
|
|
|
// 设备保养计划相关逻辑
|
|
// 设备保养计划相关逻辑
|
|
|
- this.dialogTitle = '新增设备保养计划';
|
|
|
|
|
- this.$refs.programRulesDialogRef.init(
|
|
|
|
|
- this.form,
|
|
|
|
|
- this.workOrderInfo ? this.workOrderInfo : this.form,
|
|
|
|
|
- {
|
|
|
|
|
- name: this.form.produceTaskName
|
|
|
|
|
- }
|
|
|
|
|
- );
|
|
|
|
|
|
|
+ this.planRulesSaveOrSubmit();
|
|
|
} else if (this.form.executeMethod == 2) {
|
|
} else if (this.form.executeMethod == 2) {
|
|
|
this.releaseRulesSaveOrSubmit(type);
|
|
this.releaseRulesSaveOrSubmit(type);
|
|
|
} else {
|
|
} else {
|
|
@@ -1965,6 +1965,28 @@
|
|
|
this.$refs.statisticsRef.rebuildMaterialAndProcessData();
|
|
this.$refs.statisticsRef.rebuildMaterialAndProcessData();
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
|
|
+ },
|
|
|
|
|
+ // 计划规则 去执行
|
|
|
|
|
+ async planRulesSaveOrSubmit() {
|
|
|
|
|
+ if (!this.form.planConfigId) {
|
|
|
|
|
+ this.$message.warning('请选择事项规则!');
|
|
|
|
|
+ return;
|
|
|
|
|
+ }
|
|
|
|
|
+ if (!this.form.workOrderId) {
|
|
|
|
|
+ this.$message.warning('请选择生产工单!');
|
|
|
|
|
+ return;
|
|
|
|
|
+ }
|
|
|
|
|
+ const data = await getEamInfoByMesWorkOrderIdAndPlanConfigId(
|
|
|
|
|
+ this.form.workOrderId,
|
|
|
|
|
+ this.form.planConfigId
|
|
|
|
|
+ );
|
|
|
|
|
+ if (!data || JSON.stringify(data) == '{}') {
|
|
|
|
|
+ this.$message.warning('未查询到对应的设备计划信息!');
|
|
|
|
|
+ return;
|
|
|
|
|
+ }
|
|
|
|
|
+ console.log('data', data);
|
|
|
|
|
+ // 计划规则 巡点检 设备保养
|
|
|
|
|
+ this.$refs.planRulesDialogRef.open(data);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|