| @@ -10,6 +10,7 @@ import com.iformall.controller.base.BaseController; | |||||
| import com.iformall.controller.mem.BillDailyAsyncTask; | import com.iformall.controller.mem.BillDailyAsyncTask; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillDaily; | import com.iformall.domain.po.WxBillDaily; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.enums.EnumBillDailyBuildWay; | import com.iformall.enums.EnumBillDailyBuildWay; | ||||
| import com.iformall.exception.MallinkException; | import com.iformall.exception.MallinkException; | ||||
| @@ -74,6 +75,20 @@ public class WxBillDailyController extends BaseController { | |||||
| final PageInfo<WxBillDaily> page = wxBillDailyService.listAsPage(wxBillDaily, pageNum, pageSize); | final PageInfo<WxBillDaily> page = wxBillDailyService.listAsPage(wxBillDaily, pageNum, pageSize); | ||||
| return new ResultData(page); | return new ResultData(page); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillDaily wxBillDaily) { | |||||
| if (StringUtils.isBlank(wxBillDaily.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillDaily.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillDaily.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillDaily.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillDailyService.getBillMonthSum(wxBillDaily)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "日常账单-新增") | @SystemControllerLog(description = "日常账单-新增") | ||||
| @@ -1,11 +1,13 @@ | |||||
| package com.iformall.controller.rent; | package com.iformall.controller.rent; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.annotation.SystemControllerLog; | import com.iformall.annotation.SystemControllerLog; | ||||
| import com.iformall.common.Result; | import com.iformall.common.Result; | ||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.controller.base.BaseController; | import com.iformall.controller.base.BaseController; | ||||
| import com.iformall.domain.po.WxBillDeposit; | import com.iformall.domain.po.WxBillDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.service.WxBillDepositService; | import com.iformall.service.WxBillDepositService; | ||||
| import io.swagger.annotations.ApiImplicitParam; | import io.swagger.annotations.ApiImplicitParam; | ||||
| @@ -45,6 +47,20 @@ public class WxBillDepositController extends BaseController { | |||||
| final PageInfo<WxBillDeposit> page = wxBillDepositService.listAsPage(wxBillDeposit, pageNum, pageSize); | final PageInfo<WxBillDeposit> page = wxBillDepositService.listAsPage(wxBillDeposit, pageNum, pageSize); | ||||
| return new ResultData(page); | return new ResultData(page); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillDeposit wxBillDeposit) { | |||||
| if (StringUtils.isBlank(wxBillDeposit.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillDeposit.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillDeposit.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillDeposit.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillDepositService.getBillMonthSum(wxBillDeposit)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "租赁押金-新增") | @SystemControllerLog(description = "租赁押金-新增") | ||||
| @@ -1,5 +1,6 @@ | |||||
| package com.iformall.controller.rent; | package com.iformall.controller.rent; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.annotation.SystemControllerLog; | import com.iformall.annotation.SystemControllerLog; | ||||
| import com.iformall.common.Result; | import com.iformall.common.Result; | ||||
| @@ -7,6 +8,7 @@ import com.iformall.common.ResultData; | |||||
| import com.iformall.controller.base.BaseController; | import com.iformall.controller.base.BaseController; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillOther; | import com.iformall.domain.po.WxBillOther; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.service.WxBillOtherService; | import com.iformall.service.WxBillOtherService; | ||||
| import io.swagger.annotations.ApiImplicitParam; | import io.swagger.annotations.ApiImplicitParam; | ||||
| @@ -48,6 +50,20 @@ public class WxBillOtherController extends BaseController { | |||||
| final PageInfo<WxBillOther> page = wxBillOtherService.listAsPage(wxBillOther, pageNum, pageSize); | final PageInfo<WxBillOther> page = wxBillOtherService.listAsPage(wxBillOther, pageNum, pageSize); | ||||
| return new ResultData(page); | return new ResultData(page); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillOther wxBillOther) { | |||||
| if (StringUtils.isBlank(wxBillOther.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillOther.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillOther.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillOther.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillOtherService.getBillMonthSum(wxBillOther)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "其它账单-新增") | @SystemControllerLog(description = "其它账单-新增") | ||||
| @@ -1,5 +1,6 @@ | |||||
| package com.iformall.controller.rent; | package com.iformall.controller.rent; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.annotation.SystemControllerLog; | import com.iformall.annotation.SystemControllerLog; | ||||
| import com.iformall.common.Result; | import com.iformall.common.Result; | ||||
| @@ -7,6 +8,7 @@ import com.iformall.common.ResultData; | |||||
| import com.iformall.controller.base.BaseController; | import com.iformall.controller.base.BaseController; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillOtherDeposit; | import com.iformall.domain.po.WxBillOtherDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.service.WxBillOtherDepositService; | import com.iformall.service.WxBillOtherDepositService; | ||||
| import io.swagger.annotations.ApiImplicitParam; | import io.swagger.annotations.ApiImplicitParam; | ||||
| @@ -49,6 +51,20 @@ public class WxBillOtherDepositController extends BaseController { | |||||
| final PageInfo<WxBillOtherDeposit> page = wxBillOtherDepositService.listAsPage(wxBillOtherDeposit, pageNum, pageSize); | final PageInfo<WxBillOtherDeposit> page = wxBillOtherDepositService.listAsPage(wxBillOtherDeposit, pageNum, pageSize); | ||||
| return new ResultData(page); | return new ResultData(page); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillOtherDeposit wxBillOtherDeposit) { | |||||
| if (StringUtils.isBlank(wxBillOtherDeposit.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillOtherDeposit.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillOtherDeposit.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillOtherDeposit.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillOtherDepositService.getBillMonthSum(wxBillOtherDeposit)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "其它押金账单-新增") | @SystemControllerLog(description = "其它押金账单-新增") | ||||
| @@ -1,11 +1,13 @@ | |||||
| package com.iformall.controller.rent; | package com.iformall.controller.rent; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.annotation.SystemControllerLog; | import com.iformall.annotation.SystemControllerLog; | ||||
| import com.iformall.common.Result; | import com.iformall.common.Result; | ||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.controller.base.BaseController; | import com.iformall.controller.base.BaseController; | ||||
| import com.iformall.domain.po.WxBillProperty; | import com.iformall.domain.po.WxBillProperty; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.domain.po.base.BaseEntity; | import com.iformall.domain.po.base.BaseEntity; | ||||
| import com.iformall.service.WxBillPropertyService; | import com.iformall.service.WxBillPropertyService; | ||||
| @@ -51,6 +53,20 @@ public class WxBillPropertyController extends BaseController { | |||||
| PageInfo<WxBillProperty> result = wxBillPropertyService.listAsPage(wxBillProperty, pageNum, pageSize); | PageInfo<WxBillProperty> result = wxBillPropertyService.listAsPage(wxBillProperty, pageNum, pageSize); | ||||
| return new ResultData(result); | return new ResultData(result); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillProperty wxBillProperty) { | |||||
| if (StringUtils.isBlank(wxBillProperty.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillProperty.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillProperty.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillProperty.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillPropertyService.getBillMonthSum(wxBillProperty)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "物业账单-新增") | @SystemControllerLog(description = "物业账单-新增") | ||||
| @@ -1,11 +1,13 @@ | |||||
| package com.iformall.controller.rent; | package com.iformall.controller.rent; | ||||
| import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; | |||||
| import com.github.pagehelper.PageInfo; | import com.github.pagehelper.PageInfo; | ||||
| import com.iformall.annotation.SystemControllerLog; | import com.iformall.annotation.SystemControllerLog; | ||||
| import com.iformall.common.Result; | import com.iformall.common.Result; | ||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.controller.base.BaseController; | import com.iformall.controller.base.BaseController; | ||||
| import com.iformall.domain.po.WxBillPropertyDeposit; | import com.iformall.domain.po.WxBillPropertyDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxUserDataRule; | import com.iformall.domain.po.WxUserDataRule; | ||||
| import com.iformall.service.WxBillPropertyDepositService; | import com.iformall.service.WxBillPropertyDepositService; | ||||
| import io.swagger.annotations.ApiImplicitParam; | import io.swagger.annotations.ApiImplicitParam; | ||||
| @@ -45,6 +47,20 @@ public class WxBillPropertyDepositController extends BaseController { | |||||
| PageInfo<WxBillPropertyDeposit> result = wxBillPropertyDepositService.listAsPage(wxBillPropertyDeposit, pageNum, pageSize); | PageInfo<WxBillPropertyDeposit> result = wxBillPropertyDepositService.listAsPage(wxBillPropertyDeposit, pageNum, pageSize); | ||||
| return new ResultData(result); | return new ResultData(result); | ||||
| } | } | ||||
| @GetMapping("monthBillSum") | |||||
| public ResultData monthBillSum(@ModelAttribute WxBillPropertyDeposit wxBillPropertyDeposit) { | |||||
| if (StringUtils.isBlank(wxBillPropertyDeposit.getMonth())) { | |||||
| new ResultData(Result.ERROR, "请选择月份"); | |||||
| } | |||||
| wxBillPropertyDeposit.updateTenantInfo(getTenantInfo()); | |||||
| WxUserDataRule dataRule = this.getCurrentDataFloors(); | |||||
| if (null != dataRule) { | |||||
| wxBillPropertyDeposit.setFloorForRule(dataRule.getFloorIds()); | |||||
| wxBillPropertyDeposit.setBusinessForRule(dataRule.getBussinessIds()); | |||||
| } | |||||
| return new ResultData(wxBillPropertyDepositService.getBillMonthSum(wxBillPropertyDeposit)); | |||||
| } | |||||
| @PostMapping("add") | @PostMapping("add") | ||||
| @SystemControllerLog(description = "物业押金账单-新增") | @SystemControllerLog(description = "物业押金账单-新增") | ||||
| @@ -131,4 +131,7 @@ public class WxBillDaily extends TenantEntity { | |||||
| private String serviceChargePayUpdate; | private String serviceChargePayUpdate; | ||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -99,4 +99,7 @@ public class WxBillDeposit extends TenantEntity { | |||||
| private List<Long> rentContractIdList; | private List<Long> rentContractIdList; | ||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -163,5 +163,8 @@ public class WxBillOther extends TenantEntity { | |||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -166,4 +166,7 @@ public class WxBillOtherDeposit extends TenantEntity { | |||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -231,4 +231,7 @@ public class WxBillProperty extends TenantEntity { | |||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -98,4 +98,7 @@ public class WxBillPropertyDeposit extends TenantEntity { | |||||
| private List<Long> propertyContractIdList; | private List<Long> propertyContractIdList; | ||||
| @TableField(exist = false) | @TableField(exist = false) | ||||
| private List<Long> merchantIds; | private List<Long> merchantIds; | ||||
| @TableField(exist = false) | |||||
| private String month; | |||||
| } | } | ||||
| @@ -2,6 +2,8 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillDaily; | import com.iformall.domain.po.WxBillDaily; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -18,5 +20,7 @@ public interface WxBillDailyMapper extends CommonMapper<WxBillDaily, Long> { | |||||
| void updateWaitPayStatus(Map<String,Object> params); | void updateWaitPayStatus(Map<String,Object> params); | ||||
| List<WxBillDaily> queryBillDailyList(WxBillDaily record); | List<WxBillDaily> queryBillDailyList(WxBillDaily record); | ||||
| WxBillSum getBillMonthSum(WxBillDaily record); | |||||
| } | } | ||||
| @@ -4,6 +4,7 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillDeposit; | import com.iformall.domain.po.WxBillDeposit; | ||||
| import com.iformall.domain.po.WxRentContract; | import com.iformall.domain.po.WxRentContract; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -30,5 +31,6 @@ public interface WxBillDepositMapper extends CommonMapper<WxBillDeposit, Long> { | |||||
| long queryOweCount(WxRentContract wxRentContract); | long queryOweCount(WxRentContract wxRentContract); | ||||
| WxBillSum getBillMonthSum(WxBillDeposit wxBillDeposit); | |||||
| } | } | ||||
| @@ -2,6 +2,8 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillOtherDeposit; | import com.iformall.domain.po.WxBillOtherDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -18,5 +20,7 @@ public interface WxBillOtherDepositMapper extends CommonMapper<WxBillOtherDeposi | |||||
| void updateWaitPayStatus(Map<String, Object> params); | void updateWaitPayStatus(Map<String, Object> params); | ||||
| List<WxBillOtherDeposit> queryBillList(WxBillOtherDeposit record); | List<WxBillOtherDeposit> queryBillList(WxBillOtherDeposit record); | ||||
| WxBillSum getBillMonthSum(WxBillOtherDeposit record); | |||||
| } | } | ||||
| @@ -2,6 +2,8 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillOther; | import com.iformall.domain.po.WxBillOther; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -22,4 +24,6 @@ public interface WxBillOtherMapper extends CommonMapper<WxBillOther, Long> { | |||||
| Map<String,Object> queryPayInfoTotal(Map<String,Object> params); | Map<String,Object> queryPayInfoTotal(Map<String,Object> params); | ||||
| Map<String,Object> queryOweInfo(Map<String,Object> params); | Map<String,Object> queryOweInfo(Map<String,Object> params); | ||||
| WxBillSum getBillMonthSum(WxBillOther record); | |||||
| } | } | ||||
| @@ -2,7 +2,9 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillPropertyDeposit; | import com.iformall.domain.po.WxBillPropertyDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxPropertyContract; | import com.iformall.domain.po.WxPropertyContract; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -26,5 +28,7 @@ public interface WxBillPropertyDepositMapper extends CommonMapper<WxBillProperty | |||||
| long queryOweCount(WxPropertyContract wxPropertyContract); | long queryOweCount(WxPropertyContract wxPropertyContract); | ||||
| WxBillSum getBillMonthSum(WxBillPropertyDeposit wxBillPropertyDeposit); | |||||
| } | } | ||||
| @@ -2,9 +2,11 @@ package com.iformall.mapper; | |||||
| import com.iformall.common.CommonMapper; | import com.iformall.common.CommonMapper; | ||||
| import com.iformall.domain.po.WxBillProperty; | import com.iformall.domain.po.WxBillProperty; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.po.WxPropertyContract; | import com.iformall.domain.po.WxPropertyContract; | ||||
| import com.iformall.domain.po.WxRentContract; | import com.iformall.domain.po.WxRentContract; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import java.util.List; | import java.util.List; | ||||
| import java.util.Map; | import java.util.Map; | ||||
| @@ -61,5 +63,8 @@ public interface WxBillPropertyMapper extends CommonMapper<WxBillProperty, Long> | |||||
| void updateServiceCharge(WxPayAccountBill tenantId); | void updateServiceCharge(WxPayAccountBill tenantId); | ||||
| void updateOwe(); | void updateOwe(); | ||||
| WxBillSum getBillMonthSum(WxBillProperty propertyQuery); | |||||
| } | } | ||||
| @@ -4,8 +4,10 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillDaily; | import com.iformall.domain.po.WxBillDaily; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillDailyVo; | import com.iformall.domain.vo.WxBillDailyVo; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import javax.servlet.http.HttpServletRequest; | import javax.servlet.http.HttpServletRequest; | ||||
| import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.HttpServletResponse; | ||||
| @@ -58,5 +60,7 @@ public interface WxBillDailyService { | |||||
| void insertData(WxBillDailyVo billDaily, String importKey, MallUserInfo user); | void insertData(WxBillDailyVo billDaily, String importKey, MallUserInfo user); | ||||
| void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillDaily wxBillDaily); | void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillDaily wxBillDaily); | ||||
| WxBillSum getBillMonthSum(WxBillDaily wxBillDaily); | |||||
| } | } | ||||
| @@ -5,6 +5,7 @@ import com.iformall.common.ResultData; | |||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillDeposit; | import com.iformall.domain.po.WxBillDeposit; | ||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| public interface WxBillDepositService { | public interface WxBillDepositService { | ||||
| @@ -51,5 +52,7 @@ public interface WxBillDepositService { | |||||
| ResultData adjustDeposit(WxBillDeposit wxBillDeposit); | ResultData adjustDeposit(WxBillDeposit wxBillDeposit); | ||||
| void computeTotalMoney(Integer decimalSize,WxPayAccountBill wxPayAccountBill, WxBillDeposit deposit); | void computeTotalMoney(Integer decimalSize,WxPayAccountBill wxPayAccountBill, WxBillDeposit deposit); | ||||
| WxBillSum getBillMonthSum(WxBillDeposit wxBillDeposit); | |||||
| } | } | ||||
| @@ -4,7 +4,9 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillOtherDeposit; | import com.iformall.domain.po.WxBillOtherDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import javax.servlet.http.HttpServletRequest; | import javax.servlet.http.HttpServletRequest; | ||||
| import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.HttpServletResponse; | ||||
| @@ -57,5 +59,7 @@ public interface WxBillOtherDepositService { | |||||
| ResultData adjustDeposit(WxBillOtherDeposit wxBillDeposit); | ResultData adjustDeposit(WxBillOtherDeposit wxBillDeposit); | ||||
| void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillOtherDeposit wxBillDeposit); | void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillOtherDeposit wxBillDeposit); | ||||
| WxBillSum getBillMonthSum(WxBillOtherDeposit wxBillDeposit); | |||||
| } | } | ||||
| @@ -4,7 +4,9 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillOther; | import com.iformall.domain.po.WxBillOther; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import javax.servlet.http.HttpServletRequest; | import javax.servlet.http.HttpServletRequest; | ||||
| import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.HttpServletResponse; | ||||
| @@ -53,5 +55,7 @@ public interface WxBillOtherService { | |||||
| ResultData updatePaid(Long id); | ResultData updatePaid(Long id); | ||||
| void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillOther wxBillOther); | void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillOther wxBillOther); | ||||
| WxBillSum getBillMonthSum(WxBillOther wxBillOther); | |||||
| } | } | ||||
| @@ -4,7 +4,9 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillPropertyDeposit; | import com.iformall.domain.po.WxBillPropertyDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| /** | /** | ||||
| * @author gongbiao | * @author gongbiao | ||||
| @@ -54,4 +56,6 @@ public interface WxBillPropertyDepositService { | |||||
| ResultData adjustDeposit(WxBillPropertyDeposit wxBillPropertyDeposit); | ResultData adjustDeposit(WxBillPropertyDeposit wxBillPropertyDeposit); | ||||
| void computeTotalMoney(Integer decimalSize,WxPayAccountBill wxPayAccountBill, WxBillPropertyDeposit deposit); | void computeTotalMoney(Integer decimalSize,WxPayAccountBill wxPayAccountBill, WxBillPropertyDeposit deposit); | ||||
| WxBillSum getBillMonthSum(WxBillPropertyDeposit deposit); | |||||
| } | } | ||||
| @@ -4,7 +4,9 @@ import com.github.pagehelper.PageInfo; | |||||
| import com.iformall.common.ResultData; | import com.iformall.common.ResultData; | ||||
| import com.iformall.domain.po.MallUserInfo; | import com.iformall.domain.po.MallUserInfo; | ||||
| import com.iformall.domain.po.WxBillProperty; | import com.iformall.domain.po.WxBillProperty; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import javax.servlet.http.HttpServletRequest; | import javax.servlet.http.HttpServletRequest; | ||||
| import javax.servlet.http.HttpServletResponse; | import javax.servlet.http.HttpServletResponse; | ||||
| @@ -68,4 +70,6 @@ public interface WxBillPropertyService { | |||||
| ResultData updateLatePayStatus(WxBillProperty wxBillProperty); | ResultData updateLatePayStatus(WxBillProperty wxBillProperty); | ||||
| void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillProperty wxBillProperty); | void exportBill(HttpServletRequest request, HttpServletResponse response, WxBillProperty wxBillProperty); | ||||
| WxBillSum getBillMonthSum(WxBillProperty wxBillProperty); | |||||
| } | } | ||||
| @@ -12,6 +12,7 @@ import com.iformall.domain.po.*; | |||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillDailyExportVo; | import com.iformall.domain.vo.WxBillDailyExportVo; | ||||
| import com.iformall.domain.vo.WxBillDailyVo; | import com.iformall.domain.vo.WxBillDailyVo; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.*; | import com.iformall.enums.*; | ||||
| import com.iformall.exception.MallinkException; | import com.iformall.exception.MallinkException; | ||||
| import com.iformall.mapper.WxBillDailyMapper; | import com.iformall.mapper.WxBillDailyMapper; | ||||
| @@ -77,7 +78,7 @@ public class WxBillDailyServiceImpl implements WxBillDailyService { | |||||
| return getBillRentPropertyList(pageIndex, pageSize, record, wxPayAccountBill); | return getBillRentPropertyList(pageIndex, pageSize, record, wxPayAccountBill); | ||||
| } | } | ||||
| private PageInfo<WxBillDaily> getBillRentPropertyList(Integer pageIndex, Integer pageSize,WxBillDaily record,WxPayAccountBill wxPayAccountBill) { | |||||
| private void updateQueryParam(WxBillDaily record) { | |||||
| if (null != record.getFloorForRule()) { | if (null != record.getFloorForRule()) { | ||||
| List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | ||||
| if (null != merchantIds) { | if (null != merchantIds) { | ||||
| @@ -107,7 +108,10 @@ public class WxBillDailyServiceImpl implements WxBillDailyService { | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillDaily> getBillRentPropertyList(Integer pageIndex, Integer pageSize,WxBillDaily record,WxPayAccountBill wxPayAccountBill) { | |||||
| updateQueryParam(record); | |||||
| PageInfo<WxBillDaily> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillDailyMapper.queryBillDailyList(record)); | PageInfo<WxBillDaily> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillDailyMapper.queryBillDailyList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -453,5 +457,11 @@ public class WxBillDailyServiceImpl implements WxBillDailyService { | |||||
| excelService.exportExcel(datalist, null, "日常费用账单", WxBillDailyExportVo.class, "日常费用账单.xlsx", response, false); | excelService.exportExcel(datalist, null, "日常费用账单", WxBillDailyExportVo.class, "日常费用账单.xlsx", response, false); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillDaily record) { | |||||
| updateQueryParam(record); | |||||
| return wxBillDailyMapper.getBillMonthSum(record); | |||||
| } | |||||
| } | } | ||||
| @@ -14,6 +14,7 @@ import com.iformall.domain.po.WxBillOtherDeposit; | |||||
| import com.iformall.domain.po.WxMerchant; | import com.iformall.domain.po.WxMerchant; | ||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.po.WxShop; | import com.iformall.domain.po.WxShop; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.EnumBillAction; | import com.iformall.enums.EnumBillAction; | ||||
| import com.iformall.enums.EnumBillPayWay; | import com.iformall.enums.EnumBillPayWay; | ||||
| import com.iformall.enums.EnumBillRentStatus; | import com.iformall.enums.EnumBillRentStatus; | ||||
| @@ -72,7 +73,7 @@ public class WxBillDepositServiceImpl implements WxBillDepositService { | |||||
| return getBillDepositPropertyList(wxPayAccountBill, record, pageIndex, pageSize); | return getBillDepositPropertyList(wxPayAccountBill, record, pageIndex, pageSize); | ||||
| } | } | ||||
| private PageInfo<WxBillDeposit> getBillDepositPropertyList(WxPayAccountBill wxPayAccountBill,WxBillDeposit record, Integer pageIndex, Integer pageSize) { | |||||
| private void setQueryParam(WxBillDeposit record) { | |||||
| if (null != record.getFloorForRule()) { | if (null != record.getFloorForRule()) { | ||||
| List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | ||||
| if (null != merchantIds) { | if (null != merchantIds) { | ||||
| @@ -102,7 +103,10 @@ public class WxBillDepositServiceImpl implements WxBillDepositService { | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillDeposit> getBillDepositPropertyList(WxPayAccountBill wxPayAccountBill,WxBillDeposit record, Integer pageIndex, Integer pageSize) { | |||||
| setQueryParam(record); | |||||
| PageInfo<WxBillDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillDepositMapper.queryBillDepositList(record)); | PageInfo<WxBillDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillDepositMapper.queryBillDepositList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -359,5 +363,11 @@ public class WxBillDepositServiceImpl implements WxBillDepositService { | |||||
| return new ResultData(Result.SUCCESS, "租赁押金调整成功", wxBillDeposit); | return new ResultData(Result.SUCCESS, "租赁押金调整成功", wxBillDeposit); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillDeposit wxBillDeposit) { | |||||
| setQueryParam(wxBillDeposit); | |||||
| return wxBillDepositMapper.getBillMonthSum(wxBillDeposit); | |||||
| } | |||||
| } | } | ||||
| @@ -11,9 +11,11 @@ import com.iformall.domain.po.MallUserInfo; | |||||
| import com.iformall.domain.po.WxBillAction; | import com.iformall.domain.po.WxBillAction; | ||||
| import com.iformall.domain.po.WxBillDaily; | import com.iformall.domain.po.WxBillDaily; | ||||
| import com.iformall.domain.po.WxBillOtherDeposit; | import com.iformall.domain.po.WxBillOtherDeposit; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxMerchant; | import com.iformall.domain.po.WxMerchant; | ||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.*; | import com.iformall.enums.*; | ||||
| import com.iformall.exception.MallinkException; | import com.iformall.exception.MallinkException; | ||||
| import com.iformall.mapper.WxBillOtherDepositMapper; | import com.iformall.mapper.WxBillOtherDepositMapper; | ||||
| @@ -80,7 +82,7 @@ public class WxBillOtherDepositServiceImpl implements WxBillOtherDepositService | |||||
| } | } | ||||
| private PageInfo<WxBillOtherDeposit> getBillRentPropertyList(Integer pageIndex, Integer pageSize,WxBillOtherDeposit record,WxPayAccountBill wxPayAccountBill) { | |||||
| private void updateQueryParam(WxBillOtherDeposit record) { | |||||
| if (null != record.getFloorForRule()) { | if (null != record.getFloorForRule()) { | ||||
| List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | ||||
| if (null != merchantIds) { | if (null != merchantIds) { | ||||
| @@ -110,7 +112,10 @@ public class WxBillOtherDepositServiceImpl implements WxBillOtherDepositService | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillOtherDeposit> getBillRentPropertyList(Integer pageIndex, Integer pageSize,WxBillOtherDeposit record,WxPayAccountBill wxPayAccountBill) { | |||||
| updateQueryParam(record); | |||||
| PageInfo<WxBillOtherDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillOtherDepositMapper.queryBillList(record)); | PageInfo<WxBillOtherDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillOtherDepositMapper.queryBillList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -416,5 +421,10 @@ public class WxBillOtherDepositServiceImpl implements WxBillOtherDepositService | |||||
| excelService.exportExcel(list, null, "其他押金账单", WxBillOtherDeposit.class, "其他押金账单.xlsx", response, false); | excelService.exportExcel(list, null, "其他押金账单", WxBillOtherDeposit.class, "其他押金账单.xlsx", response, false); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillOtherDeposit wxBillDeposit) { | |||||
| updateQueryParam(wxBillDeposit); | |||||
| return wxBillOtherDepositMapper.getBillMonthSum(wxBillDeposit); | |||||
| } | |||||
| } | } | ||||
| @@ -11,9 +11,11 @@ import com.iformall.domain.po.MallUserInfo; | |||||
| import com.iformall.domain.po.WxBillAction; | import com.iformall.domain.po.WxBillAction; | ||||
| import com.iformall.domain.po.WxBillDaily; | import com.iformall.domain.po.WxBillDaily; | ||||
| import com.iformall.domain.po.WxBillOther; | import com.iformall.domain.po.WxBillOther; | ||||
| import com.iformall.domain.po.WxBillRent; | |||||
| import com.iformall.domain.po.WxMerchant; | import com.iformall.domain.po.WxMerchant; | ||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.*; | import com.iformall.enums.*; | ||||
| import com.iformall.exception.MallinkException; | import com.iformall.exception.MallinkException; | ||||
| import com.iformall.mapper.WxBillOtherMapper; | import com.iformall.mapper.WxBillOtherMapper; | ||||
| @@ -80,7 +82,7 @@ public class WxBillOtherServiceImpl implements WxBillOtherService { | |||||
| } | } | ||||
| private PageInfo<WxBillOther> getBillOtherPropertyList(Integer pageIndex, Integer pageSize,WxBillOther record,WxPayAccountBill wxPayAccountBill) { | |||||
| private void updateQueryParam(WxBillOther record) { | |||||
| if (null != record.getFloorForRule()) { | if (null != record.getFloorForRule()) { | ||||
| List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | ||||
| if (null != merchantIds) { | if (null != merchantIds) { | ||||
| @@ -110,7 +112,10 @@ public class WxBillOtherServiceImpl implements WxBillOtherService { | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillOther> getBillOtherPropertyList(Integer pageIndex, Integer pageSize,WxBillOther record,WxPayAccountBill wxPayAccountBill) { | |||||
| updateQueryParam(record); | |||||
| PageInfo<WxBillOther> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillOtherMapper.queryBillList(record)); | PageInfo<WxBillOther> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillOtherMapper.queryBillList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -360,5 +365,9 @@ public class WxBillOtherServiceImpl implements WxBillOtherService { | |||||
| excelService.exportExcel(list, null, "其他费用账单", WxBillOther.class, "其他费用账单.xlsx", response, false); | excelService.exportExcel(list, null, "其他费用账单", WxBillOther.class, "其他费用账单.xlsx", response, false); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillOther wxBillOther) { | |||||
| updateQueryParam(wxBillOther); | |||||
| return wxBillOtherMapper.getBillMonthSum(wxBillOther); | |||||
| } | |||||
| } | } | ||||
| @@ -14,6 +14,7 @@ import com.iformall.domain.po.WxBillPropertyDeposit; | |||||
| import com.iformall.domain.po.WxMerchant; | import com.iformall.domain.po.WxMerchant; | ||||
| import com.iformall.domain.po.WxPayAccountBill; | import com.iformall.domain.po.WxPayAccountBill; | ||||
| import com.iformall.domain.po.WxShop; | import com.iformall.domain.po.WxShop; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.EnumBillAction; | import com.iformall.enums.EnumBillAction; | ||||
| import com.iformall.enums.EnumBillPayWay; | import com.iformall.enums.EnumBillPayWay; | ||||
| import com.iformall.enums.EnumBillRentStatus; | import com.iformall.enums.EnumBillRentStatus; | ||||
| @@ -70,7 +71,7 @@ public class WxBillPropertyDepositServiceImpl implements WxBillPropertyDepositSe | |||||
| return getBillDepositPropertyList(wxPayAccountBill, record, pageIndex, pageSize); | return getBillDepositPropertyList(wxPayAccountBill, record, pageIndex, pageSize); | ||||
| } | } | ||||
| private PageInfo<WxBillPropertyDeposit> getBillDepositPropertyList(WxPayAccountBill wxPayAccountBill,WxBillPropertyDeposit record, Integer pageIndex, Integer pageSize) { | |||||
| private void updateQueryParam(WxBillPropertyDeposit record) { | |||||
| if (null != record.getFloorForRule()) { | if (null != record.getFloorForRule()) { | ||||
| List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | List<Long> merchantIds = wxMerchantService.getFloorBuildMerchantIds(record, record.getFloorForRule(), null, null, 0, 0); | ||||
| if (null != merchantIds) { | if (null != merchantIds) { | ||||
| @@ -100,7 +101,10 @@ public class WxBillPropertyDepositServiceImpl implements WxBillPropertyDepositSe | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillPropertyDeposit> getBillDepositPropertyList(WxPayAccountBill wxPayAccountBill,WxBillPropertyDeposit record, Integer pageIndex, Integer pageSize) { | |||||
| updateQueryParam(record); | |||||
| PageInfo<WxBillPropertyDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillPropertyDepositMapper.queryBillDepositList(record)); | PageInfo<WxBillPropertyDeposit> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillPropertyDepositMapper.queryBillDepositList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -357,5 +361,11 @@ public class WxBillPropertyDepositServiceImpl implements WxBillPropertyDepositSe | |||||
| return new ResultData(Result.SUCCESS, "物业押金调整成功", wxBillDeposit); | return new ResultData(Result.SUCCESS, "物业押金调整成功", wxBillDeposit); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillPropertyDeposit deposit) { | |||||
| updateQueryParam(deposit); | |||||
| return wxBillPropertyDepositMapper.getBillMonthSum(deposit); | |||||
| } | |||||
| } | } | ||||
| @@ -10,6 +10,7 @@ import com.iformall.common.ResultData; | |||||
| import com.iformall.domain.po.*; | import com.iformall.domain.po.*; | ||||
| import com.iformall.domain.po.base.BaseEntity; | import com.iformall.domain.po.base.BaseEntity; | ||||
| import com.iformall.domain.po.base.TenantEntity; | import com.iformall.domain.po.base.TenantEntity; | ||||
| import com.iformall.domain.vo.WxBillSum; | |||||
| import com.iformall.enums.*; | import com.iformall.enums.*; | ||||
| import com.iformall.exception.MallinkException; | import com.iformall.exception.MallinkException; | ||||
| import com.iformall.mapper.WxBillActionMapper; | import com.iformall.mapper.WxBillActionMapper; | ||||
| @@ -79,7 +80,7 @@ public class WxBillPropertyServiceImpl implements WxBillPropertyService { | |||||
| return getBillPropertyList(pageIndex, pageSize, wxPayAccountBill, record); | return getBillPropertyList(pageIndex, pageSize, wxPayAccountBill, record); | ||||
| } | } | ||||
| private PageInfo<WxBillProperty> getBillPropertyList(Integer pageIndex, Integer pageSize,WxPayAccountBill wxPayAccountBill,WxBillProperty record) { | |||||
| private void updateQueryParam(WxBillProperty record) { | |||||
| if(null != record.getDepositStatus()) { | if(null != record.getDepositStatus()) { | ||||
| WxBillPropertyDeposit bdq1 = new WxBillPropertyDeposit(); | WxBillPropertyDeposit bdq1 = new WxBillPropertyDeposit(); | ||||
| bdq1.updateTenantInfo(record); | bdq1.updateTenantInfo(record); | ||||
| @@ -120,7 +121,10 @@ public class WxBillPropertyServiceImpl implements WxBillPropertyService { | |||||
| record.setId(-1L); | record.setId(-1L); | ||||
| } | } | ||||
| } | } | ||||
| } | |||||
| private PageInfo<WxBillProperty> getBillPropertyList(Integer pageIndex, Integer pageSize,WxPayAccountBill wxPayAccountBill,WxBillProperty record) { | |||||
| updateQueryParam(record); | |||||
| PageInfo<WxBillProperty> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillPropertyMapper.queryBillPropertyList(record)); | PageInfo<WxBillProperty> page = PageHelper.startPage(pageIndex, pageSize).doSelectPageInfo(() -> wxBillPropertyMapper.queryBillPropertyList(record)); | ||||
| if (null == page) { | if (null == page) { | ||||
| return null; | return null; | ||||
| @@ -506,4 +510,10 @@ public class WxBillPropertyServiceImpl implements WxBillPropertyService { | |||||
| wxBillPropertyMapper.updateById(property); | wxBillPropertyMapper.updateById(property); | ||||
| return new ResultData(); | return new ResultData(); | ||||
| } | } | ||||
| @Override | |||||
| public WxBillSum getBillMonthSum(WxBillProperty wxBillProperty) { | |||||
| updateQueryParam(wxBillProperty); | |||||
| return wxBillPropertyMapper.getBillMonthSum(wxBillProperty); | |||||
| } | |||||
| } | } | ||||
| @@ -81,12 +81,7 @@ | |||||
| <include refid="dynamicWhereConditions" /> | <include refid="dynamicWhereConditions" /> | ||||
| </select> | </select> | ||||
| <select id="queryBillDailyList" parameterType="com.iformall.domain.po.WxBillDaily" resultMap="BaseResultMap"> | |||||
| 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.`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.`apply_status`,br.`apply_pay_img`,br.`apply_update_time` | |||||
| from wx_bill_daily br | |||||
| <sql id = "queryBillDailyListConditions" > | |||||
| <where> | <where> | ||||
| <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | ||||
| <if test=" null != id ">and br.`id` = #{id}</if> | <if test=" null != id ">and br.`id` = #{id}</if> | ||||
| @@ -97,7 +92,10 @@ | |||||
| <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> | ||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | ||||
| <if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime} | |||||
| <if test=" null != starttime">and br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </if> | </if> | ||||
| <if test=" null != buildWay ">and br.`build_way` = #{buildWay}</if> | <if test=" null != buildWay ">and br.`build_way` = #{buildWay}</if> | ||||
| <if test=" null != merchantIds "> | <if test=" null != merchantIds "> | ||||
| @@ -108,11 +106,29 @@ | |||||
| </if> | </if> | ||||
| </where> | </where> | ||||
| </sql> | |||||
| <select id="queryBillDailyList" parameterType="com.iformall.domain.po.WxBillDaily" resultMap="BaseResultMap"> | |||||
| 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.`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.`apply_status`,br.`apply_pay_img`,br.`apply_update_time` | |||||
| from wx_bill_daily br | |||||
| <include refid="queryBillDailyListConditions" /> | |||||
| <if test=" null != sortColumns"> order by ${sortColumns} </if> | <if test=" null != sortColumns"> order by ${sortColumns} </if> | ||||
| <if test=" null == sortColumns">order by id desc</if> | <if test=" null == sortColumns">order by id desc</if> | ||||
| </select> | </select> | ||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillDaily" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_daily br | |||||
| <include refid="queryBillDailyListConditions"/> | |||||
| </select> | |||||
| <update id="updateNotPaidStatus" parameterType="hashmap"> | <update id="updateNotPaidStatus" parameterType="hashmap"> | ||||
| update wx_bill_daily set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | update wx_bill_daily set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | ||||
| where status!=#{paid} | where status!=#{paid} | ||||
| @@ -97,31 +97,51 @@ | |||||
| br.`owe`,br.`status`,br.`need_pay`,br.`updatetime`,br.`merchant_id`,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time`, | br.`owe`,br.`status`,br.`need_pay`,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 | from wx_bill_rent_deposit br | ||||
| <where> | |||||
| 1 = 1 | |||||
| <if test=" null != id ">and br.`id` = #{id}</if> | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | |||||
| <if test=" null != tenantId and '' != tenantId"> | |||||
| and br.`tenant_id` = #{tenantId} | |||||
| </if> | |||||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||||
| and br.`parent_tenant_id` = #{parentTenantId} | |||||
| </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 != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | |||||
| <if test=" null != rentContractId ">and br.`rent_contract_id` = #{rentContractId}</if> | |||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | |||||
| <if test=" null != merchantIds "> | |||||
| and br.`merchant_id` in | |||||
| <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | |||||
| #{midItem} | |||||
| </foreach> | |||||
| </if> | |||||
| </where> | |||||
| <include refid="queryBillRentListCondition"/> | |||||
| order by br.id desc | order by br.id desc | ||||
| </select> | </select> | ||||
| <sql id="queryBillRentListCondition"> | |||||
| <where> | |||||
| 1 = 1 | |||||
| <if test=" null != id ">and br.`id` = #{id}</if> | |||||
| <if test=" null != merchantId ">and br.`merchant_id` = #{merchantId}</if> | |||||
| <if test=" null != tenantId and '' != tenantId"> | |||||
| and br.`tenant_id` = #{tenantId} | |||||
| </if> | |||||
| <if test=" null != parentTenantId and '' != parentTenantId"> | |||||
| and br.`parent_tenant_id` = #{parentTenantId} | |||||
| </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 != rentShopType ">and br.`rent_shop_type` = #{rentShopType}</if> | |||||
| <if test=" null != rentContractId ">and br.`rent_contract_id` = #{rentContractId}</if> | |||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | |||||
| <if test=" null != starttime">and br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </if> | |||||
| <if test=" null != merchantIds "> | |||||
| and br.`merchant_id` in | |||||
| <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | |||||
| #{midItem} | |||||
| </foreach> | |||||
| </if> | |||||
| </where> | |||||
| </sql> | |||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillDeposit" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_rent_deposit br | |||||
| <include refid="queryBillRentListCondition"/> | |||||
| </select> | |||||
| <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | ||||
| select IFNULL(sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id,parent_tenant_id from wx_bill_rent_deposit | select IFNULL(sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id,parent_tenant_id from wx_bill_rent_deposit | ||||
| @@ -87,11 +87,7 @@ | |||||
| <include refid="dynamicWhereConditions"/> | <include refid="dynamicWhereConditions"/> | ||||
| </select> | </select> | ||||
| <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`, | |||||
| br.`owe`,br.`status`,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 | |||||
| from wx_bill_other_deposit br | |||||
| <sql id ="queryBillListConditions"> | |||||
| <where> | <where> | ||||
| <if test=" null != id ">and br.`id` = #{id}</if> | <if test=" null != id ">and br.`id` = #{id}</if> | ||||
| <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | ||||
| @@ -103,7 +99,11 @@ | |||||
| <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 != payWay ">and br.`pay_way` = #{payWay}</if> | <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | ||||
| <if test=" null != comments and ''!=comments">and br.`comments` like concat('%',#{comments},'%')</if> | <if test=" null != comments and ''!=comments">and br.`comments` like concat('%',#{comments},'%')</if> | ||||
| <if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime}</if> | |||||
| <if test=" null != starttime">and br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </if> | |||||
| <if test=" null != merchantIds "> | <if test=" null != merchantIds "> | ||||
| and br.`merchant_id` in | and br.`merchant_id` in | ||||
| <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | ||||
| @@ -112,10 +112,28 @@ | |||||
| </if> | </if> | ||||
| </where> | </where> | ||||
| </sql> | |||||
| <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`, | |||||
| br.`owe`,br.`status`,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 | |||||
| from wx_bill_other_deposit br | |||||
| <include refid="queryBillListConditions"/> | |||||
| <if test=" null != sortColumns"> order by ${sortColumns} </if> | <if test=" null != sortColumns"> order by ${sortColumns} </if> | ||||
| <if test=" null == sortColumns"> order by id desc </if> | <if test=" null == sortColumns"> order by id desc </if> | ||||
| </select> | </select> | ||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillOtherDeposit" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_other_deposit br | |||||
| <include refid="queryBillListConditions"/> | |||||
| </select> | |||||
| <update id="updateNotPaidStatus" parameterType="hashmap"> | <update id="updateNotPaidStatus" parameterType="hashmap"> | ||||
| update wx_bill_other_deposit set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | update wx_bill_other_deposit set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | ||||
| where status!=#{paid} | where status!=#{paid} | ||||
| @@ -83,12 +83,7 @@ | |||||
| <include refid="dynamicWhereConditions" /> | <include refid="dynamicWhereConditions" /> | ||||
| </select> | </select> | ||||
| <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`, | |||||
| case when br.status=1 then br.owe else 0 end owe,br.`status`,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.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | |||||
| from wx_bill_other br | |||||
| <sql id = "queryBillListConditions"> | |||||
| <where> | <where> | ||||
| <if test=" null != id ">and br.`id` = #{id}</if> | <if test=" null != id ">and br.`id` = #{id}</if> | ||||
| <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | <if test=" null != freeze ">and br.`freeze` = #{freeze}</if> | ||||
| @@ -99,7 +94,10 @@ | |||||
| <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> | ||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | ||||
| <if test=" null != starttime and null!=endtime ">and br.`receive_date` between #{starttime} and #{endtime} | |||||
| <if test=" null != starttime">and br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </if> | </if> | ||||
| <if test=" null != merchantIds "> | <if test=" null != merchantIds "> | ||||
| and br.`merchant_id` in | and br.`merchant_id` in | ||||
| @@ -109,10 +107,28 @@ | |||||
| </if> | </if> | ||||
| </where> | </where> | ||||
| </sql> | |||||
| <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`, | |||||
| case when br.status=1 then br.owe else 0 end owe,br.`status`,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.`starttime`,br.`endtime`,br.freeze,br.service_charge_pay | |||||
| from wx_bill_other br | |||||
| <include refid="queryBillListConditions" /> | |||||
| <if test=" null != sortColumns"> order by ${sortColumns} </if> | <if test=" null != sortColumns"> order by ${sortColumns} </if> | ||||
| <if test=" null == sortColumns">order by id desc</if> | <if test=" null == sortColumns">order by id desc</if> | ||||
| </select> | </select> | ||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillOther" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_other br | |||||
| <include refid="queryBillRentListCondition"/> | |||||
| </select> | |||||
| <update id="updateNotPaidStatus" parameterType="hashmap"> | <update id="updateNotPaidStatus" parameterType="hashmap"> | ||||
| update wx_bill_other set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | update wx_bill_other set status=#{notPaid},expired_day=DATEDIFF(now(),receive_date) | ||||
| @@ -92,11 +92,7 @@ | |||||
| <include refid="dynamicWhereConditions" /> | <include refid="dynamicWhereConditions" /> | ||||
| </select> | </select> | ||||
| <select id="queryBillDepositList" parameterType="com.iformall.domain.po.WxBillPropertyDeposit" resultMap="BaseResultMap"> | |||||
| 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`,br.`updatetime`,br.`merchant_id`,br.`rent_shop_type`,br.`return_price`,br.`shop_info`,br.pay_way, | |||||
| br.freeze,br.service_charge_pay,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time` | |||||
| from wx_bill_property_deposit br | |||||
| <sql id="queryBillDepositListConditions"> | |||||
| <where> | <where> | ||||
| <if test=" null != id ">and br.`id` = #{id}</if> | <if test=" null != id ">and br.`id` = #{id}</if> | ||||
| <if test=" null != tenantId and '' != tenantId"> | <if test=" null != tenantId and '' != tenantId"> | ||||
| @@ -112,6 +108,11 @@ | |||||
| <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> | ||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | ||||
| <if test=" null != starttime">and br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </if> | |||||
| <if test=" null != merchantIds "> | <if test=" null != merchantIds "> | ||||
| and br.`merchant_id` in | and br.`merchant_id` in | ||||
| <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | <foreach collection="merchantIds" index="index" item="midItem" open="(" separator="," close=")"> | ||||
| @@ -119,9 +120,27 @@ | |||||
| </foreach> | </foreach> | ||||
| </if> | </if> | ||||
| </where> | </where> | ||||
| </sql> | |||||
| <select id="queryBillDepositList" parameterType="com.iformall.domain.po.WxBillPropertyDeposit" resultMap="BaseResultMap"> | |||||
| 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`,br.`updatetime`,br.`merchant_id`,br.`rent_shop_type`,br.`return_price`,br.`shop_info`,br.pay_way, | |||||
| br.freeze,br.service_charge_pay,br.`apply_status`,br.`apply_pay_img`,br.`apply_update_time` | |||||
| from wx_bill_property_deposit br | |||||
| <include refid="queryBillDepositListConditions"/> | |||||
| order by id desc | order by id desc | ||||
| </select> | </select> | ||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillPropertyDeposit" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_property_deposit br | |||||
| <include refid="queryBillDepositListConditions"/> | |||||
| </select> | |||||
| <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | ||||
| select IFNULL((sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id from wx_bill_property_deposit | select IFNULL((sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id from wx_bill_property_deposit | ||||
| where date_format(receive_date,'%Y-%m')=#{receiveDate} | where date_format(receive_date,'%Y-%m')=#{receiveDate} | ||||
| @@ -126,7 +126,11 @@ | |||||
| <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 != 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 br.`starttime` <= #{starttime}</if> | |||||
| <if test=" null != endtime">and br.`endtime` >= #{endtime}</if> | |||||
| <if test=" null != month and '' != month"> | |||||
| and date_format(br.starttime,'%Y-%m') <= #{month} and date_format(br.endtime,'%Y-%m') >= #{month} | |||||
| </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> | ||||
| <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | <if test=" null != payWay ">and br.`pay_way` = #{payWay}</if> | ||||
| @@ -165,6 +169,16 @@ | |||||
| from wx_bill_property br | from wx_bill_property br | ||||
| <include refid="queryBillPropertyListConditions"/> | <include refid="queryBillPropertyListConditions"/> | ||||
| </select> | </select> | ||||
| <resultMap id="SumBaseResultMap" type="com.iformall.domain.vo.WxBillSum"> | |||||
| <result column="receive_pay" jdbcType="VARCHAR" property="needPay"/> | |||||
| <result column="paid" jdbcType="VARCHAR" property="paid" /> | |||||
| <result column="owe" jdbcType="VARCHAR" property="owe"/> | |||||
| </resultMap> | |||||
| <select id="getBillMonthSum" parameterType="com.iformall.domain.po.WxBillProperty" resultMap="SumBaseResultMap"> | |||||
| select sum(br.receive_pay) receive_pay , sum(br.pay) paid, sum(br.owe) owe from wx_bill_property br | |||||
| <include refid="queryBillPropertyListConditions"/> | |||||
| </select> | |||||
| <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | <select id="queryPayInfo" resultType="hashmap" parameterType="hashmap"> | ||||
| select IFNULL(sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id from wx_bill_property | select IFNULL(sum(receive_pay),0) receivepay,IFNULL(sum(pay),0) pay,tenant_id from wx_bill_property | ||||