|
@ -81,6 +81,7 @@ import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
import io.swagger.annotations.ApiParam;
|
|
|
import net.sf.json.JSONArray;
|
|
|
import net.sf.json.xml.XMLSerializer;
|
|
|
import org.apache.axis.utils.StringUtils;
|
|
|
import org.apache.commons.collections.map.HashedMap;
|
|
|
import org.apache.http.NameValuePair;
|
|
@ -2276,6 +2277,12 @@ public class PatientNoLoginEndPoint extends EnvelopRestEndpoint {
|
|
|
if ("tmpPush".equalsIgnoreCase(api)){
|
|
|
return success("操作成功",tasyNatService.tmpPush(jsonObject));
|
|
|
}
|
|
|
if ("CancleOrder".equalsIgnoreCase(api)){
|
|
|
return success("操作成功",tasyNatService.cancleOrder(jsonObject.getString("HisID"),jsonObject.getString("no"),jsonObject.getString("OrderNumber")));
|
|
|
}
|
|
|
if ("GetOrderInfo".equalsIgnoreCase(api)){
|
|
|
return success("操作成功",tasyNatService.GetOrderInfo(jsonObject.getString("HisID"),jsonObject.getString("ApplyType")));
|
|
|
}
|
|
|
return success("");
|
|
|
} catch (Exception e){
|
|
|
return failedException(e);
|
|
@ -2401,4 +2408,87 @@ public class PatientNoLoginEndPoint extends EnvelopRestEndpoint {
|
|
|
return Envelop.getError(e.getMessage());
|
|
|
}
|
|
|
}
|
|
|
@GetMapping("/BS10142")
|
|
|
public ListEnvelop BS10142(
|
|
|
@ApiParam(name = "deptCode", value = "deptCode")
|
|
|
@RequestParam(value = "deptCode",required = false)String deptCode,
|
|
|
@ApiParam(name = "docCode", value = "docCode")
|
|
|
@RequestParam(value = "docCode",required = false)String docCode,
|
|
|
@ApiParam(name = "chargeType", value = "chargeType")
|
|
|
@RequestParam(value = "chargeType",required = false)String chargeType) throws Exception {
|
|
|
if("xm_zsyy_wx".equalsIgnoreCase(wxId)){
|
|
|
return success(entranceService.BS10142(deptCode,docCode,chargeType,false));
|
|
|
}else if ("xm_tasy_wx".equalsIgnoreCase(wxId)){
|
|
|
String res=tasyNatService.departMent(deptCode);
|
|
|
String dept="";
|
|
|
JSONObject deptres = JSON.parseObject(res);
|
|
|
if (deptres!=null){
|
|
|
if (deptres.getString("success").equalsIgnoreCase("true")){
|
|
|
JSONObject data = JSON.parseObject(deptres.getString("data"));
|
|
|
dept=data.getString("Dept");
|
|
|
com.alibaba.fastjson.JSONArray jsonArray1 = JSON.parseArray(dept);
|
|
|
if (jsonArray1!=null&&jsonArray1.size()>0){
|
|
|
JSONObject jsonObject = jsonArray1.getJSONObject(0);
|
|
|
dept=jsonObject.getString("Id");
|
|
|
System.out.println(dept);
|
|
|
}
|
|
|
String json=tasyNatService.GetDoctorWorkDate("3",dept);
|
|
|
JSONObject jsonObject = JSON.parseObject(json);
|
|
|
jsonObject.put("dept",dept);
|
|
|
com.alibaba.fastjson.JSONArray jsonArray = new com.alibaba.fastjson.JSONArray();
|
|
|
jsonArray.add(jsonObject);
|
|
|
return success(jsonArray);
|
|
|
}else {
|
|
|
return ListEnvelop.getError("获取部门编码失败");
|
|
|
}
|
|
|
}else {
|
|
|
return ListEnvelop.getError("无效部门");
|
|
|
}
|
|
|
}else {
|
|
|
return ListEnvelop.getError("未开放");
|
|
|
}
|
|
|
|
|
|
}
|
|
|
@GetMapping("/BS10143")
|
|
|
public ListEnvelop BS10143(@ApiParam(name = "day", value = "day")
|
|
|
@RequestParam(value = "day",required = false)String day,
|
|
|
@ApiParam(name = "dept", value = "dept")
|
|
|
@RequestParam(value = "dept",required = false)String dept,
|
|
|
@ApiParam(name = "doctor", value = "doctor")
|
|
|
@RequestParam(value = "doctor",required = false)String doctor,
|
|
|
@ApiParam(name = "IsAll", value = "IsAll")
|
|
|
@RequestParam(value = "IsAll",required = false)String IsAll,
|
|
|
@ApiParam(name = "pm", value = "pm")
|
|
|
@RequestParam(value = "pm",required = false)String pm) throws Exception {
|
|
|
if("xm_zsyy_wx".equalsIgnoreCase(wxId)){
|
|
|
return success(entranceService.BS10143(day,pm,false));
|
|
|
}else if ("xm_tasy_wx".equalsIgnoreCase(wxId)){
|
|
|
String res=tasyNatService.GetOrderSource(dept,doctor,day,"3",IsAll,pm);
|
|
|
String xml="";
|
|
|
if (!StringUtils.isEmpty(res)){
|
|
|
JSONObject jsonObject = JSON.parseObject(res);
|
|
|
System.out.println("====="+jsonObject.getString("success"));
|
|
|
if (jsonObject!=null&&jsonObject.getString("success").equalsIgnoreCase("true")){
|
|
|
xml=jsonObject.getString("data");
|
|
|
XMLSerializer xmlSerializer = new XMLSerializer();
|
|
|
String json = xmlSerializer.read(xml).toString();
|
|
|
JSONObject jsonObjectRes = JSON.parseObject(json);
|
|
|
com.alibaba.fastjson.JSONArray jsonArray = new com.alibaba.fastjson.JSONArray();
|
|
|
jsonArray.add(jsonObjectRes);
|
|
|
return success(jsonArray);
|
|
|
}
|
|
|
}
|
|
|
return ListEnvelop.getError("查询失败");
|
|
|
}else {
|
|
|
return ListEnvelop.getError("未开放");
|
|
|
}
|
|
|
|
|
|
}
|
|
|
@GetMapping("/DepartMent")
|
|
|
public Envelop DepartMent(
|
|
|
@ApiParam(name = "DepartMent", value = "DepartMent")
|
|
|
@RequestParam(value = "DepartMent",required = false)String DepartMent) throws Exception {
|
|
|
return success("查询成功",tasyNatService.departMent(DepartMent));
|
|
|
|
|
|
}
|
|
|
}
|