|
@ -65,14 +65,21 @@ public class SignPatientLabelInfoController extends BaseController {
|
|
* @return
|
|
* @return
|
|
*/
|
|
*/
|
|
@RequestMapping(value = "/patients_by_team")
|
|
@RequestMapping(value = "/patients_by_team")
|
|
public String getPatientInfoByTeam(Long teamCode,int page,int pagesize){
|
|
|
|
|
|
public String getPatientInfoByTeam(Long teamCode,
|
|
|
|
@RequestParam(required = false) String exLabelCode,
|
|
|
|
@RequestParam(required = false) String exLabelType,
|
|
|
|
int page, int pagesize) {
|
|
try {
|
|
try {
|
|
if (teamCode == null || teamCode < 1) {
|
|
if (teamCode == null || teamCode < 1) {
|
|
return error(-1, "团队cdoe不能为空");
|
|
return error(-1, "团队cdoe不能为空");
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (!StringUtils.isEmpty(exLabelCode) && StringUtils.isEmpty(exLabelType)) {
|
|
|
|
return error(-1, "过滤标签参数不为空时过滤标签类型不能为空");
|
|
|
|
}
|
|
|
|
|
|
page = page - 1;
|
|
page = page - 1;
|
|
JSONArray result = labelInfoService.getPatientByTeamCode(getUID(), teamCode, page, pagesize);
|
|
|
|
|
|
JSONArray result = labelInfoService.getPatientByTeamCode(getUID(), teamCode, exLabelCode,exLabelType,page, pagesize);
|
|
|
|
|
|
return write(200, "查询成功", "data", result);
|
|
return write(200, "查询成功", "data", result);
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
@ -177,10 +184,13 @@ public class SignPatientLabelInfoController extends BaseController {
|
|
* @return
|
|
* @return
|
|
*/
|
|
*/
|
|
@RequestMapping(value = "/patient_search")
|
|
@RequestMapping(value = "/patient_search")
|
|
public String searchPatientByNameOrLabel(String filter, @RequestParam(required = false)String labelCode,
|
|
|
|
@RequestParam(required = false)String labelType,
|
|
|
|
|
|
public String searchPatientByNameOrLabel(String filter,
|
|
|
|
@RequestParam(required = false) String labelCode,
|
|
|
|
@RequestParam(required = false) String labelType,
|
|
@RequestParam(required = false) Long teamCode,
|
|
@RequestParam(required = false) Long teamCode,
|
|
int page,int pagesize) {
|
|
|
|
|
|
@RequestParam(required = false) String exLabelCode,
|
|
|
|
@RequestParam(required = false) String exLabelType,
|
|
|
|
int page, int pagesize) {
|
|
try {
|
|
try {
|
|
if (StringUtils.isEmpty(filter)) {
|
|
if (StringUtils.isEmpty(filter)) {
|
|
return error(-1, "搜索字段不能为空");
|
|
return error(-1, "搜索字段不能为空");
|
|
@ -190,13 +200,17 @@ public class SignPatientLabelInfoController extends BaseController {
|
|
return error(-1, "标签参数不为空时标签类型不能为空");
|
|
return error(-1, "标签参数不为空时标签类型不能为空");
|
|
}
|
|
}
|
|
|
|
|
|
if(teamCode == null){
|
|
|
|
|
|
if (!StringUtils.isEmpty(exLabelCode) && StringUtils.isEmpty(exLabelType)) {
|
|
|
|
return error(-1, "过滤标签参数不为空时过滤标签类型不能为空");
|
|
|
|
}
|
|
|
|
|
|
|
|
if (teamCode == null) {
|
|
teamCode = 0L;
|
|
teamCode = 0L;
|
|
}
|
|
}
|
|
|
|
|
|
page = page - 1;
|
|
page = page - 1;
|
|
|
|
|
|
JSONArray result = labelInfoService.searchPatientByNameOrLabel(getUID(), filter, labelCode, labelType,teamCode,page,pagesize);
|
|
|
|
|
|
JSONArray result = labelInfoService.searchPatientByNameOrLabel(getUID(), filter, labelCode, labelType, teamCode, exLabelCode, exLabelType, page, pagesize);
|
|
|
|
|
|
return write(200, "查询成功", "data", result);
|
|
return write(200, "查询成功", "data", result);
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|