|
@@ -123,9 +123,10 @@ export default {
|
|
|
this.$emit('close')
|
|
|
this.$refs.ruleForm.resetFields()
|
|
|
} else {
|
|
|
+ console.log(this.nowData)
|
|
|
// 获取父级分类 名称
|
|
|
- if (this.nowData && this.nowData.namePaths) {
|
|
|
- this.parentType = this.nowData.namePaths.replace(/,/g, '>') + '>' + this.nowData.name
|
|
|
+ if (this.nowData) {
|
|
|
+ this.parentType = (this.nowData.namePaths ? (this.nowData.namePaths.replace(/,/g, '>') + '>') : '') + this.nowData.name
|
|
|
} else {
|
|
|
this.parentType = ''
|
|
|
}
|