|
@@ -26,9 +26,9 @@
|
|
|
</el-form-item>
|
|
|
</el-col> -->
|
|
|
<el-col :xs="24" :sm="12" :lg="6">
|
|
|
- <el-form-item label="产品类别" prop="smallType">
|
|
|
- <el-select v-model="screenForm.smallType" placeholder="请选择产品类别" clearable>
|
|
|
- <el-option v-for="item in smallList" :key="item.kingDeeCategoryId" :label="item.kingDeeCategoryName" :value="item.kingDeeCategoryId"></el-option>
|
|
|
+ <el-form-item label="产品类别" prop="categoryId">
|
|
|
+ <el-select v-model="screenForm.categoryId" placeholder="请选择产品类别" clearable>
|
|
|
+ <el-option v-for="item in typeList" :key="item.id" :label="item.name" :value="item.id"></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
@@ -126,7 +126,7 @@
|
|
|
|
|
|
<script>
|
|
|
import { getStockList, getWarehouseList } from "@/api/stock";
|
|
|
-import { getDictList, getSmallList } from '@/api/common'
|
|
|
+import { getCategoryList, getSmallList } from '@/api/common'
|
|
|
|
|
|
export default {
|
|
|
data() {
|
|
@@ -144,7 +144,7 @@ export default {
|
|
|
goodsCode: '',
|
|
|
model: '',
|
|
|
type: '',
|
|
|
- smallType: '',
|
|
|
+ categoryId: '',
|
|
|
},
|
|
|
warehouseList: [],
|
|
|
positionList: [],
|
|
@@ -163,14 +163,14 @@ export default {
|
|
|
materialOldNumber: this.screenForm.goodsNum,
|
|
|
specification: this.screenForm.model,
|
|
|
mainNumber: this.screenForm.type,
|
|
|
- categoryId: this.screenForm.smallType,
|
|
|
+ categoryId: this.screenForm.categoryId,
|
|
|
}
|
|
|
},
|
|
|
},
|
|
|
|
|
|
created() {
|
|
|
this.getWarehouseList();
|
|
|
- this.getDictList();
|
|
|
+ this.getCategoryList();
|
|
|
this.getList();
|
|
|
},
|
|
|
|
|
@@ -186,9 +186,13 @@ export default {
|
|
|
},
|
|
|
|
|
|
// 获取产品大类列表
|
|
|
- getDictList() {
|
|
|
- getDictList({sysDictEnum: 'PRODUCT_TYPE'}).then(res => {
|
|
|
- this.typeList = res.data;
|
|
|
+ getCategoryList() {
|
|
|
+ getCategoryList({
|
|
|
+ pageNum:1,
|
|
|
+ pageSize:-1,
|
|
|
+
|
|
|
+ }).then(res => {
|
|
|
+ this.typeList = res.data.records;
|
|
|
})
|
|
|
},
|
|
|
|
|
@@ -201,7 +205,7 @@ export default {
|
|
|
|
|
|
// 更改大类
|
|
|
changeType() {
|
|
|
- this.screenForm.smallType = '';
|
|
|
+ this.screenForm.categoryId = '';
|
|
|
if(this.screenForm.type) {
|
|
|
this.getSmallList();
|
|
|
}else {
|
|
@@ -234,7 +238,7 @@ export default {
|
|
|
materialOldNumber: this.screenForm.goodsNum,
|
|
|
specification: this.screenForm.model,
|
|
|
mainNumber: this.screenForm.type,
|
|
|
- categoryId: this.screenForm.smallType,
|
|
|
+ categoryId: this.screenForm.categoryId,
|
|
|
};
|
|
|
getStockList(params).then((res) => {
|
|
|
this.dataList = res.data.records;
|