md
This commit is contained in:
parent
cd1ef79a41
commit
0cee0c4bb1
@ -202,6 +202,37 @@ public class EmisBaseService {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据客户编号,获取客户信息
|
||||
* @param customerCode
|
||||
* @return
|
||||
*/
|
||||
public EmisCustomerUser getCustomerUserByCode(String customerCode){
|
||||
EmisCustomerUser queryEmisCustomerUser = new EmisCustomerUser();
|
||||
queryEmisCustomerUser.setCustomerCode(customerCode);
|
||||
List<EmisCustomerUser> list=emisCustomerUserMapper.selectEmisCustomerUserList(queryEmisCustomerUser);
|
||||
if(CollectionUtils.isEmpty(list)){
|
||||
return null;
|
||||
}
|
||||
return list.get(0);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据月结编号获取客户信息
|
||||
* @param monthlyPayCode
|
||||
* @return
|
||||
*/
|
||||
public EmisCustomerUser getCustomerUserByMonthlyPayCode(String monthlyPayCode){
|
||||
EmisCustomerUser queryEmisCustomerUser = new EmisCustomerUser();
|
||||
queryEmisCustomerUser.setMonthlyPayCode(monthlyPayCode);
|
||||
List<EmisCustomerUser> list=emisCustomerUserMapper.selectEmisCustomerUserList(queryEmisCustomerUser);
|
||||
if(CollectionUtils.isEmpty(list)){
|
||||
return null;
|
||||
}
|
||||
return list.get(0);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取打印信息
|
||||
* @param billCode
|
||||
@ -210,25 +241,25 @@ public class EmisBaseService {
|
||||
* @param printType
|
||||
* @return
|
||||
*/
|
||||
public Map<String,Object> getWaybillPrintOrder(String billCode, String billCodeRange, String lang, String printType){
|
||||
if(StringUtils.isEmpty(billCode)){
|
||||
public Map<String,Object> getWaybillPrintOrder(String billCode, String billCodeRange, String lang, String printType) {
|
||||
if (StringUtils.isEmpty(billCode)) {
|
||||
return null;
|
||||
}
|
||||
|
||||
EmisWaybill waybill = emisWaybillMapper.selectEmisWaybillByBillCode(billCode);
|
||||
if(waybill==null){
|
||||
if (waybill == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
Map<String,Object> order = new HashMap<>();
|
||||
Map<String, Object> order = new HashMap<>();
|
||||
order.put("orderSn", waybill.getOrderSn());
|
||||
order.put("ydSn", billCode);
|
||||
order.put("logisticNo", billCode);
|
||||
order.put("kdgs", "TANEX");
|
||||
order.put("pdfInfo", waybill.getThirdCode());
|
||||
|
||||
String pdfInfo=waybill.getThirdCode();
|
||||
pdfInfo=pdfInfo.replace("][","||");
|
||||
String pdfInfo = waybill.getThirdCode();
|
||||
pdfInfo = pdfInfo.replace("][", "||");
|
||||
|
||||
// String[] striparr = pdfInfo.split("||");
|
||||
String[] striparr = pdfInfo.split("\\|\\|");
|
||||
@ -239,11 +270,22 @@ public class EmisBaseService {
|
||||
order.put("packageWJC", packageWJC);
|
||||
order.put("package3dm", package3dm);
|
||||
|
||||
order.put("address", waybill.getReceiveAddress());
|
||||
order.put("address", waybill.getReceiveAddress());
|
||||
order.put("company", waybill.getReceiveCompany());
|
||||
order.put("mobile", waybill.getReceiveMobile());
|
||||
order.put("consignee", waybill.getReceiveName());
|
||||
|
||||
//
|
||||
String custName=waybill.getReceiveCompany();
|
||||
|
||||
if ( "2".equals(waybill.getPaymentType()) || "4".equals(waybill.getPaymentType()) || "5".equals(waybill.getPaymentType() ) {
|
||||
EmisCustomerUser custUser=getCustomerUserByMonthlyPayCode(waybill.getCustNo());
|
||||
if(custUser!=null){
|
||||
custName= custUser.getCustName();
|
||||
}
|
||||
}
|
||||
order.put("custName", custName);
|
||||
|
||||
order.put("sendAddress", waybill.getSendAddress());
|
||||
order.put("sendCompany", waybill.getSendCompany());
|
||||
order.put("sendMobile", waybill.getSendMobile());
|
||||
|
||||
@ -110,11 +110,9 @@
|
||||
<if test="custName != null and custName != ''"> and customer_name like concat('%', #{custName}, '%')</if>
|
||||
|
||||
<if test="id != null "> and id = #{id}</if>
|
||||
<if test="customerCode != null and customerCode != ''"> and customer_code like concat('%', #{customerCode}, '%')</if>
|
||||
<if test="customerCode != null and customerCode != ''"> and customer_code =#{customerCode}</if>
|
||||
<if test="customerName != null and customerName != ''"> and customer_name like concat('%', #{customerName}, '%')</if>
|
||||
|
||||
|
||||
|
||||
<if test="customerNameEn != null and customerNameEn != ''"> and customer_name_en like concat('%', #{customerNameEn}, '%')</if>
|
||||
<if test="simpleName != null and simpleName != ''"> and simple_name like concat('%', #{simpleName}, '%')</if>
|
||||
<if test="contact != null and contact != ''"> and contact like concat('%', #{contact}, '%')</if>
|
||||
@ -134,7 +132,7 @@
|
||||
<if test="nickName != null and nickName != ''"> and nick_name like concat('%', #{nickName}, '%')</if>
|
||||
<if test="unionId != null and unionId != ''"> and union_id like concat('%', #{unionId}, '%')</if>
|
||||
<if test="openid != null and openid != ''"> and openid like concat('%', #{openid}, '%')</if>
|
||||
<if test="monthlyPayCode != null and monthlyPayCode != ''"> and monthly_pay_code like concat('%', #{monthlyPayCode}, '%')</if>
|
||||
<if test="monthlyPayCode != null and monthlyPayCode != ''"> and monthly_pay_code=#{monthlyPayCode}</if>
|
||||
<if test="userName != null and userName != ''"> and user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="password != null and password != ''"> and password like concat('%', #{password}, '%')</if>
|
||||
<if test="bizSite != null and bizSite != ''"> and biz_site like concat('%', #{bizSite}, '%')</if>
|
||||
|
||||
@ -35,6 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="selectEmisPrintTplList" parameterType="EmisPrintTpl" resultMap="EmisPrintTplResult">
|
||||
<include refid="selectEmisPrintTplVo"/>
|
||||
<where>
|
||||
del_flag='0'
|
||||
<if test="id != null "> and id = #{id}</if>
|
||||
<if test="code != null and code != ''"> and code like concat('%', #{code}, '%')</if>
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
@ -61,7 +62,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</select>
|
||||
|
||||
<select id="selectPrintTplListByPrinter" parameterType="EmisPrintTpl" resultMap="EmisPrintTplResult">
|
||||
select id, code, name, version,express_type,tpl_enc_data from emis_print_tpl where del_flag='0'
|
||||
select id, code, name, version,express_type,tpl_enc_data from emis_print_tpl
|
||||
where del_flag='0' and status=1
|
||||
order by order_num desc
|
||||
</select>
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user