diff --git a/cweb/src/main/java/com/cweb/config/SysConfig.java b/cweb/src/main/java/com/cweb/config/SysConfig.java index af884f6..07a1b6c 100644 --- a/cweb/src/main/java/com/cweb/config/SysConfig.java +++ b/cweb/src/main/java/com/cweb/config/SysConfig.java @@ -15,8 +15,6 @@ public class SysConfig { private String cmsPath; - private String domainName; - private String wxAppId; private String wxAppSecret; diff --git a/cweb/src/main/java/com/cweb/controller/BsDeviceOrderPayController.java b/cweb/src/main/java/com/cweb/controller/BsDeviceOrderPayController.java index cf8e765..1f9d1ea 100644 --- a/cweb/src/main/java/com/cweb/controller/BsDeviceOrderPayController.java +++ b/cweb/src/main/java/com/cweb/controller/BsDeviceOrderPayController.java @@ -14,6 +14,8 @@ import com.hfkj.common.exception.SysCode; import com.hfkj.common.security.UserCenter; import com.hfkj.common.utils.MathUtils; import com.hfkj.common.utils.ResponseMsgUtil; +import com.hfkj.config.CommonSysConfig; +import com.hfkj.config.CommonSysConst; import com.hfkj.entity.BsDeviceOrder; import com.hfkj.entity.BsTradeOrder; import com.hfkj.entity.BsTradeOrderMsg; @@ -87,8 +89,8 @@ public class BsDeviceOrderPayController { Map map = new HashMap<>(); map.put("orderNo", order.getOrderNo()); map.put("payPrice", order.getPayPrice()); - map.put("body", DeviceTypeEnum.getDataByNumber(order.getOrderType()).getName()); - map.put("subject", DeviceTypeEnum.getDataByNumber(order.getOrderType()).getName()); + map.put("body", DeviceTypeEnum.getDataByNumber(order.getDeviceType()).getName()); + map.put("subject", DeviceTypeEnum.getDataByNumber(order.getDeviceType()).getName()); // 微信支付 String nonce_str = MD5Util.MD5Encode(String.valueOf(ThreadLocalRandom.current().nextInt(10000)), "UTF-8"); @@ -110,7 +112,7 @@ public class BsDeviceOrderPayController { weChatPayReqInfo.setOut_trade_no(map.get("orderNo").toString()); // 商户订单号 weChatPayReqInfo.setTotal_fee(total_fee); // 总金额 weChatPayReqInfo.setSpbill_create_ip("122.9.135.148"); // 终端ip - weChatPayReqInfo.setNotify_url(SysConst.getSysConfig().getDomainName()+"/crest/deviceOrderPay/orderNotify"); // 通知url + weChatPayReqInfo.setNotify_url(CommonSysConst.getSysConfig().getDomainName()+"/crest/deviceOrderPay/orderNotify"); // 通知url weChatPayReqInfo.setTrade_type("JSAPI"); // 交易类型 weChatPayReqInfo.setProfit_sharing("N"); diff --git a/cweb/src/main/java/com/cweb/controller/BsMerLedgerController.java b/cweb/src/main/java/com/cweb/controller/BsMerLedgerController.java new file mode 100644 index 0000000..308348d --- /dev/null +++ b/cweb/src/main/java/com/cweb/controller/BsMerLedgerController.java @@ -0,0 +1,264 @@ +package com.cweb.controller; + +import com.github.pagehelper.PageHelper; +import com.github.pagehelper.PageInfo; +import com.hfkj.common.exception.ErrorCode; +import com.hfkj.common.exception.ErrorHelp; +import com.hfkj.common.exception.SysCode; +import com.hfkj.common.utils.ResponseMsgUtil; +import com.hfkj.entity.*; +import com.hfkj.model.ResponseData; +import com.hfkj.service.BsMerLedgerReceiverService; +import com.hfkj.service.BsMerLedgerService; +import com.hfkj.service.BsMerPlatformNoService; +import com.hfkj.sysenum.*; +import io.swagger.annotations.Api; +import io.swagger.annotations.ApiOperation; +import org.apache.commons.lang3.StringUtils; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import org.springframework.stereotype.Controller; +import org.springframework.web.bind.annotation.*; + +import javax.annotation.Resource; +import java.util.HashMap; +import java.util.Map; + +/** + * @className: BsMerLedgerController + * @author: HuRui + * @date: 2023/4/21 + **/ +@Controller +@Api(value = "设备管理") +@RequestMapping(value = "/merLedger") +public class BsMerLedgerController { + + private static Logger log = LoggerFactory.getLogger(BsMerLedgerController.class); + + @Resource + private BsMerPlatformNoService merPlatformNoService; + @Resource + private BsMerLedgerService merLedgerService; + @Resource + private BsMerLedgerReceiverService merLedgerReceiverService; + + @RequestMapping(value="/merLedgerApply",method = RequestMethod.POST) + @ResponseBody + @ApiOperation(value = "商户分账功能申请") + public ResponseData merLedgerApply(@RequestBody BsMerLedger body) { + try { + if (body.getMerId() == null || body.getPlatformType() == null) { + log.error("BsDeviceOrderPayController -> payOrder error!","参数校验失败"); + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); + } + if (body.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + if (body.getSplitLowestRatio() == null || StringUtils.isBlank(body.getSplitEntrustFilePath())) { + log.error("BsDeviceOrderPayController -> payOrder error!","参数校验失败"); + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); + } + } + // 商户平台 + BsMerPlatformNo merPlatform = merPlatformNoService.getPlatformNo(body.getMerId(), PlatformTypeEnum.getDataByNumber(body.getPlatformType())); + if (merPlatform == null) { + log.error("BsDeviceOrderPayController -> payOrder error!","参数校验失败"); + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "当前平台未进件"); + } + // 设备订单 + BsMerLedger merLedger = merLedgerService.getMerLedger(body.getMerId(), PlatformTypeEnum.getDataByNumber(body.getPlatformType())); + if (merLedger == null) { + merLedger = new BsMerLedger(); + merLedger.setMerId(merPlatform.getMerId()); + merLedger.setPlatformType(merPlatform.getPlatformType()); + merLedger.setPlatformNo(merPlatform.getPlatformNo()); + merLedger.setCupNo(merPlatform.getCupNo()); + merLedger.setSplitLowestRatio(body.getSplitLowestRatio()); + merLedger.setSplitEntrustFileName(body.getSplitEntrustFilePath().substring(body.getSplitEntrustFilePath().lastIndexOf("/")+1)); + merLedger.setSplitEntrustFilePath(body.getSplitEntrustFilePath()); + if (PlatformTypeEnum.type1.getNumber().equals(merPlatform.getPlatformType())) { + merLedger.setStatus(MerLedgerStatusEnum.status2.getNumber()); + } else { + merLedger.setStatus(MerLedgerStatusEnum.status1.getNumber()); + } + } else { + if (merLedger.getStatus().equals(MerLedgerStatusEnum.status1.getNumber()) + || merLedger.getStatus().equals(MerLedgerStatusEnum.status2.getNumber()) ) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "暂时无法修改"); + } + merLedger = new BsMerLedger(); + merLedger.setMerId(merPlatform.getMerId()); + merLedger.setPlatformType(merPlatform.getPlatformType()); + merLedger.setPlatformNo(merPlatform.getPlatformNo()); + merLedger.setCupNo(merPlatform.getCupNo()); + merLedger.setSplitLowestRatio(body.getSplitLowestRatio()); + merLedger.setSplitEntrustFileName(body.getSplitEntrustFilePath().substring(body.getSplitEntrustFilePath().lastIndexOf("/")+1)); + merLedger.setSplitEntrustFilePath(body.getSplitEntrustFilePath()); + } + merLedgerService.merLedgerApply(merLedger); + + return ResponseMsgUtil.success("操作成功"); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + + @RequestMapping(value="/getMerLedgerApply",method = RequestMethod.GET) + @ResponseBody + @ApiOperation(value = "查询商户分账功能") + public ResponseData getMerLedgerApply(@RequestParam(name = "merId", required = true) Long merId, + @RequestParam(name = "platformType", required = true) Integer platformType) { + try { + + return ResponseMsgUtil.success(merLedgerService.getMerLedger(merId, PlatformTypeEnum.getDataByNumber(platformType))); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + + @RequestMapping(value="/merLedgerReceiverApply",method = RequestMethod.GET) + @ResponseBody + @ApiOperation(value = "商户分账绑定接受方申请") + public ResponseData merLedgerReceiverApply(@RequestBody BsMerLedgerReceiver body) { + try { + + if (body == null + || body.getMerLedgerId() == null + || StringUtils.isBlank(body.getReceiverNo()) + || StringUtils.isBlank(body.getReceiverName()) + || StringUtils.isBlank(body.getEntrustFilePath()) + ) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的优惠类型"); + } + + // 查询分账开通信息 + BsMerLedger merLedger = merLedgerService.getMerLedgerById(body.getMerLedgerId()); + if (merLedger == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "商户分账功能未开通"); + } + if (!merLedger.getStatus().equals(MerLedgerStatusEnum.status1.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "商户分账功能状态无法申请"); + } + + // 查询接收方数据 + BsMerLedgerReceiver receiver = merLedgerReceiverService.getMerLedgerReceiver(merLedger.getMerId(), body.getReceiverNo()); + if (receiver == null) { + receiver = new BsMerLedgerReceiver(); + receiver.setMerId(merLedger.getMerId()); + receiver.setMerLedgerId(merLedger.getId()); + receiver.setPlatformType(merLedger.getPlatformType()); + receiver.setPlatformNo(merLedger.getPlatformNo()); + receiver.setCupNo(merLedger.getCupNo()); + receiver.setReceiverNo(body.getReceiverNo()); + receiver.setReceiverName(body.getReceiverName()); + receiver.setEntrustFileName(body.getEntrustFilePath().substring(body.getEntrustFilePath().lastIndexOf("/")+1)); + receiver.setEntrustFilePath(body.getEntrustFilePath()); + } else { + receiver.setReceiverNo(body.getReceiverNo()); + receiver.setReceiverName(body.getReceiverName()); + receiver.setEntrustFileName(body.getEntrustFilePath().substring(body.getEntrustFilePath().lastIndexOf("/")+1)); + receiver.setEntrustFilePath(body.getEntrustFilePath()); + } + merLedgerReceiverService.merLedgerReceiverApply(receiver); + + return ResponseMsgUtil.success("操作成功"); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + + @RequestMapping(value="/merLedgerReceiverSecure",method = RequestMethod.GET) + @ResponseBody + @ApiOperation(value = "商户分账绑定接受方申请") + public ResponseData merLedgerReceiverSecure(@RequestBody BsMerLedgerReceiver body) { + try { + if (body == null + || body.getMerLedgerId() == null + || StringUtils.isBlank(body.getReceiverNo()) + || StringUtils.isBlank(body.getReceiverName()) + || StringUtils.isBlank(body.getEntrustFilePath()) + ) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的优惠类型"); + } + + // 查询分账开通信息 + BsMerLedger merLedger = merLedgerService.getMerLedgerById(body.getMerLedgerId()); + if (merLedger == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "商户分账功能未开通"); + } + if (!merLedger.getStatus().equals(MerLedgerStatusEnum.status1.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "商户分账功能状态无法申请"); + } + + // 查询接收方数据 + BsMerLedgerReceiver receiver = merLedgerReceiverService.getMerLedgerReceiver(merLedger.getMerId(), body.getReceiverNo()); + if (receiver == null) { + receiver = new BsMerLedgerReceiver(); + receiver.setMerId(merLedger.getMerId()); + receiver.setMerLedgerId(merLedger.getId()); + receiver.setPlatformType(merLedger.getPlatformType()); + receiver.setPlatformNo(merLedger.getPlatformNo()); + receiver.setCupNo(merLedger.getCupNo()); + receiver.setReceiverNo(body.getReceiverNo()); + receiver.setReceiverName(body.getReceiverName()); + receiver.setEntrustFileName(body.getEntrustFilePath().substring(body.getEntrustFilePath().lastIndexOf("/")+1)); + receiver.setEntrustFilePath(body.getEntrustFilePath()); + } else { + receiver.setReceiverNo(body.getReceiverNo()); + receiver.setReceiverName(body.getReceiverName()); + receiver.setEntrustFileName(body.getEntrustFilePath().substring(body.getEntrustFilePath().lastIndexOf("/")+1)); + receiver.setEntrustFilePath(body.getEntrustFilePath()); + } + merLedgerReceiverService.merLedgerReceiverApply(receiver); + + return ResponseMsgUtil.success("操作成功"); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + + @RequestMapping(value="/getLedgerReceiverListByMer",method = RequestMethod.GET) + @ResponseBody + @ApiOperation(value = "查询接收方列表") + public ResponseData getLedgerReceiverListByMer(@RequestParam(name = "merId", required = true) Long merId, + @RequestParam(name = "platformType", required = true) Integer platformType) { + try { + + return ResponseMsgUtil.success(merLedgerReceiverService.getMerLedgerReceiverByMer(merId, PlatformTypeEnum.getDataByNumber(platformType))); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + + @RequestMapping(value="/getLedgerReceiverList",method = RequestMethod.GET) + @ResponseBody + @ApiOperation(value = "查询接收方列表") + public ResponseData getLedgerReceiverList(@RequestParam(name = "platformType", required = true) Integer platformType, + @RequestParam(name = "pageNum", required = true) Integer pageNum, + @RequestParam(name = "pageSize", required = true) Integer pageSize) { + try { + + Map param = new HashMap<>(); + param.put("platformType", platformType); + param.put("status", MerLedgerReceiverStatusEnum.status1.getNumber()); + param.put("receiverNoNotNull", "true"); + + PageHelper.startPage(pageNum, pageSize); + return ResponseMsgUtil.success(new PageInfo<>(merLedgerReceiverService.getMerLedgerReceiverList(param))); + + } catch (Exception e) { + log.error(e.getMessage(), e); + return ResponseMsgUtil.exception(e); + } + } + +} diff --git a/cweb/src/main/java/com/cweb/controller/BsStoreDiscountActivityPartakeUserController.java b/cweb/src/main/java/com/cweb/controller/BsStoreDiscountActivityPartakeUserController.java index b4fd995..404c989 100644 --- a/cweb/src/main/java/com/cweb/controller/BsStoreDiscountActivityPartakeUserController.java +++ b/cweb/src/main/java/com/cweb/controller/BsStoreDiscountActivityPartakeUserController.java @@ -125,7 +125,7 @@ public class BsStoreDiscountActivityPartakeUserController { QRCodeGenerator.overlapImage(fileUrl, "/template/qrCodeBackdrop2_2.png",250,650); } } - return ResponseMsgUtil.success(SysConst.getSysConfig().getDomainName() + "/filesystem" + fileUrl); + return ResponseMsgUtil.success(CommonSysConst.getSysConfig().getDomainName() + "/filesystem" + fileUrl); } catch (Exception e) { log.error("BsStoreDiscountActivityPartakeUserController --> generateWeChatMpQrCode() error!", e); diff --git a/cweb/src/main/java/com/cweb/controller/TestController.java b/cweb/src/main/java/com/cweb/controller/TestController.java index 9891737..b55f7d8 100644 --- a/cweb/src/main/java/com/cweb/controller/TestController.java +++ b/cweb/src/main/java/com/cweb/controller/TestController.java @@ -8,6 +8,7 @@ import com.alipay.api.request.AlipaySystemOauthTokenRequest; import com.alipay.api.response.AlipaySystemOauthTokenResponse; import com.hfkj.channel.alipay.utils.AlipayRequest; import com.hfkj.channel.alipay.utils.AlipayUtils; +import com.hfkj.channel.lakala.LaKaLaLedgerService; import com.hfkj.channel.lakala.LaKaLaTradeService; import com.hfkj.channel.lakala.config.LaKaLaConfig; import com.hfkj.channel.saas.SaasMerService; @@ -72,6 +73,9 @@ public class TestController { @Resource private BsLklMccService lklMccService; + @Resource + private LaKaLaLedgerService laKaLaLedgerService; + @RequestMapping(value="/rotationQueryTrade",method = RequestMethod.GET) @ResponseBody @ApiOperation(value = "交易【被扫】") @@ -110,9 +114,10 @@ public class TestController { // return ResponseMsgUtil.success(saasCommon.fileUpload(new File("D:/home/project/gratia-pay/filesystem/share/1680164428924.png"), "OTHERS", "0")); // 996900 6900 6905 // return ResponseMsgUtil.success(saasCommon.getArea("1")); - // return ResponseMsgUtil.success(saasCommon.getBank("1240", "工商银行")); + // return ResponseMsgUtil.success(saasCommon.getBank("6530", "大坪支行")); - return ResponseMsgUtil.success(saasMerService.merchantInfo(code)); + return ResponseMsgUtil.success(laKaLaLedgerService); + // return ResponseMsgUtil.success(""); // 1200 // return ResponseMsgUtil.success(saasCommon.fileUpload(new HashMap<>())); /* AlipaySystemOauthTokenRequest request = new AlipaySystemOauthTokenRequest(); @@ -132,10 +137,6 @@ public class TestController { } } - public static void main(String[] args) { - System.out.println(test("邯郸市", 1)); - } - public static String test(String str, Integer type) { char[] chars = str.toCharArray(); // oP: '省' 的偏移, oC: '市' 的偏移, oR: "自治区" 的偏移 diff --git a/cweb/src/main/java/com/cweb/notify/LaKaLaController.java b/cweb/src/main/java/com/cweb/notify/LaKaLaController.java index 20b25d9..73a414b 100644 --- a/cweb/src/main/java/com/cweb/notify/LaKaLaController.java +++ b/cweb/src/main/java/com/cweb/notify/LaKaLaController.java @@ -1,12 +1,12 @@ package com.cweb.notify; import com.alibaba.fastjson.JSONObject; -import com.hfkj.entity.BsTradeOrder; -import com.hfkj.entity.BsTradeOrderMsg; +import com.hfkj.entity.*; import com.hfkj.service.*; import com.hfkj.sysenum.*; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; +import org.apache.commons.lang3.StringUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.stereotype.Controller; @@ -37,11 +37,19 @@ public class LaKaLaController { @Resource private BsTradeOrderMsgService tradeOrderMsgService; + @Resource + private BsMerLedgerService merLedgerService; + @Resource + private BsMerLedgerApplyService merLedgerApplyService; + @Resource + private BsMerLedgerReceiverService merLedgerReceiverService; + @Resource + private BsMerLedgerReceiverApplyService merLedgerReceiverApplyService; @RequestMapping(value="/microPay",method = RequestMethod.POST) @ResponseBody @ApiOperation(value = "交易【被扫】通知") - public void microPay(@RequestBody String reqBody, HttpServletResponse response){ + public void microPay(@RequestBody String reqBody, HttpServletResponse response) { try { log.info("交易【被扫】通知", reqBody); System.out.println(reqBody); @@ -56,7 +64,7 @@ public class LaKaLaController { // 查询订单 BsTradeOrder order = tradeOrderService.getOrderByOutTradeNo(body.getString("out_trade_no")); - if (order != null){ + if (order != null) { tradeOrderService.paySuccess( body.getString("out_trade_no"), body.getString("trade_no"), @@ -96,4 +104,80 @@ public class LaKaLaController { } } + + @RequestMapping(value="/applyLedgerMer",method = RequestMethod.POST) + @ResponseBody + @ApiOperation(value = "开通分账业务通知") + public void applyLedgerMer(@RequestBody String reqBody) { + try { + log.info("开通分账业务通知", reqBody); + System.out.println(reqBody); + + JSONObject body = JSONObject.parseObject(reqBody); + JSONObject respData = body.getJSONObject("respData"); + + BsMerLedgerApply ledgerApply = merLedgerApplyService.getApplyByOrderNo(respData.getString("orderNo")); + if (ledgerApply != null) { + ledgerApply.setNotifyBody(reqBody); + merLedgerApplyService.editMerLedgerApply(ledgerApply); + + // 查询商户分账信息 + BsMerLedger merLedger = merLedgerService.getMerLedger(ledgerApply.getMerId(), PlatformTypeEnum.type1); + if (merLedger != null) { + // 审核状态 1:通过,2拒绝 + if (respData.getString("auditStatus").equals("1")) { + merLedger.setStatus(MerLedgerStatusEnum.status1.getNumber()); + + } else { + merLedger.setStatus(MerLedgerStatusEnum.status3.getNumber()); + merLedger.setRejectReason(respData.getString("auditStatusText")); + } + merLedgerService.editMerLedger(merLedger); + } + } + + } catch (Exception e) { + log.error("login error!",e); + } + + } + + @RequestMapping(value="/applyBindReceiver",method = RequestMethod.POST) + @ResponseBody + @ApiOperation(value = "分账关系绑定申请") + public void applyBindReceiver(@RequestBody String reqBody) { + try { + log.info("分账关系绑定申请通知", reqBody); + System.out.println(reqBody); + + JSONObject body = JSONObject.parseObject(reqBody); + JSONObject respData = body.getJSONObject("respData"); + + // 分手接收方申请记录 + BsMerLedgerReceiverApply receiverApply = merLedgerReceiverApplyService.getReceiverApplyByApplyId(respData.getString("applyId")); + if (receiverApply != null) { + receiverApply.setNotifyBody(reqBody); + // 1:通过,2拒绝 + receiverApply.setStatus(respData.getString("auditStatus").equals("1") + ?MerLedgerReceiverApplyStatusEnum.status2.getNumber() + :MerLedgerReceiverApplyStatusEnum.status3.getNumber()); + receiverApply.setRejectReason(respData.getString("auditStatusText")); + merLedgerReceiverApplyService.editReceiverApply(receiverApply); + + // 分账接收方 + BsMerLedgerReceiver ledgerReceiver = merLedgerReceiverService.getMerLedgerReceiver(receiverApply.getMerId(), receiverApply.getReceiverNo()); + if (ledgerReceiver != null) { + ledgerReceiver.setStatus(receiverApply.getStatus().equals(MerLedgerReceiverApplyStatusEnum.status2.getNumber()) + ?MerLedgerReceiverStatusEnum.status1.getNumber():MerLedgerReceiverStatusEnum.status3.getNumber()); + ledgerReceiver.setRejectReason(receiverApply.getRejectReason()); + merLedgerReceiverService.editMerLedgerReceiver(ledgerReceiver); + } + } + + } catch (Exception e) { + log.error("login error!",e); + } + + } + } diff --git a/cweb/src/main/resources/dev/config.properties b/cweb/src/main/resources/dev/config.properties index 3f42f9f..185a8ae 100644 --- a/cweb/src/main/resources/dev/config.properties +++ b/cweb/src/main/resources/dev/config.properties @@ -1,8 +1,6 @@ fileUrl=/home/project/gratia-pay/filesystem cmsPath=/home/project/gratia-pay/filesystem/cmsPath -domainName=https://gratia-pay.dctpay.com - wxAppId=wxa075e8509802f826 wxAppSecret=0e606fc1378d35e359fcf3f15570b2c5 diff --git a/cweb/src/main/resources/prod/config.properties b/cweb/src/main/resources/prod/config.properties index 4437ab6..185a8ae 100644 --- a/cweb/src/main/resources/prod/config.properties +++ b/cweb/src/main/resources/prod/config.properties @@ -1,8 +1,6 @@ fileUrl=/home/project/gratia-pay/filesystem cmsPath=/home/project/gratia-pay/filesystem/cmsPath -domainName=https://pay.dctpay.com - wxAppId=wxa075e8509802f826 wxAppSecret=0e606fc1378d35e359fcf3f15570b2c5 diff --git a/schedule/src/main/java/com/hfkj/schedule/TradeOrderSchedule.java b/schedule/src/main/java/com/hfkj/schedule/TradeOrderSchedule.java index 6d15ec4..4a895ab 100644 --- a/schedule/src/main/java/com/hfkj/schedule/TradeOrderSchedule.java +++ b/schedule/src/main/java/com/hfkj/schedule/TradeOrderSchedule.java @@ -1,5 +1,7 @@ package com.hfkj.schedule; +import com.alibaba.fastjson.JSONObject; +import com.hfkj.channel.lakala.LaKaLaTradeSeparateService; import com.hfkj.channel.weixin.utils.WxOrderConfig; import com.hfkj.entity.BsTradeOrder; import com.hfkj.entity.BsTradeOrderProfitSharing; @@ -8,9 +10,7 @@ import com.hfkj.service.BsTradeOrderProfitSharingReceiverService; import com.hfkj.service.BsTradeOrderProfitSharingService; import com.hfkj.service.BsTradeOrderService; import com.hfkj.service.BsTradeTakeConfigService; -import com.hfkj.sysenum.PlatformTypeEnum; -import com.hfkj.sysenum.TradeOrderPayModeEnum; -import com.hfkj.sysenum.TradeOrderStatusEnum; +import com.hfkj.sysenum.*; import org.apache.commons.collections4.MapUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -30,15 +30,15 @@ public class TradeOrderSchedule { private static final Logger log = LoggerFactory.getLogger(TradeOrderSchedule.class); - @Resource - private BsTradeOrderService tradeOrderService; - @Resource private BsTradeOrderProfitSharingService tradeOrderProfitSharingService; @Resource private BsTradeOrderProfitSharingReceiverService tradeOrderProfitSharingReceiverService; + @Resource + private LaKaLaTradeSeparateService laKaLaTradeSeparateService; + /** * 订单发起分账 * 5分钟扫描一次需要分账的订单 @@ -48,49 +48,150 @@ public class TradeOrderSchedule { List tradeOrderProfitSharingList = tradeOrderProfitSharingService.getNeedProfitSharingOrder(); for (BsTradeOrderProfitSharing tradeOrderProfitSharing : tradeOrderProfitSharingList) { try { + if (tradeOrderProfitSharing.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + // 拉卡拉分账 + if (tradeOrderProfitSharing.getCmdType().equals(ProfitSharingCmdTypeEnum.CMD_TYPE_1.getNumber())) { + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + laKaLaTradeSeparateService.separate(tradeOrderProfitSharing.getProfitSharingOrderNo()); + + } else if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status2.getNumber()) + || tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status3.getNumber())) { + // 查询拉卡拉分账记录 + JSONObject queryProfitSharing = laKaLaTradeSeparateService.query(tradeOrderProfitSharing.getProfitSharingOrderNo()); + if (queryProfitSharing != null) { + // ACCEPTED:已受理,PROCESSING:处理中,FAIL:失败,SUCCESS:成功, + //(如果分账指令后有反向操作指令,则原分账指令会变更成以下的状态之一:) + //CANCELING:撤销中,CANCELED:撤销成功,CANCEL_FAIL:撤销失败,FALLBACKING:回退中,FALLBACK_END:回退结束 + String status = queryProfitSharing.getString("status"); + if (status.equals("PROCESSING")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status3.getNumber()); + } else if (status.equals("ACCEPTED")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + } else if (status.equals("SUCCESS")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status1.getNumber()); + tradeOrderProfitSharing.setFinishTime(new Date()); + // 修改接收方状态 + List receiverList = tradeOrderProfitSharingReceiverService.getReceiverListByProfitSharingId(tradeOrderProfitSharing.getId()); + for (BsTradeOrderProfitSharingReceiver receiver : receiverList) { + receiver.setStatus(ProfitSharingReceiverStatusEnum.status1.getNumber()); + tradeOrderProfitSharingReceiverService.editData(receiver); + } + } else if (status.equals("FAIL")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status4.getNumber()); + } + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + } + } + } else if (tradeOrderProfitSharing.getCmdType().equals(ProfitSharingCmdTypeEnum.CMD_TYPE_2.getNumber())) { + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + laKaLaTradeSeparateService.cancel(tradeOrderProfitSharing.getProfitSharingOrderNo()); + + } else if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status2.getNumber()) + || tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status3.getNumber())) { + // 查询拉卡拉分账记录 + JSONObject queryProfitSharing = laKaLaTradeSeparateService.query(tradeOrderProfitSharing.getProfitSharingOrderNo()); + if (queryProfitSharing != null) { + // ACCEPTED:已受理,PROCESSING:处理中,FAIL:失败,SUCCESS:成功, + //(如果分账指令后有反向操作指令,则原分账指令会变更成以下的状态之一:) + //CANCELING:撤销中,CANCELED:撤销成功,CANCEL_FAIL:撤销失败,FALLBACKING:回退中,FALLBACK_END:回退结束 + String status = queryProfitSharing.getString("status"); + if (status.equals("PROCESSING")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status3.getNumber()); + } else if (status.equals("ACCEPTED")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + } else if (status.equals("SUCCESS")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status1.getNumber()); + tradeOrderProfitSharing.setFinishTime(new Date()); + // 修改接收方状态 + List receiverList = tradeOrderProfitSharingReceiverService.getReceiverListByProfitSharingId(tradeOrderProfitSharing.getId()); + for (BsTradeOrderProfitSharingReceiver receiver : receiverList) { + receiver.setStatus(ProfitSharingReceiverStatusEnum.status1.getNumber()); + tradeOrderProfitSharingReceiverService.editData(receiver); + } + } else if (status.equals("FAIL")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status4.getNumber()); + } + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + } + } + } else if (tradeOrderProfitSharing.getCmdType().equals(ProfitSharingCmdTypeEnum.CMD_TYPE_3.getNumber())) { + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + laKaLaTradeSeparateService.fallback(tradeOrderProfitSharing.getProfitSharingOrderNo()); + + } else if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status2.getNumber()) + || tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status3.getNumber())) { + // 查询拉卡拉分账记录 + JSONObject queryProfitSharing = laKaLaTradeSeparateService.query(tradeOrderProfitSharing.getProfitSharingOrderNo()); + if (queryProfitSharing != null) { + // ACCEPTED:已受理,PROCESSING:处理中,FAIL:失败,SUCCESS:成功, + //(如果分账指令后有反向操作指令,则原分账指令会变更成以下的状态之一:) + //CANCELING:撤销中,CANCELED:撤销成功,CANCEL_FAIL:撤销失败,FALLBACKING:回退中,FALLBACK_END:回退结束 + String status = queryProfitSharing.getString("status"); + if (status.equals("PROCESSING")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status3.getNumber()); + } else if (status.equals("ACCEPTED")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + } else if (status.equals("SUCCESS")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status1.getNumber()); + tradeOrderProfitSharing.setFinishTime(new Date()); + // 修改接收方状态 + List receiverList = tradeOrderProfitSharingReceiverService.getReceiverListByProfitSharingId(tradeOrderProfitSharing.getId()); + for (BsTradeOrderProfitSharingReceiver receiver : receiverList) { + receiver.setStatus(ProfitSharingReceiverStatusEnum.status1.getNumber()); + tradeOrderProfitSharingReceiverService.editData(receiver); + } + } else if (status.equals("FAIL")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status4.getNumber()); + } + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + } + } + } - List> receiversList = new ArrayList<>(); - Map receiversMap; - - // 分账接收方 - Map param = new HashMap<>(); - param.put("tradeOrderProfitSharingId", tradeOrderProfitSharing.getId()); - List profitSharingReceivers = tradeOrderProfitSharingReceiverService.getProfitSharingList(param); - for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceivers) { - if (!receiver.getReceiverAccount().equals(new BigDecimal("0"))) { - receiversMap = new HashMap<>(); - receiversMap.put("type", "MERCHANT_ID"); - receiversMap.put("account", receiver.getReceiverAccount()); - receiversMap.put("amount", receiver.getReceiverAmount().multiply(new BigDecimal("100")).intValue()); - receiversMap.put("description", "分给商户:" + receiver.getReceiverName()); - receiversList.add(receiversMap); + } else if (tradeOrderProfitSharing.getPlatformType().equals(PlatformTypeEnum.type4.getNumber())) { + List> receiversList = new ArrayList<>(); + Map receiversMap; + + // 分账接收方 + Map param = new HashMap<>(); + param.put("tradeOrderProfitSharingId", tradeOrderProfitSharing.getId()); + List profitSharingReceivers = tradeOrderProfitSharingReceiverService.getProfitSharingList(param); + for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceivers) { + if (!receiver.getReceiverAccount().equals(new BigDecimal("0"))) { + receiversMap = new HashMap<>(); + receiversMap.put("type", "MERCHANT_ID"); + receiversMap.put("account", receiver.getReceiverAccount()); + receiversMap.put("amount", receiver.getReceiverAmount().multiply(new BigDecimal("100")).intValue()); + receiversMap.put("description", "分给商户:" + receiver.getReceiverName()); + receiversList.add(receiversMap); + } } - } - if (tradeOrderProfitSharing.getPlatformType().equals(PlatformTypeEnum.type4.getNumber())) { - // 微信分账 - TreeMap refundModel = WxOrderConfig.profitsharingCreate( - tradeOrderProfitSharing.getPlatformAppid(), - tradeOrderProfitSharing.getPlatformMerNo(), - tradeOrderProfitSharing.getPlatformTradeNo(), - tradeOrderProfitSharing.getTradeOrderNo(), - receiversList - ); - if("SUCCESS".equals(MapUtils.getString(refundModel, "return_code")) - && "SUCCESS".equals(MapUtils.getString(refundModel, "result_code"))) { - tradeOrderProfitSharing.setPlatformProfitSharingOrderNo(MapUtils.getString(refundModel, "order_id")); - tradeOrderProfitSharing.setStatus(1); - tradeOrderProfitSharing.setProfitSharingTime(new Date()); - tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); - - for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceivers) { - receiver.setStatus(1); - receiver.setProfitSharingTime(new Date()); - tradeOrderProfitSharingReceiverService.editData(receiver); + if (tradeOrderProfitSharing.getPlatformType().equals(PlatformTypeEnum.type4.getNumber())) { + // 微信分账 + TreeMap refundModel = WxOrderConfig.profitsharingCreate( + tradeOrderProfitSharing.getPlatformAppid(), + tradeOrderProfitSharing.getPlatformMerNo(), + tradeOrderProfitSharing.getPlatformTradeNo(), + tradeOrderProfitSharing.getTradeOrderNo(), + receiversList + ); + if("SUCCESS".equals(MapUtils.getString(refundModel, "return_code")) + && "SUCCESS".equals(MapUtils.getString(refundModel, "result_code"))) { + tradeOrderProfitSharing.setPlatformProfitSharingOrderNo(MapUtils.getString(refundModel, "order_id")); + tradeOrderProfitSharing.setStatus(1); + tradeOrderProfitSharing.setProfitSharingTime(new Date()); + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + + for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceivers) { + receiver.setStatus(1); + receiver.setProfitSharingTime(new Date()); + tradeOrderProfitSharingReceiverService.editData(receiver); + } + } else { + tradeOrderProfitSharing.setExt1(MapUtils.getString(refundModel,"description")); + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); } - } else { - tradeOrderProfitSharing.setExt1(MapUtils.getString(refundModel,"description")); - tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); } } diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java new file mode 100644 index 0000000..8f14cbf --- /dev/null +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaLedgerService.java @@ -0,0 +1,382 @@ +package com.hfkj.channel.lakala; + +import com.alibaba.fastjson.JSONObject; +import com.hfkj.channel.lakala.config.LaKaLaConfig; +import com.hfkj.channel.saas.utils.SaasCommon; +import com.hfkj.common.exception.ErrorCode; +import com.hfkj.common.exception.ErrorHelp; +import com.hfkj.common.exception.SysCode; +import com.hfkj.common.utils.DateUtil; +import com.hfkj.common.utils.HttpsUtils; +import com.hfkj.common.utils.ImageUtils; +import com.hfkj.common.utils.UnionUtils; +import com.hfkj.config.CommonSysConst; +import com.hfkj.entity.*; +import com.hfkj.model.MerBasisModel; +import com.hfkj.service.*; +import com.hfkj.sysenum.*; +import com.hfkj.sysenum.lakala.UploadFileTypeEnum; +import org.apache.commons.lang3.StringUtils; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.io.File; +import java.math.BigDecimal; +import java.util.*; + +/** + * 拉卡拉分账 + * @author hurui + */ +@Service +public class LaKaLaLedgerService { + + @Resource + private BsMerLedgerService merLedgerService; + @Resource + private BsMerLedgerApplyService merLedgerApplyService; + @Resource + private BsMerLedgerReceiverService merLedgerReceiverService; + @Resource + private BsMerService merService; + @Resource + private BsMerAttachService merAttachService; + + /** + * 商户分账业务开通申请 + * @param merLedgerId + * @return + */ + public JSONObject applyLedger(Long merLedgerId) { + // + BsMerLedger merLedger = merLedgerService.getMerLedgerById(merLedgerId); + if (merLedger == null || merLedger.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); + } + // 商户 + MerBasisModel merDetail = merService.getMerDetail(merLedger.getId()); + if (merDetail == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } + + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + String orderNo = System.currentTimeMillis()+""; + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", orderNo); + map.put("orgCode", "1"); + map.put("merCupNo", merLedger.getCupNo()); + map.put("contactMobile", merDetail.getRegPhone()); + map.put("splitLowestRatio", merLedger.getSplitLowestRatio()); + map.put("splitEntrustFileName", merLedger.getSplitEntrustFileName()); + // 转换成bas64 + String base64ImgUrl = ImageUtils.getBase64ByImgUrl(CommonSysConst.getSysConfig().getObs_url() + "/"+ merLedger.getSplitEntrustFilePath()); + String fileType = merLedger.getSplitEntrustFilePath().substring(merLedger.getSplitEntrustFilePath().lastIndexOf(".") + 1); + map.put("splitEntrustFilePath", LaKaLaConfig.uploadFile("COOPERATION_QUALIFICATION_PROOF", fileType, base64ImgUrl).getString("attFileId")); + map.put("splitRange", "MARK"); + map.put("retUrl", CommonSysConst.getSysConfig() + "/crest/laKaLaNotify/applyLedgerMer"); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + // 请求记录 + Map requestMap = new HashMap<>(); + requestMap.put("Authorization", reqParam.get("Authorization")); + requestMap.put("req_data", JSONObject.toJSONString(commonParam)); + + BsMerLedgerApply merLedgerApply = new BsMerLedgerApply(); + merLedgerApply.setMerLedgerId(merLedger.getId()); + merLedgerApply.setMerId(merLedger.getId()); + merLedgerApply.setOrderNo(orderNo); + merLedgerApply.setRequestBody(JSONObject.toJSONString(requestMap)); + merLedgerApplyService.editMerLedgerApply(merLedgerApply); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/applyLedgerMer", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + merLedgerApply.setApplyId(responseBody.getJSONObject("respData").getString("applyId")); + merLedgerApply.setResponseBody(responseBody.toJSONString()); + merLedgerApplyService.editMerLedgerApply(merLedgerApply); + + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + + return responseBody; + } + + /** + * 商户分账信息变更申请 + * @param merLedgerId + * @return + */ + public JSONObject applyLedgerModify(Long merLedgerId) { + // + BsMerLedger merLedger = merLedgerService.getMerLedgerById(merLedgerId); + if (merLedger == null || merLedger.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, ""); + } + // 商户 + MerBasisModel merDetail = merService.getMerDetail(merLedger.getId()); + if (merDetail == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } + + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + String orderNo = System.currentTimeMillis()+""; + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", orderNo); + map.put("orgCode", "1"); + map.put("merCupNo", merLedger.getCupNo()); + map.put("contactMobile", merDetail.getRegPhone()); + map.put("splitLowestRatio", merLedger.getSplitLowestRatio()); + map.put("splitEntrustFileName", merLedger.getSplitEntrustFileName()); + // map.put("splitEntrustFilePath", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ merLedger.getSplitEntrustFilePath()), "SPLIT_ENTRUST_FILE", "0").getString("url")); + map.put("splitRange", "MARK"); + map.put("retUrl", CommonSysConst.getSysConfig() + "/crest/laKaLaNotify/applyLedgerMer"); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + // 请求记录 + Map requestMap = new HashMap<>(); + requestMap.put("Authorization", reqParam.get("Authorization")); + requestMap.put("req_data", JSONObject.toJSONString(commonParam)); + + BsMerLedgerApply merLedgerApply = new BsMerLedgerApply(); + merLedgerApply.setMerLedgerId(merLedger.getId()); + merLedgerApply.setMerId(merLedger.getId()); + merLedgerApply.setOrderNo(orderNo); + merLedgerApply.setRequestBody(JSONObject.toJSONString(requestMap)); + merLedgerApplyService.editMerLedgerApply(merLedgerApply); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/applyLedgerMer", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + merLedgerApply.setApplyId(responseBody.getJSONObject("respData").getString("applyId")); + merLedgerApply.setResponseBody(responseBody.toJSONString()); + merLedgerApplyService.editMerLedgerApply(merLedgerApply); + + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + + return responseBody; + } + + /** + * 分账商户信息查询 + * @param merCupNo 银联商户号 + * @return + */ + public JSONObject queryLedgerMer(String merCupNo) { + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + String orderNo = System.currentTimeMillis()+""; + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", orderNo); + map.put("orgCode", "1"); + map.put("merCupNo", merCupNo); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/queryLedgerMer", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + + return responseBody; + } + + /** + * 创建分账接收方 + */ + public void applyLedgerReceiver(Long merId) { + // 商户 + MerBasisModel merDetail = merService.getMerDetail(merId); + if (merDetail == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到商户"); + } + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", System.currentTimeMillis()+""); + map.put("orgCode", "1"); + map.put("receiverName", merDetail.getMerName()); + map.put("contactMobile", merDetail.getRegPhone()); + map.put("acctTypeCode", merDetail.getMerType().equals(MerSettleType.status1.getNumber())?57:58);// 57:对公 58:对私 + map.put("acctNo", merDetail.getMerSettleAcct().getBankCardNo()); + map.put("acctName", merDetail.getMerSettleAcct().getBankCardHolder()); + map.put("acctCertificateType", "17"); + map.put("acctCertificateNo", merDetail.getMerSettleAcct().getSettleIdCardNo()); + map.put("acctOpenBankCode", merDetail.getMerSettleAcct().getOpenningBankCode()); + map.put("acctOpenBankName", merDetail.getMerSettleAcct().getOpenningBankName()); + map.put("acctClearBankCode", merDetail.getMerSettleAcct().getClearingBankCode()); + + if (merDetail.getMerType().equals(MerSettleType.status1.getNumber()) == true) { + map.put("licenseNo", merDetail.getBlisNo()); + map.put("licenseName", merDetail.getBlisName()); + map.put("legalPersonName", merDetail.getLarName()); + map.put("legalPersonCertificateType", "17"); + map.put("legalPersonCertificateNo", merDetail.getLarIdCard()); + } + + List> attachMapList = new ArrayList<>(); + Map attachMap; + + List attachList = merAttachService.getAttachListByMer(merId, PlatformTypeEnum.type0, null); + for (BsMerAttach attach : attachList) { + if (StringUtils.isNotBlank(attach.getFileUrl())) { + MerAttachType attachType = MerAttachType.getDataByNumber(attach.getType()); + if (attachType != null && StringUtils.isNotBlank(attachType.getLklCode())) { + attachMap = new HashMap<>(); + + // 转换成bas64 + String base64ImgUrl = ImageUtils.getBase64ByImgUrl(CommonSysConst.getSysConfig().getObs_url() + "/"+ attach.getFileUrl()); + String fileType = attach.getFileUrl().substring(attach.getFileUrl().lastIndexOf(".") + 1); + attachMap.put("attachType", attachType.getLklCode()); + attachMap.put("attachName", attachType.getName()); + attachMap.put("attachStorePath", LaKaLaConfig.uploadFile(attachType.getLklSaasCode(), fileType, base64ImgUrl).getString("attFileId")); + attachMapList.add(attachMap); + } + } + } + map.put("attachList", attachMapList); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/applyLedgerReceiver", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + + // 查询分账信息 + BsMerLedger merLedger = merLedgerService.getMerLedger(merId, PlatformTypeEnum.type1); + if (merLedger != null) { + merLedger.setReceiverNo(responseBody.getJSONObject("respData").getString("receiverNo")); + merLedgerService.editMerLedger(merLedger); + } + } + + /** + * 绑定分账关系 + */ + public void applyBind(Long merId,String receiverNo) { + // 查询 + BsMerLedgerReceiver merLedgerReceiver = merLedgerReceiverService.getMerLedgerReceiver(merId, receiverNo); + if (merLedgerReceiver == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到分账关系"); + } + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", System.currentTimeMillis()+""); + map.put("orgCode", "1"); + map.put("merCupNo", merLedgerReceiver.getCupNo()); + map.put("receiverNo", merLedgerReceiver.getReceiverNo()); + + String base64ImgUrl = ImageUtils.getBase64ByImgUrl(CommonSysConst.getSysConfig().getObs_url() + "/"+ merLedgerReceiver.getEntrustFilePath()); + String fileType = merLedgerReceiver.getEntrustFilePath().substring(merLedgerReceiver.getEntrustFilePath().lastIndexOf(".") + 1); + map.put("entrustFileName", merLedgerReceiver.getEntrustFileName()); + map.put("entrustFilePath", LaKaLaConfig.uploadFile("COOPERATION_QUALIFICATION_PROOF", fileType, base64ImgUrl).getString("attFileId")); + map.put("retUrl", CommonSysConst.getSysConfig().getDomainName()+"/crest/laKaLaNotify/applyLedgerMer"); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/applyBind", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + merLedgerReceiver.setStatus(MerLedgerStatusEnum.status1.getNumber()); + + } + + /** + * 分账关系解绑申请 + */ + public void applyUnBind(Long merId,String receiverNo) { + // 查询 + BsMerLedgerReceiver merLedgerReceiver = merLedgerReceiverService.getMerLedgerReceiver(merId, receiverNo); + if (merLedgerReceiver == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未找到分账关系"); + } + Map commonParam = new HashMap<>(); + commonParam.put("reqTime", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "1.0.0"); + commonParam.put("reqId", UnionUtils.createNonceStr()); + + Map map = new HashMap<>(); + map.put("version", "1.0"); + map.put("orderNo", System.currentTimeMillis()+""); + map.put("orgCode", "1"); + map.put("merCupNo", "8226900581208NT"); + map.put("receiverNo", ""); + map.put("entrustFileName", "123"); + + String base64ImgUrl = ImageUtils.getBase64ByImgUrl(CommonSysConst.getSysConfig().getObs_url() + "/"+ merLedgerReceiver.getEntrustFilePath()); + String fileType = merLedgerReceiver.getEntrustFilePath().substring(merLedgerReceiver.getEntrustFilePath().lastIndexOf(".") + 1); + map.put("entrustFileName", merLedgerReceiver.getEntrustFileName()); + map.put("entrustFilePath", LaKaLaConfig.uploadFile("COOPERATION_QUALIFICATION_PROOF", fileType, base64ImgUrl).getString("attFileId")); + map.put("retUrl", "123"); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v2/mms/openApi/ledger/applyUnBind", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + } + +} diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaMerService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaMerService.java index a4bb855..0e0f991 100644 --- a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaMerService.java +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaMerService.java @@ -166,11 +166,11 @@ public class LaKaLaMerService { for (BsMerAttach attach : attachList) { attachMap = new HashMap<>(); MerAttachType attachType = MerAttachType.getDataByNumber(attach.getType()); - if (attachType == null || StringUtils.isBlank(attachType.getLakalaCode())) { + if (attachType == null || StringUtils.isBlank(attachType.getLklCode())) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的附件类型"); } - attachMap.put("attType", attachType.getLakalaCode()); - attachMap.put("attFileId", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ attach.getFileUrl()), attachType.getLakalaCode(), "0").getString("url")); + attachMap.put("attType", attachType.getLklCode()); + attachMap.put("attFileId", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ attach.getFileUrl()), attachType.getLklCode(), "0").getString("url")); attachListMap.add(attachMap); } map.put("fileData", attachListMap); diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java new file mode 100644 index 0000000..b644e05 --- /dev/null +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeSeparateService.java @@ -0,0 +1,243 @@ +package com.hfkj.channel.lakala; + +import com.alibaba.fastjson.JSONObject; +import com.hfkj.channel.lakala.config.LaKaLaConfig; +import com.hfkj.common.exception.ErrorCode; +import com.hfkj.common.exception.ErrorHelp; +import com.hfkj.common.exception.SysCode; +import com.hfkj.common.utils.DateUtil; +import com.hfkj.common.utils.HttpsUtils; +import com.hfkj.common.utils.ImageUtils; +import com.hfkj.common.utils.UnionUtils; +import com.hfkj.config.CommonSysConst; +import com.hfkj.entity.*; +import com.hfkj.model.MerBasisModel; +import com.hfkj.service.*; +import com.hfkj.sysenum.*; +import org.apache.commons.lang3.StringUtils; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.*; + +/** + * 拉卡拉分账 + * @author hurui + */ +@Service +public class LaKaLaTradeSeparateService { + + @Resource + private BsTradeOrderService tradeOrderService; + @Resource + private BsTradeOrderProfitSharingService tradeOrderProfitSharingService; + @Resource + private BsTradeOrderProfitSharingReceiverService tradeOrderProfitSharingReceiverService; + + /** + * 创建分账 + * @param profitSharingOrderNo + * @return + */ + public JSONObject separate(String profitSharingOrderNo) { + // 交易分账 + BsTradeOrderProfitSharing tradeOrderProfitSharing = tradeOrderProfitSharingService.getDetailByProfitSharingOrderNo(profitSharingOrderNo); + if (null == tradeOrderProfitSharing) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "未找到交易分账记录"); + } + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "业务不处于待处理状态"); + } + // 查询交易详情 + BsTradeOrder tradeOrder = tradeOrderService.getOrderByTradeNoId(tradeOrderProfitSharing.getTradeOrderId()); + + // 分账接收方 + List profitSharingReceiverList = tradeOrderProfitSharingReceiverService.getReceiverListByProfitSharingId(tradeOrderProfitSharing.getId()); + + Map commonParam = new HashMap<>(); + commonParam.put("req_time", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "3.0"); + + Map map = new HashMap<>(); + map.put("merchant_no", tradeOrder.getPlatformMerNo()); + map.put("log_no", tradeOrder.getPlatformLogNo()); + map.put("log_date", DateUtil.date2String(tradeOrder.getPayTime(), "yyyy-MM-dd")); + map.put("out_separate_no", tradeOrderProfitSharing.getProfitSharingOrderNo()); + map.put("total_amt", tradeOrderProfitSharing.getProfitSharingAmoun()); + map.put("lkl_org_no", "1"); + map.put("cal_type", "0"); + + List> recvDatasMapList = new ArrayList<>(); + Map recvDatasMap; + + for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceiverList) { + recvDatasMap = new HashMap<>(); + recvDatasMap.put("recv_merchant_no", receiver.getReceiverAccount()); + recvDatasMap.put("separate_value", receiver.getProfitSharingAmount()); + recvDatasMapList.add(recvDatasMap); + } + commonParam.put("recv_datas", recvDatasMapList); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v3/sacs/separate", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + + JSONObject respData = responseBody.getJSONObject("resp_data"); + // 分账状态 处理中:PROCESSING, 已受理:ACCEPTED, 成功:SUCCESS, 失败:FAIL + String statusCode = respData.getString("status"); + if (statusCode.equals("PROCESSING")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + } else if (statusCode.equals("ACCEPTED")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status3.getNumber()); + } else if (statusCode.equals("SUCCESS")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status1.getNumber()); + tradeOrderProfitSharing.setProfitSharingTime(new Date()); + tradeOrderProfitSharing.setFinishTime(new Date()); + } else if (statusCode.equals("FAIL")) { + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status4.getNumber()); + } + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + + // 处理接收方数据 + if (tradeOrderProfitSharing.equals(ProfitSharingStatusEnum.status1.getName())) { + for (BsTradeOrderProfitSharingReceiver receiver : profitSharingReceiverList) { + receiver.setStatus(ProfitSharingReceiverStatusEnum.status1.getNumber()); + receiver.setProfitSharingTime(new Date()); + receiver.setFinishTime(new Date()); + tradeOrderProfitSharingReceiverService.editData(receiver); + } + } + + return responseBody; + } + + /** + * 分账撤销 + * @param profitSharingOrderNo + * @return + */ + public JSONObject cancel(String profitSharingOrderNo) { + // 交易订单分账 + BsTradeOrderProfitSharing tradeOrderProfitSharing = tradeOrderProfitSharingService.getDetailByProfitSharingOrderNo(profitSharingOrderNo); + if (null == tradeOrderProfitSharing) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "未找到交易分账记录"); + } + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "业务不处于待处理状态"); + } + + Map commonParam = new HashMap<>(); + commonParam.put("req_time", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "3.0"); + + Map map = new HashMap<>(); + map.put("merchant_no", tradeOrderProfitSharing.getPlatformMerNo()); + map.put("origin_separate_no", tradeOrderProfitSharing.getOriginProfitSharingOrderNo()); + map.put("out_separate_no", tradeOrderProfitSharing.getProfitSharingOrderNo()); + map.put("total_amt", tradeOrderProfitSharing.getProfitSharingAmoun()); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v3/sacs/cancel", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + return responseBody; + } + + /** + * 分账回退 + * @param profitSharingOrderNo 交易订单号 + * @return + */ + public JSONObject fallback(String profitSharingOrderNo) { + // 交易订单分账 + BsTradeOrderProfitSharing tradeOrderProfitSharing = tradeOrderProfitSharingService.getDetailByProfitSharingOrderNo(profitSharingOrderNo); + if (null == tradeOrderProfitSharing) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "未找到交易分账记录"); + } + if (tradeOrderProfitSharing.getStatus().equals(ProfitSharingStatusEnum.status0.getNumber())) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "业务不处于待处理状态"); + } + + Map commonParam = new HashMap<>(); + commonParam.put("req_time", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "3.0"); + + Map map = new HashMap<>(); + map.put("merchant_no", tradeOrderProfitSharing.getPlatformMerNo()); + map.put("origin_separate_no", tradeOrderProfitSharing.getOriginProfitSharingOrderNo()); + map.put("out_separate_no", tradeOrderProfitSharing.getProfitSharingOrderNo()); + map.put("total_amt", tradeOrderProfitSharing.getProfitSharingAmoun()); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v3/sacs/fallback", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status2.getNumber()); + tradeOrderProfitSharingService.editData(tradeOrderProfitSharing); + return responseBody; + } + + /** + * 分账结果查询 + * @param profitSharingOrderNo 交易订单号 + * @return + */ + public JSONObject query(String profitSharingOrderNo) { + // 交易订单分账 + BsTradeOrderProfitSharing tradeOrderProfitSharing = tradeOrderProfitSharingService.getDetailByProfitSharingOrderNo(profitSharingOrderNo); + if (null == tradeOrderProfitSharing) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.REQ_PARAMS_ERROR, "未找到交易分账记录"); + } + + Map commonParam = new HashMap<>(); + commonParam.put("req_time", DateUtil.format(new Date(), "yyyyMMddHHmmss")); + commonParam.put("version", "3.0"); + + Map map = new HashMap<>(); + map.put("merchant_no", tradeOrderProfitSharing.getPlatformMerNo()); + map.put("separate_no", tradeOrderProfitSharing.getProfitSharingOrderNo()); + commonParam.put("reqData", map); + + Map reqParam = LaKaLaConfig.generateSignParamsV2(JSONObject.parseObject(JSONObject.toJSONString(commonParam))); + // 头部参数 + Map heard = new HashMap<>(); + heard.put("Authorization", reqParam.get("Authorization")); + + JSONObject responseBody = HttpsUtils.doPost(CommonSysConst.getSysConfig().getLkl_request_url() + "/api/v3/sacs/query", commonParam, heard); + System.out.println("body:" + JSONObject.toJSONString(commonParam)); + System.out.println("response:" + responseBody.toJSONString()); + if (!responseBody.getString("retCode").equals("000000")) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, responseBody.getString("retMsg")); + } + return responseBody.getJSONObject("resp_data"); + } + +} diff --git a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeService.java b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeService.java index f2dff7b..5c87648 100644 --- a/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeService.java +++ b/service/src/main/java/com/hfkj/channel/lakala/LaKaLaTradeService.java @@ -194,7 +194,7 @@ public class LaKaLaTradeService { map.put("notify_url", CommonSysConst.getSysConfig().getLkl_micro_pay_ret_url()); Map locationInfo = new HashMap<>(); - locationInfo.put("request_ip", "10.176.1.192"); + locationInfo.put("request_ip", "0.0.0.0"); map.put("location_info", locationInfo); Map accBusiFieldsMap = new HashMap<>(); diff --git a/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java b/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java index 533656a..c458269 100644 --- a/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java +++ b/service/src/main/java/com/hfkj/channel/saas/SaasMerService.java @@ -198,11 +198,11 @@ public class SaasMerService { for (BsMerAttach attach : attachList) { attchMap = new HashMap<>(); MerAttachType attachType = MerAttachType.getDataByNumber(attach.getType()); - if (attachType == null || StringUtils.isBlank(attachType.getLakalaCode())) { + if (attachType == null || StringUtils.isBlank(attachType.getLklSaasCode())) { throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的附件类型"); } - attchMap.put("type", attachType.getLakalaCode()); - attchMap.put("id", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ attach.getFileUrl()), attachType.getLakalaCode(), "0").getString("url")); + attchMap.put("type", attachType.getLklSaasCode()); + attchMap.put("id", saasCommon.fileUpload(new File(CommonSysConst.getSysConfig().getFile_url() +"/"+ attach.getFileUrl()), attachType.getLklSaasCode(), "0").getString("url")); attchMapList.add(attchMap); } diff --git a/service/src/main/java/com/hfkj/common/utils/DateUtil.java b/service/src/main/java/com/hfkj/common/utils/DateUtil.java index bbf1a19..9a1f7e8 100644 --- a/service/src/main/java/com/hfkj/common/utils/DateUtil.java +++ b/service/src/main/java/com/hfkj/common/utils/DateUtil.java @@ -39,7 +39,7 @@ public class DateUtil { Calendar calendar = Calendar.getInstance(); return calendar.get(Calendar.YEAR); } - public static String date2String(Date date,String format) throws Exception{ + public static String date2String(Date date,String format) { String str = null; SimpleDateFormat sdf = new SimpleDateFormat(format); if(date != null){ diff --git a/service/src/main/java/com/hfkj/config/CommonSysConfig.java b/service/src/main/java/com/hfkj/config/CommonSysConfig.java index 823f544..a690ff2 100644 --- a/service/src/main/java/com/hfkj/config/CommonSysConfig.java +++ b/service/src/main/java/com/hfkj/config/CommonSysConfig.java @@ -100,6 +100,10 @@ public class CommonSysConfig { private String lkl_saas_public_key; private String lkl_saas_private_key; + /** + * 域名 + */ + private String domainName; /** * 微信支付回调 */ diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapper.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapper.java new file mode 100644 index 0000000..16e2bcc --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapper.java @@ -0,0 +1,133 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerApply; +import com.hfkj.entity.BsMerLedgerApplyExample; +import java.util.List; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.DeleteProvider; +import org.apache.ibatis.annotations.Insert; +import org.apache.ibatis.annotations.InsertProvider; +import org.apache.ibatis.annotations.Options; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Result; +import org.apache.ibatis.annotations.Results; +import org.apache.ibatis.annotations.Select; +import org.apache.ibatis.annotations.SelectProvider; +import org.apache.ibatis.annotations.Update; +import org.apache.ibatis.annotations.UpdateProvider; +import org.apache.ibatis.type.JdbcType; +import org.springframework.stereotype.Repository; + +/** + * + * 代码由工具生成,请勿修改!!! + * 如果需要扩展请在其父类进行扩展 + * + **/ +@Repository +public interface BsMerLedgerApplyMapper extends BsMerLedgerApplyMapperExt { + @SelectProvider(type=BsMerLedgerApplySqlProvider.class, method="countByExample") + long countByExample(BsMerLedgerApplyExample example); + + @DeleteProvider(type=BsMerLedgerApplySqlProvider.class, method="deleteByExample") + int deleteByExample(BsMerLedgerApplyExample example); + + @Delete({ + "delete from bs_mer_ledger_apply", + "where id = #{id,jdbcType=BIGINT}" + }) + int deleteByPrimaryKey(Long id); + + @Insert({ + "insert into bs_mer_ledger_apply (mer_id, mer_ledger_id, ", + "order_no, apply_id, ", + "request_body, response_body, ", + "notify_body, `status`, ", + "create_time, update_time, ", + "ext_1, ext_2, ext_3)", + "values (#{merId,jdbcType=BIGINT}, #{merLedgerId,jdbcType=BIGINT}, ", + "#{orderNo,jdbcType=VARCHAR}, #{applyId,jdbcType=VARCHAR}, ", + "#{requestBody,jdbcType=VARCHAR}, #{responseBody,jdbcType=VARCHAR}, ", + "#{notifyBody,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, ", + "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ", + "#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + }) + @Options(useGeneratedKeys=true,keyProperty="id") + int insert(BsMerLedgerApply record); + + @InsertProvider(type=BsMerLedgerApplySqlProvider.class, method="insertSelective") + @Options(useGeneratedKeys=true,keyProperty="id") + int insertSelective(BsMerLedgerApply record); + + @SelectProvider(type=BsMerLedgerApplySqlProvider.class, method="selectByExample") + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="order_no", property="orderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="apply_id", property="applyId", jdbcType=JdbcType.VARCHAR), + @Result(column="request_body", property="requestBody", jdbcType=JdbcType.VARCHAR), + @Result(column="response_body", property="responseBody", jdbcType=JdbcType.VARCHAR), + @Result(column="notify_body", property="notifyBody", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + List selectByExample(BsMerLedgerApplyExample example); + + @Select({ + "select", + "id, mer_id, mer_ledger_id, order_no, apply_id, request_body, response_body, ", + "notify_body, `status`, create_time, update_time, ext_1, ext_2, ext_3", + "from bs_mer_ledger_apply", + "where id = #{id,jdbcType=BIGINT}" + }) + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="order_no", property="orderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="apply_id", property="applyId", jdbcType=JdbcType.VARCHAR), + @Result(column="request_body", property="requestBody", jdbcType=JdbcType.VARCHAR), + @Result(column="response_body", property="responseBody", jdbcType=JdbcType.VARCHAR), + @Result(column="notify_body", property="notifyBody", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + BsMerLedgerApply selectByPrimaryKey(Long id); + + @UpdateProvider(type=BsMerLedgerApplySqlProvider.class, method="updateByExampleSelective") + int updateByExampleSelective(@Param("record") BsMerLedgerApply record, @Param("example") BsMerLedgerApplyExample example); + + @UpdateProvider(type=BsMerLedgerApplySqlProvider.class, method="updateByExample") + int updateByExample(@Param("record") BsMerLedgerApply record, @Param("example") BsMerLedgerApplyExample example); + + @UpdateProvider(type=BsMerLedgerApplySqlProvider.class, method="updateByPrimaryKeySelective") + int updateByPrimaryKeySelective(BsMerLedgerApply record); + + @Update({ + "update bs_mer_ledger_apply", + "set mer_id = #{merId,jdbcType=BIGINT},", + "mer_ledger_id = #{merLedgerId,jdbcType=BIGINT},", + "order_no = #{orderNo,jdbcType=VARCHAR},", + "apply_id = #{applyId,jdbcType=VARCHAR},", + "request_body = #{requestBody,jdbcType=VARCHAR},", + "response_body = #{responseBody,jdbcType=VARCHAR},", + "notify_body = #{notifyBody,jdbcType=VARCHAR},", + "`status` = #{status,jdbcType=INTEGER},", + "create_time = #{createTime,jdbcType=TIMESTAMP},", + "update_time = #{updateTime,jdbcType=TIMESTAMP},", + "ext_1 = #{ext1,jdbcType=VARCHAR},", + "ext_2 = #{ext2,jdbcType=VARCHAR},", + "ext_3 = #{ext3,jdbcType=VARCHAR}", + "where id = #{id,jdbcType=BIGINT}" + }) + int updateByPrimaryKey(BsMerLedgerApply record); +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapperExt.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapperExt.java new file mode 100644 index 0000000..d2f9c33 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplyMapperExt.java @@ -0,0 +1,7 @@ +package com.hfkj.dao; + +/** + * mapper扩展类 + */ +public interface BsMerLedgerApplyMapperExt { +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerApplySqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplySqlProvider.java new file mode 100644 index 0000000..52ede78 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerApplySqlProvider.java @@ -0,0 +1,360 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerApply; +import com.hfkj.entity.BsMerLedgerApplyExample.Criteria; +import com.hfkj.entity.BsMerLedgerApplyExample.Criterion; +import com.hfkj.entity.BsMerLedgerApplyExample; +import java.util.List; +import java.util.Map; +import org.apache.ibatis.jdbc.SQL; + +public class BsMerLedgerApplySqlProvider { + + public String countByExample(BsMerLedgerApplyExample example) { + SQL sql = new SQL(); + sql.SELECT("count(*)").FROM("bs_mer_ledger_apply"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String deleteByExample(BsMerLedgerApplyExample example) { + SQL sql = new SQL(); + sql.DELETE_FROM("bs_mer_ledger_apply"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String insertSelective(BsMerLedgerApply record) { + SQL sql = new SQL(); + sql.INSERT_INTO("bs_mer_ledger_apply"); + + if (record.getMerId() != null) { + sql.VALUES("mer_id", "#{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.VALUES("mer_ledger_id", "#{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getOrderNo() != null) { + sql.VALUES("order_no", "#{orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.VALUES("apply_id", "#{applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.VALUES("request_body", "#{requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.VALUES("response_body", "#{responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.VALUES("notify_body", "#{notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.VALUES("`status`", "#{status,jdbcType=INTEGER}"); + } + + if (record.getCreateTime() != null) { + sql.VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.VALUES("update_time", "#{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.VALUES("ext_1", "#{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.VALUES("ext_2", "#{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.VALUES("ext_3", "#{ext3,jdbcType=VARCHAR}"); + } + + return sql.toString(); + } + + public String selectByExample(BsMerLedgerApplyExample example) { + SQL sql = new SQL(); + if (example != null && example.isDistinct()) { + sql.SELECT_DISTINCT("id"); + } else { + sql.SELECT("id"); + } + sql.SELECT("mer_id"); + sql.SELECT("mer_ledger_id"); + sql.SELECT("order_no"); + sql.SELECT("apply_id"); + sql.SELECT("request_body"); + sql.SELECT("response_body"); + sql.SELECT("notify_body"); + sql.SELECT("`status`"); + sql.SELECT("create_time"); + sql.SELECT("update_time"); + sql.SELECT("ext_1"); + sql.SELECT("ext_2"); + sql.SELECT("ext_3"); + sql.FROM("bs_mer_ledger_apply"); + applyWhere(sql, example, false); + + if (example != null && example.getOrderByClause() != null) { + sql.ORDER_BY(example.getOrderByClause()); + } + + return sql.toString(); + } + + public String updateByExampleSelective(Map parameter) { + BsMerLedgerApply record = (BsMerLedgerApply) parameter.get("record"); + BsMerLedgerApplyExample example = (BsMerLedgerApplyExample) parameter.get("example"); + + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_apply"); + + if (record.getId() != null) { + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + } + + if (record.getMerId() != null) { + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getOrderNo() != null) { + sql.SET("order_no = #{record.orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.SET("apply_id = #{record.applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.SET("request_body = #{record.requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.SET("response_body = #{record.responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.SET("notify_body = #{record.notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + } + + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByExample(Map parameter) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_apply"); + + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + sql.SET("order_no = #{record.orderNo,jdbcType=VARCHAR}"); + sql.SET("apply_id = #{record.applyId,jdbcType=VARCHAR}"); + sql.SET("request_body = #{record.requestBody,jdbcType=VARCHAR}"); + sql.SET("response_body = #{record.responseBody,jdbcType=VARCHAR}"); + sql.SET("notify_body = #{record.notifyBody,jdbcType=VARCHAR}"); + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + + BsMerLedgerApplyExample example = (BsMerLedgerApplyExample) parameter.get("example"); + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByPrimaryKeySelective(BsMerLedgerApply record) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_apply"); + + if (record.getMerId() != null) { + sql.SET("mer_id = #{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getOrderNo() != null) { + sql.SET("order_no = #{orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.SET("apply_id = #{applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.SET("request_body = #{requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.SET("response_body = #{responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.SET("notify_body = #{notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{status,jdbcType=INTEGER}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{ext3,jdbcType=VARCHAR}"); + } + + sql.WHERE("id = #{id,jdbcType=BIGINT}"); + + return sql.toString(); + } + + protected void applyWhere(SQL sql, BsMerLedgerApplyExample example, boolean includeExamplePhrase) { + if (example == null) { + return; + } + + String parmPhrase1; + String parmPhrase1_th; + String parmPhrase2; + String parmPhrase2_th; + String parmPhrase3; + String parmPhrase3_th; + if (includeExamplePhrase) { + parmPhrase1 = "%s #{example.oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{example.oredCriteria[%d].allCriteria[%d].value} and #{example.oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{example.oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{example.oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{example.oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } else { + parmPhrase1 = "%s #{oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{oredCriteria[%d].allCriteria[%d].value} and #{oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } + + StringBuilder sb = new StringBuilder(); + List oredCriteria = example.getOredCriteria(); + boolean firstCriteria = true; + for (int i = 0; i < oredCriteria.size(); i++) { + Criteria criteria = oredCriteria.get(i); + if (criteria.isValid()) { + if (firstCriteria) { + firstCriteria = false; + } else { + sb.append(" or "); + } + + sb.append('('); + List criterions = criteria.getAllCriteria(); + boolean firstCriterion = true; + for (int j = 0; j < criterions.size(); j++) { + Criterion criterion = criterions.get(j); + if (firstCriterion) { + firstCriterion = false; + } else { + sb.append(" and "); + } + + if (criterion.isNoValue()) { + sb.append(criterion.getCondition()); + } else if (criterion.isSingleValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase1, criterion.getCondition(), i, j)); + } else { + sb.append(String.format(parmPhrase1_th, criterion.getCondition(), i, j,criterion.getTypeHandler())); + } + } else if (criterion.isBetweenValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase2, criterion.getCondition(), i, j, i, j)); + } else { + sb.append(String.format(parmPhrase2_th, criterion.getCondition(), i, j, criterion.getTypeHandler(), i, j, criterion.getTypeHandler())); + } + } else if (criterion.isListValue()) { + sb.append(criterion.getCondition()); + sb.append(" ("); + List listItems = (List) criterion.getValue(); + boolean comma = false; + for (int k = 0; k < listItems.size(); k++) { + if (comma) { + sb.append(", "); + } else { + comma = true; + } + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase3, i, j, k)); + } else { + sb.append(String.format(parmPhrase3_th, i, j, k, criterion.getTypeHandler())); + } + } + sb.append(')'); + } + } + sb.append(')'); + } + } + + if (sb.length() > 0) { + sql.WHERE(sb.toString()); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerMapper.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerMapper.java new file mode 100644 index 0000000..24e5c0b --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerMapper.java @@ -0,0 +1,142 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedger; +import com.hfkj.entity.BsMerLedgerExample; +import java.util.List; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.DeleteProvider; +import org.apache.ibatis.annotations.Insert; +import org.apache.ibatis.annotations.InsertProvider; +import org.apache.ibatis.annotations.Options; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Result; +import org.apache.ibatis.annotations.Results; +import org.apache.ibatis.annotations.Select; +import org.apache.ibatis.annotations.SelectProvider; +import org.apache.ibatis.annotations.Update; +import org.apache.ibatis.annotations.UpdateProvider; +import org.apache.ibatis.type.JdbcType; +import org.springframework.stereotype.Repository; + +/** + * + * 代码由工具生成,请勿修改!!! + * 如果需要扩展请在其父类进行扩展 + * + **/ +@Repository +public interface BsMerLedgerMapper extends BsMerLedgerMapperExt { + @SelectProvider(type=BsMerLedgerSqlProvider.class, method="countByExample") + long countByExample(BsMerLedgerExample example); + + @DeleteProvider(type=BsMerLedgerSqlProvider.class, method="deleteByExample") + int deleteByExample(BsMerLedgerExample example); + + @Delete({ + "delete from bs_mer_ledger", + "where id = #{id,jdbcType=BIGINT}" + }) + int deleteByPrimaryKey(Long id); + + @Insert({ + "insert into bs_mer_ledger (mer_id, platform_type, ", + "platform_no, cup_no, ", + "receiver_no, split_lowest_ratio, ", + "split_entrust_file_name, split_entrust_file_path, ", + "`status`, reject_reason, ", + "create_time, update_time, ", + "ext_1, ext_2, ext_3)", + "values (#{merId,jdbcType=BIGINT}, #{platformType,jdbcType=INTEGER}, ", + "#{platformNo,jdbcType=VARCHAR}, #{cupNo,jdbcType=VARCHAR}, ", + "#{receiverNo,jdbcType=VARCHAR}, #{splitLowestRatio,jdbcType=DECIMAL}, ", + "#{splitEntrustFileName,jdbcType=VARCHAR}, #{splitEntrustFilePath,jdbcType=VARCHAR}, ", + "#{status,jdbcType=INTEGER}, #{rejectReason,jdbcType=VARCHAR}, ", + "#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, ", + "#{ext1,jdbcType=VARCHAR}, #{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + }) + @Options(useGeneratedKeys=true,keyProperty="id") + int insert(BsMerLedger record); + + @InsertProvider(type=BsMerLedgerSqlProvider.class, method="insertSelective") + @Options(useGeneratedKeys=true,keyProperty="id") + int insertSelective(BsMerLedger record); + + @SelectProvider(type=BsMerLedgerSqlProvider.class, method="selectByExample") + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), + @Result(column="platform_no", property="platformNo", jdbcType=JdbcType.VARCHAR), + @Result(column="cup_no", property="cupNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="split_lowest_ratio", property="splitLowestRatio", jdbcType=JdbcType.DECIMAL), + @Result(column="split_entrust_file_name", property="splitEntrustFileName", jdbcType=JdbcType.VARCHAR), + @Result(column="split_entrust_file_path", property="splitEntrustFilePath", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + List selectByExample(BsMerLedgerExample example); + + @Select({ + "select", + "id, mer_id, platform_type, platform_no, cup_no, receiver_no, split_lowest_ratio, ", + "split_entrust_file_name, split_entrust_file_path, `status`, reject_reason, create_time, ", + "update_time, ext_1, ext_2, ext_3", + "from bs_mer_ledger", + "where id = #{id,jdbcType=BIGINT}" + }) + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), + @Result(column="platform_no", property="platformNo", jdbcType=JdbcType.VARCHAR), + @Result(column="cup_no", property="cupNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="split_lowest_ratio", property="splitLowestRatio", jdbcType=JdbcType.DECIMAL), + @Result(column="split_entrust_file_name", property="splitEntrustFileName", jdbcType=JdbcType.VARCHAR), + @Result(column="split_entrust_file_path", property="splitEntrustFilePath", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + BsMerLedger selectByPrimaryKey(Long id); + + @UpdateProvider(type=BsMerLedgerSqlProvider.class, method="updateByExampleSelective") + int updateByExampleSelective(@Param("record") BsMerLedger record, @Param("example") BsMerLedgerExample example); + + @UpdateProvider(type=BsMerLedgerSqlProvider.class, method="updateByExample") + int updateByExample(@Param("record") BsMerLedger record, @Param("example") BsMerLedgerExample example); + + @UpdateProvider(type=BsMerLedgerSqlProvider.class, method="updateByPrimaryKeySelective") + int updateByPrimaryKeySelective(BsMerLedger record); + + @Update({ + "update bs_mer_ledger", + "set mer_id = #{merId,jdbcType=BIGINT},", + "platform_type = #{platformType,jdbcType=INTEGER},", + "platform_no = #{platformNo,jdbcType=VARCHAR},", + "cup_no = #{cupNo,jdbcType=VARCHAR},", + "receiver_no = #{receiverNo,jdbcType=VARCHAR},", + "split_lowest_ratio = #{splitLowestRatio,jdbcType=DECIMAL},", + "split_entrust_file_name = #{splitEntrustFileName,jdbcType=VARCHAR},", + "split_entrust_file_path = #{splitEntrustFilePath,jdbcType=VARCHAR},", + "`status` = #{status,jdbcType=INTEGER},", + "reject_reason = #{rejectReason,jdbcType=VARCHAR},", + "create_time = #{createTime,jdbcType=TIMESTAMP},", + "update_time = #{updateTime,jdbcType=TIMESTAMP},", + "ext_1 = #{ext1,jdbcType=VARCHAR},", + "ext_2 = #{ext2,jdbcType=VARCHAR},", + "ext_3 = #{ext3,jdbcType=VARCHAR}", + "where id = #{id,jdbcType=BIGINT}" + }) + int updateByPrimaryKey(BsMerLedger record); +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerMapperExt.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerMapperExt.java new file mode 100644 index 0000000..9de8390 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerMapperExt.java @@ -0,0 +1,7 @@ +package com.hfkj.dao; + +/** + * mapper扩展类 + */ +public interface BsMerLedgerMapperExt { +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapper.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapper.java new file mode 100644 index 0000000..1ce5172 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapper.java @@ -0,0 +1,147 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerReceiverApply; +import com.hfkj.entity.BsMerLedgerReceiverApplyExample; +import java.util.List; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.DeleteProvider; +import org.apache.ibatis.annotations.Insert; +import org.apache.ibatis.annotations.InsertProvider; +import org.apache.ibatis.annotations.Options; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Result; +import org.apache.ibatis.annotations.Results; +import org.apache.ibatis.annotations.Select; +import org.apache.ibatis.annotations.SelectProvider; +import org.apache.ibatis.annotations.Update; +import org.apache.ibatis.annotations.UpdateProvider; +import org.apache.ibatis.type.JdbcType; +import org.springframework.stereotype.Repository; + +/** + * + * 代码由工具生成,请勿修改!!! + * 如果需要扩展请在其父类进行扩展 + * + **/ +@Repository +public interface BsMerLedgerReceiverApplyMapper extends BsMerLedgerReceiverApplyMapperExt { + @SelectProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="countByExample") + long countByExample(BsMerLedgerReceiverApplyExample example); + + @DeleteProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="deleteByExample") + int deleteByExample(BsMerLedgerReceiverApplyExample example); + + @Delete({ + "delete from bs_mer_ledger_receiver_apply", + "where id = #{id,jdbcType=BIGINT}" + }) + int deleteByPrimaryKey(Long id); + + @Insert({ + "insert into bs_mer_ledger_receiver_apply (mer_id, mer_ledger_id, ", + "mer_ledger_receiver_id, receiver_no, ", + "order_no, apply_id, ", + "request_body, response_body, ", + "notify_body, `status`, ", + "reject_reason, create_time, ", + "update_time, ext_1, ", + "ext_2, ext_3)", + "values (#{merId,jdbcType=BIGINT}, #{merLedgerId,jdbcType=BIGINT}, ", + "#{merLedgerReceiverId,jdbcType=BIGINT}, #{receiverNo,jdbcType=VARCHAR}, ", + "#{orderNo,jdbcType=VARCHAR}, #{applyId,jdbcType=VARCHAR}, ", + "#{requestBody,jdbcType=VARCHAR}, #{responseBody,jdbcType=VARCHAR}, ", + "#{notifyBody,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, ", + "#{rejectReason,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, ", + "#{updateTime,jdbcType=TIMESTAMP}, #{ext1,jdbcType=VARCHAR}, ", + "#{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + }) + @Options(useGeneratedKeys=true,keyProperty="id") + int insert(BsMerLedgerReceiverApply record); + + @InsertProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="insertSelective") + @Options(useGeneratedKeys=true,keyProperty="id") + int insertSelective(BsMerLedgerReceiverApply record); + + @SelectProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="selectByExample") + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_receiver_id", property="merLedgerReceiverId", jdbcType=JdbcType.BIGINT), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="order_no", property="orderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="apply_id", property="applyId", jdbcType=JdbcType.VARCHAR), + @Result(column="request_body", property="requestBody", jdbcType=JdbcType.VARCHAR), + @Result(column="response_body", property="responseBody", jdbcType=JdbcType.VARCHAR), + @Result(column="notify_body", property="notifyBody", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + List selectByExample(BsMerLedgerReceiverApplyExample example); + + @Select({ + "select", + "id, mer_id, mer_ledger_id, mer_ledger_receiver_id, receiver_no, order_no, apply_id, ", + "request_body, response_body, notify_body, `status`, reject_reason, create_time, ", + "update_time, ext_1, ext_2, ext_3", + "from bs_mer_ledger_receiver_apply", + "where id = #{id,jdbcType=BIGINT}" + }) + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_receiver_id", property="merLedgerReceiverId", jdbcType=JdbcType.BIGINT), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="order_no", property="orderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="apply_id", property="applyId", jdbcType=JdbcType.VARCHAR), + @Result(column="request_body", property="requestBody", jdbcType=JdbcType.VARCHAR), + @Result(column="response_body", property="responseBody", jdbcType=JdbcType.VARCHAR), + @Result(column="notify_body", property="notifyBody", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + BsMerLedgerReceiverApply selectByPrimaryKey(Long id); + + @UpdateProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="updateByExampleSelective") + int updateByExampleSelective(@Param("record") BsMerLedgerReceiverApply record, @Param("example") BsMerLedgerReceiverApplyExample example); + + @UpdateProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="updateByExample") + int updateByExample(@Param("record") BsMerLedgerReceiverApply record, @Param("example") BsMerLedgerReceiverApplyExample example); + + @UpdateProvider(type=BsMerLedgerReceiverApplySqlProvider.class, method="updateByPrimaryKeySelective") + int updateByPrimaryKeySelective(BsMerLedgerReceiverApply record); + + @Update({ + "update bs_mer_ledger_receiver_apply", + "set mer_id = #{merId,jdbcType=BIGINT},", + "mer_ledger_id = #{merLedgerId,jdbcType=BIGINT},", + "mer_ledger_receiver_id = #{merLedgerReceiverId,jdbcType=BIGINT},", + "receiver_no = #{receiverNo,jdbcType=VARCHAR},", + "order_no = #{orderNo,jdbcType=VARCHAR},", + "apply_id = #{applyId,jdbcType=VARCHAR},", + "request_body = #{requestBody,jdbcType=VARCHAR},", + "response_body = #{responseBody,jdbcType=VARCHAR},", + "notify_body = #{notifyBody,jdbcType=VARCHAR},", + "`status` = #{status,jdbcType=INTEGER},", + "reject_reason = #{rejectReason,jdbcType=VARCHAR},", + "create_time = #{createTime,jdbcType=TIMESTAMP},", + "update_time = #{updateTime,jdbcType=TIMESTAMP},", + "ext_1 = #{ext1,jdbcType=VARCHAR},", + "ext_2 = #{ext2,jdbcType=VARCHAR},", + "ext_3 = #{ext3,jdbcType=VARCHAR}", + "where id = #{id,jdbcType=BIGINT}" + }) + int updateByPrimaryKey(BsMerLedgerReceiverApply record); +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapperExt.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapperExt.java new file mode 100644 index 0000000..5e7e115 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplyMapperExt.java @@ -0,0 +1,7 @@ +package com.hfkj.dao; + +/** + * mapper扩展类 + */ +public interface BsMerLedgerReceiverApplyMapperExt { +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplySqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplySqlProvider.java new file mode 100644 index 0000000..1dc8110 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverApplySqlProvider.java @@ -0,0 +1,402 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerReceiverApply; +import com.hfkj.entity.BsMerLedgerReceiverApplyExample.Criteria; +import com.hfkj.entity.BsMerLedgerReceiverApplyExample.Criterion; +import com.hfkj.entity.BsMerLedgerReceiverApplyExample; +import java.util.List; +import java.util.Map; +import org.apache.ibatis.jdbc.SQL; + +public class BsMerLedgerReceiverApplySqlProvider { + + public String countByExample(BsMerLedgerReceiverApplyExample example) { + SQL sql = new SQL(); + sql.SELECT("count(*)").FROM("bs_mer_ledger_receiver_apply"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String deleteByExample(BsMerLedgerReceiverApplyExample example) { + SQL sql = new SQL(); + sql.DELETE_FROM("bs_mer_ledger_receiver_apply"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String insertSelective(BsMerLedgerReceiverApply record) { + SQL sql = new SQL(); + sql.INSERT_INTO("bs_mer_ledger_receiver_apply"); + + if (record.getMerId() != null) { + sql.VALUES("mer_id", "#{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.VALUES("mer_ledger_id", "#{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerReceiverId() != null) { + sql.VALUES("mer_ledger_receiver_id", "#{merLedgerReceiverId,jdbcType=BIGINT}"); + } + + if (record.getReceiverNo() != null) { + sql.VALUES("receiver_no", "#{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getOrderNo() != null) { + sql.VALUES("order_no", "#{orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.VALUES("apply_id", "#{applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.VALUES("request_body", "#{requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.VALUES("response_body", "#{responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.VALUES("notify_body", "#{notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.VALUES("`status`", "#{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.VALUES("reject_reason", "#{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.VALUES("update_time", "#{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.VALUES("ext_1", "#{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.VALUES("ext_2", "#{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.VALUES("ext_3", "#{ext3,jdbcType=VARCHAR}"); + } + + return sql.toString(); + } + + public String selectByExample(BsMerLedgerReceiverApplyExample example) { + SQL sql = new SQL(); + if (example != null && example.isDistinct()) { + sql.SELECT_DISTINCT("id"); + } else { + sql.SELECT("id"); + } + sql.SELECT("mer_id"); + sql.SELECT("mer_ledger_id"); + sql.SELECT("mer_ledger_receiver_id"); + sql.SELECT("receiver_no"); + sql.SELECT("order_no"); + sql.SELECT("apply_id"); + sql.SELECT("request_body"); + sql.SELECT("response_body"); + sql.SELECT("notify_body"); + sql.SELECT("`status`"); + sql.SELECT("reject_reason"); + sql.SELECT("create_time"); + sql.SELECT("update_time"); + sql.SELECT("ext_1"); + sql.SELECT("ext_2"); + sql.SELECT("ext_3"); + sql.FROM("bs_mer_ledger_receiver_apply"); + applyWhere(sql, example, false); + + if (example != null && example.getOrderByClause() != null) { + sql.ORDER_BY(example.getOrderByClause()); + } + + return sql.toString(); + } + + public String updateByExampleSelective(Map parameter) { + BsMerLedgerReceiverApply record = (BsMerLedgerReceiverApply) parameter.get("record"); + BsMerLedgerReceiverApplyExample example = (BsMerLedgerReceiverApplyExample) parameter.get("example"); + + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver_apply"); + + if (record.getId() != null) { + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + } + + if (record.getMerId() != null) { + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerReceiverId() != null) { + sql.SET("mer_ledger_receiver_id = #{record.merLedgerReceiverId,jdbcType=BIGINT}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getOrderNo() != null) { + sql.SET("order_no = #{record.orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.SET("apply_id = #{record.applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.SET("request_body = #{record.requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.SET("response_body = #{record.responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.SET("notify_body = #{record.notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + } + + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByExample(Map parameter) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver_apply"); + + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + sql.SET("mer_ledger_receiver_id = #{record.merLedgerReceiverId,jdbcType=BIGINT}"); + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + sql.SET("order_no = #{record.orderNo,jdbcType=VARCHAR}"); + sql.SET("apply_id = #{record.applyId,jdbcType=VARCHAR}"); + sql.SET("request_body = #{record.requestBody,jdbcType=VARCHAR}"); + sql.SET("response_body = #{record.responseBody,jdbcType=VARCHAR}"); + sql.SET("notify_body = #{record.notifyBody,jdbcType=VARCHAR}"); + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + + BsMerLedgerReceiverApplyExample example = (BsMerLedgerReceiverApplyExample) parameter.get("example"); + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByPrimaryKeySelective(BsMerLedgerReceiverApply record) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver_apply"); + + if (record.getMerId() != null) { + sql.SET("mer_id = #{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerReceiverId() != null) { + sql.SET("mer_ledger_receiver_id = #{merLedgerReceiverId,jdbcType=BIGINT}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getOrderNo() != null) { + sql.SET("order_no = #{orderNo,jdbcType=VARCHAR}"); + } + + if (record.getApplyId() != null) { + sql.SET("apply_id = #{applyId,jdbcType=VARCHAR}"); + } + + if (record.getRequestBody() != null) { + sql.SET("request_body = #{requestBody,jdbcType=VARCHAR}"); + } + + if (record.getResponseBody() != null) { + sql.SET("response_body = #{responseBody,jdbcType=VARCHAR}"); + } + + if (record.getNotifyBody() != null) { + sql.SET("notify_body = #{notifyBody,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{ext3,jdbcType=VARCHAR}"); + } + + sql.WHERE("id = #{id,jdbcType=BIGINT}"); + + return sql.toString(); + } + + protected void applyWhere(SQL sql, BsMerLedgerReceiverApplyExample example, boolean includeExamplePhrase) { + if (example == null) { + return; + } + + String parmPhrase1; + String parmPhrase1_th; + String parmPhrase2; + String parmPhrase2_th; + String parmPhrase3; + String parmPhrase3_th; + if (includeExamplePhrase) { + parmPhrase1 = "%s #{example.oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{example.oredCriteria[%d].allCriteria[%d].value} and #{example.oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{example.oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{example.oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{example.oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } else { + parmPhrase1 = "%s #{oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{oredCriteria[%d].allCriteria[%d].value} and #{oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } + + StringBuilder sb = new StringBuilder(); + List oredCriteria = example.getOredCriteria(); + boolean firstCriteria = true; + for (int i = 0; i < oredCriteria.size(); i++) { + Criteria criteria = oredCriteria.get(i); + if (criteria.isValid()) { + if (firstCriteria) { + firstCriteria = false; + } else { + sb.append(" or "); + } + + sb.append('('); + List criterions = criteria.getAllCriteria(); + boolean firstCriterion = true; + for (int j = 0; j < criterions.size(); j++) { + Criterion criterion = criterions.get(j); + if (firstCriterion) { + firstCriterion = false; + } else { + sb.append(" and "); + } + + if (criterion.isNoValue()) { + sb.append(criterion.getCondition()); + } else if (criterion.isSingleValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase1, criterion.getCondition(), i, j)); + } else { + sb.append(String.format(parmPhrase1_th, criterion.getCondition(), i, j,criterion.getTypeHandler())); + } + } else if (criterion.isBetweenValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase2, criterion.getCondition(), i, j, i, j)); + } else { + sb.append(String.format(parmPhrase2_th, criterion.getCondition(), i, j, criterion.getTypeHandler(), i, j, criterion.getTypeHandler())); + } + } else if (criterion.isListValue()) { + sb.append(criterion.getCondition()); + sb.append(" ("); + List listItems = (List) criterion.getValue(); + boolean comma = false; + for (int k = 0; k < listItems.size(); k++) { + if (comma) { + sb.append(", "); + } else { + comma = true; + } + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase3, i, j, k)); + } else { + sb.append(String.format(parmPhrase3_th, i, j, k, criterion.getTypeHandler())); + } + } + sb.append(')'); + } + } + sb.append(')'); + } + } + + if (sb.length() > 0) { + sql.WHERE(sb.toString()); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapper.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapper.java new file mode 100644 index 0000000..7c44008 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapper.java @@ -0,0 +1,147 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerReceiver; +import com.hfkj.entity.BsMerLedgerReceiverExample; +import java.util.List; +import org.apache.ibatis.annotations.Delete; +import org.apache.ibatis.annotations.DeleteProvider; +import org.apache.ibatis.annotations.Insert; +import org.apache.ibatis.annotations.InsertProvider; +import org.apache.ibatis.annotations.Options; +import org.apache.ibatis.annotations.Param; +import org.apache.ibatis.annotations.Result; +import org.apache.ibatis.annotations.Results; +import org.apache.ibatis.annotations.Select; +import org.apache.ibatis.annotations.SelectProvider; +import org.apache.ibatis.annotations.Update; +import org.apache.ibatis.annotations.UpdateProvider; +import org.apache.ibatis.type.JdbcType; +import org.springframework.stereotype.Repository; + +/** + * + * 代码由工具生成,请勿修改!!! + * 如果需要扩展请在其父类进行扩展 + * + **/ +@Repository +public interface BsMerLedgerReceiverMapper extends BsMerLedgerReceiverMapperExt { + @SelectProvider(type=BsMerLedgerReceiverSqlProvider.class, method="countByExample") + long countByExample(BsMerLedgerReceiverExample example); + + @DeleteProvider(type=BsMerLedgerReceiverSqlProvider.class, method="deleteByExample") + int deleteByExample(BsMerLedgerReceiverExample example); + + @Delete({ + "delete from bs_mer_ledger_receiver", + "where id = #{id,jdbcType=BIGINT}" + }) + int deleteByPrimaryKey(Long id); + + @Insert({ + "insert into bs_mer_ledger_receiver (mer_id, mer_ledger_id, ", + "platform_type, platform_no, ", + "cup_no, receiver_no, ", + "receiver_name, entrust_file_name, ", + "entrust_file_path, `status`, ", + "reject_reason, create_time, ", + "update_time, ext_1, ", + "ext_2, ext_3)", + "values (#{merId,jdbcType=BIGINT}, #{merLedgerId,jdbcType=BIGINT}, ", + "#{platformType,jdbcType=INTEGER}, #{platformNo,jdbcType=VARCHAR}, ", + "#{cupNo,jdbcType=VARCHAR}, #{receiverNo,jdbcType=VARCHAR}, ", + "#{receiverName,jdbcType=VARCHAR}, #{entrustFileName,jdbcType=VARCHAR}, ", + "#{entrustFilePath,jdbcType=VARCHAR}, #{status,jdbcType=INTEGER}, ", + "#{rejectReason,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, ", + "#{updateTime,jdbcType=TIMESTAMP}, #{ext1,jdbcType=VARCHAR}, ", + "#{ext2,jdbcType=VARCHAR}, #{ext3,jdbcType=VARCHAR})" + }) + @Options(useGeneratedKeys=true,keyProperty="id") + int insert(BsMerLedgerReceiver record); + + @InsertProvider(type=BsMerLedgerReceiverSqlProvider.class, method="insertSelective") + @Options(useGeneratedKeys=true,keyProperty="id") + int insertSelective(BsMerLedgerReceiver record); + + @SelectProvider(type=BsMerLedgerReceiverSqlProvider.class, method="selectByExample") + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), + @Result(column="platform_no", property="platformNo", jdbcType=JdbcType.VARCHAR), + @Result(column="cup_no", property="cupNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_name", property="receiverName", jdbcType=JdbcType.VARCHAR), + @Result(column="entrust_file_name", property="entrustFileName", jdbcType=JdbcType.VARCHAR), + @Result(column="entrust_file_path", property="entrustFilePath", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + List selectByExample(BsMerLedgerReceiverExample example); + + @Select({ + "select", + "id, mer_id, mer_ledger_id, platform_type, platform_no, cup_no, receiver_no, ", + "receiver_name, entrust_file_name, entrust_file_path, `status`, reject_reason, ", + "create_time, update_time, ext_1, ext_2, ext_3", + "from bs_mer_ledger_receiver", + "where id = #{id,jdbcType=BIGINT}" + }) + @Results({ + @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="mer_id", property="merId", jdbcType=JdbcType.BIGINT), + @Result(column="mer_ledger_id", property="merLedgerId", jdbcType=JdbcType.BIGINT), + @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), + @Result(column="platform_no", property="platformNo", jdbcType=JdbcType.VARCHAR), + @Result(column="cup_no", property="cupNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_no", property="receiverNo", jdbcType=JdbcType.VARCHAR), + @Result(column="receiver_name", property="receiverName", jdbcType=JdbcType.VARCHAR), + @Result(column="entrust_file_name", property="entrustFileName", jdbcType=JdbcType.VARCHAR), + @Result(column="entrust_file_path", property="entrustFilePath", jdbcType=JdbcType.VARCHAR), + @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), + @Result(column="reject_reason", property="rejectReason", jdbcType=JdbcType.VARCHAR), + @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="update_time", property="updateTime", jdbcType=JdbcType.TIMESTAMP), + @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), + @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) + }) + BsMerLedgerReceiver selectByPrimaryKey(Long id); + + @UpdateProvider(type=BsMerLedgerReceiverSqlProvider.class, method="updateByExampleSelective") + int updateByExampleSelective(@Param("record") BsMerLedgerReceiver record, @Param("example") BsMerLedgerReceiverExample example); + + @UpdateProvider(type=BsMerLedgerReceiverSqlProvider.class, method="updateByExample") + int updateByExample(@Param("record") BsMerLedgerReceiver record, @Param("example") BsMerLedgerReceiverExample example); + + @UpdateProvider(type=BsMerLedgerReceiverSqlProvider.class, method="updateByPrimaryKeySelective") + int updateByPrimaryKeySelective(BsMerLedgerReceiver record); + + @Update({ + "update bs_mer_ledger_receiver", + "set mer_id = #{merId,jdbcType=BIGINT},", + "mer_ledger_id = #{merLedgerId,jdbcType=BIGINT},", + "platform_type = #{platformType,jdbcType=INTEGER},", + "platform_no = #{platformNo,jdbcType=VARCHAR},", + "cup_no = #{cupNo,jdbcType=VARCHAR},", + "receiver_no = #{receiverNo,jdbcType=VARCHAR},", + "receiver_name = #{receiverName,jdbcType=VARCHAR},", + "entrust_file_name = #{entrustFileName,jdbcType=VARCHAR},", + "entrust_file_path = #{entrustFilePath,jdbcType=VARCHAR},", + "`status` = #{status,jdbcType=INTEGER},", + "reject_reason = #{rejectReason,jdbcType=VARCHAR},", + "create_time = #{createTime,jdbcType=TIMESTAMP},", + "update_time = #{updateTime,jdbcType=TIMESTAMP},", + "ext_1 = #{ext1,jdbcType=VARCHAR},", + "ext_2 = #{ext2,jdbcType=VARCHAR},", + "ext_3 = #{ext3,jdbcType=VARCHAR}", + "where id = #{id,jdbcType=BIGINT}" + }) + int updateByPrimaryKey(BsMerLedgerReceiver record); +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapperExt.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapperExt.java new file mode 100644 index 0000000..739f78c --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverMapperExt.java @@ -0,0 +1,7 @@ +package com.hfkj.dao; + +/** + * mapper扩展类 + */ +public interface BsMerLedgerReceiverMapperExt { +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverSqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverSqlProvider.java new file mode 100644 index 0000000..61eef51 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerReceiverSqlProvider.java @@ -0,0 +1,402 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedgerReceiver; +import com.hfkj.entity.BsMerLedgerReceiverExample.Criteria; +import com.hfkj.entity.BsMerLedgerReceiverExample.Criterion; +import com.hfkj.entity.BsMerLedgerReceiverExample; +import java.util.List; +import java.util.Map; +import org.apache.ibatis.jdbc.SQL; + +public class BsMerLedgerReceiverSqlProvider { + + public String countByExample(BsMerLedgerReceiverExample example) { + SQL sql = new SQL(); + sql.SELECT("count(*)").FROM("bs_mer_ledger_receiver"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String deleteByExample(BsMerLedgerReceiverExample example) { + SQL sql = new SQL(); + sql.DELETE_FROM("bs_mer_ledger_receiver"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String insertSelective(BsMerLedgerReceiver record) { + SQL sql = new SQL(); + sql.INSERT_INTO("bs_mer_ledger_receiver"); + + if (record.getMerId() != null) { + sql.VALUES("mer_id", "#{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.VALUES("mer_ledger_id", "#{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.VALUES("platform_type", "#{platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.VALUES("platform_no", "#{platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.VALUES("cup_no", "#{cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.VALUES("receiver_no", "#{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverName() != null) { + sql.VALUES("receiver_name", "#{receiverName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFileName() != null) { + sql.VALUES("entrust_file_name", "#{entrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFilePath() != null) { + sql.VALUES("entrust_file_path", "#{entrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.VALUES("`status`", "#{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.VALUES("reject_reason", "#{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.VALUES("update_time", "#{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.VALUES("ext_1", "#{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.VALUES("ext_2", "#{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.VALUES("ext_3", "#{ext3,jdbcType=VARCHAR}"); + } + + return sql.toString(); + } + + public String selectByExample(BsMerLedgerReceiverExample example) { + SQL sql = new SQL(); + if (example != null && example.isDistinct()) { + sql.SELECT_DISTINCT("id"); + } else { + sql.SELECT("id"); + } + sql.SELECT("mer_id"); + sql.SELECT("mer_ledger_id"); + sql.SELECT("platform_type"); + sql.SELECT("platform_no"); + sql.SELECT("cup_no"); + sql.SELECT("receiver_no"); + sql.SELECT("receiver_name"); + sql.SELECT("entrust_file_name"); + sql.SELECT("entrust_file_path"); + sql.SELECT("`status`"); + sql.SELECT("reject_reason"); + sql.SELECT("create_time"); + sql.SELECT("update_time"); + sql.SELECT("ext_1"); + sql.SELECT("ext_2"); + sql.SELECT("ext_3"); + sql.FROM("bs_mer_ledger_receiver"); + applyWhere(sql, example, false); + + if (example != null && example.getOrderByClause() != null) { + sql.ORDER_BY(example.getOrderByClause()); + } + + return sql.toString(); + } + + public String updateByExampleSelective(Map parameter) { + BsMerLedgerReceiver record = (BsMerLedgerReceiver) parameter.get("record"); + BsMerLedgerReceiverExample example = (BsMerLedgerReceiverExample) parameter.get("example"); + + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver"); + + if (record.getId() != null) { + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + } + + if (record.getMerId() != null) { + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.SET("platform_type = #{record.platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.SET("platform_no = #{record.platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.SET("cup_no = #{record.cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverName() != null) { + sql.SET("receiver_name = #{record.receiverName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFileName() != null) { + sql.SET("entrust_file_name = #{record.entrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFilePath() != null) { + sql.SET("entrust_file_path = #{record.entrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + } + + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByExample(Map parameter) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver"); + + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + sql.SET("mer_ledger_id = #{record.merLedgerId,jdbcType=BIGINT}"); + sql.SET("platform_type = #{record.platformType,jdbcType=INTEGER}"); + sql.SET("platform_no = #{record.platformNo,jdbcType=VARCHAR}"); + sql.SET("cup_no = #{record.cupNo,jdbcType=VARCHAR}"); + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + sql.SET("receiver_name = #{record.receiverName,jdbcType=VARCHAR}"); + sql.SET("entrust_file_name = #{record.entrustFileName,jdbcType=VARCHAR}"); + sql.SET("entrust_file_path = #{record.entrustFilePath,jdbcType=VARCHAR}"); + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + + BsMerLedgerReceiverExample example = (BsMerLedgerReceiverExample) parameter.get("example"); + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByPrimaryKeySelective(BsMerLedgerReceiver record) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger_receiver"); + + if (record.getMerId() != null) { + sql.SET("mer_id = #{merId,jdbcType=BIGINT}"); + } + + if (record.getMerLedgerId() != null) { + sql.SET("mer_ledger_id = #{merLedgerId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.SET("platform_type = #{platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.SET("platform_no = #{platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.SET("cup_no = #{cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverName() != null) { + sql.SET("receiver_name = #{receiverName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFileName() != null) { + sql.SET("entrust_file_name = #{entrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getEntrustFilePath() != null) { + sql.SET("entrust_file_path = #{entrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{ext3,jdbcType=VARCHAR}"); + } + + sql.WHERE("id = #{id,jdbcType=BIGINT}"); + + return sql.toString(); + } + + protected void applyWhere(SQL sql, BsMerLedgerReceiverExample example, boolean includeExamplePhrase) { + if (example == null) { + return; + } + + String parmPhrase1; + String parmPhrase1_th; + String parmPhrase2; + String parmPhrase2_th; + String parmPhrase3; + String parmPhrase3_th; + if (includeExamplePhrase) { + parmPhrase1 = "%s #{example.oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{example.oredCriteria[%d].allCriteria[%d].value} and #{example.oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{example.oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{example.oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{example.oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } else { + parmPhrase1 = "%s #{oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{oredCriteria[%d].allCriteria[%d].value} and #{oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } + + StringBuilder sb = new StringBuilder(); + List oredCriteria = example.getOredCriteria(); + boolean firstCriteria = true; + for (int i = 0; i < oredCriteria.size(); i++) { + Criteria criteria = oredCriteria.get(i); + if (criteria.isValid()) { + if (firstCriteria) { + firstCriteria = false; + } else { + sb.append(" or "); + } + + sb.append('('); + List criterions = criteria.getAllCriteria(); + boolean firstCriterion = true; + for (int j = 0; j < criterions.size(); j++) { + Criterion criterion = criterions.get(j); + if (firstCriterion) { + firstCriterion = false; + } else { + sb.append(" and "); + } + + if (criterion.isNoValue()) { + sb.append(criterion.getCondition()); + } else if (criterion.isSingleValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase1, criterion.getCondition(), i, j)); + } else { + sb.append(String.format(parmPhrase1_th, criterion.getCondition(), i, j,criterion.getTypeHandler())); + } + } else if (criterion.isBetweenValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase2, criterion.getCondition(), i, j, i, j)); + } else { + sb.append(String.format(parmPhrase2_th, criterion.getCondition(), i, j, criterion.getTypeHandler(), i, j, criterion.getTypeHandler())); + } + } else if (criterion.isListValue()) { + sb.append(criterion.getCondition()); + sb.append(" ("); + List listItems = (List) criterion.getValue(); + boolean comma = false; + for (int k = 0; k < listItems.size(); k++) { + if (comma) { + sb.append(", "); + } else { + comma = true; + } + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase3, i, j, k)); + } else { + sb.append(String.format(parmPhrase3_th, i, j, k, criterion.getTypeHandler())); + } + } + sb.append(')'); + } + } + sb.append(')'); + } + } + + if (sb.length() > 0) { + sql.WHERE(sb.toString()); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsMerLedgerSqlProvider.java b/service/src/main/java/com/hfkj/dao/BsMerLedgerSqlProvider.java new file mode 100644 index 0000000..675b602 --- /dev/null +++ b/service/src/main/java/com/hfkj/dao/BsMerLedgerSqlProvider.java @@ -0,0 +1,388 @@ +package com.hfkj.dao; + +import com.hfkj.entity.BsMerLedger; +import com.hfkj.entity.BsMerLedgerExample.Criteria; +import com.hfkj.entity.BsMerLedgerExample.Criterion; +import com.hfkj.entity.BsMerLedgerExample; +import java.util.List; +import java.util.Map; +import org.apache.ibatis.jdbc.SQL; + +public class BsMerLedgerSqlProvider { + + public String countByExample(BsMerLedgerExample example) { + SQL sql = new SQL(); + sql.SELECT("count(*)").FROM("bs_mer_ledger"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String deleteByExample(BsMerLedgerExample example) { + SQL sql = new SQL(); + sql.DELETE_FROM("bs_mer_ledger"); + applyWhere(sql, example, false); + return sql.toString(); + } + + public String insertSelective(BsMerLedger record) { + SQL sql = new SQL(); + sql.INSERT_INTO("bs_mer_ledger"); + + if (record.getMerId() != null) { + sql.VALUES("mer_id", "#{merId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.VALUES("platform_type", "#{platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.VALUES("platform_no", "#{platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.VALUES("cup_no", "#{cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.VALUES("receiver_no", "#{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getSplitLowestRatio() != null) { + sql.VALUES("split_lowest_ratio", "#{splitLowestRatio,jdbcType=DECIMAL}"); + } + + if (record.getSplitEntrustFileName() != null) { + sql.VALUES("split_entrust_file_name", "#{splitEntrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getSplitEntrustFilePath() != null) { + sql.VALUES("split_entrust_file_path", "#{splitEntrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.VALUES("`status`", "#{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.VALUES("reject_reason", "#{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.VALUES("create_time", "#{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.VALUES("update_time", "#{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.VALUES("ext_1", "#{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.VALUES("ext_2", "#{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.VALUES("ext_3", "#{ext3,jdbcType=VARCHAR}"); + } + + return sql.toString(); + } + + public String selectByExample(BsMerLedgerExample example) { + SQL sql = new SQL(); + if (example != null && example.isDistinct()) { + sql.SELECT_DISTINCT("id"); + } else { + sql.SELECT("id"); + } + sql.SELECT("mer_id"); + sql.SELECT("platform_type"); + sql.SELECT("platform_no"); + sql.SELECT("cup_no"); + sql.SELECT("receiver_no"); + sql.SELECT("split_lowest_ratio"); + sql.SELECT("split_entrust_file_name"); + sql.SELECT("split_entrust_file_path"); + sql.SELECT("`status`"); + sql.SELECT("reject_reason"); + sql.SELECT("create_time"); + sql.SELECT("update_time"); + sql.SELECT("ext_1"); + sql.SELECT("ext_2"); + sql.SELECT("ext_3"); + sql.FROM("bs_mer_ledger"); + applyWhere(sql, example, false); + + if (example != null && example.getOrderByClause() != null) { + sql.ORDER_BY(example.getOrderByClause()); + } + + return sql.toString(); + } + + public String updateByExampleSelective(Map parameter) { + BsMerLedger record = (BsMerLedger) parameter.get("record"); + BsMerLedgerExample example = (BsMerLedgerExample) parameter.get("example"); + + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger"); + + if (record.getId() != null) { + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + } + + if (record.getMerId() != null) { + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.SET("platform_type = #{record.platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.SET("platform_no = #{record.platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.SET("cup_no = #{record.cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getSplitLowestRatio() != null) { + sql.SET("split_lowest_ratio = #{record.splitLowestRatio,jdbcType=DECIMAL}"); + } + + if (record.getSplitEntrustFileName() != null) { + sql.SET("split_entrust_file_name = #{record.splitEntrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getSplitEntrustFilePath() != null) { + sql.SET("split_entrust_file_path = #{record.splitEntrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + } + + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByExample(Map parameter) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger"); + + sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("mer_id = #{record.merId,jdbcType=BIGINT}"); + sql.SET("platform_type = #{record.platformType,jdbcType=INTEGER}"); + sql.SET("platform_no = #{record.platformNo,jdbcType=VARCHAR}"); + sql.SET("cup_no = #{record.cupNo,jdbcType=VARCHAR}"); + sql.SET("receiver_no = #{record.receiverNo,jdbcType=VARCHAR}"); + sql.SET("split_lowest_ratio = #{record.splitLowestRatio,jdbcType=DECIMAL}"); + sql.SET("split_entrust_file_name = #{record.splitEntrustFileName,jdbcType=VARCHAR}"); + sql.SET("split_entrust_file_path = #{record.splitEntrustFilePath,jdbcType=VARCHAR}"); + sql.SET("`status` = #{record.status,jdbcType=INTEGER}"); + sql.SET("reject_reason = #{record.rejectReason,jdbcType=VARCHAR}"); + sql.SET("create_time = #{record.createTime,jdbcType=TIMESTAMP}"); + sql.SET("update_time = #{record.updateTime,jdbcType=TIMESTAMP}"); + sql.SET("ext_1 = #{record.ext1,jdbcType=VARCHAR}"); + sql.SET("ext_2 = #{record.ext2,jdbcType=VARCHAR}"); + sql.SET("ext_3 = #{record.ext3,jdbcType=VARCHAR}"); + + BsMerLedgerExample example = (BsMerLedgerExample) parameter.get("example"); + applyWhere(sql, example, true); + return sql.toString(); + } + + public String updateByPrimaryKeySelective(BsMerLedger record) { + SQL sql = new SQL(); + sql.UPDATE("bs_mer_ledger"); + + if (record.getMerId() != null) { + sql.SET("mer_id = #{merId,jdbcType=BIGINT}"); + } + + if (record.getPlatformType() != null) { + sql.SET("platform_type = #{platformType,jdbcType=INTEGER}"); + } + + if (record.getPlatformNo() != null) { + sql.SET("platform_no = #{platformNo,jdbcType=VARCHAR}"); + } + + if (record.getCupNo() != null) { + sql.SET("cup_no = #{cupNo,jdbcType=VARCHAR}"); + } + + if (record.getReceiverNo() != null) { + sql.SET("receiver_no = #{receiverNo,jdbcType=VARCHAR}"); + } + + if (record.getSplitLowestRatio() != null) { + sql.SET("split_lowest_ratio = #{splitLowestRatio,jdbcType=DECIMAL}"); + } + + if (record.getSplitEntrustFileName() != null) { + sql.SET("split_entrust_file_name = #{splitEntrustFileName,jdbcType=VARCHAR}"); + } + + if (record.getSplitEntrustFilePath() != null) { + sql.SET("split_entrust_file_path = #{splitEntrustFilePath,jdbcType=VARCHAR}"); + } + + if (record.getStatus() != null) { + sql.SET("`status` = #{status,jdbcType=INTEGER}"); + } + + if (record.getRejectReason() != null) { + sql.SET("reject_reason = #{rejectReason,jdbcType=VARCHAR}"); + } + + if (record.getCreateTime() != null) { + sql.SET("create_time = #{createTime,jdbcType=TIMESTAMP}"); + } + + if (record.getUpdateTime() != null) { + sql.SET("update_time = #{updateTime,jdbcType=TIMESTAMP}"); + } + + if (record.getExt1() != null) { + sql.SET("ext_1 = #{ext1,jdbcType=VARCHAR}"); + } + + if (record.getExt2() != null) { + sql.SET("ext_2 = #{ext2,jdbcType=VARCHAR}"); + } + + if (record.getExt3() != null) { + sql.SET("ext_3 = #{ext3,jdbcType=VARCHAR}"); + } + + sql.WHERE("id = #{id,jdbcType=BIGINT}"); + + return sql.toString(); + } + + protected void applyWhere(SQL sql, BsMerLedgerExample example, boolean includeExamplePhrase) { + if (example == null) { + return; + } + + String parmPhrase1; + String parmPhrase1_th; + String parmPhrase2; + String parmPhrase2_th; + String parmPhrase3; + String parmPhrase3_th; + if (includeExamplePhrase) { + parmPhrase1 = "%s #{example.oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{example.oredCriteria[%d].allCriteria[%d].value} and #{example.oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{example.oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{example.oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{example.oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{example.oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } else { + parmPhrase1 = "%s #{oredCriteria[%d].allCriteria[%d].value}"; + parmPhrase1_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s}"; + parmPhrase2 = "%s #{oredCriteria[%d].allCriteria[%d].value} and #{oredCriteria[%d].criteria[%d].secondValue}"; + parmPhrase2_th = "%s #{oredCriteria[%d].allCriteria[%d].value,typeHandler=%s} and #{oredCriteria[%d].criteria[%d].secondValue,typeHandler=%s}"; + parmPhrase3 = "#{oredCriteria[%d].allCriteria[%d].value[%d]}"; + parmPhrase3_th = "#{oredCriteria[%d].allCriteria[%d].value[%d],typeHandler=%s}"; + } + + StringBuilder sb = new StringBuilder(); + List oredCriteria = example.getOredCriteria(); + boolean firstCriteria = true; + for (int i = 0; i < oredCriteria.size(); i++) { + Criteria criteria = oredCriteria.get(i); + if (criteria.isValid()) { + if (firstCriteria) { + firstCriteria = false; + } else { + sb.append(" or "); + } + + sb.append('('); + List criterions = criteria.getAllCriteria(); + boolean firstCriterion = true; + for (int j = 0; j < criterions.size(); j++) { + Criterion criterion = criterions.get(j); + if (firstCriterion) { + firstCriterion = false; + } else { + sb.append(" and "); + } + + if (criterion.isNoValue()) { + sb.append(criterion.getCondition()); + } else if (criterion.isSingleValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase1, criterion.getCondition(), i, j)); + } else { + sb.append(String.format(parmPhrase1_th, criterion.getCondition(), i, j,criterion.getTypeHandler())); + } + } else if (criterion.isBetweenValue()) { + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase2, criterion.getCondition(), i, j, i, j)); + } else { + sb.append(String.format(parmPhrase2_th, criterion.getCondition(), i, j, criterion.getTypeHandler(), i, j, criterion.getTypeHandler())); + } + } else if (criterion.isListValue()) { + sb.append(criterion.getCondition()); + sb.append(" ("); + List listItems = (List) criterion.getValue(); + boolean comma = false; + for (int k = 0; k < listItems.size(); k++) { + if (comma) { + sb.append(", "); + } else { + comma = true; + } + if (criterion.getTypeHandler() == null) { + sb.append(String.format(parmPhrase3, i, j, k)); + } else { + sb.append(String.format(parmPhrase3_th, i, j, k, criterion.getTypeHandler())); + } + } + sb.append(')'); + } + } + sb.append(')'); + } + } + + if (sb.length() > 0) { + sql.WHERE(sb.toString()); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingMapper.java b/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingMapper.java index a5157cf..0e695de 100644 --- a/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingMapper.java +++ b/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingMapper.java @@ -39,7 +39,8 @@ public interface BsTradeOrderProfitSharingMapper extends BsTradeOrderProfitShari int deleteByPrimaryKey(Long id); @Insert({ - "insert into bs_trade_order_profit_sharing (trade_order_id, trade_order_no, ", + "insert into bs_trade_order_profit_sharing (cmd_type, trade_order_id, ", + "trade_order_no, origin_profit_sharing_order_no, ", "profit_sharing_order_no, platform_type, ", "platform_profit_sharing_order_no, platform_mer_no, ", "platform_trade_no, platform_appid, ", @@ -47,7 +48,8 @@ public interface BsTradeOrderProfitSharingMapper extends BsTradeOrderProfitShari "`status`, create_time, ", "profit_sharing_time, finish_time, ", "ext_1, ext_2, ext_3)", - "values (#{tradeOrderId,jdbcType=BIGINT}, #{tradeOrderNo,jdbcType=VARCHAR}, ", + "values (#{cmdType,jdbcType=INTEGER}, #{tradeOrderId,jdbcType=BIGINT}, ", + "#{tradeOrderNo,jdbcType=VARCHAR}, #{originProfitSharingOrderNo,jdbcType=VARCHAR}, ", "#{profitSharingOrderNo,jdbcType=VARCHAR}, #{platformType,jdbcType=INTEGER}, ", "#{platformProfitSharingOrderNo,jdbcType=VARCHAR}, #{platformMerNo,jdbcType=VARCHAR}, ", "#{platformTradeNo,jdbcType=VARCHAR}, #{platformAppid,jdbcType=VARCHAR}, ", @@ -66,8 +68,10 @@ public interface BsTradeOrderProfitSharingMapper extends BsTradeOrderProfitShari @SelectProvider(type=BsTradeOrderProfitSharingSqlProvider.class, method="selectByExample") @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="cmd_type", property="cmdType", jdbcType=JdbcType.INTEGER), @Result(column="trade_order_id", property="tradeOrderId", jdbcType=JdbcType.BIGINT), @Result(column="trade_order_no", property="tradeOrderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="origin_profit_sharing_order_no", property="originProfitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @Result(column="profit_sharing_order_no", property="profitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), @Result(column="platform_profit_sharing_order_no", property="platformProfitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @@ -88,17 +92,19 @@ public interface BsTradeOrderProfitSharingMapper extends BsTradeOrderProfitShari @Select({ "select", - "id, trade_order_id, trade_order_no, profit_sharing_order_no, platform_type, ", - "platform_profit_sharing_order_no, platform_mer_no, platform_trade_no, platform_appid, ", - "ratio, profit_sharing_amoun, `status`, create_time, profit_sharing_time, finish_time, ", - "ext_1, ext_2, ext_3", + "id, cmd_type, trade_order_id, trade_order_no, origin_profit_sharing_order_no, ", + "profit_sharing_order_no, platform_type, platform_profit_sharing_order_no, platform_mer_no, ", + "platform_trade_no, platform_appid, ratio, profit_sharing_amoun, `status`, create_time, ", + "profit_sharing_time, finish_time, ext_1, ext_2, ext_3", "from bs_trade_order_profit_sharing", "where id = #{id,jdbcType=BIGINT}" }) @Results({ @Result(column="id", property="id", jdbcType=JdbcType.BIGINT, id=true), + @Result(column="cmd_type", property="cmdType", jdbcType=JdbcType.INTEGER), @Result(column="trade_order_id", property="tradeOrderId", jdbcType=JdbcType.BIGINT), @Result(column="trade_order_no", property="tradeOrderNo", jdbcType=JdbcType.VARCHAR), + @Result(column="origin_profit_sharing_order_no", property="originProfitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @Result(column="profit_sharing_order_no", property="profitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @Result(column="platform_type", property="platformType", jdbcType=JdbcType.INTEGER), @Result(column="platform_profit_sharing_order_no", property="platformProfitSharingOrderNo", jdbcType=JdbcType.VARCHAR), @@ -128,8 +134,10 @@ public interface BsTradeOrderProfitSharingMapper extends BsTradeOrderProfitShari @Update({ "update bs_trade_order_profit_sharing", - "set trade_order_id = #{tradeOrderId,jdbcType=BIGINT},", + "set cmd_type = #{cmdType,jdbcType=INTEGER},", + "trade_order_id = #{tradeOrderId,jdbcType=BIGINT},", "trade_order_no = #{tradeOrderNo,jdbcType=VARCHAR},", + "origin_profit_sharing_order_no = #{originProfitSharingOrderNo,jdbcType=VARCHAR},", "profit_sharing_order_no = #{profitSharingOrderNo,jdbcType=VARCHAR},", "platform_type = #{platformType,jdbcType=INTEGER},", "platform_profit_sharing_order_no = #{platformProfitSharingOrderNo,jdbcType=VARCHAR},", diff --git a/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingSqlProvider.java b/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingSqlProvider.java index 3ee5d5e..f9a40ba 100644 --- a/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingSqlProvider.java +++ b/service/src/main/java/com/hfkj/dao/BsTradeOrderProfitSharingSqlProvider.java @@ -28,6 +28,10 @@ public class BsTradeOrderProfitSharingSqlProvider { SQL sql = new SQL(); sql.INSERT_INTO("bs_trade_order_profit_sharing"); + if (record.getCmdType() != null) { + sql.VALUES("cmd_type", "#{cmdType,jdbcType=INTEGER}"); + } + if (record.getTradeOrderId() != null) { sql.VALUES("trade_order_id", "#{tradeOrderId,jdbcType=BIGINT}"); } @@ -36,6 +40,10 @@ public class BsTradeOrderProfitSharingSqlProvider { sql.VALUES("trade_order_no", "#{tradeOrderNo,jdbcType=VARCHAR}"); } + if (record.getOriginProfitSharingOrderNo() != null) { + sql.VALUES("origin_profit_sharing_order_no", "#{originProfitSharingOrderNo,jdbcType=VARCHAR}"); + } + if (record.getProfitSharingOrderNo() != null) { sql.VALUES("profit_sharing_order_no", "#{profitSharingOrderNo,jdbcType=VARCHAR}"); } @@ -106,8 +114,10 @@ public class BsTradeOrderProfitSharingSqlProvider { } else { sql.SELECT("id"); } + sql.SELECT("cmd_type"); sql.SELECT("trade_order_id"); sql.SELECT("trade_order_no"); + sql.SELECT("origin_profit_sharing_order_no"); sql.SELECT("profit_sharing_order_no"); sql.SELECT("platform_type"); sql.SELECT("platform_profit_sharing_order_no"); @@ -144,6 +154,10 @@ public class BsTradeOrderProfitSharingSqlProvider { sql.SET("id = #{record.id,jdbcType=BIGINT}"); } + if (record.getCmdType() != null) { + sql.SET("cmd_type = #{record.cmdType,jdbcType=INTEGER}"); + } + if (record.getTradeOrderId() != null) { sql.SET("trade_order_id = #{record.tradeOrderId,jdbcType=BIGINT}"); } @@ -152,6 +166,10 @@ public class BsTradeOrderProfitSharingSqlProvider { sql.SET("trade_order_no = #{record.tradeOrderNo,jdbcType=VARCHAR}"); } + if (record.getOriginProfitSharingOrderNo() != null) { + sql.SET("origin_profit_sharing_order_no = #{record.originProfitSharingOrderNo,jdbcType=VARCHAR}"); + } + if (record.getProfitSharingOrderNo() != null) { sql.SET("profit_sharing_order_no = #{record.profitSharingOrderNo,jdbcType=VARCHAR}"); } @@ -221,8 +239,10 @@ public class BsTradeOrderProfitSharingSqlProvider { sql.UPDATE("bs_trade_order_profit_sharing"); sql.SET("id = #{record.id,jdbcType=BIGINT}"); + sql.SET("cmd_type = #{record.cmdType,jdbcType=INTEGER}"); sql.SET("trade_order_id = #{record.tradeOrderId,jdbcType=BIGINT}"); sql.SET("trade_order_no = #{record.tradeOrderNo,jdbcType=VARCHAR}"); + sql.SET("origin_profit_sharing_order_no = #{record.originProfitSharingOrderNo,jdbcType=VARCHAR}"); sql.SET("profit_sharing_order_no = #{record.profitSharingOrderNo,jdbcType=VARCHAR}"); sql.SET("platform_type = #{record.platformType,jdbcType=INTEGER}"); sql.SET("platform_profit_sharing_order_no = #{record.platformProfitSharingOrderNo,jdbcType=VARCHAR}"); @@ -248,6 +268,10 @@ public class BsTradeOrderProfitSharingSqlProvider { SQL sql = new SQL(); sql.UPDATE("bs_trade_order_profit_sharing"); + if (record.getCmdType() != null) { + sql.SET("cmd_type = #{cmdType,jdbcType=INTEGER}"); + } + if (record.getTradeOrderId() != null) { sql.SET("trade_order_id = #{tradeOrderId,jdbcType=BIGINT}"); } @@ -256,6 +280,10 @@ public class BsTradeOrderProfitSharingSqlProvider { sql.SET("trade_order_no = #{tradeOrderNo,jdbcType=VARCHAR}"); } + if (record.getOriginProfitSharingOrderNo() != null) { + sql.SET("origin_profit_sharing_order_no = #{originProfitSharingOrderNo,jdbcType=VARCHAR}"); + } + if (record.getProfitSharingOrderNo() != null) { sql.SET("profit_sharing_order_no = #{profitSharingOrderNo,jdbcType=VARCHAR}"); } diff --git a/service/src/main/java/com/hfkj/dao/SecMenuMapperExt.java b/service/src/main/java/com/hfkj/dao/SecMenuMapperExt.java index 64d04c2..b7057d3 100644 --- a/service/src/main/java/com/hfkj/dao/SecMenuMapperExt.java +++ b/service/src/main/java/com/hfkj/dao/SecMenuMapperExt.java @@ -4,4 +4,7 @@ package com.hfkj.dao; * mapper扩展类 */ public interface SecMenuMapperExt { + + + } diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedger.java b/service/src/main/java/com/hfkj/entity/BsMerLedger.java new file mode 100644 index 0000000..7408870 --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedger.java @@ -0,0 +1,297 @@ +package com.hfkj.entity; + +import java.io.Serializable; +import java.math.BigDecimal; +import java.util.Date; + +/** + * bs_mer_ledger + * @author + */ +/** + * + * 代码由工具生成 + * + **/ +public class BsMerLedger implements Serializable { + /** + * 主键 + */ + private Long id; + + /** + * 商户id + */ + private Long merId; + + /** + * 平台 + */ + private Integer platformType; + + /** + * 平台商户号 + */ + private String platformNo; + + /** + * 银联商户号 + */ + private String cupNo; + + /** + * 接收编号 + */ + private String receiverNo; + + /** + * 最低分账比例 + */ + private BigDecimal splitLowestRatio; + + /** + * 分账结算委托书文件名称 + */ + private String splitEntrustFileName; + + /** + * 分账结算委托书文件路径 + */ + private String splitEntrustFilePath; + + /** + * 状态 0:不可用 1:可用 2:审核中 3:审核驳回 + */ + private Integer status; + + /** + * 驳回原因 + */ + private String rejectReason; + + /** + * 创建时间 + */ + private Date createTime; + + /** + * 更新时间 + */ + private Date updateTime; + + private String ext1; + + private String ext2; + + private String ext3; + + private static final long serialVersionUID = 1L; + + public Long getId() { + return id; + } + + public void setId(Long id) { + this.id = id; + } + + public Long getMerId() { + return merId; + } + + public void setMerId(Long merId) { + this.merId = merId; + } + + public Integer getPlatformType() { + return platformType; + } + + public void setPlatformType(Integer platformType) { + this.platformType = platformType; + } + + public String getPlatformNo() { + return platformNo; + } + + public void setPlatformNo(String platformNo) { + this.platformNo = platformNo; + } + + public String getCupNo() { + return cupNo; + } + + public void setCupNo(String cupNo) { + this.cupNo = cupNo; + } + + public String getReceiverNo() { + return receiverNo; + } + + public void setReceiverNo(String receiverNo) { + this.receiverNo = receiverNo; + } + + public BigDecimal getSplitLowestRatio() { + return splitLowestRatio; + } + + public void setSplitLowestRatio(BigDecimal splitLowestRatio) { + this.splitLowestRatio = splitLowestRatio; + } + + public String getSplitEntrustFileName() { + return splitEntrustFileName; + } + + public void setSplitEntrustFileName(String splitEntrustFileName) { + this.splitEntrustFileName = splitEntrustFileName; + } + + public String getSplitEntrustFilePath() { + return splitEntrustFilePath; + } + + public void setSplitEntrustFilePath(String splitEntrustFilePath) { + this.splitEntrustFilePath = splitEntrustFilePath; + } + + public Integer getStatus() { + return status; + } + + public void setStatus(Integer status) { + this.status = status; + } + + public String getRejectReason() { + return rejectReason; + } + + public void setRejectReason(String rejectReason) { + this.rejectReason = rejectReason; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getExt1() { + return ext1; + } + + public void setExt1(String ext1) { + this.ext1 = ext1; + } + + public String getExt2() { + return ext2; + } + + public void setExt2(String ext2) { + this.ext2 = ext2; + } + + public String getExt3() { + return ext3; + } + + public void setExt3(String ext3) { + this.ext3 = ext3; + } + + @Override + public boolean equals(Object that) { + if (this == that) { + return true; + } + if (that == null) { + return false; + } + if (getClass() != that.getClass()) { + return false; + } + BsMerLedger other = (BsMerLedger) that; + return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getMerId() == null ? other.getMerId() == null : this.getMerId().equals(other.getMerId())) + && (this.getPlatformType() == null ? other.getPlatformType() == null : this.getPlatformType().equals(other.getPlatformType())) + && (this.getPlatformNo() == null ? other.getPlatformNo() == null : this.getPlatformNo().equals(other.getPlatformNo())) + && (this.getCupNo() == null ? other.getCupNo() == null : this.getCupNo().equals(other.getCupNo())) + && (this.getReceiverNo() == null ? other.getReceiverNo() == null : this.getReceiverNo().equals(other.getReceiverNo())) + && (this.getSplitLowestRatio() == null ? other.getSplitLowestRatio() == null : this.getSplitLowestRatio().equals(other.getSplitLowestRatio())) + && (this.getSplitEntrustFileName() == null ? other.getSplitEntrustFileName() == null : this.getSplitEntrustFileName().equals(other.getSplitEntrustFileName())) + && (this.getSplitEntrustFilePath() == null ? other.getSplitEntrustFilePath() == null : this.getSplitEntrustFilePath().equals(other.getSplitEntrustFilePath())) + && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus())) + && (this.getRejectReason() == null ? other.getRejectReason() == null : this.getRejectReason().equals(other.getRejectReason())) + && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime())) + && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime())) + && (this.getExt1() == null ? other.getExt1() == null : this.getExt1().equals(other.getExt1())) + && (this.getExt2() == null ? other.getExt2() == null : this.getExt2().equals(other.getExt2())) + && (this.getExt3() == null ? other.getExt3() == null : this.getExt3().equals(other.getExt3())); + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getMerId() == null) ? 0 : getMerId().hashCode()); + result = prime * result + ((getPlatformType() == null) ? 0 : getPlatformType().hashCode()); + result = prime * result + ((getPlatformNo() == null) ? 0 : getPlatformNo().hashCode()); + result = prime * result + ((getCupNo() == null) ? 0 : getCupNo().hashCode()); + result = prime * result + ((getReceiverNo() == null) ? 0 : getReceiverNo().hashCode()); + result = prime * result + ((getSplitLowestRatio() == null) ? 0 : getSplitLowestRatio().hashCode()); + result = prime * result + ((getSplitEntrustFileName() == null) ? 0 : getSplitEntrustFileName().hashCode()); + result = prime * result + ((getSplitEntrustFilePath() == null) ? 0 : getSplitEntrustFilePath().hashCode()); + result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode()); + result = prime * result + ((getRejectReason() == null) ? 0 : getRejectReason().hashCode()); + result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode()); + result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode()); + result = prime * result + ((getExt1() == null) ? 0 : getExt1().hashCode()); + result = prime * result + ((getExt2() == null) ? 0 : getExt2().hashCode()); + result = prime * result + ((getExt3() == null) ? 0 : getExt3().hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append(getClass().getSimpleName()); + sb.append(" ["); + sb.append("Hash = ").append(hashCode()); + sb.append(", id=").append(id); + sb.append(", merId=").append(merId); + sb.append(", platformType=").append(platformType); + sb.append(", platformNo=").append(platformNo); + sb.append(", cupNo=").append(cupNo); + sb.append(", receiverNo=").append(receiverNo); + sb.append(", splitLowestRatio=").append(splitLowestRatio); + sb.append(", splitEntrustFileName=").append(splitEntrustFileName); + sb.append(", splitEntrustFilePath=").append(splitEntrustFilePath); + sb.append(", status=").append(status); + sb.append(", rejectReason=").append(rejectReason); + sb.append(", createTime=").append(createTime); + sb.append(", updateTime=").append(updateTime); + sb.append(", ext1=").append(ext1); + sb.append(", ext2=").append(ext2); + sb.append(", ext3=").append(ext3); + sb.append(", serialVersionUID=").append(serialVersionUID); + sb.append("]"); + return sb.toString(); + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerApply.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerApply.java new file mode 100644 index 0000000..2dc4a7b --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerApply.java @@ -0,0 +1,264 @@ +package com.hfkj.entity; + +import java.io.Serializable; +import java.util.Date; + +/** + * bs_mer_ledger_apply + * @author + */ +/** + * + * 代码由工具生成 + * + **/ +public class BsMerLedgerApply implements Serializable { + /** + * 主键 + */ + private Long id; + + /** + * 商户id + */ + private Long merId; + + /** + * 商户分账id + */ + private Long merLedgerId; + + /** + * 订单编号 + */ + private String orderNo; + + /** + * 受理编号 + */ + private String applyId; + + /** + * 请求报文 + */ + private String requestBody; + + /** + * 响应报文 + */ + private String responseBody; + + /** + * 异步通知报文 + */ + private String notifyBody; + + /** + * 状态 0:删除 1:正常 + */ + private Integer status; + + /** + * 创建时间 + */ + private Date createTime; + + /** + * 修改时间 + */ + private Date updateTime; + + private String ext1; + + private String ext2; + + private String ext3; + + private static final long serialVersionUID = 1L; + + public Long getId() { + return id; + } + + public void setId(Long id) { + this.id = id; + } + + public Long getMerId() { + return merId; + } + + public void setMerId(Long merId) { + this.merId = merId; + } + + public Long getMerLedgerId() { + return merLedgerId; + } + + public void setMerLedgerId(Long merLedgerId) { + this.merLedgerId = merLedgerId; + } + + public String getOrderNo() { + return orderNo; + } + + public void setOrderNo(String orderNo) { + this.orderNo = orderNo; + } + + public String getApplyId() { + return applyId; + } + + public void setApplyId(String applyId) { + this.applyId = applyId; + } + + public String getRequestBody() { + return requestBody; + } + + public void setRequestBody(String requestBody) { + this.requestBody = requestBody; + } + + public String getResponseBody() { + return responseBody; + } + + public void setResponseBody(String responseBody) { + this.responseBody = responseBody; + } + + public String getNotifyBody() { + return notifyBody; + } + + public void setNotifyBody(String notifyBody) { + this.notifyBody = notifyBody; + } + + public Integer getStatus() { + return status; + } + + public void setStatus(Integer status) { + this.status = status; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getExt1() { + return ext1; + } + + public void setExt1(String ext1) { + this.ext1 = ext1; + } + + public String getExt2() { + return ext2; + } + + public void setExt2(String ext2) { + this.ext2 = ext2; + } + + public String getExt3() { + return ext3; + } + + public void setExt3(String ext3) { + this.ext3 = ext3; + } + + @Override + public boolean equals(Object that) { + if (this == that) { + return true; + } + if (that == null) { + return false; + } + if (getClass() != that.getClass()) { + return false; + } + BsMerLedgerApply other = (BsMerLedgerApply) that; + return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getMerId() == null ? other.getMerId() == null : this.getMerId().equals(other.getMerId())) + && (this.getMerLedgerId() == null ? other.getMerLedgerId() == null : this.getMerLedgerId().equals(other.getMerLedgerId())) + && (this.getOrderNo() == null ? other.getOrderNo() == null : this.getOrderNo().equals(other.getOrderNo())) + && (this.getApplyId() == null ? other.getApplyId() == null : this.getApplyId().equals(other.getApplyId())) + && (this.getRequestBody() == null ? other.getRequestBody() == null : this.getRequestBody().equals(other.getRequestBody())) + && (this.getResponseBody() == null ? other.getResponseBody() == null : this.getResponseBody().equals(other.getResponseBody())) + && (this.getNotifyBody() == null ? other.getNotifyBody() == null : this.getNotifyBody().equals(other.getNotifyBody())) + && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus())) + && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime())) + && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime())) + && (this.getExt1() == null ? other.getExt1() == null : this.getExt1().equals(other.getExt1())) + && (this.getExt2() == null ? other.getExt2() == null : this.getExt2().equals(other.getExt2())) + && (this.getExt3() == null ? other.getExt3() == null : this.getExt3().equals(other.getExt3())); + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getMerId() == null) ? 0 : getMerId().hashCode()); + result = prime * result + ((getMerLedgerId() == null) ? 0 : getMerLedgerId().hashCode()); + result = prime * result + ((getOrderNo() == null) ? 0 : getOrderNo().hashCode()); + result = prime * result + ((getApplyId() == null) ? 0 : getApplyId().hashCode()); + result = prime * result + ((getRequestBody() == null) ? 0 : getRequestBody().hashCode()); + result = prime * result + ((getResponseBody() == null) ? 0 : getResponseBody().hashCode()); + result = prime * result + ((getNotifyBody() == null) ? 0 : getNotifyBody().hashCode()); + result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode()); + result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode()); + result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode()); + result = prime * result + ((getExt1() == null) ? 0 : getExt1().hashCode()); + result = prime * result + ((getExt2() == null) ? 0 : getExt2().hashCode()); + result = prime * result + ((getExt3() == null) ? 0 : getExt3().hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append(getClass().getSimpleName()); + sb.append(" ["); + sb.append("Hash = ").append(hashCode()); + sb.append(", id=").append(id); + sb.append(", merId=").append(merId); + sb.append(", merLedgerId=").append(merLedgerId); + sb.append(", orderNo=").append(orderNo); + sb.append(", applyId=").append(applyId); + sb.append(", requestBody=").append(requestBody); + sb.append(", responseBody=").append(responseBody); + sb.append(", notifyBody=").append(notifyBody); + sb.append(", status=").append(status); + sb.append(", createTime=").append(createTime); + sb.append(", updateTime=").append(updateTime); + sb.append(", ext1=").append(ext1); + sb.append(", ext2=").append(ext2); + sb.append(", ext3=").append(ext3); + sb.append(", serialVersionUID=").append(serialVersionUID); + sb.append("]"); + return sb.toString(); + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerApplyExample.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerApplyExample.java new file mode 100644 index 0000000..6a38313 --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerApplyExample.java @@ -0,0 +1,1143 @@ +package com.hfkj.entity; + +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +public class BsMerLedgerApplyExample { + protected String orderByClause; + + protected boolean distinct; + + protected List oredCriteria; + + private Integer limit; + + private Long offset; + + public BsMerLedgerApplyExample() { + oredCriteria = new ArrayList(); + } + + public void setOrderByClause(String orderByClause) { + this.orderByClause = orderByClause; + } + + public String getOrderByClause() { + return orderByClause; + } + + public void setDistinct(boolean distinct) { + this.distinct = distinct; + } + + public boolean isDistinct() { + return distinct; + } + + public List getOredCriteria() { + return oredCriteria; + } + + public void or(Criteria criteria) { + oredCriteria.add(criteria); + } + + public Criteria or() { + Criteria criteria = createCriteriaInternal(); + oredCriteria.add(criteria); + return criteria; + } + + public Criteria createCriteria() { + Criteria criteria = createCriteriaInternal(); + if (oredCriteria.size() == 0) { + oredCriteria.add(criteria); + } + return criteria; + } + + protected Criteria createCriteriaInternal() { + Criteria criteria = new Criteria(); + return criteria; + } + + public void clear() { + oredCriteria.clear(); + orderByClause = null; + distinct = false; + } + + public void setLimit(Integer limit) { + this.limit = limit; + } + + public Integer getLimit() { + return limit; + } + + public void setOffset(Long offset) { + this.offset = offset; + } + + public Long getOffset() { + return offset; + } + + protected abstract static class GeneratedCriteria { + protected List criteria; + + protected GeneratedCriteria() { + super(); + criteria = new ArrayList(); + } + + public boolean isValid() { + return criteria.size() > 0; + } + + public List getAllCriteria() { + return criteria; + } + + public List getCriteria() { + return criteria; + } + + protected void addCriterion(String condition) { + if (condition == null) { + throw new RuntimeException("Value for condition cannot be null"); + } + criteria.add(new Criterion(condition)); + } + + protected void addCriterion(String condition, Object value, String property) { + if (value == null) { + throw new RuntimeException("Value for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value)); + } + + protected void addCriterion(String condition, Object value1, Object value2, String property) { + if (value1 == null || value2 == null) { + throw new RuntimeException("Between values for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value1, value2)); + } + + public Criteria andIdIsNull() { + addCriterion("id is null"); + return (Criteria) this; + } + + public Criteria andIdIsNotNull() { + addCriterion("id is not null"); + return (Criteria) this; + } + + public Criteria andIdEqualTo(Long value) { + addCriterion("id =", value, "id"); + return (Criteria) this; + } + + public Criteria andIdNotEqualTo(Long value) { + addCriterion("id <>", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThan(Long value) { + addCriterion("id >", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThanOrEqualTo(Long value) { + addCriterion("id >=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThan(Long value) { + addCriterion("id <", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThanOrEqualTo(Long value) { + addCriterion("id <=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdIn(List values) { + addCriterion("id in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdNotIn(List values) { + addCriterion("id not in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdBetween(Long value1, Long value2) { + addCriterion("id between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andIdNotBetween(Long value1, Long value2) { + addCriterion("id not between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andMerIdIsNull() { + addCriterion("mer_id is null"); + return (Criteria) this; + } + + public Criteria andMerIdIsNotNull() { + addCriterion("mer_id is not null"); + return (Criteria) this; + } + + public Criteria andMerIdEqualTo(Long value) { + addCriterion("mer_id =", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotEqualTo(Long value) { + addCriterion("mer_id <>", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThan(Long value) { + addCriterion("mer_id >", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_id >=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThan(Long value) { + addCriterion("mer_id <", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_id <=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdIn(List values) { + addCriterion("mer_id in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotIn(List values) { + addCriterion("mer_id not in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdBetween(Long value1, Long value2) { + addCriterion("mer_id between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_id not between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNull() { + addCriterion("mer_ledger_id is null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNotNull() { + addCriterion("mer_ledger_id is not null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdEqualTo(Long value) { + addCriterion("mer_ledger_id =", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotEqualTo(Long value) { + addCriterion("mer_ledger_id <>", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThan(Long value) { + addCriterion("mer_ledger_id >", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id >=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThan(Long value) { + addCriterion("mer_ledger_id <", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id <=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIn(List values) { + addCriterion("mer_ledger_id in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotIn(List values) { + addCriterion("mer_ledger_id not in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id not between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andOrderNoIsNull() { + addCriterion("order_no is null"); + return (Criteria) this; + } + + public Criteria andOrderNoIsNotNull() { + addCriterion("order_no is not null"); + return (Criteria) this; + } + + public Criteria andOrderNoEqualTo(String value) { + addCriterion("order_no =", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotEqualTo(String value) { + addCriterion("order_no <>", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoGreaterThan(String value) { + addCriterion("order_no >", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoGreaterThanOrEqualTo(String value) { + addCriterion("order_no >=", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLessThan(String value) { + addCriterion("order_no <", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLessThanOrEqualTo(String value) { + addCriterion("order_no <=", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLike(String value) { + addCriterion("order_no like", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotLike(String value) { + addCriterion("order_no not like", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoIn(List values) { + addCriterion("order_no in", values, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotIn(List values) { + addCriterion("order_no not in", values, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoBetween(String value1, String value2) { + addCriterion("order_no between", value1, value2, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotBetween(String value1, String value2) { + addCriterion("order_no not between", value1, value2, "orderNo"); + return (Criteria) this; + } + + public Criteria andApplyIdIsNull() { + addCriterion("apply_id is null"); + return (Criteria) this; + } + + public Criteria andApplyIdIsNotNull() { + addCriterion("apply_id is not null"); + return (Criteria) this; + } + + public Criteria andApplyIdEqualTo(String value) { + addCriterion("apply_id =", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotEqualTo(String value) { + addCriterion("apply_id <>", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdGreaterThan(String value) { + addCriterion("apply_id >", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdGreaterThanOrEqualTo(String value) { + addCriterion("apply_id >=", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLessThan(String value) { + addCriterion("apply_id <", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLessThanOrEqualTo(String value) { + addCriterion("apply_id <=", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLike(String value) { + addCriterion("apply_id like", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotLike(String value) { + addCriterion("apply_id not like", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdIn(List values) { + addCriterion("apply_id in", values, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotIn(List values) { + addCriterion("apply_id not in", values, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdBetween(String value1, String value2) { + addCriterion("apply_id between", value1, value2, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotBetween(String value1, String value2) { + addCriterion("apply_id not between", value1, value2, "applyId"); + return (Criteria) this; + } + + public Criteria andRequestBodyIsNull() { + addCriterion("request_body is null"); + return (Criteria) this; + } + + public Criteria andRequestBodyIsNotNull() { + addCriterion("request_body is not null"); + return (Criteria) this; + } + + public Criteria andRequestBodyEqualTo(String value) { + addCriterion("request_body =", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotEqualTo(String value) { + addCriterion("request_body <>", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyGreaterThan(String value) { + addCriterion("request_body >", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyGreaterThanOrEqualTo(String value) { + addCriterion("request_body >=", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLessThan(String value) { + addCriterion("request_body <", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLessThanOrEqualTo(String value) { + addCriterion("request_body <=", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLike(String value) { + addCriterion("request_body like", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotLike(String value) { + addCriterion("request_body not like", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyIn(List values) { + addCriterion("request_body in", values, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotIn(List values) { + addCriterion("request_body not in", values, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyBetween(String value1, String value2) { + addCriterion("request_body between", value1, value2, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotBetween(String value1, String value2) { + addCriterion("request_body not between", value1, value2, "requestBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyIsNull() { + addCriterion("response_body is null"); + return (Criteria) this; + } + + public Criteria andResponseBodyIsNotNull() { + addCriterion("response_body is not null"); + return (Criteria) this; + } + + public Criteria andResponseBodyEqualTo(String value) { + addCriterion("response_body =", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotEqualTo(String value) { + addCriterion("response_body <>", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyGreaterThan(String value) { + addCriterion("response_body >", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyGreaterThanOrEqualTo(String value) { + addCriterion("response_body >=", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLessThan(String value) { + addCriterion("response_body <", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLessThanOrEqualTo(String value) { + addCriterion("response_body <=", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLike(String value) { + addCriterion("response_body like", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotLike(String value) { + addCriterion("response_body not like", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyIn(List values) { + addCriterion("response_body in", values, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotIn(List values) { + addCriterion("response_body not in", values, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyBetween(String value1, String value2) { + addCriterion("response_body between", value1, value2, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotBetween(String value1, String value2) { + addCriterion("response_body not between", value1, value2, "responseBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIsNull() { + addCriterion("notify_body is null"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIsNotNull() { + addCriterion("notify_body is not null"); + return (Criteria) this; + } + + public Criteria andNotifyBodyEqualTo(String value) { + addCriterion("notify_body =", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotEqualTo(String value) { + addCriterion("notify_body <>", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyGreaterThan(String value) { + addCriterion("notify_body >", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyGreaterThanOrEqualTo(String value) { + addCriterion("notify_body >=", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLessThan(String value) { + addCriterion("notify_body <", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLessThanOrEqualTo(String value) { + addCriterion("notify_body <=", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLike(String value) { + addCriterion("notify_body like", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotLike(String value) { + addCriterion("notify_body not like", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIn(List values) { + addCriterion("notify_body in", values, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotIn(List values) { + addCriterion("notify_body not in", values, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyBetween(String value1, String value2) { + addCriterion("notify_body between", value1, value2, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotBetween(String value1, String value2) { + addCriterion("notify_body not between", value1, value2, "notifyBody"); + return (Criteria) this; + } + + public Criteria andStatusIsNull() { + addCriterion("`status` is null"); + return (Criteria) this; + } + + public Criteria andStatusIsNotNull() { + addCriterion("`status` is not null"); + return (Criteria) this; + } + + public Criteria andStatusEqualTo(Integer value) { + addCriterion("`status` =", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotEqualTo(Integer value) { + addCriterion("`status` <>", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThan(Integer value) { + addCriterion("`status` >", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThanOrEqualTo(Integer value) { + addCriterion("`status` >=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThan(Integer value) { + addCriterion("`status` <", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThanOrEqualTo(Integer value) { + addCriterion("`status` <=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusIn(List values) { + addCriterion("`status` in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotIn(List values) { + addCriterion("`status` not in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusBetween(Integer value1, Integer value2) { + addCriterion("`status` between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotBetween(Integer value1, Integer value2) { + addCriterion("`status` not between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNull() { + addCriterion("create_time is null"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNotNull() { + addCriterion("create_time is not null"); + return (Criteria) this; + } + + public Criteria andCreateTimeEqualTo(Date value) { + addCriterion("create_time =", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotEqualTo(Date value) { + addCriterion("create_time <>", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThan(Date value) { + addCriterion("create_time >", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("create_time >=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThan(Date value) { + addCriterion("create_time <", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThanOrEqualTo(Date value) { + addCriterion("create_time <=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeIn(List values) { + addCriterion("create_time in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotIn(List values) { + addCriterion("create_time not in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeBetween(Date value1, Date value2) { + addCriterion("create_time between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotBetween(Date value1, Date value2) { + addCriterion("create_time not between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNull() { + addCriterion("update_time is null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNotNull() { + addCriterion("update_time is not null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeEqualTo(Date value) { + addCriterion("update_time =", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotEqualTo(Date value) { + addCriterion("update_time <>", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThan(Date value) { + addCriterion("update_time >", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("update_time >=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThan(Date value) { + addCriterion("update_time <", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { + addCriterion("update_time <=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIn(List values) { + addCriterion("update_time in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotIn(List values) { + addCriterion("update_time not in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeBetween(Date value1, Date value2) { + addCriterion("update_time between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { + addCriterion("update_time not between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andExt1IsNull() { + addCriterion("ext_1 is null"); + return (Criteria) this; + } + + public Criteria andExt1IsNotNull() { + addCriterion("ext_1 is not null"); + return (Criteria) this; + } + + public Criteria andExt1EqualTo(String value) { + addCriterion("ext_1 =", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotEqualTo(String value) { + addCriterion("ext_1 <>", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThan(String value) { + addCriterion("ext_1 >", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThanOrEqualTo(String value) { + addCriterion("ext_1 >=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThan(String value) { + addCriterion("ext_1 <", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThanOrEqualTo(String value) { + addCriterion("ext_1 <=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Like(String value) { + addCriterion("ext_1 like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotLike(String value) { + addCriterion("ext_1 not like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1In(List values) { + addCriterion("ext_1 in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotIn(List values) { + addCriterion("ext_1 not in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Between(String value1, String value2) { + addCriterion("ext_1 between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotBetween(String value1, String value2) { + addCriterion("ext_1 not between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt2IsNull() { + addCriterion("ext_2 is null"); + return (Criteria) this; + } + + public Criteria andExt2IsNotNull() { + addCriterion("ext_2 is not null"); + return (Criteria) this; + } + + public Criteria andExt2EqualTo(String value) { + addCriterion("ext_2 =", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotEqualTo(String value) { + addCriterion("ext_2 <>", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThan(String value) { + addCriterion("ext_2 >", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThanOrEqualTo(String value) { + addCriterion("ext_2 >=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThan(String value) { + addCriterion("ext_2 <", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThanOrEqualTo(String value) { + addCriterion("ext_2 <=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Like(String value) { + addCriterion("ext_2 like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotLike(String value) { + addCriterion("ext_2 not like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2In(List values) { + addCriterion("ext_2 in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotIn(List values) { + addCriterion("ext_2 not in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Between(String value1, String value2) { + addCriterion("ext_2 between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotBetween(String value1, String value2) { + addCriterion("ext_2 not between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt3IsNull() { + addCriterion("ext_3 is null"); + return (Criteria) this; + } + + public Criteria andExt3IsNotNull() { + addCriterion("ext_3 is not null"); + return (Criteria) this; + } + + public Criteria andExt3EqualTo(String value) { + addCriterion("ext_3 =", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotEqualTo(String value) { + addCriterion("ext_3 <>", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThan(String value) { + addCriterion("ext_3 >", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThanOrEqualTo(String value) { + addCriterion("ext_3 >=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThan(String value) { + addCriterion("ext_3 <", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThanOrEqualTo(String value) { + addCriterion("ext_3 <=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Like(String value) { + addCriterion("ext_3 like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotLike(String value) { + addCriterion("ext_3 not like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3In(List values) { + addCriterion("ext_3 in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotIn(List values) { + addCriterion("ext_3 not in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Between(String value1, String value2) { + addCriterion("ext_3 between", value1, value2, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotBetween(String value1, String value2) { + addCriterion("ext_3 not between", value1, value2, "ext3"); + return (Criteria) this; + } + } + + /** + */ + public static class Criteria extends GeneratedCriteria { + + protected Criteria() { + super(); + } + } + + public static class Criterion { + private String condition; + + private Object value; + + private Object secondValue; + + private boolean noValue; + + private boolean singleValue; + + private boolean betweenValue; + + private boolean listValue; + + private String typeHandler; + + public String getCondition() { + return condition; + } + + public Object getValue() { + return value; + } + + public Object getSecondValue() { + return secondValue; + } + + public boolean isNoValue() { + return noValue; + } + + public boolean isSingleValue() { + return singleValue; + } + + public boolean isBetweenValue() { + return betweenValue; + } + + public boolean isListValue() { + return listValue; + } + + public String getTypeHandler() { + return typeHandler; + } + + protected Criterion(String condition) { + super(); + this.condition = condition; + this.typeHandler = null; + this.noValue = true; + } + + protected Criterion(String condition, Object value, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.typeHandler = typeHandler; + if (value instanceof List) { + this.listValue = true; + } else { + this.singleValue = true; + } + } + + protected Criterion(String condition, Object value) { + this(condition, value, null); + } + + protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.secondValue = secondValue; + this.typeHandler = typeHandler; + this.betweenValue = true; + } + + protected Criterion(String condition, Object value, Object secondValue) { + this(condition, value, secondValue, null); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerExample.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerExample.java new file mode 100644 index 0000000..4e81902 --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerExample.java @@ -0,0 +1,1274 @@ +package com.hfkj.entity; + +import java.math.BigDecimal; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +public class BsMerLedgerExample { + protected String orderByClause; + + protected boolean distinct; + + protected List oredCriteria; + + private Integer limit; + + private Long offset; + + public BsMerLedgerExample() { + oredCriteria = new ArrayList(); + } + + public void setOrderByClause(String orderByClause) { + this.orderByClause = orderByClause; + } + + public String getOrderByClause() { + return orderByClause; + } + + public void setDistinct(boolean distinct) { + this.distinct = distinct; + } + + public boolean isDistinct() { + return distinct; + } + + public List getOredCriteria() { + return oredCriteria; + } + + public void or(Criteria criteria) { + oredCriteria.add(criteria); + } + + public Criteria or() { + Criteria criteria = createCriteriaInternal(); + oredCriteria.add(criteria); + return criteria; + } + + public Criteria createCriteria() { + Criteria criteria = createCriteriaInternal(); + if (oredCriteria.size() == 0) { + oredCriteria.add(criteria); + } + return criteria; + } + + protected Criteria createCriteriaInternal() { + Criteria criteria = new Criteria(); + return criteria; + } + + public void clear() { + oredCriteria.clear(); + orderByClause = null; + distinct = false; + } + + public void setLimit(Integer limit) { + this.limit = limit; + } + + public Integer getLimit() { + return limit; + } + + public void setOffset(Long offset) { + this.offset = offset; + } + + public Long getOffset() { + return offset; + } + + protected abstract static class GeneratedCriteria { + protected List criteria; + + protected GeneratedCriteria() { + super(); + criteria = new ArrayList(); + } + + public boolean isValid() { + return criteria.size() > 0; + } + + public List getAllCriteria() { + return criteria; + } + + public List getCriteria() { + return criteria; + } + + protected void addCriterion(String condition) { + if (condition == null) { + throw new RuntimeException("Value for condition cannot be null"); + } + criteria.add(new Criterion(condition)); + } + + protected void addCriterion(String condition, Object value, String property) { + if (value == null) { + throw new RuntimeException("Value for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value)); + } + + protected void addCriterion(String condition, Object value1, Object value2, String property) { + if (value1 == null || value2 == null) { + throw new RuntimeException("Between values for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value1, value2)); + } + + public Criteria andIdIsNull() { + addCriterion("id is null"); + return (Criteria) this; + } + + public Criteria andIdIsNotNull() { + addCriterion("id is not null"); + return (Criteria) this; + } + + public Criteria andIdEqualTo(Long value) { + addCriterion("id =", value, "id"); + return (Criteria) this; + } + + public Criteria andIdNotEqualTo(Long value) { + addCriterion("id <>", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThan(Long value) { + addCriterion("id >", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThanOrEqualTo(Long value) { + addCriterion("id >=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThan(Long value) { + addCriterion("id <", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThanOrEqualTo(Long value) { + addCriterion("id <=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdIn(List values) { + addCriterion("id in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdNotIn(List values) { + addCriterion("id not in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdBetween(Long value1, Long value2) { + addCriterion("id between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andIdNotBetween(Long value1, Long value2) { + addCriterion("id not between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andMerIdIsNull() { + addCriterion("mer_id is null"); + return (Criteria) this; + } + + public Criteria andMerIdIsNotNull() { + addCriterion("mer_id is not null"); + return (Criteria) this; + } + + public Criteria andMerIdEqualTo(Long value) { + addCriterion("mer_id =", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotEqualTo(Long value) { + addCriterion("mer_id <>", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThan(Long value) { + addCriterion("mer_id >", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_id >=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThan(Long value) { + addCriterion("mer_id <", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_id <=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdIn(List values) { + addCriterion("mer_id in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotIn(List values) { + addCriterion("mer_id not in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdBetween(Long value1, Long value2) { + addCriterion("mer_id between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_id not between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIsNull() { + addCriterion("platform_type is null"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIsNotNull() { + addCriterion("platform_type is not null"); + return (Criteria) this; + } + + public Criteria andPlatformTypeEqualTo(Integer value) { + addCriterion("platform_type =", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotEqualTo(Integer value) { + addCriterion("platform_type <>", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeGreaterThan(Integer value) { + addCriterion("platform_type >", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeGreaterThanOrEqualTo(Integer value) { + addCriterion("platform_type >=", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeLessThan(Integer value) { + addCriterion("platform_type <", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeLessThanOrEqualTo(Integer value) { + addCriterion("platform_type <=", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIn(List values) { + addCriterion("platform_type in", values, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotIn(List values) { + addCriterion("platform_type not in", values, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeBetween(Integer value1, Integer value2) { + addCriterion("platform_type between", value1, value2, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotBetween(Integer value1, Integer value2) { + addCriterion("platform_type not between", value1, value2, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformNoIsNull() { + addCriterion("platform_no is null"); + return (Criteria) this; + } + + public Criteria andPlatformNoIsNotNull() { + addCriterion("platform_no is not null"); + return (Criteria) this; + } + + public Criteria andPlatformNoEqualTo(String value) { + addCriterion("platform_no =", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotEqualTo(String value) { + addCriterion("platform_no <>", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoGreaterThan(String value) { + addCriterion("platform_no >", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoGreaterThanOrEqualTo(String value) { + addCriterion("platform_no >=", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLessThan(String value) { + addCriterion("platform_no <", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLessThanOrEqualTo(String value) { + addCriterion("platform_no <=", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLike(String value) { + addCriterion("platform_no like", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotLike(String value) { + addCriterion("platform_no not like", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoIn(List values) { + addCriterion("platform_no in", values, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotIn(List values) { + addCriterion("platform_no not in", values, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoBetween(String value1, String value2) { + addCriterion("platform_no between", value1, value2, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotBetween(String value1, String value2) { + addCriterion("platform_no not between", value1, value2, "platformNo"); + return (Criteria) this; + } + + public Criteria andCupNoIsNull() { + addCriterion("cup_no is null"); + return (Criteria) this; + } + + public Criteria andCupNoIsNotNull() { + addCriterion("cup_no is not null"); + return (Criteria) this; + } + + public Criteria andCupNoEqualTo(String value) { + addCriterion("cup_no =", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotEqualTo(String value) { + addCriterion("cup_no <>", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoGreaterThan(String value) { + addCriterion("cup_no >", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoGreaterThanOrEqualTo(String value) { + addCriterion("cup_no >=", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLessThan(String value) { + addCriterion("cup_no <", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLessThanOrEqualTo(String value) { + addCriterion("cup_no <=", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLike(String value) { + addCriterion("cup_no like", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotLike(String value) { + addCriterion("cup_no not like", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoIn(List values) { + addCriterion("cup_no in", values, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotIn(List values) { + addCriterion("cup_no not in", values, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoBetween(String value1, String value2) { + addCriterion("cup_no between", value1, value2, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotBetween(String value1, String value2) { + addCriterion("cup_no not between", value1, value2, "cupNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNull() { + addCriterion("receiver_no is null"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNotNull() { + addCriterion("receiver_no is not null"); + return (Criteria) this; + } + + public Criteria andReceiverNoEqualTo(String value) { + addCriterion("receiver_no =", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotEqualTo(String value) { + addCriterion("receiver_no <>", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThan(String value) { + addCriterion("receiver_no >", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThanOrEqualTo(String value) { + addCriterion("receiver_no >=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThan(String value) { + addCriterion("receiver_no <", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThanOrEqualTo(String value) { + addCriterion("receiver_no <=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLike(String value) { + addCriterion("receiver_no like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotLike(String value) { + addCriterion("receiver_no not like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoIn(List values) { + addCriterion("receiver_no in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotIn(List values) { + addCriterion("receiver_no not in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoBetween(String value1, String value2) { + addCriterion("receiver_no between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotBetween(String value1, String value2) { + addCriterion("receiver_no not between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioIsNull() { + addCriterion("split_lowest_ratio is null"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioIsNotNull() { + addCriterion("split_lowest_ratio is not null"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioEqualTo(BigDecimal value) { + addCriterion("split_lowest_ratio =", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioNotEqualTo(BigDecimal value) { + addCriterion("split_lowest_ratio <>", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioGreaterThan(BigDecimal value) { + addCriterion("split_lowest_ratio >", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioGreaterThanOrEqualTo(BigDecimal value) { + addCriterion("split_lowest_ratio >=", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioLessThan(BigDecimal value) { + addCriterion("split_lowest_ratio <", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioLessThanOrEqualTo(BigDecimal value) { + addCriterion("split_lowest_ratio <=", value, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioIn(List values) { + addCriterion("split_lowest_ratio in", values, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioNotIn(List values) { + addCriterion("split_lowest_ratio not in", values, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioBetween(BigDecimal value1, BigDecimal value2) { + addCriterion("split_lowest_ratio between", value1, value2, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitLowestRatioNotBetween(BigDecimal value1, BigDecimal value2) { + addCriterion("split_lowest_ratio not between", value1, value2, "splitLowestRatio"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameIsNull() { + addCriterion("split_entrust_file_name is null"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameIsNotNull() { + addCriterion("split_entrust_file_name is not null"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameEqualTo(String value) { + addCriterion("split_entrust_file_name =", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameNotEqualTo(String value) { + addCriterion("split_entrust_file_name <>", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameGreaterThan(String value) { + addCriterion("split_entrust_file_name >", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameGreaterThanOrEqualTo(String value) { + addCriterion("split_entrust_file_name >=", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameLessThan(String value) { + addCriterion("split_entrust_file_name <", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameLessThanOrEqualTo(String value) { + addCriterion("split_entrust_file_name <=", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameLike(String value) { + addCriterion("split_entrust_file_name like", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameNotLike(String value) { + addCriterion("split_entrust_file_name not like", value, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameIn(List values) { + addCriterion("split_entrust_file_name in", values, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameNotIn(List values) { + addCriterion("split_entrust_file_name not in", values, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameBetween(String value1, String value2) { + addCriterion("split_entrust_file_name between", value1, value2, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFileNameNotBetween(String value1, String value2) { + addCriterion("split_entrust_file_name not between", value1, value2, "splitEntrustFileName"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathIsNull() { + addCriterion("split_entrust_file_path is null"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathIsNotNull() { + addCriterion("split_entrust_file_path is not null"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathEqualTo(String value) { + addCriterion("split_entrust_file_path =", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathNotEqualTo(String value) { + addCriterion("split_entrust_file_path <>", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathGreaterThan(String value) { + addCriterion("split_entrust_file_path >", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathGreaterThanOrEqualTo(String value) { + addCriterion("split_entrust_file_path >=", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathLessThan(String value) { + addCriterion("split_entrust_file_path <", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathLessThanOrEqualTo(String value) { + addCriterion("split_entrust_file_path <=", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathLike(String value) { + addCriterion("split_entrust_file_path like", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathNotLike(String value) { + addCriterion("split_entrust_file_path not like", value, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathIn(List values) { + addCriterion("split_entrust_file_path in", values, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathNotIn(List values) { + addCriterion("split_entrust_file_path not in", values, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathBetween(String value1, String value2) { + addCriterion("split_entrust_file_path between", value1, value2, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andSplitEntrustFilePathNotBetween(String value1, String value2) { + addCriterion("split_entrust_file_path not between", value1, value2, "splitEntrustFilePath"); + return (Criteria) this; + } + + public Criteria andStatusIsNull() { + addCriterion("`status` is null"); + return (Criteria) this; + } + + public Criteria andStatusIsNotNull() { + addCriterion("`status` is not null"); + return (Criteria) this; + } + + public Criteria andStatusEqualTo(Integer value) { + addCriterion("`status` =", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotEqualTo(Integer value) { + addCriterion("`status` <>", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThan(Integer value) { + addCriterion("`status` >", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThanOrEqualTo(Integer value) { + addCriterion("`status` >=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThan(Integer value) { + addCriterion("`status` <", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThanOrEqualTo(Integer value) { + addCriterion("`status` <=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusIn(List values) { + addCriterion("`status` in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotIn(List values) { + addCriterion("`status` not in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusBetween(Integer value1, Integer value2) { + addCriterion("`status` between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotBetween(Integer value1, Integer value2) { + addCriterion("`status` not between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNull() { + addCriterion("reject_reason is null"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNotNull() { + addCriterion("reject_reason is not null"); + return (Criteria) this; + } + + public Criteria andRejectReasonEqualTo(String value) { + addCriterion("reject_reason =", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotEqualTo(String value) { + addCriterion("reject_reason <>", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThan(String value) { + addCriterion("reject_reason >", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThanOrEqualTo(String value) { + addCriterion("reject_reason >=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThan(String value) { + addCriterion("reject_reason <", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThanOrEqualTo(String value) { + addCriterion("reject_reason <=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLike(String value) { + addCriterion("reject_reason like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotLike(String value) { + addCriterion("reject_reason not like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonIn(List values) { + addCriterion("reject_reason in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotIn(List values) { + addCriterion("reject_reason not in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonBetween(String value1, String value2) { + addCriterion("reject_reason between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotBetween(String value1, String value2) { + addCriterion("reject_reason not between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNull() { + addCriterion("create_time is null"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNotNull() { + addCriterion("create_time is not null"); + return (Criteria) this; + } + + public Criteria andCreateTimeEqualTo(Date value) { + addCriterion("create_time =", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotEqualTo(Date value) { + addCriterion("create_time <>", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThan(Date value) { + addCriterion("create_time >", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("create_time >=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThan(Date value) { + addCriterion("create_time <", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThanOrEqualTo(Date value) { + addCriterion("create_time <=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeIn(List values) { + addCriterion("create_time in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotIn(List values) { + addCriterion("create_time not in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeBetween(Date value1, Date value2) { + addCriterion("create_time between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotBetween(Date value1, Date value2) { + addCriterion("create_time not between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNull() { + addCriterion("update_time is null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNotNull() { + addCriterion("update_time is not null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeEqualTo(Date value) { + addCriterion("update_time =", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotEqualTo(Date value) { + addCriterion("update_time <>", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThan(Date value) { + addCriterion("update_time >", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("update_time >=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThan(Date value) { + addCriterion("update_time <", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { + addCriterion("update_time <=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIn(List values) { + addCriterion("update_time in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotIn(List values) { + addCriterion("update_time not in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeBetween(Date value1, Date value2) { + addCriterion("update_time between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { + addCriterion("update_time not between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andExt1IsNull() { + addCriterion("ext_1 is null"); + return (Criteria) this; + } + + public Criteria andExt1IsNotNull() { + addCriterion("ext_1 is not null"); + return (Criteria) this; + } + + public Criteria andExt1EqualTo(String value) { + addCriterion("ext_1 =", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotEqualTo(String value) { + addCriterion("ext_1 <>", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThan(String value) { + addCriterion("ext_1 >", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThanOrEqualTo(String value) { + addCriterion("ext_1 >=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThan(String value) { + addCriterion("ext_1 <", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThanOrEqualTo(String value) { + addCriterion("ext_1 <=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Like(String value) { + addCriterion("ext_1 like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotLike(String value) { + addCriterion("ext_1 not like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1In(List values) { + addCriterion("ext_1 in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotIn(List values) { + addCriterion("ext_1 not in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Between(String value1, String value2) { + addCriterion("ext_1 between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotBetween(String value1, String value2) { + addCriterion("ext_1 not between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt2IsNull() { + addCriterion("ext_2 is null"); + return (Criteria) this; + } + + public Criteria andExt2IsNotNull() { + addCriterion("ext_2 is not null"); + return (Criteria) this; + } + + public Criteria andExt2EqualTo(String value) { + addCriterion("ext_2 =", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotEqualTo(String value) { + addCriterion("ext_2 <>", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThan(String value) { + addCriterion("ext_2 >", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThanOrEqualTo(String value) { + addCriterion("ext_2 >=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThan(String value) { + addCriterion("ext_2 <", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThanOrEqualTo(String value) { + addCriterion("ext_2 <=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Like(String value) { + addCriterion("ext_2 like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotLike(String value) { + addCriterion("ext_2 not like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2In(List values) { + addCriterion("ext_2 in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotIn(List values) { + addCriterion("ext_2 not in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Between(String value1, String value2) { + addCriterion("ext_2 between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotBetween(String value1, String value2) { + addCriterion("ext_2 not between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt3IsNull() { + addCriterion("ext_3 is null"); + return (Criteria) this; + } + + public Criteria andExt3IsNotNull() { + addCriterion("ext_3 is not null"); + return (Criteria) this; + } + + public Criteria andExt3EqualTo(String value) { + addCriterion("ext_3 =", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotEqualTo(String value) { + addCriterion("ext_3 <>", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThan(String value) { + addCriterion("ext_3 >", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThanOrEqualTo(String value) { + addCriterion("ext_3 >=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThan(String value) { + addCriterion("ext_3 <", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThanOrEqualTo(String value) { + addCriterion("ext_3 <=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Like(String value) { + addCriterion("ext_3 like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotLike(String value) { + addCriterion("ext_3 not like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3In(List values) { + addCriterion("ext_3 in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotIn(List values) { + addCriterion("ext_3 not in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Between(String value1, String value2) { + addCriterion("ext_3 between", value1, value2, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotBetween(String value1, String value2) { + addCriterion("ext_3 not between", value1, value2, "ext3"); + return (Criteria) this; + } + } + + /** + */ + public static class Criteria extends GeneratedCriteria { + + protected Criteria() { + super(); + } + } + + public static class Criterion { + private String condition; + + private Object value; + + private Object secondValue; + + private boolean noValue; + + private boolean singleValue; + + private boolean betweenValue; + + private boolean listValue; + + private String typeHandler; + + public String getCondition() { + return condition; + } + + public Object getValue() { + return value; + } + + public Object getSecondValue() { + return secondValue; + } + + public boolean isNoValue() { + return noValue; + } + + public boolean isSingleValue() { + return singleValue; + } + + public boolean isBetweenValue() { + return betweenValue; + } + + public boolean isListValue() { + return listValue; + } + + public String getTypeHandler() { + return typeHandler; + } + + protected Criterion(String condition) { + super(); + this.condition = condition; + this.typeHandler = null; + this.noValue = true; + } + + protected Criterion(String condition, Object value, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.typeHandler = typeHandler; + if (value instanceof List) { + this.listValue = true; + } else { + this.singleValue = true; + } + } + + protected Criterion(String condition, Object value) { + this(condition, value, null); + } + + protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.secondValue = secondValue; + this.typeHandler = typeHandler; + this.betweenValue = true; + } + + protected Criterion(String condition, Object value, Object secondValue) { + this(condition, value, secondValue, null); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiver.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiver.java new file mode 100644 index 0000000..e9f3ffd --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiver.java @@ -0,0 +1,312 @@ +package com.hfkj.entity; + +import java.io.Serializable; +import java.util.Date; + +/** + * bs_mer_ledger_receiver + * @author + */ +/** + * + * 代码由工具生成 + * + **/ +public class BsMerLedgerReceiver implements Serializable { + /** + * 主键 + */ + private Long id; + + /** + * 商户id + */ + private Long merId; + + /** + * 商户分账id + */ + private Long merLedgerId; + + /** + * 平台 1:拉卡拉 + */ + private Integer platformType; + + /** + * 平台商户号 + */ + private String platformNo; + + /** + * 银联商户号 + */ + private String cupNo; + + /** + * 接收方编号 + */ + private String receiverNo; + + /** + * 接收方名称 + */ + private String receiverName; + + /** + * 合作协议附件名称 + */ + private String entrustFileName; + + /** + * 合作协议附件路径 + */ + private String entrustFilePath; + + /** + * 状态 0:删除 1:可用 2:审核中 3:审核驳回 + */ + private Integer status; + + /** + * 驳回原因 + */ + private String rejectReason; + + /** + * 创建时间 + */ + private Date createTime; + + /** + * 修改时间 + */ + private Date updateTime; + + private String ext1; + + private String ext2; + + private String ext3; + + private static final long serialVersionUID = 1L; + + public Long getId() { + return id; + } + + public void setId(Long id) { + this.id = id; + } + + public Long getMerId() { + return merId; + } + + public void setMerId(Long merId) { + this.merId = merId; + } + + public Long getMerLedgerId() { + return merLedgerId; + } + + public void setMerLedgerId(Long merLedgerId) { + this.merLedgerId = merLedgerId; + } + + public Integer getPlatformType() { + return platformType; + } + + public void setPlatformType(Integer platformType) { + this.platformType = platformType; + } + + public String getPlatformNo() { + return platformNo; + } + + public void setPlatformNo(String platformNo) { + this.platformNo = platformNo; + } + + public String getCupNo() { + return cupNo; + } + + public void setCupNo(String cupNo) { + this.cupNo = cupNo; + } + + public String getReceiverNo() { + return receiverNo; + } + + public void setReceiverNo(String receiverNo) { + this.receiverNo = receiverNo; + } + + public String getReceiverName() { + return receiverName; + } + + public void setReceiverName(String receiverName) { + this.receiverName = receiverName; + } + + public String getEntrustFileName() { + return entrustFileName; + } + + public void setEntrustFileName(String entrustFileName) { + this.entrustFileName = entrustFileName; + } + + public String getEntrustFilePath() { + return entrustFilePath; + } + + public void setEntrustFilePath(String entrustFilePath) { + this.entrustFilePath = entrustFilePath; + } + + public Integer getStatus() { + return status; + } + + public void setStatus(Integer status) { + this.status = status; + } + + public String getRejectReason() { + return rejectReason; + } + + public void setRejectReason(String rejectReason) { + this.rejectReason = rejectReason; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getExt1() { + return ext1; + } + + public void setExt1(String ext1) { + this.ext1 = ext1; + } + + public String getExt2() { + return ext2; + } + + public void setExt2(String ext2) { + this.ext2 = ext2; + } + + public String getExt3() { + return ext3; + } + + public void setExt3(String ext3) { + this.ext3 = ext3; + } + + @Override + public boolean equals(Object that) { + if (this == that) { + return true; + } + if (that == null) { + return false; + } + if (getClass() != that.getClass()) { + return false; + } + BsMerLedgerReceiver other = (BsMerLedgerReceiver) that; + return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getMerId() == null ? other.getMerId() == null : this.getMerId().equals(other.getMerId())) + && (this.getMerLedgerId() == null ? other.getMerLedgerId() == null : this.getMerLedgerId().equals(other.getMerLedgerId())) + && (this.getPlatformType() == null ? other.getPlatformType() == null : this.getPlatformType().equals(other.getPlatformType())) + && (this.getPlatformNo() == null ? other.getPlatformNo() == null : this.getPlatformNo().equals(other.getPlatformNo())) + && (this.getCupNo() == null ? other.getCupNo() == null : this.getCupNo().equals(other.getCupNo())) + && (this.getReceiverNo() == null ? other.getReceiverNo() == null : this.getReceiverNo().equals(other.getReceiverNo())) + && (this.getReceiverName() == null ? other.getReceiverName() == null : this.getReceiverName().equals(other.getReceiverName())) + && (this.getEntrustFileName() == null ? other.getEntrustFileName() == null : this.getEntrustFileName().equals(other.getEntrustFileName())) + && (this.getEntrustFilePath() == null ? other.getEntrustFilePath() == null : this.getEntrustFilePath().equals(other.getEntrustFilePath())) + && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus())) + && (this.getRejectReason() == null ? other.getRejectReason() == null : this.getRejectReason().equals(other.getRejectReason())) + && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime())) + && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime())) + && (this.getExt1() == null ? other.getExt1() == null : this.getExt1().equals(other.getExt1())) + && (this.getExt2() == null ? other.getExt2() == null : this.getExt2().equals(other.getExt2())) + && (this.getExt3() == null ? other.getExt3() == null : this.getExt3().equals(other.getExt3())); + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getMerId() == null) ? 0 : getMerId().hashCode()); + result = prime * result + ((getMerLedgerId() == null) ? 0 : getMerLedgerId().hashCode()); + result = prime * result + ((getPlatformType() == null) ? 0 : getPlatformType().hashCode()); + result = prime * result + ((getPlatformNo() == null) ? 0 : getPlatformNo().hashCode()); + result = prime * result + ((getCupNo() == null) ? 0 : getCupNo().hashCode()); + result = prime * result + ((getReceiverNo() == null) ? 0 : getReceiverNo().hashCode()); + result = prime * result + ((getReceiverName() == null) ? 0 : getReceiverName().hashCode()); + result = prime * result + ((getEntrustFileName() == null) ? 0 : getEntrustFileName().hashCode()); + result = prime * result + ((getEntrustFilePath() == null) ? 0 : getEntrustFilePath().hashCode()); + result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode()); + result = prime * result + ((getRejectReason() == null) ? 0 : getRejectReason().hashCode()); + result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode()); + result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode()); + result = prime * result + ((getExt1() == null) ? 0 : getExt1().hashCode()); + result = prime * result + ((getExt2() == null) ? 0 : getExt2().hashCode()); + result = prime * result + ((getExt3() == null) ? 0 : getExt3().hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append(getClass().getSimpleName()); + sb.append(" ["); + sb.append("Hash = ").append(hashCode()); + sb.append(", id=").append(id); + sb.append(", merId=").append(merId); + sb.append(", merLedgerId=").append(merLedgerId); + sb.append(", platformType=").append(platformType); + sb.append(", platformNo=").append(platformNo); + sb.append(", cupNo=").append(cupNo); + sb.append(", receiverNo=").append(receiverNo); + sb.append(", receiverName=").append(receiverName); + sb.append(", entrustFileName=").append(entrustFileName); + sb.append(", entrustFilePath=").append(entrustFilePath); + sb.append(", status=").append(status); + sb.append(", rejectReason=").append(rejectReason); + sb.append(", createTime=").append(createTime); + sb.append(", updateTime=").append(updateTime); + sb.append(", ext1=").append(ext1); + sb.append(", ext2=").append(ext2); + sb.append(", ext3=").append(ext3); + sb.append(", serialVersionUID=").append(serialVersionUID); + sb.append("]"); + return sb.toString(); + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApply.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApply.java new file mode 100644 index 0000000..ab9cf4c --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApply.java @@ -0,0 +1,312 @@ +package com.hfkj.entity; + +import java.io.Serializable; +import java.util.Date; + +/** + * bs_mer_ledger_receiver_apply + * @author + */ +/** + * + * 代码由工具生成 + * + **/ +public class BsMerLedgerReceiverApply implements Serializable { + /** + * 主键 + */ + private Long id; + + /** + * 商户id + */ + private Long merId; + + /** + * 商户分账id + */ + private Long merLedgerId; + + /** + * 商户分账接收方id + */ + private Long merLedgerReceiverId; + + /** + * 接受编号 + */ + private String receiverNo; + + /** + * 订单编号 + */ + private String orderNo; + + /** + * 受理编号 + */ + private String applyId; + + /** + * 请求报文 + */ + private String requestBody; + + /** + * 响应报文 + */ + private String responseBody; + + /** + * 异步通知报文 + */ + private String notifyBody; + + /** + * 状态 0:删除 1:审核中 2:通过 3:驳回 + */ + private Integer status; + + /** + * 驳回原因 + */ + private String rejectReason; + + /** + * 创建时间 + */ + private Date createTime; + + /** + * 修改时间 + */ + private Date updateTime; + + private String ext1; + + private String ext2; + + private String ext3; + + private static final long serialVersionUID = 1L; + + public Long getId() { + return id; + } + + public void setId(Long id) { + this.id = id; + } + + public Long getMerId() { + return merId; + } + + public void setMerId(Long merId) { + this.merId = merId; + } + + public Long getMerLedgerId() { + return merLedgerId; + } + + public void setMerLedgerId(Long merLedgerId) { + this.merLedgerId = merLedgerId; + } + + public Long getMerLedgerReceiverId() { + return merLedgerReceiverId; + } + + public void setMerLedgerReceiverId(Long merLedgerReceiverId) { + this.merLedgerReceiverId = merLedgerReceiverId; + } + + public String getReceiverNo() { + return receiverNo; + } + + public void setReceiverNo(String receiverNo) { + this.receiverNo = receiverNo; + } + + public String getOrderNo() { + return orderNo; + } + + public void setOrderNo(String orderNo) { + this.orderNo = orderNo; + } + + public String getApplyId() { + return applyId; + } + + public void setApplyId(String applyId) { + this.applyId = applyId; + } + + public String getRequestBody() { + return requestBody; + } + + public void setRequestBody(String requestBody) { + this.requestBody = requestBody; + } + + public String getResponseBody() { + return responseBody; + } + + public void setResponseBody(String responseBody) { + this.responseBody = responseBody; + } + + public String getNotifyBody() { + return notifyBody; + } + + public void setNotifyBody(String notifyBody) { + this.notifyBody = notifyBody; + } + + public Integer getStatus() { + return status; + } + + public void setStatus(Integer status) { + this.status = status; + } + + public String getRejectReason() { + return rejectReason; + } + + public void setRejectReason(String rejectReason) { + this.rejectReason = rejectReason; + } + + public Date getCreateTime() { + return createTime; + } + + public void setCreateTime(Date createTime) { + this.createTime = createTime; + } + + public Date getUpdateTime() { + return updateTime; + } + + public void setUpdateTime(Date updateTime) { + this.updateTime = updateTime; + } + + public String getExt1() { + return ext1; + } + + public void setExt1(String ext1) { + this.ext1 = ext1; + } + + public String getExt2() { + return ext2; + } + + public void setExt2(String ext2) { + this.ext2 = ext2; + } + + public String getExt3() { + return ext3; + } + + public void setExt3(String ext3) { + this.ext3 = ext3; + } + + @Override + public boolean equals(Object that) { + if (this == that) { + return true; + } + if (that == null) { + return false; + } + if (getClass() != that.getClass()) { + return false; + } + BsMerLedgerReceiverApply other = (BsMerLedgerReceiverApply) that; + return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getMerId() == null ? other.getMerId() == null : this.getMerId().equals(other.getMerId())) + && (this.getMerLedgerId() == null ? other.getMerLedgerId() == null : this.getMerLedgerId().equals(other.getMerLedgerId())) + && (this.getMerLedgerReceiverId() == null ? other.getMerLedgerReceiverId() == null : this.getMerLedgerReceiverId().equals(other.getMerLedgerReceiverId())) + && (this.getReceiverNo() == null ? other.getReceiverNo() == null : this.getReceiverNo().equals(other.getReceiverNo())) + && (this.getOrderNo() == null ? other.getOrderNo() == null : this.getOrderNo().equals(other.getOrderNo())) + && (this.getApplyId() == null ? other.getApplyId() == null : this.getApplyId().equals(other.getApplyId())) + && (this.getRequestBody() == null ? other.getRequestBody() == null : this.getRequestBody().equals(other.getRequestBody())) + && (this.getResponseBody() == null ? other.getResponseBody() == null : this.getResponseBody().equals(other.getResponseBody())) + && (this.getNotifyBody() == null ? other.getNotifyBody() == null : this.getNotifyBody().equals(other.getNotifyBody())) + && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus())) + && (this.getRejectReason() == null ? other.getRejectReason() == null : this.getRejectReason().equals(other.getRejectReason())) + && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime())) + && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime())) + && (this.getExt1() == null ? other.getExt1() == null : this.getExt1().equals(other.getExt1())) + && (this.getExt2() == null ? other.getExt2() == null : this.getExt2().equals(other.getExt2())) + && (this.getExt3() == null ? other.getExt3() == null : this.getExt3().equals(other.getExt3())); + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getMerId() == null) ? 0 : getMerId().hashCode()); + result = prime * result + ((getMerLedgerId() == null) ? 0 : getMerLedgerId().hashCode()); + result = prime * result + ((getMerLedgerReceiverId() == null) ? 0 : getMerLedgerReceiverId().hashCode()); + result = prime * result + ((getReceiverNo() == null) ? 0 : getReceiverNo().hashCode()); + result = prime * result + ((getOrderNo() == null) ? 0 : getOrderNo().hashCode()); + result = prime * result + ((getApplyId() == null) ? 0 : getApplyId().hashCode()); + result = prime * result + ((getRequestBody() == null) ? 0 : getRequestBody().hashCode()); + result = prime * result + ((getResponseBody() == null) ? 0 : getResponseBody().hashCode()); + result = prime * result + ((getNotifyBody() == null) ? 0 : getNotifyBody().hashCode()); + result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode()); + result = prime * result + ((getRejectReason() == null) ? 0 : getRejectReason().hashCode()); + result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode()); + result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode()); + result = prime * result + ((getExt1() == null) ? 0 : getExt1().hashCode()); + result = prime * result + ((getExt2() == null) ? 0 : getExt2().hashCode()); + result = prime * result + ((getExt3() == null) ? 0 : getExt3().hashCode()); + return result; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append(getClass().getSimpleName()); + sb.append(" ["); + sb.append("Hash = ").append(hashCode()); + sb.append(", id=").append(id); + sb.append(", merId=").append(merId); + sb.append(", merLedgerId=").append(merLedgerId); + sb.append(", merLedgerReceiverId=").append(merLedgerReceiverId); + sb.append(", receiverNo=").append(receiverNo); + sb.append(", orderNo=").append(orderNo); + sb.append(", applyId=").append(applyId); + sb.append(", requestBody=").append(requestBody); + sb.append(", responseBody=").append(responseBody); + sb.append(", notifyBody=").append(notifyBody); + sb.append(", status=").append(status); + sb.append(", rejectReason=").append(rejectReason); + sb.append(", createTime=").append(createTime); + sb.append(", updateTime=").append(updateTime); + sb.append(", ext1=").append(ext1); + sb.append(", ext2=").append(ext2); + sb.append(", ext3=").append(ext3); + sb.append(", serialVersionUID=").append(serialVersionUID); + sb.append("]"); + return sb.toString(); + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApplyExample.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApplyExample.java new file mode 100644 index 0000000..74b138c --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverApplyExample.java @@ -0,0 +1,1343 @@ +package com.hfkj.entity; + +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +public class BsMerLedgerReceiverApplyExample { + protected String orderByClause; + + protected boolean distinct; + + protected List oredCriteria; + + private Integer limit; + + private Long offset; + + public BsMerLedgerReceiverApplyExample() { + oredCriteria = new ArrayList(); + } + + public void setOrderByClause(String orderByClause) { + this.orderByClause = orderByClause; + } + + public String getOrderByClause() { + return orderByClause; + } + + public void setDistinct(boolean distinct) { + this.distinct = distinct; + } + + public boolean isDistinct() { + return distinct; + } + + public List getOredCriteria() { + return oredCriteria; + } + + public void or(Criteria criteria) { + oredCriteria.add(criteria); + } + + public Criteria or() { + Criteria criteria = createCriteriaInternal(); + oredCriteria.add(criteria); + return criteria; + } + + public Criteria createCriteria() { + Criteria criteria = createCriteriaInternal(); + if (oredCriteria.size() == 0) { + oredCriteria.add(criteria); + } + return criteria; + } + + protected Criteria createCriteriaInternal() { + Criteria criteria = new Criteria(); + return criteria; + } + + public void clear() { + oredCriteria.clear(); + orderByClause = null; + distinct = false; + } + + public void setLimit(Integer limit) { + this.limit = limit; + } + + public Integer getLimit() { + return limit; + } + + public void setOffset(Long offset) { + this.offset = offset; + } + + public Long getOffset() { + return offset; + } + + protected abstract static class GeneratedCriteria { + protected List criteria; + + protected GeneratedCriteria() { + super(); + criteria = new ArrayList(); + } + + public boolean isValid() { + return criteria.size() > 0; + } + + public List getAllCriteria() { + return criteria; + } + + public List getCriteria() { + return criteria; + } + + protected void addCriterion(String condition) { + if (condition == null) { + throw new RuntimeException("Value for condition cannot be null"); + } + criteria.add(new Criterion(condition)); + } + + protected void addCriterion(String condition, Object value, String property) { + if (value == null) { + throw new RuntimeException("Value for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value)); + } + + protected void addCriterion(String condition, Object value1, Object value2, String property) { + if (value1 == null || value2 == null) { + throw new RuntimeException("Between values for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value1, value2)); + } + + public Criteria andIdIsNull() { + addCriterion("id is null"); + return (Criteria) this; + } + + public Criteria andIdIsNotNull() { + addCriterion("id is not null"); + return (Criteria) this; + } + + public Criteria andIdEqualTo(Long value) { + addCriterion("id =", value, "id"); + return (Criteria) this; + } + + public Criteria andIdNotEqualTo(Long value) { + addCriterion("id <>", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThan(Long value) { + addCriterion("id >", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThanOrEqualTo(Long value) { + addCriterion("id >=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThan(Long value) { + addCriterion("id <", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThanOrEqualTo(Long value) { + addCriterion("id <=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdIn(List values) { + addCriterion("id in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdNotIn(List values) { + addCriterion("id not in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdBetween(Long value1, Long value2) { + addCriterion("id between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andIdNotBetween(Long value1, Long value2) { + addCriterion("id not between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andMerIdIsNull() { + addCriterion("mer_id is null"); + return (Criteria) this; + } + + public Criteria andMerIdIsNotNull() { + addCriterion("mer_id is not null"); + return (Criteria) this; + } + + public Criteria andMerIdEqualTo(Long value) { + addCriterion("mer_id =", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotEqualTo(Long value) { + addCriterion("mer_id <>", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThan(Long value) { + addCriterion("mer_id >", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_id >=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThan(Long value) { + addCriterion("mer_id <", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_id <=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdIn(List values) { + addCriterion("mer_id in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotIn(List values) { + addCriterion("mer_id not in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdBetween(Long value1, Long value2) { + addCriterion("mer_id between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_id not between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNull() { + addCriterion("mer_ledger_id is null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNotNull() { + addCriterion("mer_ledger_id is not null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdEqualTo(Long value) { + addCriterion("mer_ledger_id =", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotEqualTo(Long value) { + addCriterion("mer_ledger_id <>", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThan(Long value) { + addCriterion("mer_ledger_id >", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id >=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThan(Long value) { + addCriterion("mer_ledger_id <", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id <=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIn(List values) { + addCriterion("mer_ledger_id in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotIn(List values) { + addCriterion("mer_ledger_id not in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id not between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdIsNull() { + addCriterion("mer_ledger_receiver_id is null"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdIsNotNull() { + addCriterion("mer_ledger_receiver_id is not null"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdEqualTo(Long value) { + addCriterion("mer_ledger_receiver_id =", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdNotEqualTo(Long value) { + addCriterion("mer_ledger_receiver_id <>", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdGreaterThan(Long value) { + addCriterion("mer_ledger_receiver_id >", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_ledger_receiver_id >=", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdLessThan(Long value) { + addCriterion("mer_ledger_receiver_id <", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdLessThanOrEqualTo(Long value) { + addCriterion("mer_ledger_receiver_id <=", value, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdIn(List values) { + addCriterion("mer_ledger_receiver_id in", values, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdNotIn(List values) { + addCriterion("mer_ledger_receiver_id not in", values, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdBetween(Long value1, Long value2) { + addCriterion("mer_ledger_receiver_id between", value1, value2, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andMerLedgerReceiverIdNotBetween(Long value1, Long value2) { + addCriterion("mer_ledger_receiver_id not between", value1, value2, "merLedgerReceiverId"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNull() { + addCriterion("receiver_no is null"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNotNull() { + addCriterion("receiver_no is not null"); + return (Criteria) this; + } + + public Criteria andReceiverNoEqualTo(String value) { + addCriterion("receiver_no =", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotEqualTo(String value) { + addCriterion("receiver_no <>", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThan(String value) { + addCriterion("receiver_no >", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThanOrEqualTo(String value) { + addCriterion("receiver_no >=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThan(String value) { + addCriterion("receiver_no <", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThanOrEqualTo(String value) { + addCriterion("receiver_no <=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLike(String value) { + addCriterion("receiver_no like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotLike(String value) { + addCriterion("receiver_no not like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoIn(List values) { + addCriterion("receiver_no in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotIn(List values) { + addCriterion("receiver_no not in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoBetween(String value1, String value2) { + addCriterion("receiver_no between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotBetween(String value1, String value2) { + addCriterion("receiver_no not between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andOrderNoIsNull() { + addCriterion("order_no is null"); + return (Criteria) this; + } + + public Criteria andOrderNoIsNotNull() { + addCriterion("order_no is not null"); + return (Criteria) this; + } + + public Criteria andOrderNoEqualTo(String value) { + addCriterion("order_no =", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotEqualTo(String value) { + addCriterion("order_no <>", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoGreaterThan(String value) { + addCriterion("order_no >", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoGreaterThanOrEqualTo(String value) { + addCriterion("order_no >=", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLessThan(String value) { + addCriterion("order_no <", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLessThanOrEqualTo(String value) { + addCriterion("order_no <=", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoLike(String value) { + addCriterion("order_no like", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotLike(String value) { + addCriterion("order_no not like", value, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoIn(List values) { + addCriterion("order_no in", values, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotIn(List values) { + addCriterion("order_no not in", values, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoBetween(String value1, String value2) { + addCriterion("order_no between", value1, value2, "orderNo"); + return (Criteria) this; + } + + public Criteria andOrderNoNotBetween(String value1, String value2) { + addCriterion("order_no not between", value1, value2, "orderNo"); + return (Criteria) this; + } + + public Criteria andApplyIdIsNull() { + addCriterion("apply_id is null"); + return (Criteria) this; + } + + public Criteria andApplyIdIsNotNull() { + addCriterion("apply_id is not null"); + return (Criteria) this; + } + + public Criteria andApplyIdEqualTo(String value) { + addCriterion("apply_id =", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotEqualTo(String value) { + addCriterion("apply_id <>", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdGreaterThan(String value) { + addCriterion("apply_id >", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdGreaterThanOrEqualTo(String value) { + addCriterion("apply_id >=", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLessThan(String value) { + addCriterion("apply_id <", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLessThanOrEqualTo(String value) { + addCriterion("apply_id <=", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdLike(String value) { + addCriterion("apply_id like", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotLike(String value) { + addCriterion("apply_id not like", value, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdIn(List values) { + addCriterion("apply_id in", values, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotIn(List values) { + addCriterion("apply_id not in", values, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdBetween(String value1, String value2) { + addCriterion("apply_id between", value1, value2, "applyId"); + return (Criteria) this; + } + + public Criteria andApplyIdNotBetween(String value1, String value2) { + addCriterion("apply_id not between", value1, value2, "applyId"); + return (Criteria) this; + } + + public Criteria andRequestBodyIsNull() { + addCriterion("request_body is null"); + return (Criteria) this; + } + + public Criteria andRequestBodyIsNotNull() { + addCriterion("request_body is not null"); + return (Criteria) this; + } + + public Criteria andRequestBodyEqualTo(String value) { + addCriterion("request_body =", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotEqualTo(String value) { + addCriterion("request_body <>", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyGreaterThan(String value) { + addCriterion("request_body >", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyGreaterThanOrEqualTo(String value) { + addCriterion("request_body >=", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLessThan(String value) { + addCriterion("request_body <", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLessThanOrEqualTo(String value) { + addCriterion("request_body <=", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyLike(String value) { + addCriterion("request_body like", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotLike(String value) { + addCriterion("request_body not like", value, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyIn(List values) { + addCriterion("request_body in", values, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotIn(List values) { + addCriterion("request_body not in", values, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyBetween(String value1, String value2) { + addCriterion("request_body between", value1, value2, "requestBody"); + return (Criteria) this; + } + + public Criteria andRequestBodyNotBetween(String value1, String value2) { + addCriterion("request_body not between", value1, value2, "requestBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyIsNull() { + addCriterion("response_body is null"); + return (Criteria) this; + } + + public Criteria andResponseBodyIsNotNull() { + addCriterion("response_body is not null"); + return (Criteria) this; + } + + public Criteria andResponseBodyEqualTo(String value) { + addCriterion("response_body =", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotEqualTo(String value) { + addCriterion("response_body <>", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyGreaterThan(String value) { + addCriterion("response_body >", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyGreaterThanOrEqualTo(String value) { + addCriterion("response_body >=", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLessThan(String value) { + addCriterion("response_body <", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLessThanOrEqualTo(String value) { + addCriterion("response_body <=", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyLike(String value) { + addCriterion("response_body like", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotLike(String value) { + addCriterion("response_body not like", value, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyIn(List values) { + addCriterion("response_body in", values, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotIn(List values) { + addCriterion("response_body not in", values, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyBetween(String value1, String value2) { + addCriterion("response_body between", value1, value2, "responseBody"); + return (Criteria) this; + } + + public Criteria andResponseBodyNotBetween(String value1, String value2) { + addCriterion("response_body not between", value1, value2, "responseBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIsNull() { + addCriterion("notify_body is null"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIsNotNull() { + addCriterion("notify_body is not null"); + return (Criteria) this; + } + + public Criteria andNotifyBodyEqualTo(String value) { + addCriterion("notify_body =", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotEqualTo(String value) { + addCriterion("notify_body <>", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyGreaterThan(String value) { + addCriterion("notify_body >", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyGreaterThanOrEqualTo(String value) { + addCriterion("notify_body >=", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLessThan(String value) { + addCriterion("notify_body <", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLessThanOrEqualTo(String value) { + addCriterion("notify_body <=", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyLike(String value) { + addCriterion("notify_body like", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotLike(String value) { + addCriterion("notify_body not like", value, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyIn(List values) { + addCriterion("notify_body in", values, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotIn(List values) { + addCriterion("notify_body not in", values, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyBetween(String value1, String value2) { + addCriterion("notify_body between", value1, value2, "notifyBody"); + return (Criteria) this; + } + + public Criteria andNotifyBodyNotBetween(String value1, String value2) { + addCriterion("notify_body not between", value1, value2, "notifyBody"); + return (Criteria) this; + } + + public Criteria andStatusIsNull() { + addCriterion("`status` is null"); + return (Criteria) this; + } + + public Criteria andStatusIsNotNull() { + addCriterion("`status` is not null"); + return (Criteria) this; + } + + public Criteria andStatusEqualTo(Integer value) { + addCriterion("`status` =", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotEqualTo(Integer value) { + addCriterion("`status` <>", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThan(Integer value) { + addCriterion("`status` >", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThanOrEqualTo(Integer value) { + addCriterion("`status` >=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThan(Integer value) { + addCriterion("`status` <", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThanOrEqualTo(Integer value) { + addCriterion("`status` <=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusIn(List values) { + addCriterion("`status` in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotIn(List values) { + addCriterion("`status` not in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusBetween(Integer value1, Integer value2) { + addCriterion("`status` between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotBetween(Integer value1, Integer value2) { + addCriterion("`status` not between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNull() { + addCriterion("reject_reason is null"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNotNull() { + addCriterion("reject_reason is not null"); + return (Criteria) this; + } + + public Criteria andRejectReasonEqualTo(String value) { + addCriterion("reject_reason =", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotEqualTo(String value) { + addCriterion("reject_reason <>", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThan(String value) { + addCriterion("reject_reason >", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThanOrEqualTo(String value) { + addCriterion("reject_reason >=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThan(String value) { + addCriterion("reject_reason <", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThanOrEqualTo(String value) { + addCriterion("reject_reason <=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLike(String value) { + addCriterion("reject_reason like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotLike(String value) { + addCriterion("reject_reason not like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonIn(List values) { + addCriterion("reject_reason in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotIn(List values) { + addCriterion("reject_reason not in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonBetween(String value1, String value2) { + addCriterion("reject_reason between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotBetween(String value1, String value2) { + addCriterion("reject_reason not between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNull() { + addCriterion("create_time is null"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNotNull() { + addCriterion("create_time is not null"); + return (Criteria) this; + } + + public Criteria andCreateTimeEqualTo(Date value) { + addCriterion("create_time =", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotEqualTo(Date value) { + addCriterion("create_time <>", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThan(Date value) { + addCriterion("create_time >", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("create_time >=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThan(Date value) { + addCriterion("create_time <", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThanOrEqualTo(Date value) { + addCriterion("create_time <=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeIn(List values) { + addCriterion("create_time in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotIn(List values) { + addCriterion("create_time not in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeBetween(Date value1, Date value2) { + addCriterion("create_time between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotBetween(Date value1, Date value2) { + addCriterion("create_time not between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNull() { + addCriterion("update_time is null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNotNull() { + addCriterion("update_time is not null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeEqualTo(Date value) { + addCriterion("update_time =", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotEqualTo(Date value) { + addCriterion("update_time <>", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThan(Date value) { + addCriterion("update_time >", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("update_time >=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThan(Date value) { + addCriterion("update_time <", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { + addCriterion("update_time <=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIn(List values) { + addCriterion("update_time in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotIn(List values) { + addCriterion("update_time not in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeBetween(Date value1, Date value2) { + addCriterion("update_time between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { + addCriterion("update_time not between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andExt1IsNull() { + addCriterion("ext_1 is null"); + return (Criteria) this; + } + + public Criteria andExt1IsNotNull() { + addCriterion("ext_1 is not null"); + return (Criteria) this; + } + + public Criteria andExt1EqualTo(String value) { + addCriterion("ext_1 =", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotEqualTo(String value) { + addCriterion("ext_1 <>", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThan(String value) { + addCriterion("ext_1 >", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThanOrEqualTo(String value) { + addCriterion("ext_1 >=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThan(String value) { + addCriterion("ext_1 <", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThanOrEqualTo(String value) { + addCriterion("ext_1 <=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Like(String value) { + addCriterion("ext_1 like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotLike(String value) { + addCriterion("ext_1 not like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1In(List values) { + addCriterion("ext_1 in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotIn(List values) { + addCriterion("ext_1 not in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Between(String value1, String value2) { + addCriterion("ext_1 between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotBetween(String value1, String value2) { + addCriterion("ext_1 not between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt2IsNull() { + addCriterion("ext_2 is null"); + return (Criteria) this; + } + + public Criteria andExt2IsNotNull() { + addCriterion("ext_2 is not null"); + return (Criteria) this; + } + + public Criteria andExt2EqualTo(String value) { + addCriterion("ext_2 =", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotEqualTo(String value) { + addCriterion("ext_2 <>", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThan(String value) { + addCriterion("ext_2 >", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThanOrEqualTo(String value) { + addCriterion("ext_2 >=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThan(String value) { + addCriterion("ext_2 <", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThanOrEqualTo(String value) { + addCriterion("ext_2 <=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Like(String value) { + addCriterion("ext_2 like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotLike(String value) { + addCriterion("ext_2 not like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2In(List values) { + addCriterion("ext_2 in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotIn(List values) { + addCriterion("ext_2 not in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Between(String value1, String value2) { + addCriterion("ext_2 between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotBetween(String value1, String value2) { + addCriterion("ext_2 not between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt3IsNull() { + addCriterion("ext_3 is null"); + return (Criteria) this; + } + + public Criteria andExt3IsNotNull() { + addCriterion("ext_3 is not null"); + return (Criteria) this; + } + + public Criteria andExt3EqualTo(String value) { + addCriterion("ext_3 =", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotEqualTo(String value) { + addCriterion("ext_3 <>", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThan(String value) { + addCriterion("ext_3 >", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThanOrEqualTo(String value) { + addCriterion("ext_3 >=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThan(String value) { + addCriterion("ext_3 <", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThanOrEqualTo(String value) { + addCriterion("ext_3 <=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Like(String value) { + addCriterion("ext_3 like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotLike(String value) { + addCriterion("ext_3 not like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3In(List values) { + addCriterion("ext_3 in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotIn(List values) { + addCriterion("ext_3 not in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Between(String value1, String value2) { + addCriterion("ext_3 between", value1, value2, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotBetween(String value1, String value2) { + addCriterion("ext_3 not between", value1, value2, "ext3"); + return (Criteria) this; + } + } + + /** + */ + public static class Criteria extends GeneratedCriteria { + + protected Criteria() { + super(); + } + } + + public static class Criterion { + private String condition; + + private Object value; + + private Object secondValue; + + private boolean noValue; + + private boolean singleValue; + + private boolean betweenValue; + + private boolean listValue; + + private String typeHandler; + + public String getCondition() { + return condition; + } + + public Object getValue() { + return value; + } + + public Object getSecondValue() { + return secondValue; + } + + public boolean isNoValue() { + return noValue; + } + + public boolean isSingleValue() { + return singleValue; + } + + public boolean isBetweenValue() { + return betweenValue; + } + + public boolean isListValue() { + return listValue; + } + + public String getTypeHandler() { + return typeHandler; + } + + protected Criterion(String condition) { + super(); + this.condition = condition; + this.typeHandler = null; + this.noValue = true; + } + + protected Criterion(String condition, Object value, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.typeHandler = typeHandler; + if (value instanceof List) { + this.listValue = true; + } else { + this.singleValue = true; + } + } + + protected Criterion(String condition, Object value) { + this(condition, value, null); + } + + protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.secondValue = secondValue; + this.typeHandler = typeHandler; + this.betweenValue = true; + } + + protected Criterion(String condition, Object value, Object secondValue) { + this(condition, value, secondValue, null); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverExample.java b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverExample.java new file mode 100644 index 0000000..0c5130e --- /dev/null +++ b/service/src/main/java/com/hfkj/entity/BsMerLedgerReceiverExample.java @@ -0,0 +1,1343 @@ +package com.hfkj.entity; + +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +public class BsMerLedgerReceiverExample { + protected String orderByClause; + + protected boolean distinct; + + protected List oredCriteria; + + private Integer limit; + + private Long offset; + + public BsMerLedgerReceiverExample() { + oredCriteria = new ArrayList(); + } + + public void setOrderByClause(String orderByClause) { + this.orderByClause = orderByClause; + } + + public String getOrderByClause() { + return orderByClause; + } + + public void setDistinct(boolean distinct) { + this.distinct = distinct; + } + + public boolean isDistinct() { + return distinct; + } + + public List getOredCriteria() { + return oredCriteria; + } + + public void or(Criteria criteria) { + oredCriteria.add(criteria); + } + + public Criteria or() { + Criteria criteria = createCriteriaInternal(); + oredCriteria.add(criteria); + return criteria; + } + + public Criteria createCriteria() { + Criteria criteria = createCriteriaInternal(); + if (oredCriteria.size() == 0) { + oredCriteria.add(criteria); + } + return criteria; + } + + protected Criteria createCriteriaInternal() { + Criteria criteria = new Criteria(); + return criteria; + } + + public void clear() { + oredCriteria.clear(); + orderByClause = null; + distinct = false; + } + + public void setLimit(Integer limit) { + this.limit = limit; + } + + public Integer getLimit() { + return limit; + } + + public void setOffset(Long offset) { + this.offset = offset; + } + + public Long getOffset() { + return offset; + } + + protected abstract static class GeneratedCriteria { + protected List criteria; + + protected GeneratedCriteria() { + super(); + criteria = new ArrayList(); + } + + public boolean isValid() { + return criteria.size() > 0; + } + + public List getAllCriteria() { + return criteria; + } + + public List getCriteria() { + return criteria; + } + + protected void addCriterion(String condition) { + if (condition == null) { + throw new RuntimeException("Value for condition cannot be null"); + } + criteria.add(new Criterion(condition)); + } + + protected void addCriterion(String condition, Object value, String property) { + if (value == null) { + throw new RuntimeException("Value for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value)); + } + + protected void addCriterion(String condition, Object value1, Object value2, String property) { + if (value1 == null || value2 == null) { + throw new RuntimeException("Between values for " + property + " cannot be null"); + } + criteria.add(new Criterion(condition, value1, value2)); + } + + public Criteria andIdIsNull() { + addCriterion("id is null"); + return (Criteria) this; + } + + public Criteria andIdIsNotNull() { + addCriterion("id is not null"); + return (Criteria) this; + } + + public Criteria andIdEqualTo(Long value) { + addCriterion("id =", value, "id"); + return (Criteria) this; + } + + public Criteria andIdNotEqualTo(Long value) { + addCriterion("id <>", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThan(Long value) { + addCriterion("id >", value, "id"); + return (Criteria) this; + } + + public Criteria andIdGreaterThanOrEqualTo(Long value) { + addCriterion("id >=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThan(Long value) { + addCriterion("id <", value, "id"); + return (Criteria) this; + } + + public Criteria andIdLessThanOrEqualTo(Long value) { + addCriterion("id <=", value, "id"); + return (Criteria) this; + } + + public Criteria andIdIn(List values) { + addCriterion("id in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdNotIn(List values) { + addCriterion("id not in", values, "id"); + return (Criteria) this; + } + + public Criteria andIdBetween(Long value1, Long value2) { + addCriterion("id between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andIdNotBetween(Long value1, Long value2) { + addCriterion("id not between", value1, value2, "id"); + return (Criteria) this; + } + + public Criteria andMerIdIsNull() { + addCriterion("mer_id is null"); + return (Criteria) this; + } + + public Criteria andMerIdIsNotNull() { + addCriterion("mer_id is not null"); + return (Criteria) this; + } + + public Criteria andMerIdEqualTo(Long value) { + addCriterion("mer_id =", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotEqualTo(Long value) { + addCriterion("mer_id <>", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThan(Long value) { + addCriterion("mer_id >", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_id >=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThan(Long value) { + addCriterion("mer_id <", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_id <=", value, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdIn(List values) { + addCriterion("mer_id in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotIn(List values) { + addCriterion("mer_id not in", values, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdBetween(Long value1, Long value2) { + addCriterion("mer_id between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_id not between", value1, value2, "merId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNull() { + addCriterion("mer_ledger_id is null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIsNotNull() { + addCriterion("mer_ledger_id is not null"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdEqualTo(Long value) { + addCriterion("mer_ledger_id =", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotEqualTo(Long value) { + addCriterion("mer_ledger_id <>", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThan(Long value) { + addCriterion("mer_ledger_id >", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdGreaterThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id >=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThan(Long value) { + addCriterion("mer_ledger_id <", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdLessThanOrEqualTo(Long value) { + addCriterion("mer_ledger_id <=", value, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdIn(List values) { + addCriterion("mer_ledger_id in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotIn(List values) { + addCriterion("mer_ledger_id not in", values, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andMerLedgerIdNotBetween(Long value1, Long value2) { + addCriterion("mer_ledger_id not between", value1, value2, "merLedgerId"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIsNull() { + addCriterion("platform_type is null"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIsNotNull() { + addCriterion("platform_type is not null"); + return (Criteria) this; + } + + public Criteria andPlatformTypeEqualTo(Integer value) { + addCriterion("platform_type =", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotEqualTo(Integer value) { + addCriterion("platform_type <>", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeGreaterThan(Integer value) { + addCriterion("platform_type >", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeGreaterThanOrEqualTo(Integer value) { + addCriterion("platform_type >=", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeLessThan(Integer value) { + addCriterion("platform_type <", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeLessThanOrEqualTo(Integer value) { + addCriterion("platform_type <=", value, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeIn(List values) { + addCriterion("platform_type in", values, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotIn(List values) { + addCriterion("platform_type not in", values, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeBetween(Integer value1, Integer value2) { + addCriterion("platform_type between", value1, value2, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformTypeNotBetween(Integer value1, Integer value2) { + addCriterion("platform_type not between", value1, value2, "platformType"); + return (Criteria) this; + } + + public Criteria andPlatformNoIsNull() { + addCriterion("platform_no is null"); + return (Criteria) this; + } + + public Criteria andPlatformNoIsNotNull() { + addCriterion("platform_no is not null"); + return (Criteria) this; + } + + public Criteria andPlatformNoEqualTo(String value) { + addCriterion("platform_no =", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotEqualTo(String value) { + addCriterion("platform_no <>", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoGreaterThan(String value) { + addCriterion("platform_no >", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoGreaterThanOrEqualTo(String value) { + addCriterion("platform_no >=", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLessThan(String value) { + addCriterion("platform_no <", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLessThanOrEqualTo(String value) { + addCriterion("platform_no <=", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoLike(String value) { + addCriterion("platform_no like", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotLike(String value) { + addCriterion("platform_no not like", value, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoIn(List values) { + addCriterion("platform_no in", values, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotIn(List values) { + addCriterion("platform_no not in", values, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoBetween(String value1, String value2) { + addCriterion("platform_no between", value1, value2, "platformNo"); + return (Criteria) this; + } + + public Criteria andPlatformNoNotBetween(String value1, String value2) { + addCriterion("platform_no not between", value1, value2, "platformNo"); + return (Criteria) this; + } + + public Criteria andCupNoIsNull() { + addCriterion("cup_no is null"); + return (Criteria) this; + } + + public Criteria andCupNoIsNotNull() { + addCriterion("cup_no is not null"); + return (Criteria) this; + } + + public Criteria andCupNoEqualTo(String value) { + addCriterion("cup_no =", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotEqualTo(String value) { + addCriterion("cup_no <>", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoGreaterThan(String value) { + addCriterion("cup_no >", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoGreaterThanOrEqualTo(String value) { + addCriterion("cup_no >=", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLessThan(String value) { + addCriterion("cup_no <", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLessThanOrEqualTo(String value) { + addCriterion("cup_no <=", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoLike(String value) { + addCriterion("cup_no like", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotLike(String value) { + addCriterion("cup_no not like", value, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoIn(List values) { + addCriterion("cup_no in", values, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotIn(List values) { + addCriterion("cup_no not in", values, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoBetween(String value1, String value2) { + addCriterion("cup_no between", value1, value2, "cupNo"); + return (Criteria) this; + } + + public Criteria andCupNoNotBetween(String value1, String value2) { + addCriterion("cup_no not between", value1, value2, "cupNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNull() { + addCriterion("receiver_no is null"); + return (Criteria) this; + } + + public Criteria andReceiverNoIsNotNull() { + addCriterion("receiver_no is not null"); + return (Criteria) this; + } + + public Criteria andReceiverNoEqualTo(String value) { + addCriterion("receiver_no =", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotEqualTo(String value) { + addCriterion("receiver_no <>", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThan(String value) { + addCriterion("receiver_no >", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoGreaterThanOrEqualTo(String value) { + addCriterion("receiver_no >=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThan(String value) { + addCriterion("receiver_no <", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLessThanOrEqualTo(String value) { + addCriterion("receiver_no <=", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoLike(String value) { + addCriterion("receiver_no like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotLike(String value) { + addCriterion("receiver_no not like", value, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoIn(List values) { + addCriterion("receiver_no in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotIn(List values) { + addCriterion("receiver_no not in", values, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoBetween(String value1, String value2) { + addCriterion("receiver_no between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNoNotBetween(String value1, String value2) { + addCriterion("receiver_no not between", value1, value2, "receiverNo"); + return (Criteria) this; + } + + public Criteria andReceiverNameIsNull() { + addCriterion("receiver_name is null"); + return (Criteria) this; + } + + public Criteria andReceiverNameIsNotNull() { + addCriterion("receiver_name is not null"); + return (Criteria) this; + } + + public Criteria andReceiverNameEqualTo(String value) { + addCriterion("receiver_name =", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameNotEqualTo(String value) { + addCriterion("receiver_name <>", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameGreaterThan(String value) { + addCriterion("receiver_name >", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameGreaterThanOrEqualTo(String value) { + addCriterion("receiver_name >=", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameLessThan(String value) { + addCriterion("receiver_name <", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameLessThanOrEqualTo(String value) { + addCriterion("receiver_name <=", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameLike(String value) { + addCriterion("receiver_name like", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameNotLike(String value) { + addCriterion("receiver_name not like", value, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameIn(List values) { + addCriterion("receiver_name in", values, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameNotIn(List values) { + addCriterion("receiver_name not in", values, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameBetween(String value1, String value2) { + addCriterion("receiver_name between", value1, value2, "receiverName"); + return (Criteria) this; + } + + public Criteria andReceiverNameNotBetween(String value1, String value2) { + addCriterion("receiver_name not between", value1, value2, "receiverName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameIsNull() { + addCriterion("entrust_file_name is null"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameIsNotNull() { + addCriterion("entrust_file_name is not null"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameEqualTo(String value) { + addCriterion("entrust_file_name =", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameNotEqualTo(String value) { + addCriterion("entrust_file_name <>", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameGreaterThan(String value) { + addCriterion("entrust_file_name >", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameGreaterThanOrEqualTo(String value) { + addCriterion("entrust_file_name >=", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameLessThan(String value) { + addCriterion("entrust_file_name <", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameLessThanOrEqualTo(String value) { + addCriterion("entrust_file_name <=", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameLike(String value) { + addCriterion("entrust_file_name like", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameNotLike(String value) { + addCriterion("entrust_file_name not like", value, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameIn(List values) { + addCriterion("entrust_file_name in", values, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameNotIn(List values) { + addCriterion("entrust_file_name not in", values, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameBetween(String value1, String value2) { + addCriterion("entrust_file_name between", value1, value2, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFileNameNotBetween(String value1, String value2) { + addCriterion("entrust_file_name not between", value1, value2, "entrustFileName"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathIsNull() { + addCriterion("entrust_file_path is null"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathIsNotNull() { + addCriterion("entrust_file_path is not null"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathEqualTo(String value) { + addCriterion("entrust_file_path =", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathNotEqualTo(String value) { + addCriterion("entrust_file_path <>", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathGreaterThan(String value) { + addCriterion("entrust_file_path >", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathGreaterThanOrEqualTo(String value) { + addCriterion("entrust_file_path >=", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathLessThan(String value) { + addCriterion("entrust_file_path <", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathLessThanOrEqualTo(String value) { + addCriterion("entrust_file_path <=", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathLike(String value) { + addCriterion("entrust_file_path like", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathNotLike(String value) { + addCriterion("entrust_file_path not like", value, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathIn(List values) { + addCriterion("entrust_file_path in", values, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathNotIn(List values) { + addCriterion("entrust_file_path not in", values, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathBetween(String value1, String value2) { + addCriterion("entrust_file_path between", value1, value2, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andEntrustFilePathNotBetween(String value1, String value2) { + addCriterion("entrust_file_path not between", value1, value2, "entrustFilePath"); + return (Criteria) this; + } + + public Criteria andStatusIsNull() { + addCriterion("`status` is null"); + return (Criteria) this; + } + + public Criteria andStatusIsNotNull() { + addCriterion("`status` is not null"); + return (Criteria) this; + } + + public Criteria andStatusEqualTo(Integer value) { + addCriterion("`status` =", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotEqualTo(Integer value) { + addCriterion("`status` <>", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThan(Integer value) { + addCriterion("`status` >", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusGreaterThanOrEqualTo(Integer value) { + addCriterion("`status` >=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThan(Integer value) { + addCriterion("`status` <", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusLessThanOrEqualTo(Integer value) { + addCriterion("`status` <=", value, "status"); + return (Criteria) this; + } + + public Criteria andStatusIn(List values) { + addCriterion("`status` in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotIn(List values) { + addCriterion("`status` not in", values, "status"); + return (Criteria) this; + } + + public Criteria andStatusBetween(Integer value1, Integer value2) { + addCriterion("`status` between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andStatusNotBetween(Integer value1, Integer value2) { + addCriterion("`status` not between", value1, value2, "status"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNull() { + addCriterion("reject_reason is null"); + return (Criteria) this; + } + + public Criteria andRejectReasonIsNotNull() { + addCriterion("reject_reason is not null"); + return (Criteria) this; + } + + public Criteria andRejectReasonEqualTo(String value) { + addCriterion("reject_reason =", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotEqualTo(String value) { + addCriterion("reject_reason <>", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThan(String value) { + addCriterion("reject_reason >", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonGreaterThanOrEqualTo(String value) { + addCriterion("reject_reason >=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThan(String value) { + addCriterion("reject_reason <", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLessThanOrEqualTo(String value) { + addCriterion("reject_reason <=", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonLike(String value) { + addCriterion("reject_reason like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotLike(String value) { + addCriterion("reject_reason not like", value, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonIn(List values) { + addCriterion("reject_reason in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotIn(List values) { + addCriterion("reject_reason not in", values, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonBetween(String value1, String value2) { + addCriterion("reject_reason between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andRejectReasonNotBetween(String value1, String value2) { + addCriterion("reject_reason not between", value1, value2, "rejectReason"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNull() { + addCriterion("create_time is null"); + return (Criteria) this; + } + + public Criteria andCreateTimeIsNotNull() { + addCriterion("create_time is not null"); + return (Criteria) this; + } + + public Criteria andCreateTimeEqualTo(Date value) { + addCriterion("create_time =", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotEqualTo(Date value) { + addCriterion("create_time <>", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThan(Date value) { + addCriterion("create_time >", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("create_time >=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThan(Date value) { + addCriterion("create_time <", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeLessThanOrEqualTo(Date value) { + addCriterion("create_time <=", value, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeIn(List values) { + addCriterion("create_time in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotIn(List values) { + addCriterion("create_time not in", values, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeBetween(Date value1, Date value2) { + addCriterion("create_time between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andCreateTimeNotBetween(Date value1, Date value2) { + addCriterion("create_time not between", value1, value2, "createTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNull() { + addCriterion("update_time is null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIsNotNull() { + addCriterion("update_time is not null"); + return (Criteria) this; + } + + public Criteria andUpdateTimeEqualTo(Date value) { + addCriterion("update_time =", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotEqualTo(Date value) { + addCriterion("update_time <>", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThan(Date value) { + addCriterion("update_time >", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) { + addCriterion("update_time >=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThan(Date value) { + addCriterion("update_time <", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeLessThanOrEqualTo(Date value) { + addCriterion("update_time <=", value, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeIn(List values) { + addCriterion("update_time in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotIn(List values) { + addCriterion("update_time not in", values, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeBetween(Date value1, Date value2) { + addCriterion("update_time between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andUpdateTimeNotBetween(Date value1, Date value2) { + addCriterion("update_time not between", value1, value2, "updateTime"); + return (Criteria) this; + } + + public Criteria andExt1IsNull() { + addCriterion("ext_1 is null"); + return (Criteria) this; + } + + public Criteria andExt1IsNotNull() { + addCriterion("ext_1 is not null"); + return (Criteria) this; + } + + public Criteria andExt1EqualTo(String value) { + addCriterion("ext_1 =", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotEqualTo(String value) { + addCriterion("ext_1 <>", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThan(String value) { + addCriterion("ext_1 >", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1GreaterThanOrEqualTo(String value) { + addCriterion("ext_1 >=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThan(String value) { + addCriterion("ext_1 <", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1LessThanOrEqualTo(String value) { + addCriterion("ext_1 <=", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Like(String value) { + addCriterion("ext_1 like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotLike(String value) { + addCriterion("ext_1 not like", value, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1In(List values) { + addCriterion("ext_1 in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotIn(List values) { + addCriterion("ext_1 not in", values, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1Between(String value1, String value2) { + addCriterion("ext_1 between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt1NotBetween(String value1, String value2) { + addCriterion("ext_1 not between", value1, value2, "ext1"); + return (Criteria) this; + } + + public Criteria andExt2IsNull() { + addCriterion("ext_2 is null"); + return (Criteria) this; + } + + public Criteria andExt2IsNotNull() { + addCriterion("ext_2 is not null"); + return (Criteria) this; + } + + public Criteria andExt2EqualTo(String value) { + addCriterion("ext_2 =", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotEqualTo(String value) { + addCriterion("ext_2 <>", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThan(String value) { + addCriterion("ext_2 >", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2GreaterThanOrEqualTo(String value) { + addCriterion("ext_2 >=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThan(String value) { + addCriterion("ext_2 <", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2LessThanOrEqualTo(String value) { + addCriterion("ext_2 <=", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Like(String value) { + addCriterion("ext_2 like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotLike(String value) { + addCriterion("ext_2 not like", value, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2In(List values) { + addCriterion("ext_2 in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotIn(List values) { + addCriterion("ext_2 not in", values, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2Between(String value1, String value2) { + addCriterion("ext_2 between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt2NotBetween(String value1, String value2) { + addCriterion("ext_2 not between", value1, value2, "ext2"); + return (Criteria) this; + } + + public Criteria andExt3IsNull() { + addCriterion("ext_3 is null"); + return (Criteria) this; + } + + public Criteria andExt3IsNotNull() { + addCriterion("ext_3 is not null"); + return (Criteria) this; + } + + public Criteria andExt3EqualTo(String value) { + addCriterion("ext_3 =", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotEqualTo(String value) { + addCriterion("ext_3 <>", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThan(String value) { + addCriterion("ext_3 >", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3GreaterThanOrEqualTo(String value) { + addCriterion("ext_3 >=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThan(String value) { + addCriterion("ext_3 <", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3LessThanOrEqualTo(String value) { + addCriterion("ext_3 <=", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Like(String value) { + addCriterion("ext_3 like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotLike(String value) { + addCriterion("ext_3 not like", value, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3In(List values) { + addCriterion("ext_3 in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotIn(List values) { + addCriterion("ext_3 not in", values, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3Between(String value1, String value2) { + addCriterion("ext_3 between", value1, value2, "ext3"); + return (Criteria) this; + } + + public Criteria andExt3NotBetween(String value1, String value2) { + addCriterion("ext_3 not between", value1, value2, "ext3"); + return (Criteria) this; + } + } + + /** + */ + public static class Criteria extends GeneratedCriteria { + + protected Criteria() { + super(); + } + } + + public static class Criterion { + private String condition; + + private Object value; + + private Object secondValue; + + private boolean noValue; + + private boolean singleValue; + + private boolean betweenValue; + + private boolean listValue; + + private String typeHandler; + + public String getCondition() { + return condition; + } + + public Object getValue() { + return value; + } + + public Object getSecondValue() { + return secondValue; + } + + public boolean isNoValue() { + return noValue; + } + + public boolean isSingleValue() { + return singleValue; + } + + public boolean isBetweenValue() { + return betweenValue; + } + + public boolean isListValue() { + return listValue; + } + + public String getTypeHandler() { + return typeHandler; + } + + protected Criterion(String condition) { + super(); + this.condition = condition; + this.typeHandler = null; + this.noValue = true; + } + + protected Criterion(String condition, Object value, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.typeHandler = typeHandler; + if (value instanceof List) { + this.listValue = true; + } else { + this.singleValue = true; + } + } + + protected Criterion(String condition, Object value) { + this(condition, value, null); + } + + protected Criterion(String condition, Object value, Object secondValue, String typeHandler) { + super(); + this.condition = condition; + this.value = value; + this.secondValue = secondValue; + this.typeHandler = typeHandler; + this.betweenValue = true; + } + + protected Criterion(String condition, Object value, Object secondValue) { + this(condition, value, secondValue, null); + } + } +} \ No newline at end of file diff --git a/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharing.java b/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharing.java index 0327baf..40f83eb 100644 --- a/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharing.java +++ b/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharing.java @@ -19,6 +19,12 @@ public class BsTradeOrderProfitSharing implements Serializable { */ private Long id; + /** + * 指令类型 1:分账 2:分账撤销 +3:分账回退 + */ + private Integer cmdType; + /** * 交易id */ @@ -29,6 +35,11 @@ public class BsTradeOrderProfitSharing implements Serializable { */ private String tradeOrderNo; + /** + * 原分账单号 + */ + private String originProfitSharingOrderNo; + /** * 分账单号 */ @@ -70,7 +81,7 @@ public class BsTradeOrderProfitSharing implements Serializable { private BigDecimal profitSharingAmoun; /** - * 分账状态 0:未分账 1:已分账 2:已完成 + * 分账状态 0:未分账 1:已分账 2:处理中 3:已受理 4:分账失败 */ private Integer status; @@ -105,6 +116,14 @@ public class BsTradeOrderProfitSharing implements Serializable { this.id = id; } + public Integer getCmdType() { + return cmdType; + } + + public void setCmdType(Integer cmdType) { + this.cmdType = cmdType; + } + public Long getTradeOrderId() { return tradeOrderId; } @@ -121,6 +140,14 @@ public class BsTradeOrderProfitSharing implements Serializable { this.tradeOrderNo = tradeOrderNo; } + public String getOriginProfitSharingOrderNo() { + return originProfitSharingOrderNo; + } + + public void setOriginProfitSharingOrderNo(String originProfitSharingOrderNo) { + this.originProfitSharingOrderNo = originProfitSharingOrderNo; + } + public String getProfitSharingOrderNo() { return profitSharingOrderNo; } @@ -254,8 +281,10 @@ public class BsTradeOrderProfitSharing implements Serializable { } BsTradeOrderProfitSharing other = (BsTradeOrderProfitSharing) that; return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId())) + && (this.getCmdType() == null ? other.getCmdType() == null : this.getCmdType().equals(other.getCmdType())) && (this.getTradeOrderId() == null ? other.getTradeOrderId() == null : this.getTradeOrderId().equals(other.getTradeOrderId())) && (this.getTradeOrderNo() == null ? other.getTradeOrderNo() == null : this.getTradeOrderNo().equals(other.getTradeOrderNo())) + && (this.getOriginProfitSharingOrderNo() == null ? other.getOriginProfitSharingOrderNo() == null : this.getOriginProfitSharingOrderNo().equals(other.getOriginProfitSharingOrderNo())) && (this.getProfitSharingOrderNo() == null ? other.getProfitSharingOrderNo() == null : this.getProfitSharingOrderNo().equals(other.getProfitSharingOrderNo())) && (this.getPlatformType() == null ? other.getPlatformType() == null : this.getPlatformType().equals(other.getPlatformType())) && (this.getPlatformProfitSharingOrderNo() == null ? other.getPlatformProfitSharingOrderNo() == null : this.getPlatformProfitSharingOrderNo().equals(other.getPlatformProfitSharingOrderNo())) @@ -278,8 +307,10 @@ public class BsTradeOrderProfitSharing implements Serializable { final int prime = 31; int result = 1; result = prime * result + ((getId() == null) ? 0 : getId().hashCode()); + result = prime * result + ((getCmdType() == null) ? 0 : getCmdType().hashCode()); result = prime * result + ((getTradeOrderId() == null) ? 0 : getTradeOrderId().hashCode()); result = prime * result + ((getTradeOrderNo() == null) ? 0 : getTradeOrderNo().hashCode()); + result = prime * result + ((getOriginProfitSharingOrderNo() == null) ? 0 : getOriginProfitSharingOrderNo().hashCode()); result = prime * result + ((getProfitSharingOrderNo() == null) ? 0 : getProfitSharingOrderNo().hashCode()); result = prime * result + ((getPlatformType() == null) ? 0 : getPlatformType().hashCode()); result = prime * result + ((getPlatformProfitSharingOrderNo() == null) ? 0 : getPlatformProfitSharingOrderNo().hashCode()); @@ -305,8 +336,10 @@ public class BsTradeOrderProfitSharing implements Serializable { sb.append(" ["); sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id); + sb.append(", cmdType=").append(cmdType); sb.append(", tradeOrderId=").append(tradeOrderId); sb.append(", tradeOrderNo=").append(tradeOrderNo); + sb.append(", originProfitSharingOrderNo=").append(originProfitSharingOrderNo); sb.append(", profitSharingOrderNo=").append(profitSharingOrderNo); sb.append(", platformType=").append(platformType); sb.append(", platformProfitSharingOrderNo=").append(platformProfitSharingOrderNo); diff --git a/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharingExample.java b/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharingExample.java index 7df5521..3423091 100644 --- a/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharingExample.java +++ b/service/src/main/java/com/hfkj/entity/BsTradeOrderProfitSharingExample.java @@ -186,6 +186,66 @@ public class BsTradeOrderProfitSharingExample { return (Criteria) this; } + public Criteria andCmdTypeIsNull() { + addCriterion("cmd_type is null"); + return (Criteria) this; + } + + public Criteria andCmdTypeIsNotNull() { + addCriterion("cmd_type is not null"); + return (Criteria) this; + } + + public Criteria andCmdTypeEqualTo(Integer value) { + addCriterion("cmd_type =", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeNotEqualTo(Integer value) { + addCriterion("cmd_type <>", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeGreaterThan(Integer value) { + addCriterion("cmd_type >", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeGreaterThanOrEqualTo(Integer value) { + addCriterion("cmd_type >=", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeLessThan(Integer value) { + addCriterion("cmd_type <", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeLessThanOrEqualTo(Integer value) { + addCriterion("cmd_type <=", value, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeIn(List values) { + addCriterion("cmd_type in", values, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeNotIn(List values) { + addCriterion("cmd_type not in", values, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeBetween(Integer value1, Integer value2) { + addCriterion("cmd_type between", value1, value2, "cmdType"); + return (Criteria) this; + } + + public Criteria andCmdTypeNotBetween(Integer value1, Integer value2) { + addCriterion("cmd_type not between", value1, value2, "cmdType"); + return (Criteria) this; + } + public Criteria andTradeOrderIdIsNull() { addCriterion("trade_order_id is null"); return (Criteria) this; @@ -316,6 +376,76 @@ public class BsTradeOrderProfitSharingExample { return (Criteria) this; } + public Criteria andOriginProfitSharingOrderNoIsNull() { + addCriterion("origin_profit_sharing_order_no is null"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoIsNotNull() { + addCriterion("origin_profit_sharing_order_no is not null"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoEqualTo(String value) { + addCriterion("origin_profit_sharing_order_no =", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoNotEqualTo(String value) { + addCriterion("origin_profit_sharing_order_no <>", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoGreaterThan(String value) { + addCriterion("origin_profit_sharing_order_no >", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoGreaterThanOrEqualTo(String value) { + addCriterion("origin_profit_sharing_order_no >=", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoLessThan(String value) { + addCriterion("origin_profit_sharing_order_no <", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoLessThanOrEqualTo(String value) { + addCriterion("origin_profit_sharing_order_no <=", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoLike(String value) { + addCriterion("origin_profit_sharing_order_no like", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoNotLike(String value) { + addCriterion("origin_profit_sharing_order_no not like", value, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoIn(List values) { + addCriterion("origin_profit_sharing_order_no in", values, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoNotIn(List values) { + addCriterion("origin_profit_sharing_order_no not in", values, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoBetween(String value1, String value2) { + addCriterion("origin_profit_sharing_order_no between", value1, value2, "originProfitSharingOrderNo"); + return (Criteria) this; + } + + public Criteria andOriginProfitSharingOrderNoNotBetween(String value1, String value2) { + addCriterion("origin_profit_sharing_order_no not between", value1, value2, "originProfitSharingOrderNo"); + return (Criteria) this; + } + public Criteria andProfitSharingOrderNoIsNull() { addCriterion("profit_sharing_order_no is null"); return (Criteria) this; diff --git a/service/src/main/java/com/hfkj/service/BsMerLedgerApplyService.java b/service/src/main/java/com/hfkj/service/BsMerLedgerApplyService.java new file mode 100644 index 0000000..99defe3 --- /dev/null +++ b/service/src/main/java/com/hfkj/service/BsMerLedgerApplyService.java @@ -0,0 +1,31 @@ +package com.hfkj.service; + +import com.hfkj.entity.BsMerLedgerApply; + +/** + * @className: BsMerLedgerApplyService + * @author: HuRui + * @date: 2023/4/18 + **/ +public interface BsMerLedgerApplyService { + + /** + * 编辑商户分账申请记录 + * @param merLedgerApply + */ + void editMerLedgerApply(BsMerLedgerApply merLedgerApply); + + /** + * 获取商户分账申请记录 + * @param orderNo + * @return + */ + BsMerLedgerApply getApplyByOrderNo(String orderNo); + + /** + * 获取商户分账申请记录 + * @param applyId + * @return + */ + BsMerLedgerApply getApplyByApplyId(String applyId); +} diff --git a/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverApplyService.java b/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverApplyService.java new file mode 100644 index 0000000..5e6abb5 --- /dev/null +++ b/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverApplyService.java @@ -0,0 +1,24 @@ +package com.hfkj.service; + +import com.hfkj.entity.BsMerLedgerReceiverApply; + +/** + * @className: BsMerLedgerReceiverApplyService + * @author: HuRui + * @date: 2023/4/19 + **/ +public interface BsMerLedgerReceiverApplyService { + + /** + * 编辑接收方申请 + * @param merLedgerReceiverApply + */ + void editReceiverApply(BsMerLedgerReceiverApply merLedgerReceiverApply); + + /** + * 根据受理编号查询 + * @param applyId + * @return + */ + BsMerLedgerReceiverApply getReceiverApplyByApplyId(String applyId); +} diff --git a/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverService.java b/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverService.java new file mode 100644 index 0000000..5c9dd6a --- /dev/null +++ b/service/src/main/java/com/hfkj/service/BsMerLedgerReceiverService.java @@ -0,0 +1,55 @@ +package com.hfkj.service; + +import com.hfkj.entity.BsMerLedgerReceiver; +import com.hfkj.sysenum.PlatformTypeEnum; + +import java.util.List; +import java.util.Map; + +/** + * @className: BsMerLedgerReceiverService + * @author: HuRui + * @date: 2023/4/19 + **/ +public interface BsMerLedgerReceiverService { + + /** + * 编辑分账接收方 + * @param merLedgerReceiver + */ + void editMerLedgerReceiver(BsMerLedgerReceiver merLedgerReceiver); + + /** + * 商户分账接收方申请 + * @param merLedgerReceiver + */ + void merLedgerReceiverApply(BsMerLedgerReceiver merLedgerReceiver); + + /** + * 商户分账接收方申请 + * @param merLedgerReceiver + */ + void merLedgerReceiverDel(BsMerLedgerReceiver merLedgerReceiver); + + /** + * 查询分账接收方详情 + * @param merId + * @param receiverNo + * @return + */ + BsMerLedgerReceiver getMerLedgerReceiver(Long merId,String receiverNo); + + /** + * 查询商户的接收方 + * @param merId + * @return + */ + List getMerLedgerReceiverByMer(Long merId, PlatformTypeEnum platformType); + + /** + * 查询分账接收方列表 + * @param param + * @return + */ + List getMerLedgerReceiverList(Map param); +} diff --git a/service/src/main/java/com/hfkj/service/BsMerLedgerService.java b/service/src/main/java/com/hfkj/service/BsMerLedgerService.java new file mode 100644 index 0000000..9852914 --- /dev/null +++ b/service/src/main/java/com/hfkj/service/BsMerLedgerService.java @@ -0,0 +1,41 @@ +package com.hfkj.service; + +import com.hfkj.entity.BsMerLedger; +import com.hfkj.sysenum.PlatformTypeEnum; + +/** + * @className: BsMerLedgerService + * @author: HuRui + * @date: 2023/4/18 + **/ +public interface BsMerLedgerService { + + /** + * 编辑商户分账信息 + * @param merLedger + */ + void editMerLedger(BsMerLedger merLedger); + + /** + * 商户分账功能申请 + * @param merLedger + */ + void merLedgerApply(BsMerLedger merLedger); + + /** + * 查询商户分账信息 + * @param merId + * @param platformType + * @return + */ + BsMerLedger getMerLedger(Long merId, PlatformTypeEnum platformType); + + /** + * 查询商户分账信息 + * @param id + * @return + */ + BsMerLedger getMerLedgerById(Long id); + + +} diff --git a/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingReceiverService.java b/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingReceiverService.java index 95b6f20..46f74c2 100644 --- a/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingReceiverService.java +++ b/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingReceiverService.java @@ -19,6 +19,13 @@ public interface BsTradeOrderProfitSharingReceiverService { */ void editData(BsTradeOrderProfitSharingReceiver profitSharingReceiver); + /** + * 根据分账记录,查询接收方 + * @param profitSharingId + * @return + */ + List getReceiverListByProfitSharingId(Long profitSharingId); + /** * 查询分账列表 * @param param diff --git a/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingService.java b/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingService.java index 4b0a5ee..4c9ab6a 100644 --- a/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingService.java +++ b/service/src/main/java/com/hfkj/service/BsTradeOrderProfitSharingService.java @@ -25,6 +25,13 @@ public interface BsTradeOrderProfitSharingService { */ void createProfitSharing(BsTradeOrder tradeOrder); + /** + * 根据分账单号 查询详情 + * @param profitSharingOrderNo + * @return + */ + BsTradeOrderProfitSharing getDetailByProfitSharingOrderNo(String profitSharingOrderNo); + /** * 获取需要分账的订单 * @return diff --git a/service/src/main/java/com/hfkj/service/impl/BsMerLedgerApplyServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerApplyServiceImpl.java new file mode 100644 index 0000000..6a97cbe --- /dev/null +++ b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerApplyServiceImpl.java @@ -0,0 +1,53 @@ +package com.hfkj.service.impl; + +import com.hfkj.dao.BsMerLedgerApplyMapper; +import com.hfkj.dao.BsMerLedgerMapper; +import com.hfkj.entity.BsMerLedgerApply; +import com.hfkj.entity.BsMerLedgerApplyExample; +import com.hfkj.service.BsMerLedgerApplyService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.Date; +import java.util.List; + +/** + * @className: BsMerLedgerApplyServiceImpl + * @author: HuRui + * @date: 2023/4/18 + **/ +@Service("merLedgerApplyService") +public class BsMerLedgerApplyServiceImpl implements BsMerLedgerApplyService { + + @Resource + private BsMerLedgerApplyMapper merLedgerApplyMapper; + + @Override + public void editMerLedgerApply(BsMerLedgerApply merLedgerApply) { + if (merLedgerApply.getId() == null) { + merLedgerApply.setStatus(1); + merLedgerApply.setCreateTime(new Date()); + merLedgerApply.setUpdateTime(new Date()); + merLedgerApplyMapper.insert(merLedgerApply); + } else { + merLedgerApply.setUpdateTime(new Date()); + merLedgerApplyMapper.updateByPrimaryKey(merLedgerApply); + } + } + + @Override + public BsMerLedgerApply getApplyByOrderNo(String orderNo) { + return null; + } + + @Override + public BsMerLedgerApply getApplyByApplyId(String applyId) { + BsMerLedgerApplyExample example = new BsMerLedgerApplyExample(); + example.createCriteria().andApplyIdEqualTo(applyId).andStatusNotEqualTo(0); + List list = merLedgerApplyMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } +} diff --git a/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverApplyServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverApplyServiceImpl.java new file mode 100644 index 0000000..3e2369b --- /dev/null +++ b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverApplyServiceImpl.java @@ -0,0 +1,46 @@ +package com.hfkj.service.impl; + +import com.hfkj.dao.BsMerLedgerReceiverApplyMapper; +import com.hfkj.entity.BsMerLedgerReceiverApply; +import com.hfkj.entity.BsMerLedgerReceiverApplyExample; +import com.hfkj.service.BsMerLedgerReceiverApplyService; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.Date; +import java.util.List; + +/** + * @className: BsMerLedgerReceiverApplyServiceImpl + * @author: HuRui + * @date: 2023/4/19 + **/ +@Service("merLedgerReceiverApplyService") +public class BsMerLedgerReceiverApplyServiceImpl implements BsMerLedgerReceiverApplyService { + + @Resource + private BsMerLedgerReceiverApplyMapper merLedgerReceiverApplyMapper; + + @Override + public void editReceiverApply(BsMerLedgerReceiverApply merLedgerReceiverApply) { + if (merLedgerReceiverApply.getId() == null) { + merLedgerReceiverApply.setUpdateTime(new Date()); + merLedgerReceiverApply.setCreateTime(new Date()); + merLedgerReceiverApplyMapper.insert(merLedgerReceiverApply); + } else { + merLedgerReceiverApply.setUpdateTime(new Date()); + merLedgerReceiverApplyMapper.updateByPrimaryKey(merLedgerReceiverApply); + } + } + + @Override + public BsMerLedgerReceiverApply getReceiverApplyByApplyId(String applyId) { + BsMerLedgerReceiverApplyExample example = new BsMerLedgerReceiverApplyExample(); + example.createCriteria().andApplyIdEqualTo(applyId); + List list = merLedgerReceiverApplyMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } +} diff --git a/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverServiceImpl.java new file mode 100644 index 0000000..0634600 --- /dev/null +++ b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerReceiverServiceImpl.java @@ -0,0 +1,104 @@ +package com.hfkj.service.impl; + +import com.hfkj.channel.lakala.LaKaLaLedgerService; +import com.hfkj.channel.lakala.LaKaLaMerService; +import com.hfkj.dao.BsMerLedgerReceiverMapper; +import com.hfkj.entity.BsMerLedgerReceiver; +import com.hfkj.entity.BsMerLedgerReceiverExample; +import com.hfkj.service.BsMerLedgerReceiverService; +import com.hfkj.sysenum.MerLedgerReceiverStatusEnum; +import com.hfkj.sysenum.PlatformTypeEnum; +import org.apache.commons.collections4.MapUtils; +import org.apache.commons.lang3.StringUtils; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.Date; +import java.util.List; +import java.util.Map; + +/** + * @className: BsMerLedgerReceiverServiceImpl + * @author: HuRui + * @date: 2023/4/19 + **/ +@Service("merLedgerReceiverService") +public class BsMerLedgerReceiverServiceImpl implements BsMerLedgerReceiverService { + + @Resource + private BsMerLedgerReceiverMapper merLedgerReceiverMapper; + + @Resource + private LaKaLaLedgerService laKaLaLedgerService; + + @Override + public void editMerLedgerReceiver(BsMerLedgerReceiver merLedgerReceiver) { + if (merLedgerReceiver.getId() == null) { + merLedgerReceiver.setCreateTime(new Date()); + merLedgerReceiver.setUpdateTime(new Date()); + merLedgerReceiverMapper.insert(merLedgerReceiver); + } else { + merLedgerReceiver.setUpdateTime(new Date()); + merLedgerReceiverMapper.updateByPrimaryKey(merLedgerReceiver); + } + } + + @Override + public void merLedgerReceiverApply(BsMerLedgerReceiver merLedgerReceiver) { + editMerLedgerReceiver(merLedgerReceiver); + + if (merLedgerReceiver.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + laKaLaLedgerService.applyBind(merLedgerReceiver.getMerId(), merLedgerReceiver.getReceiverNo()); + } + } + + @Override + public void merLedgerReceiverDel(BsMerLedgerReceiver merLedgerReceiver) { + editMerLedgerReceiver(merLedgerReceiver); + + if (merLedgerReceiver.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + laKaLaLedgerService.applyUnBind(merLedgerReceiver.getMerId(), merLedgerReceiver.getReceiverNo()); + } + } + + @Override + public BsMerLedgerReceiver getMerLedgerReceiver(Long merId, String receiverNo) { + BsMerLedgerReceiverExample example = new BsMerLedgerReceiverExample(); + example.createCriteria().andMerIdEqualTo(merId).andReceiverNoEqualTo(receiverNo).andStatusNotEqualTo(0); + List list = merLedgerReceiverMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } + + @Override + public List getMerLedgerReceiverByMer(Long merId, PlatformTypeEnum platformType) { + BsMerLedgerReceiverExample example = new BsMerLedgerReceiverExample(); + example.createCriteria().andMerIdEqualTo(merId).andStatusNotEqualTo(0).andPlatformTypeEqualTo(platformType.getNumber()); + return merLedgerReceiverMapper.selectByExample(example); + } + + @Override + public List getMerLedgerReceiverList(Map param) { + BsMerLedgerReceiverExample example = new BsMerLedgerReceiverExample(); + BsMerLedgerReceiverExample.Criteria criteria = example.createCriteria() + .andStatusNotEqualTo(MerLedgerReceiverStatusEnum.status0.getNumber()); + + if (MapUtils.getInteger(param, "platformType") != null) { + criteria.andPlatformTypeEqualTo(MapUtils.getInteger(param, "platformType")); + } + + if (MapUtils.getInteger(param, "status") != null) { + criteria.andStatusEqualTo(MapUtils.getInteger(param, "status")); + } + + if (MapUtils.getBoolean(param, "receiverNoNotNull") != null) { + criteria.andReceiverNoIsNotNull(); + } + + example.setOrderByClause("create_time desc"); + return merLedgerReceiverMapper.selectByExample(example); + } + +} diff --git a/service/src/main/java/com/hfkj/service/impl/BsMerLedgerServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerServiceImpl.java new file mode 100644 index 0000000..c689a6e --- /dev/null +++ b/service/src/main/java/com/hfkj/service/impl/BsMerLedgerServiceImpl.java @@ -0,0 +1,68 @@ +package com.hfkj.service.impl; + +import com.hfkj.channel.lakala.LaKaLaLedgerService; +import com.hfkj.dao.BsMerLedgerMapper; +import com.hfkj.entity.BsMerLedger; +import com.hfkj.entity.BsMerLedgerExample; +import com.hfkj.service.BsMerLedgerService; +import com.hfkj.sysenum.PlatformTypeEnum; +import org.springframework.stereotype.Service; + +import javax.annotation.Resource; +import java.util.Date; +import java.util.List; + +/** + * @className: BsMerLedgerServiceImpl + * @author: HuRui + * @date: 2023/4/18 + **/ +@Service("merLedgerService") +public class BsMerLedgerServiceImpl implements BsMerLedgerService { + + @Resource + private BsMerLedgerMapper merLedgerMapper; + + @Resource + private LaKaLaLedgerService laKaLaLedgerService; + + @Override + public void editMerLedger(BsMerLedger merLedger) { + if (merLedger.getId() == null) { + merLedger.setCreateTime(new Date()); + merLedger.setUpdateTime(new Date()); + merLedgerMapper.insert(merLedger); + } else { + merLedger.setUpdateTime(new Date()); + merLedgerMapper.updateByPrimaryKey(merLedger); + } + } + + @Override + public void merLedgerApply(BsMerLedger merLedger) { + editMerLedger(merLedger); + + if (merLedger.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + laKaLaLedgerService.applyLedger(merLedger.getId()); + } + } + + @Override + public BsMerLedger getMerLedger(Long merId, PlatformTypeEnum platformType) { + BsMerLedgerExample example = new BsMerLedgerExample(); + example.createCriteria() + .andMerIdEqualTo(merId) + .andStatusNotEqualTo(0) + .andPlatformTypeEqualTo(platformType.getNumber()); + List list = merLedgerMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } + + @Override + public BsMerLedger getMerLedgerById(Long id) { + return merLedgerMapper.selectByPrimaryKey(id); + } +} diff --git a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingReceiverServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingReceiverServiceImpl.java index ac910e6..d09c233 100644 --- a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingReceiverServiceImpl.java +++ b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingReceiverServiceImpl.java @@ -37,6 +37,13 @@ public class BsTradeOrderProfitSharingReceiverServiceImpl implements BsTradeOrde } } + @Override + public List getReceiverListByProfitSharingId(Long profitSharingId) { + BsTradeOrderProfitSharingReceiverExample example = new BsTradeOrderProfitSharingReceiverExample(); + example.createCriteria().andTradeOrderProfitSharingIdEqualTo(profitSharingId); + return tradeOrderProfitSharingReceiverMapper.selectByExample(example); + } + @Override public List getProfitSharingList(Map param) { BsTradeOrderProfitSharingReceiverExample example = new BsTradeOrderProfitSharingReceiverExample(); diff --git a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingServiceImpl.java b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingServiceImpl.java index 7eca0f1..0210a67 100644 --- a/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingServiceImpl.java +++ b/service/src/main/java/com/hfkj/service/impl/BsTradeOrderProfitSharingServiceImpl.java @@ -8,10 +8,7 @@ import com.hfkj.common.utils.IDGenerator; import com.hfkj.dao.BsTradeOrderProfitSharingMapper; import com.hfkj.entity.*; import com.hfkj.service.*; -import com.hfkj.sysenum.PlatformTypeEnum; -import com.hfkj.sysenum.ProfitSharingReceiverObjectType; -import com.hfkj.sysenum.ProfitSharingReceiverRoleEnum; -import com.hfkj.sysenum.StoreDiscountActivityTypeEnum; +import com.hfkj.sysenum.*; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Propagation; import org.springframework.transaction.annotation.Transactional; @@ -48,7 +45,6 @@ public class BsTradeOrderProfitSharingServiceImpl implements BsTradeOrderProfitS public void editData(BsTradeOrderProfitSharing profitSharing) { if (profitSharing.getId() == null) { profitSharing.setCreateTime(new Date()); - profitSharing.setStatus(0); tradeOrderProfitSharingMapper.insert(profitSharing); } else { tradeOrderProfitSharingMapper.updateByPrimaryKeySelective(profitSharing); @@ -59,13 +55,8 @@ public class BsTradeOrderProfitSharingServiceImpl implements BsTradeOrderProfitS @Transactional(propagation= Propagation.REQUIRES_NEW) public void createProfitSharing(BsTradeOrder tradeOrder) { if (tradeOrder.getProfitSharingStatus() != null && tradeOrder.getProfitSharingStatus().equals(true)) { - // 比例 - BsMerPlatformNoRate rate = merPlatformNoRateService.getDetail(tradeOrder.getMerId(), PlatformTypeEnum.type4.getNumber(), null); - if (rate == null) { - throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未配置比例"); - } - BsTradeOrderProfitSharing tradeOrderProfitSharing = new BsTradeOrderProfitSharing(); + tradeOrderProfitSharing.setCmdType(ProfitSharingCmdTypeEnum.CMD_TYPE_1.getNumber()); tradeOrderProfitSharing.setProfitSharingOrderNo("1530"+ DateUtil.format(new Date(), DateUtil.YMDHMS) + IDGenerator.nextId(10)); tradeOrderProfitSharing.setTradeOrderId(tradeOrder.getId()); tradeOrderProfitSharing.setTradeOrderNo(tradeOrder.getOutTradeNo()); @@ -73,16 +64,26 @@ public class BsTradeOrderProfitSharingServiceImpl implements BsTradeOrderProfitS tradeOrderProfitSharing.setPlatformMerNo(tradeOrder.getPlatformMerNo()); tradeOrderProfitSharing.setPlatformTradeNo(tradeOrder.getPlatformTradeNo()); tradeOrderProfitSharing.setPlatformAppid(tradeOrder.getPlatformAppid()); + tradeOrderProfitSharing.setStatus(ProfitSharingStatusEnum.status0.getNumber()); editData(tradeOrderProfitSharing); + // 比例 + BsMerPlatformNoRate rate = merPlatformNoRateService.getDetail(tradeOrder.getMerId(), PlatformTypeEnum.getDataByNumber(tradeOrder.getPlatformType()).getNumber(), null); + if (rate == null) { + throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未配置比例"); + } + // 渠道平台手续费 BigDecimal platformServiceCharge = null; - if (tradeOrder.getPlatformType().equals(PlatformTypeEnum.type4.getNumber())) { + if (tradeOrder.getPlatformType().equals(PlatformTypeEnum.type1.getNumber())) { + platformServiceCharge = new BigDecimal("0.002"); + } else if (tradeOrder.getPlatformType().equals(PlatformTypeEnum.type4.getNumber())) { platformServiceCharge = new BigDecimal("0.002"); } // 交易金额 * 渠道平台收取手续费率 = 渠道平台手续费 (四舍五入向上取取整) BigDecimal platformServiceChargeAmount = tradeOrder.getTradeActualAmount().multiply(platformServiceCharge).setScale(2, BigDecimal.ROUND_HALF_DOWN); + // 自建平台手续费 BigDecimal platformServiceAmount = tradeOrder.getTradeAmount().multiply(rate.getRatePct()).setScale(2, BigDecimal.ROUND_HALF_DOWN); @@ -387,6 +388,17 @@ public class BsTradeOrderProfitSharingServiceImpl implements BsTradeOrderProfitS } } + @Override + public BsTradeOrderProfitSharing getDetailByProfitSharingOrderNo(String profitSharingOrderNo) { + BsTradeOrderProfitSharingExample example = new BsTradeOrderProfitSharingExample(); + example.createCriteria().andProfitSharingOrderNoEqualTo(profitSharingOrderNo); + List list = tradeOrderProfitSharingMapper.selectByExample(example); + if (list.size() > 0) { + return list.get(0); + } + return null; + } + @Override public List getNeedProfitSharingOrder() { return tradeOrderProfitSharingMapper.getNeedProfitSharingOrder(); diff --git a/service/src/main/java/com/hfkj/sysenum/DeviceOrderTypeEnum.java b/service/src/main/java/com/hfkj/sysenum/DeviceOrderTypeEnum.java index f166bcf..7d523f3 100644 --- a/service/src/main/java/com/hfkj/sysenum/DeviceOrderTypeEnum.java +++ b/service/src/main/java/com/hfkj/sysenum/DeviceOrderTypeEnum.java @@ -8,7 +8,7 @@ import java.util.Objects; */ public enum DeviceOrderTypeEnum { type1(1, "押金"), - type2(1, "购买"), + type2(2, "购买"), ; private Integer number; diff --git a/service/src/main/java/com/hfkj/sysenum/MerAttachType.java b/service/src/main/java/com/hfkj/sysenum/MerAttachType.java index 1360b68..7d26060 100644 --- a/service/src/main/java/com/hfkj/sysenum/MerAttachType.java +++ b/service/src/main/java/com/hfkj/sysenum/MerAttachType.java @@ -8,31 +8,33 @@ import java.util.Objects; */ public enum MerAttachType { - type1(1, "营业执照", "BUSINESS_LICENCE"), - type2(2, "法人身份证正面", "ID_CARD_FRONT"), - type3(3, "法人身份证反面", "ID_CARD_BEHIND"), - type4(4, "场所门头照片", "SHOP_OUTSIDE_IMG"), - type5(5, "场所内部照片", "SHOP_INSIDE_IMG"), - type6(6, "场所收银台照片", "CHECKSTAND_IMG"), - type7(7, "银行卡照片", "BANK_CARD"), - type8(8, "开户许可证", "OPENING_PERMIT"), - type9(9, "结算人身份证人像面", "SETTLE_ID_CARD_FRONT"), - type10(10, "结算人身份证国徽面", "SETTLE_ID_CARD_BEHIND"), - type11(11, "协议", "AGREE_MENT"), - type12(12, "法人授权涵", "LETTER_OF_AUTHORIZATION"), - type99(99, "补充资料", "OTHERS"), + type1(1, "营业执照", "BUSINESS_LICENCE", "BUSINESS_LICENCE"), + type2(2, "法人身份证正面", "ID_CARD_FRONT", "FR_ID_CARD_FRONT"), + type3(3, "法人身份证反面", "ID_CARD_BEHIND", "FR_ID_CARD_BEHIND"), + type4(4, "场所门头照片", "SHOP_OUTSIDE_IMG", "MERCHANT_PHOTO"), + type5(5, "场所内部照片", "SHOP_INSIDE_IMG", "SHOPINNER"), + type6(6, "场所收银台照片", "CHECKSTAND_IMG", ""), + type7(7, "银行卡照片", "BANK_CARD", "BANK_CARD"), + type8(8, "开户许可证", "OPENING_PERMIT",""), + type9(9, "结算人身份证人像面", "SETTLE_ID_CARD_FRONT",""), + type10(10, "结算人身份证国徽面", "SETTLE_ID_CARD_BEHIND",""), + type11(11, "协议", "AGREE_MENT",""), + type12(12, "法人授权涵", "LETTER_OF_AUTHORIZATION",""), + type99(99, "补充资料", "OTHERS","OTHERS"), ; private Integer number; private String name; - private String lakalaCode; + private String lklSaasCode; + private String lklCode; - MerAttachType(int number, String name, String lakalaCode) { + MerAttachType(int number, String name, String lklSaasCode, String lklCode) { this.number = number; this.name = name; - this.lakalaCode = lakalaCode; + this.lklSaasCode = lklSaasCode; + this.lklCode = lklCode; } public static MerAttachType getDataByNumber(Integer number) { @@ -60,11 +62,19 @@ public enum MerAttachType { this.name = name; } - public String getLakalaCode() { - return lakalaCode; + public String getLklSaasCode() { + return lklSaasCode; } - public void setLakalaCode(String lakalaCode) { - this.lakalaCode = lakalaCode; + public void setLklSaasCode(String lklSaasCode) { + this.lklSaasCode = lklSaasCode; + } + + public String getLklCode() { + return lklCode; + } + + public void setLklCode(String lklCode) { + this.lklCode = lklCode; } } diff --git a/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverApplyStatusEnum.java b/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverApplyStatusEnum.java new file mode 100644 index 0000000..d23af54 --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverApplyStatusEnum.java @@ -0,0 +1,52 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum MerLedgerReceiverApplyStatusEnum { + status0(0, "不可用"), + status1(1, "审核中"), + status2(2, "通过"), + status3(3, "驳回"), + ; + + private Integer number; + + private String name; + + + MerLedgerReceiverApplyStatusEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static MerLedgerReceiverApplyStatusEnum getDataByNumber(Integer number) { + for (MerLedgerReceiverApplyStatusEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverStatusEnum.java b/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverStatusEnum.java new file mode 100644 index 0000000..6cdabb5 --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/MerLedgerReceiverStatusEnum.java @@ -0,0 +1,52 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum MerLedgerReceiverStatusEnum { + status0(0, "不可用"), + status1(1, "可用"), + status2(2, "审核中"), + status3(3, "审核驳回"), + ; + + private Integer number; + + private String name; + + + MerLedgerReceiverStatusEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static MerLedgerReceiverStatusEnum getDataByNumber(Integer number) { + for (MerLedgerReceiverStatusEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/java/com/hfkj/sysenum/MerLedgerStatusEnum.java b/service/src/main/java/com/hfkj/sysenum/MerLedgerStatusEnum.java new file mode 100644 index 0000000..00b1d07 --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/MerLedgerStatusEnum.java @@ -0,0 +1,52 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum MerLedgerStatusEnum { + status0(0, "不可用"), + status1(1, "可用"), + status2(2, "审核中"), + status3(3, "审核驳回"), + ; + + private Integer number; + + private String name; + + + MerLedgerStatusEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static MerLedgerStatusEnum getDataByNumber(Integer number) { + for (MerLedgerStatusEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/java/com/hfkj/sysenum/ProfitSharingCmdTypeEnum.java b/service/src/main/java/com/hfkj/sysenum/ProfitSharingCmdTypeEnum.java new file mode 100644 index 0000000..ce46a6d --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/ProfitSharingCmdTypeEnum.java @@ -0,0 +1,52 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * 分账指令类型 + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum ProfitSharingCmdTypeEnum { + CMD_TYPE_1(1, "分账"), + CMD_TYPE_2(2, "分账撤销"), + CMD_TYPE_3(3, "分账回退"), + ; + + private Integer number; + + private String name; + + + ProfitSharingCmdTypeEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static ProfitSharingCmdTypeEnum getDataByNumber(Integer number) { + for (ProfitSharingCmdTypeEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/java/com/hfkj/sysenum/ProfitSharingReceiverStatusEnum.java b/service/src/main/java/com/hfkj/sysenum/ProfitSharingReceiverStatusEnum.java new file mode 100644 index 0000000..1eeae40 --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/ProfitSharingReceiverStatusEnum.java @@ -0,0 +1,50 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum ProfitSharingReceiverStatusEnum { + status0(0, "待分账"), + status1(1, "已分账"), + ; + + private Integer number; + + private String name; + + + ProfitSharingReceiverStatusEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static ProfitSharingReceiverStatusEnum getDataByNumber(Integer number) { + for (ProfitSharingReceiverStatusEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/java/com/hfkj/sysenum/ProfitSharingStatusEnum.java b/service/src/main/java/com/hfkj/sysenum/ProfitSharingStatusEnum.java new file mode 100644 index 0000000..7dc66cb --- /dev/null +++ b/service/src/main/java/com/hfkj/sysenum/ProfitSharingStatusEnum.java @@ -0,0 +1,53 @@ +package com.hfkj.sysenum; + +import java.util.Objects; + +/** + * @className: MerLedgerStatusEnum + * @author: HuRui + * @date: 2023/4/18 + **/ +public enum ProfitSharingStatusEnum { + status0(0, "待处理"), + status1(1, "已完成"), + status2(2, "处理中"), + status3(3, "已受理"), + status4(4, "失败"), + ; + + private Integer number; + + private String name; + + + ProfitSharingStatusEnum(int number, String name) { + this.number = number; + this.name = name; + } + + public static ProfitSharingStatusEnum getDataByNumber(Integer number) { + for (ProfitSharingStatusEnum ele : values()) { + if (Objects.equals(number,ele.getNumber())) { + return ele; + } + } + return null; + } + + public Integer getNumber() { + return number; + } + + public void setNumber(Integer number) { + this.number = number; + } + + public String getName() { + return name; + } + + public void setName(String name) { + this.name = name; + } + +} diff --git a/service/src/main/resources/dev/commonConfig.properties b/service/src/main/resources/dev/commonConfig.properties index 97c3a42..61614cb 100644 --- a/service/src/main/resources/dev/commonConfig.properties +++ b/service/src/main/resources/dev/commonConfig.properties @@ -36,6 +36,5 @@ wechat_pay_notify_url=https://gratia-pay.dctpay.com/crest/weiXinNotify/jsapiPay file_url=/home/project/gratia-pay/file filesystem=/home/project/gratia-pay/filesystem - +domainName=https://gratia-pay.dctpay.com hsg_domain_name=https://hsgcs.dctpay.com/ - diff --git a/service/src/main/resources/prod/commonConfig.properties b/service/src/main/resources/prod/commonConfig.properties index b0cafd2..e249998 100644 --- a/service/src/main/resources/prod/commonConfig.properties +++ b/service/src/main/resources/prod/commonConfig.properties @@ -33,5 +33,5 @@ wechat_pay_notify_url=https://pay.dctpay.com/crest/weiXinNotify/jsapiPay file_url=/home/project/gratia-pay/file filesystem=/home/project/gratia-pay/filesystem - +domainName=https://pay.dctpay.com hsg_domain_name=https://hsg.dctpay.com/