|
|
@ -195,6 +195,61 @@ public class SysFloatingColumnSchemeServiceImpl extends ServiceImpl<SysFloatingC |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
|
|
|
|
public R columnDisplayFloatingBar(String columnId) { |
|
|
|
|
|
|
|
List<SysFloatingColumnSchemeModule> columnSchemeModuleList = new ArrayList<>(); |
|
|
|
|
|
|
|
//获取站点
|
|
|
|
|
|
|
|
SysColumn column = columnMapper.selectById(columnId); |
|
|
|
|
|
|
|
if (ObjectUtil.isEmpty(column)) { |
|
|
|
|
|
|
|
return R.fail("未找到该栏目"); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//查询当前站点下已启用,且已发布的悬浮栏
|
|
|
|
|
|
|
|
List<SysFloatingColumnScheme> floatingColumnSchemeList = baseMapper.selectList(new LambdaQueryWrapper<SysFloatingColumnScheme>() |
|
|
|
|
|
|
|
.eq(SysFloatingColumnScheme::getSiteId, column.getSiteId()) |
|
|
|
|
|
|
|
.eq(SysFloatingColumnScheme::getIsDisable, 0) |
|
|
|
|
|
|
|
.eq(SysFloatingColumnScheme::getStatus, 1)); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for (SysFloatingColumnScheme scheme : floatingColumnSchemeList) { |
|
|
|
|
|
|
|
//判断当前启用的栏目如果为全局的直接返回全局的已启用的方案
|
|
|
|
|
|
|
|
if (scheme.getIsGlobal() == 1) { |
|
|
|
|
|
|
|
//查询悬浮栏当前绑定的方案
|
|
|
|
|
|
|
|
List<SysFloatingColumnSchemeModule> columnSchemeModule = floatingColumnSchemeModuleMapper.selectList(new LambdaQueryWrapper<SysFloatingColumnSchemeModule>() |
|
|
|
|
|
|
|
.eq(SysFloatingColumnSchemeModule::getFloatingBarSchemeId, scheme.getId()).eq(SysFloatingColumnSchemeModule::getIsDisable, 0)); |
|
|
|
|
|
|
|
; |
|
|
|
|
|
|
|
if (!ObjectUtil.isEmpty(columnSchemeModule)) { |
|
|
|
|
|
|
|
return R.success(columnSchemeModule); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
}else{ |
|
|
|
|
|
|
|
//查询栏目绑定过的悬浮栏
|
|
|
|
|
|
|
|
List<Integer> floatingBarIds = scopeOfApplicationMapper.checkBoundByColumnId(columnId); |
|
|
|
|
|
|
|
//查询悬浮栏绑定的方案
|
|
|
|
|
|
|
|
for (Integer floatingBarId: floatingBarIds) { |
|
|
|
|
|
|
|
List<SysFloatingColumnSchemeModule> list = floatingColumnSchemeModuleMapper.selectList(new LambdaQueryWrapper<SysFloatingColumnSchemeModule>() |
|
|
|
|
|
|
|
.eq(SysFloatingColumnSchemeModule::getFloatingBarSchemeId, floatingBarId).eq(SysFloatingColumnSchemeModule::getIsDisable, 0)); |
|
|
|
|
|
|
|
columnSchemeModuleList.addAll(list); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return R.success(columnSchemeModuleList); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return R.success(columnSchemeModuleList); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*@Override |
|
|
|
public R columnDisplayFloatingBar(String columnId) { |
|
|
|
public R columnDisplayFloatingBar(String columnId) { |
|
|
|
//获取站点
|
|
|
|
//获取站点
|
|
|
|
SysColumn column = columnMapper.selectById(columnId); |
|
|
|
SysColumn column = columnMapper.selectById(columnId); |
|
|
@ -203,10 +258,12 @@ public class SysFloatingColumnSchemeServiceImpl extends ServiceImpl<SysFloatingC |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
//查询范围应用为栏目的
|
|
|
|
//查询范围应用为栏目的
|
|
|
|
/* List<SysFloatingColumnSchemeScopeOfApplication> sysFloatingColumnSchemeScopeOfApplications = scopeOfApplicationMapper.selectList(new LambdaQueryWrapper<SysFloatingColumnSchemeScopeOfApplication>() |
|
|
|
*//* List<SysFloatingColumnSchemeScopeOfApplication> sysFloatingColumnSchemeScopeOfApplications = scopeOfApplicationMapper.selectList(new LambdaQueryWrapper<SysFloatingColumnSchemeScopeOfApplication>()
|
|
|
|
.eq(SysFloatingColumnSchemeScopeOfApplication::getFloatingBarSchemeId, columnId) |
|
|
|
.eq(SysFloatingColumnSchemeScopeOfApplication::getFloatingBarSchemeId, columnId) |
|
|
|
); |
|
|
|
); |
|
|
|
*/ |
|
|
|
*//*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//查询栏目绑定过的悬浮栏
|
|
|
|
//查询栏目绑定过的悬浮栏
|
|
|
|
List<Integer> sysFloatingColumnSchemeScopeOfApplications = scopeOfApplicationMapper.checkBoundByColumnId(columnId); |
|
|
|
List<Integer> sysFloatingColumnSchemeScopeOfApplications = scopeOfApplicationMapper.checkBoundByColumnId(columnId); |
|
|
@ -235,7 +292,7 @@ public class SysFloatingColumnSchemeServiceImpl extends ServiceImpl<SysFloatingC |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return R.success(columnSchemeModuleList); |
|
|
|
return R.success(columnSchemeModuleList); |
|
|
|
} |
|
|
|
}*/ |
|
|
|
|
|
|
|
|
|
|
|
// 辅助方法检查站点下是否存在启用的全局悬浮栏
|
|
|
|
// 辅助方法检查站点下是否存在启用的全局悬浮栏
|
|
|
|
private boolean existsEnabledGlobal(Integer siteId) { |
|
|
|
private boolean existsEnabledGlobal(Integer siteId) { |
|
|
|