diff --git a/src/api/product/category.js b/src/api/product/category.js
index a8ab19f..889eebe 100644
--- a/src/api/product/category.js
+++ b/src/api/product/category.js
@@ -17,6 +17,14 @@ export function getCategory(id) {
})
}
+// 查询品类信息详细
+export function parentCommonElement(id) {
+ return request({
+ url: '/product/category/parentCommonElement/' + id,
+ method: 'get'
+ })
+}
+
// 新增品类信息
export function addCategory(data) {
return request({
diff --git a/src/components/CheckAttribute/index.vue b/src/components/CheckAttribute/index.vue
index 45d1076..5b20ab3 100644
--- a/src/components/CheckAttribute/index.vue
+++ b/src/components/CheckAttribute/index.vue
@@ -70,6 +70,10 @@ export default {
value: {
type: Array,
default: []
+ },
+ checkedList: {
+ type: Array,
+ default: null
}
},
watch: {
@@ -82,6 +86,15 @@ export default {
},
immediate: true,
},
+ checkedList: {
+ handler(val){
+ if (val !== undefined && val.length > 0){
+ this.checkedAttributeList = val;
+ this.attributeIdList = this.checkedAttributeList.map(checked => checked.id);
+ }
+ },
+ immediate: true
+ }
},
data() {
return {
diff --git a/src/components/CheckAttributeGroup/index.vue b/src/components/CheckAttributeGroup/index.vue
index 948298f..d857d81 100644
--- a/src/components/CheckAttributeGroup/index.vue
+++ b/src/components/CheckAttributeGroup/index.vue
@@ -67,6 +67,10 @@ export default {
value: {
type: Array,
default: []
+ },
+ checkedList: {
+ type: Array,
+ default: null
}
},
data() {
@@ -92,6 +96,15 @@ export default {
},
immediate: true,
},
+ checkedList: {
+ handler(val){
+ if (val !== undefined && val.length > 0){
+ this.checkedAttributeGroupList = val;
+ this.attributeGroupIdList = this.checkedAttributeGroupList.map(checked => checked.id);
+ }
+ },
+ immediate: true
+ }
},
created() {
this.queryAttributeGroup();
diff --git a/src/components/CheckBrand/index.vue b/src/components/CheckBrand/index.vue
index f229487..f0bfaa2 100644
--- a/src/components/CheckBrand/index.vue
+++ b/src/components/CheckBrand/index.vue
@@ -67,6 +67,10 @@ export default {
value: {
type: Array,
default: []
+ },
+ checkedList: {
+ type: Array,
+ default: null
}
},
data() {
@@ -92,6 +96,15 @@ export default {
},
immediate: true,
},
+ checkedList: {
+ handler(val){
+ if (val !== undefined && val.length > 0){
+ this.checkedBrandList = val;
+ this.brandIdList = this.checkedBrandList.map(checked => checked.id);
+ }
+ },
+ immediate: true
+ }
},
created() {
this.queryBrand();
diff --git a/src/views/product/category/index.vue b/src/views/product/category/index.vue
index 5adf2d6..977dd35 100644
--- a/src/views/product/category/index.vue
+++ b/src/views/product/category/index.vue
@@ -150,13 +150,13 @@
-
+
-
+
-
+
@@ -170,7 +170,14 @@