|
@ -67,10 +67,6 @@ public class DoorOrderService {
|
|
|
|
|
|
@Autowired
|
|
|
private HttpClientUtil httpClientUtil;
|
|
|
// @Value("${sign.check_upload}")
|
|
|
private String jwUrl;
|
|
|
// @Value("${server.server_url}")
|
|
|
private String wxServerUrl;
|
|
|
//图片服务地址
|
|
|
@Value("${fastDFS.fastdfs_file_url}")
|
|
|
private String imgUrlDomain;
|
|
@ -99,7 +95,6 @@ public class DoorOrderService {
|
|
|
|
|
|
@Autowired
|
|
|
private DoorServiceVoucherDao doorServiceVoucherDao;
|
|
|
|
|
|
@Autowired
|
|
|
private SystemMessageDao systemMessageDao;
|
|
|
@Autowired
|
|
@ -110,7 +105,6 @@ public class DoorOrderService {
|
|
|
@Autowired
|
|
|
private DoctorRegistrationTempService templateService;
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
private WlyyDoorPrescriptionDao doorPrescriptionDao;
|
|
|
@Autowired
|
|
@ -123,10 +117,6 @@ public class DoorOrderService {
|
|
|
|
|
|
@Autowired
|
|
|
private WxTemplateConfigDao wxTemplateConfigDao;
|
|
|
// @Autowired
|
|
|
// private HttpUtil httpUtil;
|
|
|
@Autowired
|
|
|
private WlyyDoorCommentDao doorCommentDao;
|
|
|
|
|
|
@Autowired
|
|
|
private PushMsgTask pushMsgTask;
|
|
@ -140,39 +130,19 @@ public class DoorOrderService {
|
|
|
|
|
|
/**
|
|
|
* 服务项查询
|
|
|
*
|
|
|
* @param signId 签约id
|
|
|
* @param type doorService 上门服务
|
|
|
* type =4
|
|
|
*/
|
|
|
public PageEnvelop getServiceItem(String signId, String name, String type, Integer page, Integer size) {
|
|
|
// String sql = "SELECT si.* ";
|
|
|
// String countSql = "select count(si.id) ";
|
|
|
// String filter = " from base_service_package_sign_record r," +
|
|
|
// "base_service_package_item i,base_service_package_sub_item si,base_service_package_item_relational ir " +
|
|
|
// "WHERE r.id = '"+signId+"' and i.service_package_id=r.service_package_id and i.`code`='"+type+"' and si.status='1' " +
|
|
|
// " and i.id = ir.item_id and ir.sub_item_id= si.id ";
|
|
|
// if(StringUtils.isNotBlank(name)){
|
|
|
// filter += " and si.name like '%"+name+"%' ";
|
|
|
// }
|
|
|
// String oderBy = " order by si.sort limit "+(page-1)*size+","+size;
|
|
|
|
|
|
String sql = "SELECT e.* ";
|
|
|
String countSql = "select count(e.id) ";
|
|
|
String filter =
|
|
|
"FROM\n" +
|
|
|
" base_service_package_sign_record a \n" +
|
|
|
" INNER JOIN base_service_package_item b ON a.service_package_id = b.service_package_id\n" +
|
|
|
" INNER JOIN base_service_package_item c ON c.id=b.service_package_item_id\n" +
|
|
|
" INNER JOIN base_service_package_item_relational d ON d.item_id=c.id \n" +
|
|
|
" INNER JOIN base_service_package_sub_item e ON e.id=d.sub_item_id\n" +
|
|
|
"WHERE 1=1\n" +
|
|
|
" AND b.`code` = '" + type + "' \n" +
|
|
|
" AND e.`status` = '1' \n" +
|
|
|
" AND a.id = '" + signId + "' ";
|
|
|
public PageEnvelop getServiceItem(String name, String type, Integer page, Integer size) {
|
|
|
String sql = "SELECT a.* ";
|
|
|
String countSql = "select count(a.id) ";
|
|
|
String filter = "FROM " +
|
|
|
" base_service_package_sub_item a " +
|
|
|
"WHERE a.dict_item_id = '" + type + "' \n" +
|
|
|
" AND a.`status` = '1' ";
|
|
|
if (StringUtils.isNotBlank(name)) {
|
|
|
filter += " and e.name like '%" + name + "%' ";
|
|
|
filter += " and a.name like '%" + name + "%' ";
|
|
|
}
|
|
|
String oderBy = " order by e.sort limit " + (page - 1) * size + "," + size;
|
|
|
String oderBy = " order by a.sort limit " + (page - 1) * size + "," + size;
|
|
|
|
|
|
sql = sql + filter + oderBy;
|
|
|
countSql = countSql + filter;
|
|
@ -2346,30 +2316,6 @@ public class DoorOrderService {
|
|
|
return list;
|
|
|
}
|
|
|
|
|
|
public JSONObject getAllDoorOrder(String idCard, String doctorSignTime) throws Exception {
|
|
|
if (StringUtils.isEmpty(idCard)) {
|
|
|
idCard = "";
|
|
|
}
|
|
|
if (StringUtils.isEmpty(doctorSignTime)) {
|
|
|
doctorSignTime = "";
|
|
|
}
|
|
|
JSONObject object = new JSONObject();
|
|
|
String url = jwUrl + "/third/allDoor/getAllDoorOrder?idCard=" + idCard + "&doctorSignTime=" + doctorSignTime;
|
|
|
|
|
|
String response = httpClientUtil.get(url, "UTF-8");
|
|
|
if (!org.apache.commons.lang3.StringUtils.isEmpty(response)) {
|
|
|
org.json.JSONObject jsonObject = new org.json.JSONObject(response);
|
|
|
int status = jsonObject.getInt("status");
|
|
|
if (status == 200) {
|
|
|
object = JSONObject.parseObject(response);
|
|
|
} else {
|
|
|
throw new Exception(jsonObject.getString("msg"));
|
|
|
}
|
|
|
} else {
|
|
|
throw new Exception("null response.");
|
|
|
}
|
|
|
return object;
|
|
|
}
|
|
|
|
|
|
// /**
|
|
|
// * 导出咨询未及时回复数据
|