diff --git a/litemall-admin/src/views/goods/create.vue b/litemall-admin/src/views/goods/create.vue index 0d9d4dbb..47866593 100644 --- a/litemall-admin/src/views/goods/create.vue +++ b/litemall-admin/src/views/goods/create.vue @@ -39,15 +39,15 @@ - - + + - + diff --git a/litemall-admin/src/views/mall/brand.vue b/litemall-admin/src/views/mall/brand.vue index 29f7202f..abb3b456 100644 --- a/litemall-admin/src/views/mall/brand.vue +++ b/litemall-admin/src/views/mall/brand.vue @@ -187,7 +187,7 @@ export default { }) }, uploadPicUrl: function(response) { - this.dataForm.picUrl = response.data.data.url + this.dataForm.picUrl = response.data.url }, createData() { this.$refs['dataForm'].validate((valid) => { diff --git a/litemall-admin/src/views/mall/category.vue b/litemall-admin/src/views/mall/category.vue index 10d9ba23..bbea19ea 100644 --- a/litemall-admin/src/views/mall/category.vue +++ b/litemall-admin/src/views/mall/category.vue @@ -74,7 +74,7 @@ - + @@ -164,7 +164,7 @@ export default { name: '', keyword: '', level: 'L2', - pid: 1005000, + pid: undefined, desc: '', iconUrl: undefined, picUrl: undefined @@ -221,15 +221,20 @@ export default { name: '', keyword: '', level: 'L2', - pid: 1005000, + pid: undefined, desc: '', iconUrl: undefined, picUrl: undefined } }, - filterLevel(value, row) { + filterLevel: function(value, row) { return row.level === value }, + onLevelChange: function(value) { + if (value === 'L1') { + this.pid = undefined + } + }, handleCreate() { this.resetForm() this.dialogStatus = 'create' @@ -239,10 +244,10 @@ export default { }) }, uploadIconUrl: function(response) { - this.dataForm.iconUrl = response.data.data.url + this.dataForm.iconUrl = response.data.url }, uploadPicUrl: function(response) { - this.dataForm.picUrl = response.data.data.url + this.dataForm.picUrl = response.data.url }, createData() { this.$refs['dataForm'].validate((valid) => {