品类增删改查
parent
095fc4d78a
commit
8dbfac5726
|
@ -307,10 +307,9 @@ export default {
|
|||
* @param index
|
||||
*/
|
||||
removeChecked(index){
|
||||
console.log(this.form.attributeIdList)
|
||||
this.checkedAttributeList.splice(index, 1);
|
||||
this.form.attributeIdList.splice(index, 1);
|
||||
console.log(this.form.attributeIdList)
|
||||
console.log(index)
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
|
@ -217,6 +217,9 @@ export default {
|
|||
},
|
||||
// 表单参数
|
||||
form: {
|
||||
attributeInfoList: [],
|
||||
attributeGroupList: [],
|
||||
brandInfoList: []
|
||||
},
|
||||
// 表单校验
|
||||
rules: {
|
||||
|
@ -249,9 +252,13 @@ export default {
|
|||
handler(val){
|
||||
if (val !== undefined && val !== 0){
|
||||
parentCommonElement(val).then(response => {
|
||||
console.log(response)
|
||||
this.attributeInfoList = response.data.attributeInfoList;
|
||||
this.attributeGroupList = response.data.attributeGroupList;
|
||||
this.brandInfoList = response.data.brandInfoList;
|
||||
console.log(val)
|
||||
console.log(this.attributeGroupList)
|
||||
console.log(this.brandInfoList)
|
||||
})
|
||||
}
|
||||
},
|
||||
|
@ -309,7 +316,10 @@ export default {
|
|||
createBy: null,
|
||||
createTime: null,
|
||||
updateBy: null,
|
||||
updateTime: null
|
||||
updateTime: null,
|
||||
attributeInfoList: [],
|
||||
attributeGroupList: [],
|
||||
brandInfoList: []
|
||||
};
|
||||
this.resetForm("form");
|
||||
},
|
||||
|
@ -324,6 +334,7 @@ export default {
|
|||
},
|
||||
/** 新增按钮操作 */
|
||||
handleAdd(row) {
|
||||
console.log(row)
|
||||
this.reset();
|
||||
this.getTreeselect();
|
||||
if (row != null && row.id) {
|
||||
|
@ -348,7 +359,6 @@ export default {
|
|||
this.getTreeselect();
|
||||
if (row != null) {
|
||||
this.form.parentId = row.parentId;
|
||||
this.form.attributeIdList
|
||||
}
|
||||
getCategory(row.id).then(response => {
|
||||
this.form = response.data;
|
||||
|
|
Loading…
Reference in New Issue