zd_123 7 роки тому
батько
коміт
aad610819a

+ 2 - 2
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/account/PatientInfoService.java

@ -1812,9 +1812,9 @@ public class PatientInfoService extends BaseService {
        return patientList;
    }
    public List<Map<String,Object>> getPatientSignByDoctor(int pageNo,int pageSize,String keyWord,String doctor)throws Exception{
    public List<Map<String,Object>> getPatientSignByDoctor(int pageNo,int pageSize,String keyWord,String doctor,long teamCode)throws Exception{
        int start = (pageNo-1)*pageSize;
        String sql = "SELECT `name`,patient,mobile,idcard,openid FROM wlyy_sign_family WHERE `status`>0 AND (doctor='"+doctor+"' OR doctor_health='"+doctor+"')";
        String sql = "SELECT `name`,patient,mobile,idcard,openid FROM wlyy_sign_family WHERE `status`>0 AND (doctor='"+doctor+"' OR doctor_health='"+doctor+"') and admin_team_code = "+teamCode;
        if (StringUtils.isNotEmpty(keyWord)){
            sql += " and name LIKE '%"+keyWord+"%'";
        }

+ 8 - 3
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/survey/SurveyScreenResultService.java

@ -119,9 +119,14 @@ public class SurveyScreenResultService extends BaseService {
     * @param labelType
     * @return
     */
    public List<SurveyTemplates> getScreenList(int pageNo,int pageSize,int labelType){
    public List<SurveyTemplates> getScreenList(int pageNo,int pageSize,int labelType,String title){
        int start = (pageNo-1)*pageSize;
        String sql = "SELECT st.* FROM wlyy_survey_templates st LEFT JOIN wlyy_survey_label_info sli ON st.`code`= sli.relation_code WHERE st.del = 1 and sli.label="+labelType+" order by st.create_time desc limit "+start+","+pageSize;
        String sql = "SELECT st.* FROM wlyy_survey_templates st LEFT JOIN wlyy_survey_label_info sli ON st.`code`= sli.relation_code" +
                " WHERE st.del = 1 and sli.label="+labelType+"";
        if (StringUtils.isNotEmpty(title)){
            sql += " and st.title lile '%"+title+"%'";
        }
        sql += " order by st.create_time desc limit "+start+","+pageSize;
        List<SurveyTemplates> surveyTemplatesList = jdbcTemplate.query(sql,new BeanPropertyRowMapper<>(SurveyTemplates.class));
        return surveyTemplatesList;
    }
@ -333,7 +338,7 @@ public class SurveyScreenResultService extends BaseService {
    public Map<String,Object> patientGetList(int pageNo,int pageSize,int labelType,String patientCode){
        Map<String,Object> map = new HashedMap();
        List<SurveyTemplates> templates = getScreenList(pageNo,pageSize,labelType);
        List<SurveyTemplates> templates = getScreenList(pageNo,pageSize,labelType,null);
        List<Map<String,Object>> mapList = new ArrayList<>();
        for (SurveyTemplates surveyTemplates : templates){
            Map<String,Object> sMap = new HashedMap();

+ 2 - 1
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/patient/PatientInfoController.java

@ -575,6 +575,7 @@ public class PatientInfoController extends BaseController {
    @ResponseBody
    @ApiOperation("查询医生的签约居民")
    public String getPatientSignByDoctor(@ApiParam(value = "关键搜索词", name = "keyWord") @RequestParam(value = "keyWord",required = false,defaultValue = "")String keyWord,
                                         @ApiParam(value = "团队code", name = "teamCode") @RequestParam(value = "teamCode")long teamCode,
                                         @ApiParam(name="pageNo",value="第几页",defaultValue = "1") @RequestParam(value="pageNo",required = true) String pageNo,
                                         @ApiParam(name="pageSize",value="",defaultValue = "10") @RequestParam(value="pageSize",required = true) String pageSize){
        if (StringUtils.isBlank(pageSize)) {
@ -584,7 +585,7 @@ public class PatientInfoController extends BaseController {
            pageNo = "1";
        }
        try {
            return  write(200,"查找成功!","data",patientInfoService.getPatientSignByDoctor(Integer.parseInt(pageNo),Integer.parseInt(pageSize),keyWord,getUID()));
            return  write(200,"查找成功!","data",patientInfoService.getPatientSignByDoctor(Integer.parseInt(pageNo),Integer.parseInt(pageSize),keyWord,getUID(),teamCode));
        } catch (Exception e) {
            error(e);
            return error( -1, "查询失败!");

+ 4 - 3
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/survey/DoctorSurveyScreenResultController.java

@ -98,9 +98,10 @@ public class DoctorSurveyScreenResultController extends BaseController {
    @ResponseBody
    public String getScreenList(@ApiParam(value = "当前页")@RequestParam(value = "pageNo") int pageNo,
                                @ApiParam(value = "显示记录数")@RequestParam(value = "pageSize") int pageSize,
                                @ApiParam(value = "问卷类型标签")@RequestParam(value = "labelType") int labelType) {
                                @ApiParam(value = "问卷类型标签")@RequestParam(value = "labelType") int labelType,
                                @ApiParam(value = "问卷题目")@RequestParam(value = "title",required = false) String title) {
        try {
            return write(200, "获取成功!", "data", surveyScreenResultService.getScreenList(pageNo,pageSize,labelType));
            return write(200, "获取成功!", "data", surveyScreenResultService.getScreenList(pageNo,pageSize,labelType,title));
        } catch (Exception e) {
            e.printStackTrace();
            return write(-1, "获取失败!");
@ -135,7 +136,7 @@ public class DoctorSurveyScreenResultController extends BaseController {
    @ApiOperation(value = "医生跟踪")
    @ResponseBody
    public String updateAfterFollwoing(@ApiParam(value = "筛查记录code")@RequestParam(value = "code") String code,
                                    @ApiParam(value = "建议code,多个逗号隔开")@RequestParam(value = "advicCcodes") String advicCcodes,
                                    @ApiParam(value = "建议code,多个逗号隔开")@RequestParam(value = "adviceCodes") String advicCcodes,
                                    @ApiParam(value = "其他建议")@RequestParam(value = "otherAdvice",required = false) String otherAdvice) {
        try {
            surveyScreenResultService.updateAfterFollowing(code,advicCcodes,otherAdvice);