|
@ -161,9 +161,10 @@ public class MedicineOrderService extends BaseJpaService<Mediicineorder, Mediici
|
|
|
|
|
|
|
|
|
|
//orderNum, equNum, contact, startTime, endTime, sellState, orderState, dispensingWindow
|
|
//orderNum, equNum, contact, startTime, endTime, sellState, orderState, dispensingWindow
|
|
public JSONObject queryOrderListFullInfo(String orderNum, String equNum, String contact,
|
|
|
|
|
|
public JSONObject queryOrderListFullInfo(String content,String orderNum, String equNum, String contact,
|
|
String startTime, String endTime, String sellState,
|
|
String startTime, String endTime, String sellState,
|
|
String orderState, String dispensingWindow, String community, String userId, int page, int size, String wechatId) throws Exception {
|
|
|
|
|
|
String orderState, String dispensingWindow, String community,
|
|
|
|
String userId, int page, int size, String wechatId) throws Exception {
|
|
|
|
|
|
JSONObject result = new JSONObject();
|
|
JSONObject result = new JSONObject();
|
|
|
|
|
|
@ -226,6 +227,7 @@ public class MedicineOrderService extends BaseJpaService<Mediicineorder, Mediici
|
|
}
|
|
}
|
|
|
|
|
|
String sencodSql = "SELECT\n" +
|
|
String sencodSql = "SELECT\n" +
|
|
|
|
" tmd.equ_name as equName,\n" +
|
|
" t.id as id,\n" +
|
|
" t.id as id,\n" +
|
|
" t.address as address,\n" +
|
|
" t.address as address,\n" +
|
|
" t.age as age,\n" +
|
|
" t.age as age,\n" +
|
|
@ -276,12 +278,15 @@ public class MedicineOrderService extends BaseJpaService<Mediicineorder, Mediici
|
|
" t.social_security_card_num AS socialSecurityCardNum,\n" +
|
|
" t.social_security_card_num AS socialSecurityCardNum,\n" +
|
|
" t.belong_community AS belongCommunity\n" +
|
|
" t.belong_community AS belongCommunity\n" +
|
|
"FROM\n" +
|
|
"FROM\n" +
|
|
" t_mediicine_order AS t where 1=1 \n";
|
|
|
|
|
|
" t_mediicine_order AS t left join t_mediicine_device tmd on t.shipping_equ = tmd.equ_num where 1=1 \n";
|
|
|
|
|
|
|
|
|
|
if (!StringUtils.isEmpty(belongCommunitys)) {
|
|
if (!StringUtils.isEmpty(belongCommunitys)) {
|
|
conditionSql += " and '," + belongCommunitys + ",' LIKE CONCAT('%,',t.belong_community,',%')\n";
|
|
conditionSql += " and '," + belongCommunitys + ",' LIKE CONCAT('%,',t.belong_community,',%')\n";
|
|
}
|
|
}
|
|
|
|
if (!StringUtils.isEmpty(content)) {
|
|
|
|
conditionSql += " and CONCAT(IFNULL(t.`prescribe_num`,''),IFNULL(t.`contact`,''),IFNULL(t.`shipping_equ`,'')) like '%" + content + "%'";
|
|
|
|
}
|
|
if (!StringUtils.isEmpty(community)) {
|
|
if (!StringUtils.isEmpty(community)) {
|
|
conditionSql += " and t.belong_community = '" + community + "'";
|
|
conditionSql += " and t.belong_community = '" + community + "'";
|
|
}
|
|
}
|