|
@ -1,10 +1,13 @@
|
|
//package com.yihu.wlyy.web.patient.prenatalInspector;
|
|
//package com.yihu.wlyy.web.patient.prenatalInspector;
|
|
//
|
|
//
|
|
|
|
//import com.alibaba.fastjson.JSONArray;
|
|
//import com.alibaba.fastjson.JSONObject;
|
|
//import com.alibaba.fastjson.JSONObject;
|
|
|
|
//import com.yihu.wlyy.service.app.prenatalInspector.ChildImmuneService;
|
|
//import com.yihu.wlyy.web.BaseController;
|
|
//import com.yihu.wlyy.web.BaseController;
|
|
//import io.swagger.annotations.Api;
|
|
//import io.swagger.annotations.Api;
|
|
//import io.swagger.annotations.ApiOperation;
|
|
//import io.swagger.annotations.ApiOperation;
|
|
//import io.swagger.annotations.ApiParam;
|
|
//import io.swagger.annotations.ApiParam;
|
|
|
|
//import org.springframework.beans.factory.annotation.Autowired;
|
|
//import org.springframework.http.MediaType;
|
|
//import org.springframework.http.MediaType;
|
|
//import org.springframework.web.bind.annotation.RequestMapping;
|
|
//import org.springframework.web.bind.annotation.RequestMapping;
|
|
//import org.springframework.web.bind.annotation.RequestMethod;
|
|
//import org.springframework.web.bind.annotation.RequestMethod;
|
|
@ -19,14 +22,19 @@
|
|
//@Api(description = "患者端-免疫")
|
|
//@Api(description = "患者端-免疫")
|
|
//public class ChildImmuneController extends BaseController{
|
|
//public class ChildImmuneController extends BaseController{
|
|
//
|
|
//
|
|
|
|
// @Autowired
|
|
|
|
// private ChildImmuneService childImmuneService;
|
|
//
|
|
//
|
|
//
|
|
//
|
|
// @ApiOperation("获取儿童信息")
|
|
// @ApiOperation("获取儿童信息")
|
|
// @RequestMapping(value = "findChildInfo", method = RequestMethod.GET)
|
|
// @RequestMapping(value = "findChildInfo", method = RequestMethod.GET)
|
|
// public String findChildInfo(@ApiParam(name = "pregnancyNo", value = "产检号", defaultValue = "")
|
|
|
|
// @RequestParam(value = "pregnancyNo", required = true) String pregnancyNo){
|
|
|
|
|
|
// public String findChildInfo(@ApiParam(name = "barcodeNo", value = "儿童条形码", defaultValue = "")
|
|
|
|
// @RequestParam(value = "barcodeNo", required = true) String barcodeNo){
|
|
// try {
|
|
// try {
|
|
// JSONObject jsonObject = null;
|
|
|
|
|
|
// JSONObject jsonObject = childImmuneService.findChildInfo(barcodeNo,getUID());
|
|
|
|
// if(jsonObject.size()==0){
|
|
|
|
// return error(-1,"条码有误,请重新确认");
|
|
|
|
// }
|
|
// return write(200, "查询成功!", "data", jsonObject);
|
|
// return write(200, "查询成功!", "data", jsonObject);
|
|
// }catch (Exception e){
|
|
// }catch (Exception e){
|
|
// error(e);
|
|
// error(e);
|
|
@ -35,19 +43,36 @@
|
|
// }
|
|
// }
|
|
//
|
|
//
|
|
// @ApiOperation("绑定儿童关联")
|
|
// @ApiOperation("绑定儿童关联")
|
|
// @RequestMapping(value = "findChildInfo", method = RequestMethod.GET)
|
|
|
|
// public String bindChildInfo(@ApiParam(name = "pregnancyNo", value = "产检号", defaultValue = "")
|
|
|
|
// @RequestParam(value = "pregnancyNo", required = true) String pregnancyNo){
|
|
|
|
|
|
// @RequestMapping(value = "bindChildInfo", method = RequestMethod.POST)
|
|
|
|
// public String bindChildInfo(@ApiParam(name = "barcodeNo", value = "儿童条形码", defaultValue = "")
|
|
|
|
// @RequestParam(value = "barcodeNo", required = true) String barcodeNo){
|
|
// try {
|
|
// try {
|
|
// JSONObject jsonObject = null;
|
|
|
|
//
|
|
|
|
|
|
// Integer status = childImmuneService.bindChildInfo(barcodeNo,getUID());
|
|
|
|
// if(status==-1){
|
|
|
|
// return error(-1,"绑定失败,儿童信息已被其他居民绑定");
|
|
|
|
// }else if(status==-2){
|
|
|
|
// return error(-1,"已绑定成功,请不要重复绑定");
|
|
|
|
// }else {
|
|
|
|
// return success("绑定成功!");
|
|
|
|
// }
|
|
//
|
|
//
|
|
|
|
// }catch (Exception e){
|
|
|
|
// error(e);
|
|
|
|
// return error(-1,"绑定失败");
|
|
|
|
// }
|
|
|
|
// }
|
|
//
|
|
//
|
|
// return write(200, "查询成功!", "data", jsonObject);
|
|
|
|
|
|
// @ApiOperation("获取免疫关联的家人")
|
|
|
|
// @RequestMapping(value = "bindChildInfo", method = RequestMethod.GET)
|
|
|
|
// public String getImmuneFamily(){
|
|
|
|
// try {
|
|
|
|
// JSONArray response = childImmuneService.getImmuneFamily(getUID());
|
|
|
|
// return write(200, "查询成功!", "list", response);
|
|
// }catch (Exception e){
|
|
// }catch (Exception e){
|
|
// error(e);
|
|
// error(e);
|
|
// return error(-1,"查询失败");
|
|
|
|
|
|
// return error(-1,"绑定失败");
|
|
// }
|
|
// }
|
|
// }
|
|
// }
|
|
//
|
|
//
|
|
|
|
//
|
|
//}
|
|
//}
|