|
|
@@ -24,7 +24,7 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="8" style="margin-bottom: 22px">
|
|
|
+ <el-col :span="8">
|
|
|
<el-form-item label="产线:" prop="productionLineId">
|
|
|
<el-select v-model="form.productionLineId" multiple placeholder="请选择"
|
|
|
style="width: 100%">
|
|
|
@@ -34,7 +34,7 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="8" style="margin-bottom: 22px">
|
|
|
+ <el-col :span="8" style="margin-bottom: 22px">
|
|
|
<el-form-item label="工作中心:" prop="workCenterIds">
|
|
|
<div class="location-warp">
|
|
|
<el-select v-model="form.workCenterIds" multiple filterable placeholder="请选择" style="width: 100%">
|
|
|
@@ -45,6 +45,31 @@
|
|
|
</div>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ <el-col :span="8" style="margin-bottom: 22px">
|
|
|
+ <el-form-item label="是否首工序:" prop="isFirst">
|
|
|
+ <el-radio-group v-model="form.isFirst">
|
|
|
+ <el-radio-button :label="1" >是</el-radio-button>
|
|
|
+ <el-radio-button :label="0" >否</el-radio-button>
|
|
|
+ </el-radio-group>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+
|
|
|
+ <el-col :span="8" style="margin-bottom: 22px" >
|
|
|
+ <el-form-item label="生产版本:" prop="produceVersionId">
|
|
|
+ <el-select v-model="form.produceVersionId" filterable placeholder="请选择" :style="{ width: '100%' }">
|
|
|
+ <el-option v-for="item in versionList" :key="item.id" :label="item.code + '-' + item.name" :value="item.id" @click.native="form.produceVersionName = item.name">
|
|
|
+ </el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
</el-row>
|
|
|
</el-card>
|
|
|
<el-card shadow="never" header="员工配置" body-style="padding: 22px 22px 0 22px;">
|
|
|
@@ -67,6 +92,7 @@ import {
|
|
|
saveteam,
|
|
|
updateteam
|
|
|
} from '@/api/workforceManagement/team';
|
|
|
+import { pageList } from '@/api/technology/version/version.js';
|
|
|
import work from '@/api/technology/work';
|
|
|
import userTable from './userTable.vue';
|
|
|
export default {
|
|
|
@@ -74,6 +100,16 @@ export default {
|
|
|
userTable
|
|
|
},
|
|
|
data() {
|
|
|
+
|
|
|
+ var checkVersion = (rule, value, callback) => {
|
|
|
+ if (this.form.isFirst == 1 && this.form.produceVersionId == '') {
|
|
|
+ callback(new Error('请选择生产版本'));
|
|
|
+ }else {
|
|
|
+ callback();
|
|
|
+ }
|
|
|
+ };
|
|
|
+
|
|
|
+
|
|
|
const defaultForm = function () {
|
|
|
return {
|
|
|
id: '',
|
|
|
@@ -84,7 +120,9 @@ export default {
|
|
|
userIds: '',
|
|
|
userNumber: '',
|
|
|
workCenterIds: [],
|
|
|
- workshopId: []
|
|
|
+ workshopId: [],
|
|
|
+ isFirst: 0,
|
|
|
+ produceVersionId: ''
|
|
|
};
|
|
|
};
|
|
|
return {
|
|
|
@@ -98,6 +136,10 @@ export default {
|
|
|
workshopId: [{ required: true, message: '请输入', trigger: 'change' }],
|
|
|
productionLineId: [
|
|
|
{ required: true, message: '请输入', trigger: 'change' }
|
|
|
+ ],
|
|
|
+ produceVersionId: [
|
|
|
+ { validator: checkVersion, trigger: 'blur' }
|
|
|
+
|
|
|
]
|
|
|
},
|
|
|
visible: false,
|
|
|
@@ -107,7 +149,9 @@ export default {
|
|
|
workshopId: [],
|
|
|
productionLineId: [],
|
|
|
workCenterIds: []
|
|
|
- }
|
|
|
+ },
|
|
|
+
|
|
|
+ versionList: [],
|
|
|
};
|
|
|
},
|
|
|
computed: {
|
|
|
@@ -154,7 +198,7 @@ export default {
|
|
|
await this.getlistFactoryLineByParentId();
|
|
|
|
|
|
}
|
|
|
-
|
|
|
+ this.getVersionList()
|
|
|
this.getlistByProductionLineId();
|
|
|
},
|
|
|
/* 保存编辑 */
|
|
|
@@ -248,6 +292,14 @@ export default {
|
|
|
this.getlistFactoryLineByParentId();
|
|
|
},
|
|
|
|
|
|
+ async getVersionList() {
|
|
|
+ const res = await pageList({
|
|
|
+ pageNum: 1,
|
|
|
+ size: 100
|
|
|
+ });
|
|
|
+ this.versionList = res.list
|
|
|
+ },
|
|
|
+
|
|
|
}
|
|
|
};
|
|
|
</script>
|