| @@ -0,0 +1,32 @@ | |||||
| alter table wx_bill_rent add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_rent add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_rent add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_rent_deposit add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_rent_deposit add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_rent_deposit add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_other_deposit add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_other_deposit add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_other_deposit add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_property_deposit add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_property_deposit add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_property_deposit add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_property add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_property add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_property add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_other add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_other add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_other add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| alter table wx_bill_daily add COLUMN `apply_status` int(1) not null default 0 COMMENT '账单审核状态'; | |||||
| alter table wx_bill_daily add COLUMN `apply_pay_img` varchar(1000) COMMENT '付款截图'; | |||||
| alter table wx_bill_daily add COLUMN `apply_update_time` datetime COMMENT '审核更新时间'; | |||||
| @@ -63,6 +63,12 @@ public class WxBillDaily extends TenantEntity { | |||||
| private Long owe; | private Long owe; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="删除 是1否0",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="删除 是1否0",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @io.swagger.annotations.ApiModelProperty(value="商户ID",name="merchantId") | @io.swagger.annotations.ApiModelProperty(value="商户ID",name="merchantId") | ||||
| @@ -43,6 +43,12 @@ public class WxBillDeposit extends TenantEntity { | |||||
| private Long owe; | private Long owe; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @io.swagger.annotations.ApiModelProperty(value="应收金额",name="needPay") | @io.swagger.annotations.ApiModelProperty(value="应收金额",name="needPay") | ||||
| @@ -67,6 +67,12 @@ public class WxBillOther extends TenantEntity { | |||||
| @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "9") | @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "9") | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="删除 是1否0",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="删除 是1否0",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @io.swagger.annotations.ApiModelProperty(value="商户ID",name="merchantId") | @io.swagger.annotations.ApiModelProperty(value="商户ID",name="merchantId") | ||||
| @@ -62,6 +62,12 @@ public class WxBillOtherDeposit extends TenantEntity { | |||||
| @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "8") | @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "8") | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "删除 是1否0", name = "isDel") | @io.swagger.annotations.ApiModelProperty(value = "删除 是1否0", name = "isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "商户ID", name = "merchantId") | @io.swagger.annotations.ApiModelProperty(value = "商户ID", name = "merchantId") | ||||
| @@ -87,6 +87,12 @@ public class WxBillProperty extends TenantEntity { | |||||
| @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "8") | @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "8") | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @@ -42,6 +42,12 @@ public class WxBillPropertyDeposit extends TenantEntity { | |||||
| private Long owe; | private Long owe; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期5已退还", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @io.swagger.annotations.ApiModelProperty(value="应收金额",name="needPay") | @io.swagger.annotations.ApiModelProperty(value="应收金额",name="needPay") | ||||
| @@ -83,6 +83,13 @@ public class WxBillRent extends TenantEntity { | |||||
| @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "10") | @Excel(name = "状态", replace = {"欠缴_1", "待缴_2", "已结清_3", "未到期_4", "已退还_5", "失效_6"}, width = 20, orderNum = "10") | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | @io.swagger.annotations.ApiModelProperty(value = "账单状态1欠缴2待缴3已结清4未到期", name = "status") | ||||
| private Integer status; | private Integer status; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | @io.swagger.annotations.ApiModelProperty(value="是否删除 是1否0 未到期不显示",name="isDel") | ||||
| private Integer isDel; | private Integer isDel; | ||||
| @@ -48,6 +48,12 @@ public class WxBillSettleBill extends TenantEntity { | |||||
| @io.swagger.annotations.ApiModelProperty(value="账单结束时间",name="endtime") | @io.swagger.annotations.ApiModelProperty(value="账单结束时间",name="endtime") | ||||
| private Date endtime; | private Date endtime; | ||||
| @io.swagger.annotations.ApiModelProperty(value = "账单审核状态EnumBillRentApplyStatus", name = "applyStatus") | |||||
| private Integer applyStatus; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyPayImg") | |||||
| private String applyPayImg; | |||||
| @io.swagger.annotations.ApiModelProperty(value = "付款截图", name = "applyUpdateTime") | |||||
| private Date applyUpdateTime; | |||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| @io.swagger.annotations.ApiModelProperty(value="获取应收还是欠缴 0欠缴 1应收",name="getReceivePayOrOwe") | @io.swagger.annotations.ApiModelProperty(value="获取应收还是欠缴 0欠缴 1应收",name="getReceivePayOrOwe") | ||||
| @@ -0,0 +1,39 @@ | |||||
| package com.iformall.enums; | |||||
| /** | |||||
| * @author gongbiao | |||||
| */ | |||||
| public enum EnumBillRentApplyStatus { | |||||
| NO_APPLY(0,"未提交审核"), | |||||
| APPLYING(1, "审核中"), | |||||
| REJECT(2,"已退回"), | |||||
| PASSED(3, "已通过") | |||||
| ; | |||||
| public static EnumBillRentApplyStatus getEnum(Integer code) { | |||||
| for (EnumBillRentApplyStatus value : values()) { | |||||
| if (value.getCode().equals(code)) { | |||||
| return value; | |||||
| } | |||||
| } | |||||
| return null; | |||||
| } | |||||
| private Integer code; | |||||
| private String message; | |||||
| EnumBillRentApplyStatus(Integer code, String message) { | |||||
| this.code = code; | |||||
| this.message = message; | |||||
| } | |||||
| public Integer getCode() { | |||||
| return code; | |||||
| } | |||||
| public String getMessage() { | |||||
| return message; | |||||
| } | |||||
| } | |||||
| @@ -323,6 +323,7 @@ public class WxBillAllServiceImpl implements WxBillAllService { | |||||
| } | } | ||||
| if (null != maps && hasSet) { | if (null != maps && hasSet) { | ||||
| for (Map<String, Object> map : maps) { | for (Map<String, Object> map : maps) { | ||||
| Integer billType = ((Long) map.get("billTypeValue")).intValue(); | Integer billType = ((Long) map.get("billTypeValue")).intValue(); | ||||
| if (EnumBillType.SETTLE.getCode().equals(billType)) { | if (EnumBillType.SETTLE.getCode().equals(billType)) { | ||||
| Long id = (Long) map.get("id"); | Long id = (Long) map.get("id"); | ||||
| @@ -312,6 +312,7 @@ public class WxBillRentServiceImpl implements WxBillRentService { | |||||
| merchantTradeDaily.setMerchantId(billRent.getMerchantId()); | merchantTradeDaily.setMerchantId(billRent.getMerchantId()); | ||||
| merchantTradeDaily.setStartTime(sd.format(billRent.getStarttime())); | merchantTradeDaily.setStartTime(sd.format(billRent.getStarttime())); | ||||
| merchantTradeDaily.setEndTime(sd.format(billRent.getEndtime())); | merchantTradeDaily.setEndTime(sd.format(billRent.getEndtime())); | ||||
| merchantTradeDaily.updateTenantInfo(wxRentContract); | |||||
| Integer money = wxMerchantTradeDailyService.findSumMoney(merchantTradeDaily); | Integer money = wxMerchantTradeDailyService.findSumMoney(merchantTradeDaily); | ||||
| String moneyStr = new BigDecimal(money.toString()).divide(new BigDecimal(100)).setScale(2, RoundingMode.HALF_EVEN).toPlainString(); | String moneyStr = new BigDecimal(money.toString()).divide(new BigDecimal(100)).setScale(2, RoundingMode.HALF_EVEN).toPlainString(); | ||||
| result.put("solutionBillMoney", moneyStr); | result.put("solutionBillMoney", moneyStr); | ||||
| @@ -1,5 +1,6 @@ | |||||
| package com.iformall.service.impl; | package com.iformall.service.impl; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageHelper; | import com.github.pagehelper.PageHelper; | ||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.common.ErrorCode; | import com.iformall.common.ErrorCode; | ||||
| @@ -169,12 +170,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| if(EnumBillQueryType.RENT.getCode().equals(bill.getBillType())) { | if(EnumBillQueryType.RENT.getCode().equals(bill.getBillType())) { | ||||
| WxBillRent wxBillRent = new WxBillRent(); | WxBillRent wxBillRent = new WxBillRent(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillRent dbBill = wxBillRentMapper.selectById(wxBillRent.getId()); | WxBillRent dbBill = wxBillRentMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -188,12 +196,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else if(EnumBillType.DEPOSIT.getCode().equals(bill.getBillType())) { | }else if(EnumBillType.DEPOSIT.getCode().equals(bill.getBillType())) { | ||||
| WxBillDeposit wxBillRent = new WxBillDeposit(); | WxBillDeposit wxBillRent = new WxBillDeposit(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillDeposit dbBill = wxBillDepositMapper.selectById(wxBillRent.getId()); | WxBillDeposit dbBill = wxBillDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -212,12 +227,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| WxBillOtherDeposit wxBillOtherDeposit = new WxBillOtherDeposit(); | WxBillOtherDeposit wxBillOtherDeposit = new WxBillOtherDeposit(); | ||||
| wxBillOtherDeposit.setId(bill.getBillId()); | wxBillOtherDeposit.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillOtherDeposit.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillOtherDeposit.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillOtherDeposit.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillOtherDeposit.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillOtherDeposit.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillOtherDeposit.setStatus(status); | wxBillOtherDeposit.setStatus(status); | ||||
| wxBillOtherDeposit.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillOtherDeposit.setPayDate(new Date()); | |||||
| WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -236,12 +258,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | ||||
| propertyDeposit.setId(bill.getBillId()); | propertyDeposit.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| propertyDeposit.setApplyStatus(bill.getApplyStatus()); | |||||
| propertyDeposit.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| propertyDeposit.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| propertyDeposit.setStatus(status); | propertyDeposit.setStatus(status); | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -261,12 +290,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else if(EnumBillType.PROPERTY.getCode().equals(bill.getBillType())) { | }else if(EnumBillType.PROPERTY.getCode().equals(bill.getBillType())) { | ||||
| WxBillProperty wxBillRent = new WxBillProperty(); | WxBillProperty wxBillRent = new WxBillProperty(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillProperty dbBill = wxBillPropertyMapper.selectById(wxBillRent.getId()); | WxBillProperty dbBill = wxBillPropertyMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -280,12 +316,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | ||||
| propertyDeposit.setId(bill.getBillId()); | propertyDeposit.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| propertyDeposit.setApplyStatus(bill.getApplyStatus()); | |||||
| propertyDeposit.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| propertyDeposit.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| propertyDeposit.setStatus(status); | propertyDeposit.setStatus(status); | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -304,12 +347,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else if(EnumBillType.ROUTINE.getCode().equals(bill.getBillType())) { | }else if(EnumBillType.ROUTINE.getCode().equals(bill.getBillType())) { | ||||
| WxBillOther wxBillRent = new WxBillOther(); | WxBillOther wxBillRent = new WxBillOther(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillOther dbBill = wxBillOtherMapper.selectById(wxBillRent.getId()); | WxBillOther dbBill = wxBillOtherMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -323,12 +373,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else if(EnumBillType.OTHER_DEPOSIT.getCode().equals(bill.getBillType())) { | }else if(EnumBillType.OTHER_DEPOSIT.getCode().equals(bill.getBillType())) { | ||||
| WxBillOtherDeposit wxBillRent = new WxBillOtherDeposit(); | WxBillOtherDeposit wxBillRent = new WxBillOtherDeposit(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -355,12 +412,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else if(EnumBillType.OTHER_DEPOSIT.getCode().equals(bill.getBillType())) { | }else if(EnumBillType.OTHER_DEPOSIT.getCode().equals(bill.getBillType())) { | ||||
| WxBillOtherDeposit wxBillRent = new WxBillOtherDeposit(); | WxBillOtherDeposit wxBillRent = new WxBillOtherDeposit(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | WxBillOtherDeposit dbBill = wxBillOtherDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -379,12 +443,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| }else{ | }else{ | ||||
| WxBillDaily wxBillDaily = new WxBillDaily(); | WxBillDaily wxBillDaily = new WxBillDaily(); | ||||
| wxBillDaily.setId(bill.getBillId()); | wxBillDaily.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillDaily.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillDaily.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillDaily.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillDaily.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillDaily.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillDaily.setStatus(status); | wxBillDaily.setStatus(status); | ||||
| wxBillDaily.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillDaily.setPayDate(new Date()); | |||||
| WxBillDaily dbBill = wxBillDailyMapper.selectById(wxBillDaily.getId()); | WxBillDaily dbBill = wxBillDailyMapper.selectById(wxBillDaily.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -398,12 +469,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| WxBillOther wxBillRent = new WxBillOther(); | WxBillOther wxBillRent = new WxBillOther(); | ||||
| wxBillRent.setId(bill.getBillId()); | wxBillRent.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| wxBillRent.setApplyStatus(bill.getApplyStatus()); | |||||
| wxBillRent.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| wxBillRent.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | if(freezeStatus != null) wxBillRent.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| wxBillRent.setStatus(status); | wxBillRent.setStatus(status); | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| wxBillRent.setPayDate(new Date()); | |||||
| WxBillOther dbBill = wxBillOtherMapper.selectById(wxBillRent.getId()); | WxBillOther dbBill = wxBillOtherMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| if(dbBill.getPay() == null) dbBill.setPay(0l); | if(dbBill.getPay() == null) dbBill.setPay(0l); | ||||
| @@ -417,12 +495,19 @@ public class WxBillSettleServiceImpl implements WxBillSettleService { | |||||
| WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | WxBillPropertyDeposit propertyDeposit = new WxBillPropertyDeposit(); | ||||
| propertyDeposit.setId(bill.getBillId()); | propertyDeposit.setId(bill.getBillId()); | ||||
| if ( null != bill.getApplyStatus()) { | |||||
| propertyDeposit.setApplyStatus(bill.getApplyStatus()); | |||||
| propertyDeposit.setApplyUpdateTime(bill.getApplyUpdateTime()); | |||||
| } | |||||
| if (!StringUtils.isBlank(bill.getApplyPayImg())) { | |||||
| propertyDeposit.setApplyPayImg(bill.getApplyPayImg()); | |||||
| } | |||||
| if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | if(freezeStatus != null) propertyDeposit.setFreeze(freezeStatus); | ||||
| if(status != null){ | if(status != null){ | ||||
| propertyDeposit.setStatus(status); | propertyDeposit.setStatus(status); | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| } | } | ||||
| if(EnumBillRentStatus.PAID.getCode().equals(status)){ | if(EnumBillRentStatus.PAID.getCode().equals(status)){ | ||||
| propertyDeposit.setPayDate(new Date()); | |||||
| WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | WxBillPropertyDeposit dbBill = wxBillPropertyDepositMapper.selectById(wxBillRent.getId()); | ||||
| if(dbBill!=null) { | if(dbBill!=null) { | ||||
| propertyDeposit.setPay(dbBill.getPay()+dbBill.getReceivePay()); | propertyDeposit.setPay(dbBill.getPay()+dbBill.getReceivePay()); | ||||
| @@ -346,6 +346,8 @@ public class WxFlowServiceImpl implements WxFlowService { | |||||
| WxBillSettleBill settleBill = new WxBillSettleBill(); | WxBillSettleBill settleBill = new WxBillSettleBill(); | ||||
| settleBill.setBillType(billType); | settleBill.setBillType(billType); | ||||
| settleBill.setBillId(Long.parseLong(businessId)); | settleBill.setBillId(Long.parseLong(businessId)); | ||||
| settleBill.setApplyStatus(EnumBillRentApplyStatus.PASSED.getCode()); | |||||
| settleBill.setApplyUpdateTime(new Date()); | |||||
| billList.add(settleBill); | billList.add(settleBill); | ||||
| wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.DEF.getCode(),null); | wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.DEF.getCode(),null); | ||||
| }else if(EnumRentContractAppStatus.APPLYING.getCode().intValue() == applyStatus.intValue()) { | }else if(EnumRentContractAppStatus.APPLYING.getCode().intValue() == applyStatus.intValue()) { | ||||
| @@ -354,6 +356,12 @@ public class WxFlowServiceImpl implements WxFlowService { | |||||
| WxBillSettleBill settleBill = new WxBillSettleBill(); | WxBillSettleBill settleBill = new WxBillSettleBill(); | ||||
| settleBill.setBillType(billType); | settleBill.setBillType(billType); | ||||
| settleBill.setBillId(Long.parseLong(businessId)); | settleBill.setBillId(Long.parseLong(businessId)); | ||||
| if (EnumFlowKey.BILL_FINISH.getCode().equals(flowType)) { | |||||
| String payImg = (String)getVariableByKey(variables, "payImg"); | |||||
| settleBill.setApplyPayImg(payImg); | |||||
| } | |||||
| settleBill.setApplyStatus(EnumBillRentApplyStatus.APPLYING.getCode()); | |||||
| settleBill.setApplyUpdateTime(new Date()); | |||||
| billList.add(settleBill); | billList.add(settleBill); | ||||
| wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.YES.getCode(),null); | wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.YES.getCode(),null); | ||||
| }else if(EnumRentContractAppStatus.SETBACK.getCode().intValue() == applyStatus.intValue() || EnumRentContractAppStatus.REJECT.getCode().intValue() == applyStatus.intValue()) { | }else if(EnumRentContractAppStatus.SETBACK.getCode().intValue() == applyStatus.intValue() || EnumRentContractAppStatus.REJECT.getCode().intValue() == applyStatus.intValue()) { | ||||
| @@ -362,6 +370,8 @@ public class WxFlowServiceImpl implements WxFlowService { | |||||
| WxBillSettleBill settleBill = new WxBillSettleBill(); | WxBillSettleBill settleBill = new WxBillSettleBill(); | ||||
| settleBill.setBillType(billType); | settleBill.setBillType(billType); | ||||
| settleBill.setBillId(Long.parseLong(businessId)); | settleBill.setBillId(Long.parseLong(businessId)); | ||||
| settleBill.setApplyStatus(EnumBillRentApplyStatus.REJECT.getCode()); | |||||
| settleBill.setApplyUpdateTime(new Date()); | |||||
| billList.add(settleBill); | billList.add(settleBill); | ||||
| wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.DEF.getCode(),null); | wxBillSettleService.updateFreezeOrStatus(billList,EnumFreezeType.DEF.getCode(),null); | ||||
| } | } | ||||
| @@ -1229,6 +1229,10 @@ public class WxRentContractServiceImpl implements WxRentContractService { | |||||
| priceArrs[i] = 0; | priceArrs[i] = 0; | ||||
| } | } | ||||
| } | } | ||||
| }else { | |||||
| size = 1; | |||||
| priceArrs = new long[size]; | |||||
| priceArrs[0] = 0; | |||||
| } | } | ||||
| }else{ | }else{ | ||||
| return new ArrayList<>(); | return new ArrayList<>(); | ||||
| @@ -13,6 +13,9 @@ | |||||
| <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" /> | <result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId" /> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status" /> | <result column="status" jdbcType="INTEGER" property="status" /> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel" /> | <result column="is_del" jdbcType="INTEGER" property="isDel" /> | ||||
| <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | ||||
| <result column="user_id" jdbcType="BIGINT" property="userId" /> | <result column="user_id" jdbcType="BIGINT" property="userId" /> | ||||
| @@ -32,7 +35,7 @@ | |||||
| </resultMap> | </resultMap> | ||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`, | |||||
| `id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `tenant_id`,`parent_tenant_id`,`owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`type`, | `tenant_id`,`parent_tenant_id`,`owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`type`, | ||||
| `rent_shop_type`,`pay_way`,`price_detail`,`starttime`,`endtime`,freeze,build_way,service_charge_pay | `rent_shop_type`,`pay_way`,`price_detail`,`starttime`,`endtime`,freeze,build_way,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -53,7 +56,8 @@ | |||||
| and `parent_tenant_id` = #{parentTenantId} | and `parent_tenant_id` = #{parentTenantId} | ||||
| </if> | </if> | ||||
| <if test=" null != owe "> and `owe` = #{owe} </if> | <if test=" null != owe "> and `owe` = #{owe} </if> | ||||
| <if test=" null != status "> and `status` = #{status} </if> | |||||
| <if test=" null != status "> and `status` = #{status} </if> | |||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel "> and `is_del` = #{isDel} </if> | <if test=" null != isDel "> and `is_del` = #{isDel} </if> | ||||
| <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | ||||
| <if test=" null != userId "> and `user_id` = #{userId} </if> | <if test=" null != userId "> and `user_id` = #{userId} </if> | ||||
| @@ -81,7 +85,7 @@ | |||||
| select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day` , | select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day` , | ||||
| case when br.status=1 then br.owe else 0 end owe,br.`status`,m.`name` merchant_name, | case when br.status=1 then br.owe else 0 end owe,br.`status`,m.`name` merchant_name, | ||||
| br.`updatetime`,br.`merchant_id`,br.shop_id,br.shop_name,br.type,br.`rent_shop_type`,br.pay_way,br.price_detail, | br.`updatetime`,br.`merchant_id`,br.shop_id,br.shop_name,br.type,br.`rent_shop_type`,br.pay_way,br.price_detail, | ||||
| br.`starttime`,br.`endtime`,br.`build_way`,br.freeze,br.service_charge_pay | |||||
| br.`starttime`,br.`endtime`,br.`build_way`,br.freeze,br.service_charge_pay,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| from wx_bill_daily br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_daily br left join wx_merchant m on br.merchant_id=m.id | ||||
| <where> | <where> | ||||
| <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | ||||
| @@ -89,6 +93,7 @@ | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != type ">and br.`type` = #{type}</if> | <if test=" null != type ">and br.`type` = #{type}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| @@ -14,6 +14,9 @@ | |||||
| <result column="expired_day" jdbcType="BIGINT" property="expiredDay" /> | <result column="expired_day" jdbcType="BIGINT" property="expiredDay" /> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status" /> | <result column="status" jdbcType="INTEGER" property="status" /> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel" /> | <result column="is_del" jdbcType="INTEGER" property="isDel" /> | ||||
| <result column="need_pay" jdbcType="BIGINT" property="needPay"/> | <result column="need_pay" jdbcType="BIGINT" property="needPay"/> | ||||
| <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | ||||
| @@ -32,7 +35,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`, | `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`, | ||||
| `expired_day`,`owe`,`status`,`is_del`,`need_pay`,`merchant_id`,`user_id`,`shop_id`,`updatetime`, | |||||
| `expired_day`,`owe`,`status`,`is_del`,`need_pay`,`merchant_id`,`user_id`,`shop_id`,`updatetime`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `rent_shop_type`,`return_price`,`pay_way`,service_charge_pay | `rent_shop_type`,`return_price`,`pay_way`,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -54,6 +57,7 @@ | |||||
| <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | ||||
| <if test=" null != owe "> and `owe` = #{owe} </if> | <if test=" null != owe "> and `owe` = #{owe} </if> | ||||
| <if test=" null != status "> and `status` = #{status} </if> | <if test=" null != status "> and `status` = #{status} </if> | ||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel "> and `is_del` = #{isDel} </if> | <if test=" null != isDel "> and `is_del` = #{isDel} </if> | ||||
| <if test=" null != needPay "> and `need_pay` = #{needPay} </if> | <if test=" null != needPay "> and `need_pay` = #{needPay} </if> | ||||
| <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | ||||
| @@ -80,6 +84,7 @@ | |||||
| <select id="queryBillDepositList" parameterType="com.iformall.domain.po.WxBillDeposit" resultMap="BaseResultMap"> | <select id="queryBillDepositList" parameterType="com.iformall.domain.po.WxBillDeposit" resultMap="BaseResultMap"> | ||||
| select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | ||||
| br.`owe`,br.`status`,br.`need_pay`,m.`name` merchant_name,s.shop_number,br.`updatetime`,br.`merchant_id`, | br.`owe`,br.`status`,br.`need_pay`,m.`name` merchant_name,s.shop_number,br.`updatetime`,br.`merchant_id`, | ||||
| br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| br.`rent_shop_type`,br.`return_price`, br.pay_way,br.shop_info ,br.freeze,br.service_charge_pay | br.`rent_shop_type`,br.`return_price`, br.pay_way,br.shop_info ,br.freeze,br.service_charge_pay | ||||
| from wx_bill_rent_deposit br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_rent_deposit br left join wx_merchant m on br.merchant_id=m.id | ||||
| left join wx_shop s on br.shop_id=s.id | left join wx_shop s on br.shop_id=s.id | ||||
| @@ -94,6 +99,7 @@ | |||||
| and br.`parent_tenant_id` = #{parentTenantId} | and br.`parent_tenant_id` = #{parentTenantId} | ||||
| </if> | </if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| <if test=" null != rentContractId ">and br.`rent_contract_id` = #{rentContractId}</if> | <if test=" null != rentContractId ">and br.`rent_contract_id` = #{rentContractId}</if> | ||||
| @@ -13,6 +13,9 @@ | |||||
| <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status"/> | <result column="status" jdbcType="INTEGER" property="status"/> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel"/> | <result column="is_del" jdbcType="INTEGER" property="isDel"/> | ||||
| <result column="merchant_id" jdbcType="BIGINT" property="merchantId"/> | <result column="merchant_id" jdbcType="BIGINT" property="merchantId"/> | ||||
| <result column="user_id" jdbcType="BIGINT" property="userId"/> | <result column="user_id" jdbcType="BIGINT" property="userId"/> | ||||
| @@ -35,7 +38,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`, | `id`,`tenant_id`,`parent_tenant_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`, | ||||
| `owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`name`,`comments`, | |||||
| `owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`name`,`comments`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `rent_shop_type`,`return_price`,`pay_way`,`starttime`,`endtime`,freeze,service_charge_pay | `rent_shop_type`,`return_price`,`pay_way`,`starttime`,`endtime`,freeze,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -56,6 +59,7 @@ | |||||
| <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | ||||
| <if test=" null != owe ">and `owe` = #{owe}</if> | <if test=" null != owe ">and `owe` = #{owe}</if> | ||||
| <if test=" null != status ">and `status` = #{status}</if> | <if test=" null != status ">and `status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and `is_del` = #{isDel}</if> | <if test=" null != isDel ">and `is_del` = #{isDel}</if> | ||||
| <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != userId ">and `user_id` = #{userId}</if> | <if test=" null != userId ">and `user_id` = #{userId}</if> | ||||
| @@ -86,6 +90,7 @@ | |||||
| <select id="queryBillList" parameterType="com.iformall.domain.po.WxBillOtherDeposit" resultMap="BaseResultMap"> | <select id="queryBillList" parameterType="com.iformall.domain.po.WxBillOtherDeposit" resultMap="BaseResultMap"> | ||||
| select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | ||||
| br.`owe`,br.`status`,m.`name` merchant_name,br.shop_name,br.`updatetime`,br.`return_price`,br.`merchant_id`, | br.`owe`,br.`status`,m.`name` merchant_name,br.shop_name,br.`updatetime`,br.`return_price`,br.`merchant_id`, | ||||
| br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| br.shop_id,br.name,br.comments,br.`rent_shop_type`,br.pay_way,br.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | br.shop_id,br.name,br.comments,br.`rent_shop_type`,br.pay_way,br.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | ||||
| from wx_bill_other_deposit br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_other_deposit br left join wx_merchant m on br.merchant_id=m.id | ||||
| <where> | <where> | ||||
| @@ -94,6 +99,7 @@ | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != name and ''!=name">and br.`name` = #{name}</if> | <if test=" null != name and ''!=name">and br.`name` = #{name}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| @@ -13,6 +13,9 @@ | |||||
| <result column="expired_day" jdbcType="INTEGER" property="expiredDay" /> | <result column="expired_day" jdbcType="INTEGER" property="expiredDay" /> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status" /> | <result column="status" jdbcType="INTEGER" property="status" /> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel" /> | <result column="is_del" jdbcType="INTEGER" property="isDel" /> | ||||
| <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | <result column="merchant_id" jdbcType="BIGINT" property="merchantId" /> | ||||
| <result column="user_id" jdbcType="BIGINT" property="userId" /> | <result column="user_id" jdbcType="BIGINT" property="userId" /> | ||||
| @@ -36,7 +39,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`, | `id`,`tenant_id`,`parent_tenant_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`,`createtime`,`expired_day`, | ||||
| `owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`name`,`comments`, | `owe`,`status`,`is_del`,`merchant_id`,`user_id`,`shop_id`,`shop_name`,`updatetime`,`name`,`comments`, | ||||
| `rent_shop_type`,`pay_way`,`starttime`,`endtime`,endtime,service_charge_pay | |||||
| `rent_shop_type`,`pay_way`,`starttime`,`endtime`,endtime,service_charge_pay,`apply_status`,`apply_pay_img`,`apply_update_time` | |||||
| </sql> | </sql> | ||||
| <sql id="dynamicWhereConditions"> | <sql id="dynamicWhereConditions"> | ||||
| @@ -56,6 +59,7 @@ | |||||
| <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | ||||
| <if test=" null != owe "> and `owe` = #{owe} </if> | <if test=" null != owe "> and `owe` = #{owe} </if> | ||||
| <if test=" null != status "> and `status` = #{status} </if> | <if test=" null != status "> and `status` = #{status} </if> | ||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel "> and `is_del` = #{isDel} </if> | <if test=" null != isDel "> and `is_del` = #{isDel} </if> | ||||
| <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | ||||
| <if test=" null != userId "> and `user_id` = #{userId} </if> | <if test=" null != userId "> and `user_id` = #{userId} </if> | ||||
| @@ -82,7 +86,7 @@ | |||||
| <select id="queryBillList" parameterType="com.iformall.domain.po.WxBillOther" resultMap="BaseResultMap"> | <select id="queryBillList" parameterType="com.iformall.domain.po.WxBillOther" resultMap="BaseResultMap"> | ||||
| select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`, br.`pay_date`,br.`createtime`,br.`expired_day`, | select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`, br.`pay_date`,br.`createtime`,br.`expired_day`, | ||||
| case when br.status=1 then br.owe else 0 end owe,br.`status`,m.`name` | case when br.status=1 then br.owe else 0 end owe,br.`status`,m.`name` | ||||
| merchant_name,br.shop_name,br.`updatetime`, | |||||
| merchant_name,br.shop_name,br.`updatetime`,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| br.`merchant_id`,br.shop_id,br.name,br.comments,br.`rent_shop_type`,br.pay_way, | br.`merchant_id`,br.shop_id,br.name,br.comments,br.`rent_shop_type`,br.pay_way, | ||||
| br.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | br.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | ||||
| from wx_bill_other br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_other br left join wx_merchant m on br.merchant_id=m.id | ||||
| @@ -92,6 +96,7 @@ | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != name and ''!=name">and br.`name` like concat('%',#{name},'%')</if> | <if test=" null != name and ''!=name">and br.`name` like concat('%',#{name},'%')</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| @@ -14,6 +14,9 @@ | |||||
| <result column="expired_day" jdbcType="INTEGER" property="expiredDay" /> | <result column="expired_day" jdbcType="INTEGER" property="expiredDay" /> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status" /> | <result column="status" jdbcType="INTEGER" property="status" /> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel" /> | <result column="is_del" jdbcType="INTEGER" property="isDel" /> | ||||
| <result column="need_pay" jdbcType="INTEGER" property="needPay" /> | <result column="need_pay" jdbcType="INTEGER" property="needPay" /> | ||||
| <result column="merchant_id" jdbcType="INTEGER" property="merchantId" /> | <result column="merchant_id" jdbcType="INTEGER" property="merchantId" /> | ||||
| @@ -32,7 +35,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`property_contract_id`,`receive_pay`,`pay`,`receive_date`, | `id`,`tenant_id`,`parent_tenant_id`,`property_contract_id`,`receive_pay`,`pay`,`receive_date`, | ||||
| `pay_date`,`createtime`,`expired_day`,`owe`,`status`,`is_del`,`need_pay`, | |||||
| `pay_date`,`createtime`,`expired_day`,`owe`,`status`,`is_del`,`need_pay`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`,`return_price`,`shop_info`,`pay_way`,freeze,service_charge_pay | `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`,`return_price`,`shop_info`,`pay_way`,freeze,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -53,7 +56,8 @@ | |||||
| <if test=" null != createtime "> and `createtime` = #{createtime} </if> | <if test=" null != createtime "> and `createtime` = #{createtime} </if> | ||||
| <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | <if test=" null != expiredDay "> and `expired_day` = #{expiredDay} </if> | ||||
| <if test=" null != owe "> and `owe` = #{owe} </if> | <if test=" null != owe "> and `owe` = #{owe} </if> | ||||
| <if test=" null != status "> and `status` = #{status} </if> | |||||
| <if test=" null != status "> and `status` = #{status} </if> | |||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel "> and `is_del` = #{isDel} </if> | <if test=" null != isDel "> and `is_del` = #{isDel} </if> | ||||
| <if test=" null != needPay "> and `need_pay` = #{needPay} </if> | <if test=" null != needPay "> and `need_pay` = #{needPay} </if> | ||||
| <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | <if test=" null != merchantId "> and `merchant_id` = #{merchantId} </if> | ||||
| @@ -83,7 +87,7 @@ | |||||
| br.`pay_date`,br.`createtime`,br.`expired_day`,br.`owe`,br.`status`, | br.`pay_date`,br.`createtime`,br.`expired_day`,br.`owe`,br.`status`, | ||||
| br.`need_pay`,m.`name` merchant_name,s.shop_number,br.`updatetime`, | br.`need_pay`,m.`name` merchant_name,s.shop_number,br.`updatetime`, | ||||
| br.`merchant_id`,br.`rent_shop_type`,br.`return_price`,br.`shop_info`,br.pay_way, | br.`merchant_id`,br.`rent_shop_type`,br.`return_price`,br.`shop_info`,br.pay_way, | ||||
| br.freeze,br.service_charge_pay | |||||
| br.freeze,br.service_charge_pay,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time` | |||||
| from wx_bill_property_deposit br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_property_deposit br left join wx_merchant m on br.merchant_id=m.id | ||||
| left join wx_shop s on br.shop_id=s.id | left join wx_shop s on br.shop_id=s.id | ||||
| <where> | <where> | ||||
| @@ -97,6 +101,7 @@ | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| <if test=" null != propertyContractId ">and br.`property_contract_id` = #{propertyContractId}</if> | <if test=" null != propertyContractId ">and br.`property_contract_id` = #{propertyContractId}</if> | ||||
| @@ -14,6 +14,9 @@ | |||||
| <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status"/> | <result column="status" jdbcType="INTEGER" property="status"/> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel"/> | <result column="is_del" jdbcType="INTEGER" property="isDel"/> | ||||
| <result column="need_pay" jdbcType="BIGINT" property="needPay"/> | <result column="need_pay" jdbcType="BIGINT" property="needPay"/> | ||||
| <result column="merchant_id" jdbcType="INTEGER" property="merchantId"/> | <result column="merchant_id" jdbcType="INTEGER" property="merchantId"/> | ||||
| @@ -48,7 +51,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`property_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`, | `id`,`tenant_id`,`parent_tenant_id`,`property_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`, | ||||
| `createtime`,`expired_day`,`tenant_id`,`owe`,`status`,`is_del`,`need_pay`, | `createtime`,`expired_day`,`tenant_id`,`owe`,`status`,`is_del`,`need_pay`, | ||||
| `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`, | |||||
| `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `revenue`,`late_pay_ratio`,`late_pay_time`,`late_pay_price`,`period`,`is_preview`,`shop_info`, | `revenue`,`late_pay_ratio`,`late_pay_time`,`late_pay_price`,`period`,`is_preview`,`shop_info`, | ||||
| `pay_way`,`late_pay_status`,`comments`,starttime,endtime,freeze,service_charge_pay | `pay_way`,`late_pay_status`,`comments`,starttime,endtime,freeze,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -71,6 +74,7 @@ | |||||
| <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | ||||
| <if test=" null != owe ">and `owe` = #{owe}</if> | <if test=" null != owe ">and `owe` = #{owe}</if> | ||||
| <if test=" null != status ">and `status` = #{status}</if> | <if test=" null != status ">and `status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and `is_del` = #{isDel}</if> | <if test=" null != isDel ">and `is_del` = #{isDel}</if> | ||||
| <if test=" null != needPay ">and `need_pay` = #{needPay}</if> | <if test=" null != needPay ">and `need_pay` = #{needPay}</if> | ||||
| <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | ||||
| @@ -105,7 +109,7 @@ | |||||
| br.`revenue`,r.`late_pay_ratio`,br.`late_pay_time`,br.`property_contract_id`,d.receive_pay deposit, | br.`revenue`,r.`late_pay_ratio`,br.`late_pay_time`,br.`property_contract_id`,d.receive_pay deposit, | ||||
| br.late_pay_price,d.`status` | br.late_pay_price,d.`status` | ||||
| deposit_status,br.`shop_info`,br.pay_way,br.late_pay_status, | deposit_status,br.`shop_info`,br.pay_way,br.late_pay_status, | ||||
| br.`comments`,br.starttime,br.endtime, | |||||
| br.`comments`,br.starttime,br.endtime,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| r.late_pay_day,r.late_pay_ratio,br.freeze,br.service_charge_pay | r.late_pay_day,r.late_pay_ratio,br.freeze,br.service_charge_pay | ||||
| from wx_bill_property br left join wx_merchant m on br.merchant_id=m.id | from wx_bill_property br left join wx_merchant m on br.merchant_id=m.id | ||||
| left join wx_shop s on br.shop_id=s.id | left join wx_shop s on br.shop_id=s.id | ||||
| @@ -118,6 +122,7 @@ | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||
| <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | <if test=" null != merchantName and ''!=merchantName ">and m.`name` like concat('%',#{merchantName},'%')</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | <if test=" null != isDel ">and br.`is_del` = #{isDel}</if> | ||||
| <if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime}</if> | <if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| @@ -14,6 +14,9 @@ | |||||
| <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | <result column="expired_day" jdbcType="INTEGER" property="expiredDay"/> | ||||
| <result column="owe" jdbcType="BIGINT" property="owe"/> | <result column="owe" jdbcType="BIGINT" property="owe"/> | ||||
| <result column="status" jdbcType="INTEGER" property="status"/> | <result column="status" jdbcType="INTEGER" property="status"/> | ||||
| <result column="apply_status" jdbcType="INTEGER" property="applyStatus"/> | |||||
| <result column="apply_pay_img" jdbcType="INTEGER" property="applyPayImg"/> | |||||
| <result column="apply_update_time" jdbcType="INTEGER" property="applyUpdateTime"/> | |||||
| <result column="is_del" jdbcType="INTEGER" property="isDel"/> | <result column="is_del" jdbcType="INTEGER" property="isDel"/> | ||||
| <result column="contract_need_pay" jdbcType="BIGINT" property="contractNeedPay"/> | <result column="contract_need_pay" jdbcType="BIGINT" property="contractNeedPay"/> | ||||
| <result column="rent_price_info" jdbcType="VARCHAR" property="rentPriceInfo"/> | <result column="rent_price_info" jdbcType="VARCHAR" property="rentPriceInfo"/> | ||||
| @@ -56,7 +59,7 @@ | |||||
| <sql id="allColumns"> | <sql id="allColumns"> | ||||
| `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`, | `id`,`tenant_id`,`parent_tenant_id`,`rent_contract_id`,`receive_pay`,`pay`,`receive_date`,`pay_date`, | ||||
| `createtime`,`expired_day`,`owe`,`status`,`is_del`,`contract_need_pay`,`rent_price_info`,`need_pay`, | `createtime`,`expired_day`,`owe`,`status`,`is_del`,`contract_need_pay`,`rent_price_info`,`need_pay`, | ||||
| `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`, | |||||
| `merchant_id`,`user_id`,`shop_id`,`updatetime`,`rent_shop_type`,`apply_status`,`apply_pay_img`,`apply_update_time`, | |||||
| `revenue`,`late_pay_ratio`,`late_pay_time`,`late_pay_price`,`period`,`is_preview`,`shop_info`, | `revenue`,`late_pay_ratio`,`late_pay_time`,`late_pay_price`,`period`,`is_preview`,`shop_info`, | ||||
| `pay_way`,`late_pay_status`,`comments`,starttime,endtime,bus_discount_ratio,freeze,join_rent_price,service_charge_pay | `pay_way`,`late_pay_status`,`comments`,starttime,endtime,bus_discount_ratio,freeze,join_rent_price,service_charge_pay | ||||
| </sql> | </sql> | ||||
| @@ -79,6 +82,7 @@ | |||||
| <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | <if test=" null != expiredDay ">and `expired_day` = #{expiredDay}</if> | ||||
| <if test=" null != owe ">and `owe` = #{owe}</if> | <if test=" null != owe ">and `owe` = #{owe}</if> | ||||
| <if test=" null != status ">and `status` = #{status}</if> | <if test=" null != status ">and `status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and `apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != isDel ">and `is_del` = #{isDel}</if> | <if test=" null != isDel ">and `is_del` = #{isDel}</if> | ||||
| <if test=" null != needPay ">and `need_pay` = #{needPay}</if> | <if test=" null != needPay ">and `need_pay` = #{needPay}</if> | ||||
| <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and `merchant_id` = #{merchantId}</if> | ||||
| @@ -109,7 +113,7 @@ | |||||
| <select id="queryBillRentList" parameterType="com.iformall.domain.po.WxBillRent" resultMap="BaseResultMap"> | <select id="queryBillRentList" parameterType="com.iformall.domain.po.WxBillRent" resultMap="BaseResultMap"> | ||||
| select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | select br.`id`,br.`receive_pay`,br.`pay`,br.`receive_date`,br.`pay_date`,br.`createtime`,br.`expired_day`, | ||||
| case when br.status=1 then br.owe else 0 end owe,br.`status`,br.`contract_need_pay`,br.`rent_price_info`,br.`need_pay`,r.merchant_name, | case when br.status=1 then br.owe else 0 end owe,br.`status`,br.`contract_need_pay`,br.`rent_price_info`,br.`need_pay`,r.merchant_name, | ||||
| br.`updatetime`,br.`merchant_id`,br.`rent_shop_type`,r.type as rent_type, | |||||
| br.`updatetime`,br.`merchant_id`,br.`rent_shop_type`,r.type as rent_type,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | |||||
| r.pay_ratio,br.`revenue`,r.`late_pay_ratio`,br.`late_pay_time`,br.`period`,br.`rent_contract_id`, | r.pay_ratio,br.`revenue`,r.`late_pay_ratio`,br.`late_pay_time`,br.`period`,br.`rent_contract_id`, | ||||
| d.receive_pay deposit,d.`status` | d.receive_pay deposit,d.`status` | ||||
| deposit_status,br.late_pay_price,br.shop_info,br.pay_way,br.late_pay_status,br.`comments`,br.starttime,br.endtime, | deposit_status,br.late_pay_price,br.shop_info,br.pay_way,br.late_pay_status,br.`comments`,br.starttime,br.endtime, | ||||
| @@ -122,6 +126,7 @@ | |||||
| <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | ||||
| <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | <if test=" null != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | ||||
| <if test=" null != status ">and br.`status` = #{status}</if> | <if test=" null != status ">and br.`status` = #{status}</if> | ||||
| <if test=" null != applyStatus ">and br.`apply_status` = #{applyStatus}</if> | |||||
| <if test=" null != depositStatus ">and d.`status` = #{depositStatus}</if> | <if test=" null != depositStatus ">and d.`status` = #{depositStatus}</if> | ||||
| <if test=" null != id ">and br.`id` = #{id}</if> | <if test=" null != id ">and br.`id` = #{id}</if> | ||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | ||||