mirror of
https://github.com/bufanyun/hotgo.git
synced 2025-11-10 03:03:44 +08:00
优化菜单、省市区树结构排序,修复部门搜索空指针问题
This commit is contained in:
@@ -79,7 +79,7 @@ func (c *cDept) List(ctx context.Context, req *dept.ListReq) (res *dept.ListRes,
|
||||
}
|
||||
|
||||
data, err := service.AdminDept().List(ctx, in)
|
||||
if err != nil {
|
||||
if err != nil || data == nil {
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
@@ -62,6 +62,6 @@ func (c *cMenu) List(ctx context.Context, req *menu.ListReq) (res menu.ListRes,
|
||||
return
|
||||
}
|
||||
|
||||
res.List, err = service.AdminMenu().List(ctx, in)
|
||||
res.MenuListModel, err = service.AdminMenu().List(ctx, in)
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user