|
@ -19,9 +19,11 @@ import com.yihu.jw.entity.hospital.consult.WlyyHospitalSysDictDO;
|
|
import com.yihu.jw.hospital.dict.WlyyHospitalSysDictDao;
|
|
import com.yihu.jw.hospital.dict.WlyyHospitalSysDictDao;
|
|
import com.yihu.jw.patient.dao.BasePatientDao;
|
|
import com.yihu.jw.patient.dao.BasePatientDao;
|
|
import com.yihu.jw.restmodel.web.MixEnvelop;
|
|
import com.yihu.jw.restmodel.web.MixEnvelop;
|
|
|
|
import com.yihu.jw.utils.DmDBUtl;
|
|
import com.yihu.jw.utils.hibernate.HibenateUtils;
|
|
import com.yihu.jw.utils.hibernate.HibenateUtils;
|
|
import org.apache.commons.lang3.StringUtils;
|
|
import org.apache.commons.lang3.StringUtils;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
import org.springframework.jdbc.core.BeanPropertyRowMapper;
|
|
import org.springframework.jdbc.core.BeanPropertyRowMapper;
|
|
import org.springframework.jdbc.core.JdbcTemplate;
|
|
import org.springframework.jdbc.core.JdbcTemplate;
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
@ -60,7 +62,8 @@ public class BaseMenuManageService {
|
|
private KnowledgeArticleDoctorDao knowledgeArticleDoctorDao;
|
|
private KnowledgeArticleDoctorDao knowledgeArticleDoctorDao;
|
|
@Autowired
|
|
@Autowired
|
|
private KnowledgeArticleBrowseDao knowledgeArticleBrowseDao;
|
|
private KnowledgeArticleBrowseDao knowledgeArticleBrowseDao;
|
|
|
|
|
|
|
|
@Value("${wechat.id}")
|
|
|
|
private String wxId;
|
|
|
|
|
|
/**
|
|
/**
|
|
*
|
|
*
|
|
@ -743,7 +746,7 @@ public class BaseMenuManageService {
|
|
return list;
|
|
return list;
|
|
}
|
|
}
|
|
|
|
|
|
public MixEnvelop findArticleByMenuId(String menuId,String title,Integer page,Integer pageSize,String isContent){
|
|
|
|
|
|
public MixEnvelop findArticleByMenuId(String menuId,String title,Integer page,Integer pageSize,String isContent,String articleType){
|
|
List<String> menuIds = new ArrayList<>();
|
|
List<String> menuIds = new ArrayList<>();
|
|
if (StringUtils.isNoneBlank(menuId)){
|
|
if (StringUtils.isNoneBlank(menuId)){
|
|
String str[]= menuId.split(",");
|
|
String str[]= menuId.split(",");
|
|
@ -751,6 +754,20 @@ public class BaseMenuManageService {
|
|
menuIds.add(str[i]);
|
|
menuIds.add(str[i]);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
if(StringUtils.isNotBlank(articleType)){
|
|
|
|
if(StringUtils.isBlank(menuId)){
|
|
|
|
menuId = "";
|
|
|
|
}
|
|
|
|
String sqlType = "select * from base_menu_dict where article_type='"+articleType+"' and is_del='1' and status=1";
|
|
|
|
List<BaseMenuDictDO> menuDictDOS = jdbcTemplate.query(sqlType,new BeanPropertyRowMapper<>(BaseMenuDictDO.class));
|
|
|
|
if(menuDictDOS.size()>0){
|
|
|
|
for (BaseMenuDictDO menuDictDO:menuDictDOS){
|
|
|
|
menuIds.add(menuDictDO.getId());
|
|
|
|
menuId +=",";
|
|
|
|
}
|
|
|
|
menuId = menuId.substring(0,menuId.length()-1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
System.out.print("menuId"+menuId);
|
|
System.out.print("menuId"+menuId);
|
|
Integer count;
|
|
Integer count;
|
|
@ -789,7 +806,7 @@ public class BaseMenuManageService {
|
|
" read_count,\n" +
|
|
" read_count,\n" +
|
|
" collection,\n" +
|
|
" collection,\n" +
|
|
" fabulous,\n" +
|
|
" fabulous,\n" +
|
|
" comment,\n" +
|
|
|
|
|
|
DmDBUtl.changeField("comment",wxId)+" ," +
|
|
" is_share,\n" +
|
|
" is_share,\n" +
|
|
" create_user_name ,\n" +
|
|
" create_user_name ,\n" +
|
|
" create_user_dept ,\n" +
|
|
" create_user_dept ,\n" +
|
|
@ -1013,7 +1030,7 @@ public class BaseMenuManageService {
|
|
if (flag==5){
|
|
if (flag==5){
|
|
condition+=" and kau.is_read = "+status;
|
|
condition+=" and kau.is_read = "+status;
|
|
}
|
|
}
|
|
condition += " GROUP BY kad.category_first ";
|
|
|
|
|
|
condition += " GROUP BY kad.category_first,kad.category_first_name,kad.category_second,kad.category_second_name ";
|
|
List<Map<String,Object>> mapList = jdbcTemplate.queryForList(sql+condition);
|
|
List<Map<String,Object>> mapList = jdbcTemplate.queryForList(sql+condition);
|
|
return mapList;
|
|
return mapList;
|
|
}
|
|
}
|