|
|
@@ -166,6 +166,8 @@
|
|
|
listWorkCenter
|
|
|
} from '@/api/mainData/index.js';
|
|
|
|
|
|
+ import { parameterGetByCode } from '@/api/mainData/index';
|
|
|
+
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
@@ -248,7 +250,7 @@
|
|
|
factoryName: '',
|
|
|
factoryLineIds: ''
|
|
|
};
|
|
|
- this.workCenterList = [];
|
|
|
+ this.workCenterList = [];
|
|
|
this.teamList = [];
|
|
|
this.crewList = [];
|
|
|
this.stationList = [];
|
|
|
@@ -261,7 +263,8 @@
|
|
|
this.firstTaskId = list[0].firstTaskId;
|
|
|
this.datasource = list;
|
|
|
this.workCenterData();
|
|
|
- this.form.singleReport = this.clientEnvironmentId === 2 ? 0 : 1;
|
|
|
+ this.getReportType('report_type');
|
|
|
+ // this.form.singleReport = this.clientEnvironmentId === 2 ? 0 : 1;
|
|
|
},
|
|
|
async workCenterData() {
|
|
|
const res = await listWorkCenter(this.firstTaskId);
|
|
|
@@ -284,6 +287,22 @@
|
|
|
const res = await lineByCurrentUser(this.form.workCenterId);
|
|
|
this.productionList = res;
|
|
|
},
|
|
|
+
|
|
|
+ async getReportType(code) {
|
|
|
+ await parameterGetByCode({ code }).then((res) => {
|
|
|
+ if (res) {
|
|
|
+ this.form.singleReport =
|
|
|
+ this.clientEnvironmentId == 2
|
|
|
+ ? 0
|
|
|
+ : res.value == '0'
|
|
|
+ ? 0
|
|
|
+ : res.value == '1'
|
|
|
+ ? 1
|
|
|
+ : '';
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+
|
|
|
// 查询工位数据
|
|
|
FirstTaskIdFn() {
|
|
|
listByFirstTaskId(this.firstTaskId)
|
|
|
@@ -369,7 +388,7 @@
|
|
|
this.loading = true;
|
|
|
batchReleaseWorkOrder(dataArr)
|
|
|
.then((res) => {
|
|
|
- if ( res){
|
|
|
+ if (res) {
|
|
|
this.loading = false;
|
|
|
this.$message.success('操作成功');
|
|
|
this.cancel();
|