Skip to content

Commit 449aae9

Browse files
Fix: pid not set on category update in the admin, causing "参数不对" error message (#539)
1 parent 596a54d commit 449aae9

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

litemall-admin-api/src/main/java/org/linlinjava/litemall/admin/vo/CategoryVo.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ public class CategoryVo {
1010
private String iconUrl;
1111
private String picUrl;
1212
private String level;
13+
private Integer pid;
1314
private List<CategoryVo> children;
1415

1516
public List<CategoryVo> getChildren() {
@@ -75,4 +76,12 @@ public String getLevel() {
7576
public void setLevel(String level) {
7677
this.level = level;
7778
}
79+
80+
public Integer getPid() {
81+
return pid;
82+
}
83+
84+
public void setPid(Integer pid) {
85+
this.pid = pid;
86+
}
7887
}

litemall-admin-api/src/main/java/org/linlinjava/litemall/admin/web/AdminCategoryController.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ public Object list() {
5656
subCategoryVo.setKeywords(subCategory.getKeywords());
5757
subCategoryVo.setName(subCategory.getName());
5858
subCategoryVo.setLevel(subCategory.getLevel());
59+
subCategoryVo.setPid(subCategory.getPid());
5960

6061
children.add(subCategoryVo);
6162
}

0 commit comments

Comments
 (0)