开关标识
This commit is contained in:
@@ -31,16 +31,19 @@ public class QuickMenuController {
|
||||
|
||||
@SaAdminCheckPermission(parentName = "悬浮窗", value = "quick:list", name = "悬浮窗-列表")
|
||||
@GetMapping
|
||||
public CzgResult<List<QuickMenu>> getQuickList(Integer status) {
|
||||
public CzgResult<List<QuickMenu>> getQuickList(@RequestParam(required = false) Integer status,
|
||||
@RequestParam(required = false, defaultValue = "0") Integer isEdit) {
|
||||
List<QuickMenu> list = quickMenuService.list(QueryWrapper.create()
|
||||
.eq(QuickMenu::getShopId, StpKit.USER.getShopId())
|
||||
.eq(QuickMenu::getStatus, status)
|
||||
.orderBy(QuickMenu::getSort, true));
|
||||
if (CollUtil.isEmpty(list)) {
|
||||
list = quickMenuService.list(QueryWrapper.create()
|
||||
.eq(QuickMenu::getShopId, 1)
|
||||
.eq(QuickMenu::getStatus, status)
|
||||
.orderBy(QuickMenu::getSort, true));
|
||||
if (isEdit.equals(0)) {
|
||||
if (CollUtil.isEmpty(list)) {
|
||||
list = quickMenuService.list(QueryWrapper.create()
|
||||
.eq(QuickMenu::getShopId, 1)
|
||||
.eq(QuickMenu::getStatus, status)
|
||||
.orderBy(QuickMenu::getSort, true));
|
||||
}
|
||||
}
|
||||
return CzgResult.success(list);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user