|
@@ -373,6 +373,56 @@
|
|
|
prop="lackNum"
|
|
prop="lackNum"
|
|
|
>
|
|
>
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
|
|
+ <el-table-column
|
|
|
|
|
+ label="机型"
|
|
|
|
|
+ align="center"
|
|
|
|
|
+ prop="modelKey"
|
|
|
|
|
+ width="240"
|
|
|
|
|
+ >
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-select
|
|
|
|
|
+ clearable
|
|
|
|
|
+ v-model="scope.row.modelKey"
|
|
|
|
|
+ multiple
|
|
|
|
|
+ filterable
|
|
|
|
|
+ allow-create
|
|
|
|
|
+ default-first-option
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in modelList"
|
|
|
|
|
+ :key="item.label"
|
|
|
|
|
+ :value="item.label"
|
|
|
|
|
+ :label="item.label"
|
|
|
|
|
+ >
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column
|
|
|
|
|
+ label="颜色"
|
|
|
|
|
+ align="center"
|
|
|
|
|
+ prop="colorKey"
|
|
|
|
|
+ width="240"
|
|
|
|
|
+ >
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-select
|
|
|
|
|
+ clearable
|
|
|
|
|
+ v-model="scope.row.colorKey"
|
|
|
|
|
+ multiple
|
|
|
|
|
+ filterable
|
|
|
|
|
+ allow-create
|
|
|
|
|
+ default-first-option
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-option
|
|
|
|
|
+ v-for="item in colorList"
|
|
|
|
|
+ :key="item.label"
|
|
|
|
|
+ :value="item.label"
|
|
|
|
|
+ :label="item.label"
|
|
|
|
|
+ >
|
|
|
|
|
+ </el-option>
|
|
|
|
|
+ </el-select>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
<el-table-column
|
|
<el-table-column
|
|
|
label="批次号"
|
|
label="批次号"
|
|
|
width="160"
|
|
width="160"
|
|
@@ -875,7 +925,9 @@
|
|
|
loading: false,
|
|
loading: false,
|
|
|
processingRequired: 0, // 生产类型跟BOM 版本是否必填 1:是 0:否
|
|
processingRequired: 0, // 生产类型跟BOM 版本是否必填 1:是 0:否
|
|
|
selectionRowShow: false, // 工艺路线输入框展示 状态
|
|
selectionRowShow: false, // 工艺路线输入框展示 状态
|
|
|
- validDate
|
|
|
|
|
|
|
+ validDate,
|
|
|
|
|
+ modelList: [], // 机型数据
|
|
|
|
|
+ colorList: [] // 颜色数据
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
props: {
|
|
props: {
|
|
@@ -919,6 +971,7 @@
|
|
|
},
|
|
},
|
|
|
mounted() {
|
|
mounted() {
|
|
|
this.mandatoryField();
|
|
this.mandatoryField();
|
|
|
|
|
+ this.getCodeData();
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
clientEnvironmentId() {
|
|
clientEnvironmentId() {
|
|
@@ -956,11 +1009,36 @@
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ // 获取
|
|
|
|
|
+ async getCodeData() {
|
|
|
|
|
+ let arr1 = await this.getLevelCode('product_model_key');
|
|
|
|
|
+ let arr2 = await this.getLevelCode('product_color_key');
|
|
|
|
|
+ this.modelList = arr1;
|
|
|
|
|
+ this.colorList = arr2;
|
|
|
|
|
+ },
|
|
|
|
|
+ async getLevelCode(code) {
|
|
|
|
|
+ try {
|
|
|
|
|
+ const res = await getByCode(code);
|
|
|
|
|
+ if (res.code == 0) {
|
|
|
|
|
+ let list = Object.values(res.data).map((el) => {
|
|
|
|
|
+ let k = Object.keys(el)[0];
|
|
|
|
|
+ let v = Object.values(el)[0];
|
|
|
|
|
+ return {
|
|
|
|
|
+ label: v,
|
|
|
|
|
+ value: k
|
|
|
|
|
+ };
|
|
|
|
|
+ });
|
|
|
|
|
+ return list;
|
|
|
|
|
+ }
|
|
|
|
|
+ } catch (err) {
|
|
|
|
|
+ this.$message.error(err.message);
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
async getProducedData() {
|
|
async getProducedData() {
|
|
|
- console.log(111111111111111)
|
|
|
|
|
|
|
+ console.log(111111111111111);
|
|
|
let query = this.$route.query;
|
|
let query = this.$route.query;
|
|
|
- console.log(query,'query');
|
|
|
|
|
-
|
|
|
|
|
|
|
+ console.log(query, 'query');
|
|
|
|
|
+
|
|
|
if (!query.producedList || query.producedList.length == 0) {
|
|
if (!query.producedList || query.producedList.length == 0) {
|
|
|
this.producedList = [
|
|
this.producedList = [
|
|
|
{ code: 2, name: 'MBOM' },
|
|
{ code: 2, name: 'MBOM' },
|
|
@@ -1096,9 +1174,9 @@
|
|
|
bomType: this.form.produceType || null,
|
|
bomType: this.form.produceType || null,
|
|
|
categoryId: categoryId
|
|
categoryId: categoryId
|
|
|
};
|
|
};
|
|
|
- console.log(param,'param')
|
|
|
|
|
|
|
+ console.log(param, 'param');
|
|
|
bomListByPlan(param).then((res) => {
|
|
bomListByPlan(param).then((res) => {
|
|
|
- console.log(res,'res 查出来没')
|
|
|
|
|
|
|
+ console.log(res, 'res 查出来没');
|
|
|
this.bomVersionList = res || [];
|
|
this.bomVersionList = res || [];
|
|
|
if (res.length) {
|
|
if (res.length) {
|
|
|
let o = res[0];
|
|
let o = res[0];
|
|
@@ -1192,7 +1270,7 @@
|
|
|
this.form.produceType = this.$route.query.produceType
|
|
this.form.produceType = this.$route.query.produceType
|
|
|
? parseInt(this.$route.query.produceType)
|
|
? parseInt(this.$route.query.produceType)
|
|
|
: res.produceType;
|
|
: res.produceType;
|
|
|
- console.log(this.form.produceType,'这里吗')
|
|
|
|
|
|
|
+ console.log(this.form.produceType, '这里吗');
|
|
|
this.changeProduceType('init');
|
|
this.changeProduceType('init');
|
|
|
this.form.bomCategoryId =
|
|
this.form.bomCategoryId =
|
|
|
res.bomCategoryId || this.$route.query.bomCategoryId;
|
|
res.bomCategoryId || this.$route.query.bomCategoryId;
|