Просмотр исходного кода

[B端账单][查询][添加查询字段]

release_toaliyun_real
gongbiao 7 лет назад
Родитель
Сommit
093e4eafef
4 измененных файлов: 18 добавлений и 18 удалений
  1. +6
    -7
      mallinkService/src/main/java/com/iformall/domain/vo/WxBillAll.java
  2. +2
    -1
      mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java
  3. +1
    -1
      mallinkService/src/main/java/com/iformall/service/impl/WxMsgServiceImpl.java
  4. +9
    -9
      mallinkService/src/main/resources/mapper/WxBillAllMapper.xml

+ 6
- 7
mallinkService/src/main/java/com/iformall/domain/vo/WxBillAll.java Просмотреть файл

@@ -1,6 +1,5 @@
package com.iformall.domain.vo;

import java.util.Date;
import java.util.List;

/**
@@ -28,10 +27,10 @@ public class WxBillAll {
private String month;

@io.swagger.annotations.ApiModelProperty(value="开始时间",name="starttime")
private Date starttime;
private String starttime;

@io.swagger.annotations.ApiModelProperty(value="结束时间",name="endtime")
private Date endtime;
private String endtime;

@io.swagger.annotations.ApiModelProperty(value="商户Id",name="merchantId")
private Long merchantId;
@@ -89,19 +88,19 @@ public class WxBillAll {
this.typeList = typeList;
}

public Date getStarttime() {
public String getStarttime() {
return starttime;
}

public void setStarttime(Date starttime) {
public void setStarttime(String starttime) {
this.starttime = starttime;
}

public Date getEndtime() {
public String getEndtime() {
return endtime;
}

public void setEndtime(Date endtime) {
public void setEndtime(String endtime) {
this.endtime = endtime;
}



+ 2
- 1
mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java Просмотреть файл

@@ -12,6 +12,7 @@ import com.iformall.enums.EnumBillTypeParam;
import com.iformall.mapper.WxBillAllMapper;
import com.iformall.service.*;
import com.iformall.utils.DateUtils;
import org.apache.commons.lang3.StringUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
@@ -85,7 +86,7 @@ public class WxBillAllServiceImpl implements WxBillAllService {
public ResultData listBill(WxBillAll wxBillAll) {
//更新各账单状态
updateBillStatus(wxBillAll);
if(wxBillAll.getStarttime()!=null && wxBillAll.getEndtime()==null){
if(StringUtils.isEmpty(wxBillAll.getStarttime()) && StringUtils.isEmpty(wxBillAll.getEndtime())){
String month = DateUtils.getSystemTime("yyyy-MM");
wxBillAll.setMonth(month);
}


+ 1
- 1
mallinkService/src/main/java/com/iformall/service/impl/WxMsgServiceImpl.java Просмотреть файл

@@ -241,7 +241,7 @@ public class WxMsgServiceImpl implements WxMsgService {

if(wxMsgConfig.getRemains()==0){
logger.info("短信数量为0");
return new ResultData(ErrorCode.MSG_SEND_ERROR.MSG_SUM_ZERO);
return new ResultData(ErrorCode.MSG_SUM_ZERO);
}

if(wxMsgConfig.getRemains()<wxMsg.getExpectSendNumber()){


+ 9
- 9
mallinkService/src/main/resources/mapper/WxBillAllMapper.xml Просмотреть файл

@@ -74,18 +74,18 @@
<select id="listData" resultType="hashmap" parameterType="com.iformall.domain.vo.WxBillAll">
select bill.id,bill.merchant_id merchantId,bill.shop_id shopId,bill.bill_type_value billTypeValue,bill.bill_type billType,bill.need_pay needPay,
bill.receive_pay receivePay,bill.pay,bill.owe,bill.receive_date receiveDate,bill.pay_date payDate,
bill.expired_day expiredDay,bill.status,bill.tenant_id tenantId,m.name merchantName,s.shop_number shopNumber from (
select id,merchant_id,shop_id,tenant_id,1 bill_type_value,'租金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_rent
bill.expired_day expiredDay,bill.status,bill.tenant_id tenantId,m.name merchantName,s.shop_number shopNumber,bill.starttime,bill.endtime from (
select id,merchant_id,shop_id,tenant_id,1 bill_type_value,'租金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,starttime,endtime from wx_bill_rent
union
select id,merchant_id,shop_id,tenant_id,2 bill_type_value,'租赁押金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_rent_deposit
select id,merchant_id,shop_id,tenant_id,2 bill_type_value,'租赁押金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,starttime,endtime from wx_bill_rent_deposit
union
select id,merchant_id,shop_id,tenant_id,3 bill_type_value,'物业费' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_property
select id,merchant_id,shop_id,tenant_id,3 bill_type_value,'物业费' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,starttime,endtime from wx_bill_property
union
select id,merchant_id,shop_id,tenant_id,4 bill_type_value,'物业押金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_property_deposit
select id,merchant_id,shop_id,tenant_id,4 bill_type_value,'物业押金' bill_type,need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,starttime,endtime from wx_bill_property_deposit
union
select id,merchant_id,shop_id,tenant_id,5 bill_type_value,'水费' bill_type, '' need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_daily where type=1
select id,merchant_id,shop_id,tenant_id,5 bill_type_value,'水费' bill_type, '' need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,'' starttime,'' endtime from wx_bill_daily where type=1
union
select id,merchant_id,shop_id,tenant_id,6 bill_type_value,'电费' bill_type,'' need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status from wx_bill_daily where type=2
select id,merchant_id,shop_id,tenant_id,6 bill_type_value,'电费' bill_type,'' need_pay,receive_pay,pay,owe,receive_date,pay_date,expired_day,status,'' starttime,'' endtime from wx_bill_daily where type=2
) bill
left join wx_merchant m on bill.merchant_id=m.id
left join wx_shop s on bill.shop_id=s.id
@@ -107,7 +107,7 @@
</foreach>
</if>
<if test="null!=starttime and null!=endtime">
and bill.receive_date between #{starttime} and #{endtime}
and DATE_FORMAT(bill.receive_date,'%Y-%m') between #{starttime} and #{endtime}
</if>
<if test=" null != status ">
and bill.status=#{status}
@@ -115,7 +115,7 @@
<if test=" null != billTypeValue ">
and bill.bill_type_value=#{billTypeValue}
</if>
order by bill.id,bill.merchant_id,bill.receive_date
order by bill.merchant_id,bill.receive_date
</select>


Загрузка…
Отмена
Сохранить