|
@ -329,6 +329,13 @@ public class BaseMenuManageService {
|
|
|
*/
|
|
|
@Transactional(rollbackFor = Exception.class)
|
|
|
public void updateStatus(String id,Integer status){
|
|
|
BaseMenuDictDO menuDictDO = baseMenuDictDao.findByIdAndDel(id);
|
|
|
if (menuDictDO.getParentId().equalsIgnoreCase("0")){
|
|
|
List<BaseMenuDictDO> baseMenuDictDOS = baseMenuDictDao.findByParentId(id);
|
|
|
for (BaseMenuDictDO menuDictDO1:baseMenuDictDOS){
|
|
|
baseMenuDictDao.updateStatus(menuDictDO1.getId(),status);
|
|
|
}
|
|
|
}
|
|
|
baseMenuDictDao.updateStatus(id,status);
|
|
|
}
|
|
|
//新增修改菜单
|
|
@ -947,7 +954,7 @@ public class BaseMenuManageService {
|
|
|
"\twlyy_knowledge_article_user kau\n" +
|
|
|
"LEFT JOIN wlyy_knowledge_article_dict kad ON kad.id = kau.relation_code\n" +
|
|
|
"WHERE\n" +
|
|
|
"\tkau.user_code = '"+userCode+"' AND kad.category_second IN(SELECT md.id from base_menu_dict md where md.status=1 and md.is_del= 1) ";
|
|
|
"\tkau.user_code = '"+userCode+"' AND kad.category_second IN(SELECT md.id from base_menu_dict md where md.status=1 and md.is_del= 1) AND kad.category_first IN(SELECT md.parent_id from base_menu_dict md where md.status=1 and md.is_del= 1) ";
|
|
|
String condition = "";
|
|
|
if (flag==1){
|
|
|
condition+=" and kau.fabulous = "+status;
|
|
@ -999,7 +1006,7 @@ public class BaseMenuManageService {
|
|
|
"\twlyy_knowledge_article_user kau\n" +
|
|
|
"LEFT JOIN wlyy_knowledge_article_dict kad ON kad.id = kau.relation_code \n" +
|
|
|
"WHERE\n" +
|
|
|
"\tkau.user_code = '"+userCode+"' AND kad.category_second IN(SELECT md.id from base_menu_dict md where md.status=1 and md.is_del= 1) ";
|
|
|
"\tkau.user_code = '"+userCode+"' AND kad.category_second IN(SELECT md.id from base_menu_dict md where md.status=1 and md.is_del= 1) AND kad.category_first IN(SELECT md.parent_id from base_menu_dict md where md.status=1 and md.is_del= 1) ";
|
|
|
String condition = "";
|
|
|
if (StringUtils.isNoneBlank(categoryFirst)){
|
|
|
condition =" and kad.category_first = '"+categoryFirst+"' ";
|
|
@ -1030,7 +1037,7 @@ public class BaseMenuManageService {
|
|
|
"\twlyy_knowledge_article_user kau\n" +
|
|
|
"LEFT JOIN wlyy_knowledge_article_dict kad ON kad.id = kau.relation_code \n" +
|
|
|
"WHERE\n" +
|
|
|
"\tkau.user_code = '"+userCode+"' ";
|
|
|
"\tkau.user_code = '"+userCode+"' AND kad.category_second IN(SELECT md.id from base_menu_dict md where md.status=1 and md.is_del= 1) AND kad.category_first IN(SELECT md.parent_id from base_menu_dict md where md.status=1 and md.is_del= 1) ";
|
|
|
List<Map<String,Object>> mapTotalList = hibenateUtils.createSQLQuery(sqlTotal+condition);
|
|
|
Long count = 0L;
|
|
|
if(mapTotalList!=null){
|