Sfoglia il codice sorgente

Merge commit 'ea9ce6878020b75d4ecf0d998c7e543336bf9b26' into release

release_toaliyun_real
luozukai 6 anni fa
parent
commit
934bf0ff4b
13 ha cambiato i file con 379 aggiunte e 21 eliminazioni
  1. +23
    -1
      mallinkAdmin/src/main/java/com/iformall/controller/sys/WxBusinessController.java
  2. +33
    -0
      mallinkAdmin/src/main/resources/db/migration/V201907111416__L_ADD_FLOW_DATA.sql
  3. +2
    -0
      mallinkAdmin/src/main/resources/db/migration/V201907111418__CHANGE_WX_MSG_LIMIT.sql
  4. +2
    -0
      mallinkAdmin/src/main/resources/db/migration/V201907111507__CHANGE_WX_MSG_LIMIT.sql
  5. +1
    -1
      mallinkService/src/main/java/com/iformall/domain/po/WxActivityJoin.java
  6. +2
    -2
      mallinkService/src/main/java/com/iformall/enums/EnumMsgLimitType.java
  7. +3
    -0
      mallinkService/src/main/java/com/iformall/mapper/WxCardSpendMapper.java
  8. +2
    -0
      mallinkService/src/main/java/com/iformall/mapper/WxCouponOrderMapper.java
  9. +36
    -8
      mallinkService/src/main/java/com/iformall/service/impl/WxCUserTagsServiceImpl.java
  10. +8
    -8
      mallinkService/src/main/resources/mapper/WxBusinessMapper.xml
  11. +88
    -0
      mallinkService/src/main/resources/mapper/WxCardSpendMapper.xml
  12. +178
    -0
      mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml
  13. +1
    -1
      mallinkService/src/main/resources/mapper/WxMsgLimitMapper.xml

+ 23
- 1
mallinkAdmin/src/main/java/com/iformall/controller/sys/WxBusinessController.java Vedi File

@@ -121,11 +121,33 @@ public class WxBusinessController extends BaseController {
if(m.get("volume") != null) {
//单位转万
BigDecimal b = (BigDecimal)m.get("volume");
String dstr = b.divide(new BigDecimal(10000)).setScale(2, BigDecimal.ROUND_HALF_UP).toString();
String dstr = b.divide(new BigDecimal(10000)).setScale(4, BigDecimal.ROUND_HALF_UP).toString();
businessDataVo.setSale(dstr);
}
if(m.get("sale") != null)
businessDataVo.setSaleRate(m.get("sale").toString());

if(m.get("rent") == null){
m.put("rent",0);
}
if(m.get("sale") == null){
m.put("sale",0);
m.put("rentSaleRate",0);
businessDataVo.setRentSaleRate("0");
exeList.add(businessDataVo);
continue;
}
BigDecimal sale = new BigDecimal(m.get("sale").toString());
BigDecimal rent = new BigDecimal(m.get("rent").toString());
if(sale.doubleValue() <= 0){
businessDataVo.setRentSaleRate("0");
exeList.add(businessDataVo);
continue;
}else {
BigDecimal divide = rent.divide(sale, 2, BigDecimal.ROUND_HALF_UP);
m.put("rentSaleRate", divide);
businessDataVo.setRentSaleRate(divide.toString());
}
exeList.add(businessDataVo);
}
excelService.exportExcel(exeList, null, "业态统计", WxBusinessDataVo.class, "业态统计列表.xlsx", response, false);


+ 33
- 0
mallinkAdmin/src/main/resources/db/migration/V201907111416__L_ADD_FLOW_DATA.sql Vedi File

@@ -0,0 +1,33 @@
delete from wx_msg_validationcode_model where tenant_id = 790;
INSERT INTO `wx_msg_validationcode_model` (`id`, `tenant_id`, `type`, `name`, `signature`, `content`, `createtime`, `status`, `minutes`, `model_id`, `email_bg_img`)
VALUES
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 6, '验证码', '富茂', '{s6}(动态验证码),请在5分钟内填写', '2019-04-27 18:54:48', 1, 5, 115, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 7, '账单待缴模板', '富茂', '{merName}当期的待缴账单为{price}元,截止日期为{date} ,请登录{app}小程序查看账单并交费。', '2019-05-27 17:27:04', 1, 0, NULL, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 8, '账单欠缴模板', '富茂', '截止今日{merName}的账单共计欠缴{price}元,请登录{app}小程序查看账单并交费。', '2019-05-23 18:17:55', 1, 0, NULL, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 9, '场景投放', '富茂', '亲爱的vip,悄悄地送您一张{title},请到{app}微信小程序中使用吧!', '2019-04-30 21:35:30', 1, 0, NULL, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 17, '限时活动报名成功', '富茂', '亲爱的{person},您已成功报名{party},盼望您于{time}到场参加活动,谢谢。', '2019-06-20 00:08:07', 1, 0, NULL, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 18, '限时活动参加提醒', '富茂', '亲爱的{person},{party}活动将在{time}准时开始,感谢您能够抽出宝贵时间准时到活动现场参与,谢谢。', '2019-06-20 00:08:08', 1, 0, NULL, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 12, '审批通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"{bg}\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\"><span>{userName}</span>同意编号<span>{contract}</span>的{bustype}审批,已呈送<span>{toUserName},</span>请登录<a href=\"{page}\">{page}</a>查看审批进度</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 14, '待办通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">待办通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 40px;\"><span>{name}</span><span>提交了一个{bustype}待您审批,电脑登录</span><a href=\"{page}\" target=\"_blank\">{page}</a>查看您的待办</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请时间:</div>\n <div style=\"float: left;font-size:18px;width:cale(80%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{applyTime}</div>\n </div>\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请进度:</div>\n <div style=\"float: left;width:cale(80%-55px);margin-left: 55px;\">\n \n {taskList}\n </div>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;padding: 56px 55px 0;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系申请人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 13, '欠缴账单通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background: #fff;padding-bottom: 40px;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">欠缴账单通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 0;\">您当前的欠缴账单为<span style=\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">租金账单</span>\n <div style=\"margin: 0 5%;width:90%;overflow: hidden;font-size:14px;\">\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单类型</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单金额(元)</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">缴费时间</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">逾期天数</div>\n </div>\n {billList}\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系商管负责人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 15, '驳回通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 40px;\">编号<span>{contract}</span>的{bustype}审批被驳回,请登录<a href=\"{page}\">{page}</a>查看审批明细</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回人:</span>\n <span style=\"display: block;float: left; width:calc(100% - 240px);font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{name}</span>\n </div>\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回原因:</span>\n <span style=\"display: block;float: left;width:calc(100% - 240px); font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{remark}</span>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;margin-top: 26px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系驳回人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 10, '审批通过通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"https://s3.cn-northwest-1.amazonaws.com.cn/iformall-net/cimg/changrong-logo.png\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\">编号<span>{contract}</span>的{bustype}已经审批通过,请登录<a href=\"{page}\">{page}</a>跟进后续工作</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-06-04 14:22:27', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 11, '待缴账单通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background: #fff;padding-bottom: 40px;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding-top: 56px;padding-left: 55px;\">待缴账单通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 0;\">您当前的待缴账单为<span style=\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">租金账单</span>\n <div style=\"margin: 0 5%;width:90%;overflow: hidden;\">\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单类型</div>\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单金额(元)</div>\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">缴费时间</div>\n </div>\n {billList}\n </div>\n </div>\n <div style=\"background: #fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系商管负责人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 12, '审批通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"{bg}\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\"><span>{userName}</span>同意编号<span>{contract}</span>的{bustype}审批,已呈送<span>{toUserName},</span>请登录<a href=\"{page}\">{page}</a>查看审批进度</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 10, '审批通过通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"https://s3.cn-northwest-1.amazonaws.com.cn/iformall-net/cimg/changrong-logo.png\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\">编号<span>{contract}</span>的{bustype}已经审批通过,请登录<a href=\"{page}\">{page}</a>跟进后续工作</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-06-04 14:22:27', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 15, '驳回通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 40px;\">编号<span>{contract}</span>的{bustype}审批被驳回,请登录<a href=\"{page}\">{page}</a>查看审批明细</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回人:</span>\n <span style=\"display: block;float: left; width:calc(100% - 240px);font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{name}</span>\n </div>\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回原因:</span>\n <span style=\"display: block;float: left;width:calc(100% - 240px); font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{remark}</span>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;margin-top: 26px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系驳回人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 13, '欠缴账单通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background: #fff;padding-bottom: 40px;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">欠缴账单通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 0;\">您当前的欠缴账单为<span style=\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">租金账单</span>\n <div style=\"margin: 0 5%;width:90%;overflow: hidden;font-size:14px;\">\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单类型</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单金额(元)</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">缴费时间</div>\n <div style=\"width: 25%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">逾期天数</div>\n </div>\n {billList}\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系商管负责人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 14, '待办通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">待办通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 40px;\"><span>{name}</span><span>提交了一个{bustype}待您审批,电脑登录</span><a href=\"{page}\" target=\"_blank\">{page}</a>查看您的待办</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请时间:</div>\n <div style=\"float: left;font-size:18px;width:cale(80%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{applyTime}</div>\n </div>\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请进度:</div>\n <div style=\"float: left;width:cale(80%-55px);margin-left: 55px;\">\n \n {taskList}\n </div>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;padding: 56px 55px 0;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系申请人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 11, '待缴账单通知', '富茂', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background: #fff;padding-bottom: 40px;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding-top: 56px;padding-left: 55px;\">待缴账单通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 0;\">您当前的待缴账单为<span style=\"font-weight:400;color:rgba(200,89,98,1);margin:0 10px;\">{price}</span>元,截止日期为<span>{date}</span>请登录<span>您的商户端</span>小程序查看账单并缴费</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">租金账单</span>\n <div style=\"margin: 0 5%;width:90%;overflow: hidden;\">\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单类型</div>\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">账单金额(元)</div>\n <div style=\"width: 33.3%;float: left;height: 60px;line-height: 60px;text-align: center;font-family:MicrosoftYaHei;color:rgba(85,85,85,1);\">缴费时间</div>\n </div>\n {billList}\n </div>\n </div>\n <div style=\"background: #fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold; font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;margin-left: 55px;padding-top: 56px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系商管负责人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-05-23 18:18:02', 1, NULL, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 21, '通过审批通知', '富茂', '您申请的[{type}],[{name}]已通过审批,请登录{page} 跟进后续工作。', '2019-04-24 12:42:33', 1, 0, 228, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 19, '代办通知', '富茂', '{userName}提交了一个营销申请待您审批,电脑登陆{page} 查看您的待办。', '2019-04-24 12:42:33', 1, 0, 226, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 20, '审批通知', '富茂', '{userName}同意[{type}][{name}]的审批,已呈送至{toUserName},登录{page}查看审批进度。', '2019-05-21 13:41:33', 1, 0, 500, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 22, '驳回通知', '富茂', '您申请的[{type}],[{name}]被驳回,请登录{page} 查看审批明细。', '2019-05-21 13:41:33', 1, 0, 500, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 25, '审批通知', '', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"{bg}\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\"><span>{userName}</span>同意[{type}][{name}]的审批,已呈送<span>{toUserName},</span>请登录<a href=\"{page}\">{page}</a>查看审批进度</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-07-10 11:36:23', 0, 0, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 27, '驳回通知', '', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding:36px 55px 40px;\">您申请的[{type}],[{name}]被驳回,请登录<a href=\"{page}\">{page}</a>查看审批明细</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回人:</span>\n <span style=\"display: block;float: left; width:calc(100% - 240px);font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{name}</span>\n </div>\n <div style=\"overflow: hidden;\">\n <span style=\"display: block;float: left; font-size:18px;width:80px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">驳回原因:</span>\n <span style=\"display: block;float: left;width:calc(100% - 240px); font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{remark}</span>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;margin-top: 26px;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系驳回人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-07-10 11:38:22', 0, 0, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 26, '待办通知', '', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <style>\n *{\n margin: 0;\n padding: 0;\n }\n </style>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;margin-left: 40px;\" src=\"{bg}\"/>\n </header>\n <content>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding: 56px 55px 0;\">待办通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px 40px;\"><span>{name}</span><span>提交了一个营销申请待您审批,电脑登录</span><a href=\"{page}\" target=\"_blank\">{page}</a>查看您的待办</div>\n </div>\n <div style=\"height: auto;width: 100%;line-height: 40px; background: rgba(245,245,245,1);padding: 30px 0;\">\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请时间:</div>\n <div style=\"float: left;font-size:18px;width:cale(80%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 55px;\">{applyTime}</div>\n </div>\n <div style=\"overflow: hidden;\">\n <div style=\"float: left;font-size:18px;width:cale(20%-55px);font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">申请进度:</div>\n <div style=\"float: left;width:cale(80%-55px);margin-left: 55px;\">\n \n {taskList}\n </div>\n </div>\n </div>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;margin-top: 26px;padding: 56px 55px 0;\">遇到问题?</div>\n <div style=\"overflow: hidden;line-height: 60px;padding-bottom: 40px;\">\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(153,153,153,1);margin-left: 55px;\">请联系申请人:</span>\n <span style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);margin-left: 25px;\"><span>{linkName}</span><span style=\"margin-left: 16px; font-family:MicrosoftYaHei;font-weight:400;color:rgba(64,103,139,1);\">{linkPhone}</span></span>\n </div>\n </div>\n </content>\n </div>\n</body>\n\n</html>', '2019-07-10 11:37:33', 0, 0, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 24, '审批通过通知', '', '<!DOCTYPE html>\n<html>\n\n<head>\n <meta charset=\"utf-8\">\n <meta name=\"viewport\" content=\"width=device-width,initial-scale=1.0\">\n <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />\n <meta name=\"viewport\" content=\"initial-scale=1.0, user-scalable=no\" />\n <meta name=\"renderer\" content=\"webkit\">\n <meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\">\n <title>富茂审批邮件</title>\n <title></title>\n <script> document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + \'px\';</script>\n</head>\n\n<body>\n <div id=\"box\" style=\"padding:80px 20%;background:#E9E7E7;min-height:100vh;\">\n <header style=\"height:140px;width:100%;display:flex;background:rgba(31,47,62,1);border-radius:15px 15px 0px 0px;\">\n <img style=\"height:auto;width:292px;display:flex;align-self: center;justify-content: center;padding:0 40px;\" src=\"https://s3.cn-northwest-1.amazonaws.com.cn/iformall-net/cimg/changrong-logo.png\"/>\n </header>\n <div style=\"background:#fff;\">\n <div style=\"font-size:26px;font-family:MicrosoftYaHei-Bold;font-weight:bold;color:rgba(85,85,85,1);line-height: 32px;padding:56px 55px 0;\">审批通过通知</div>\n <div style=\"font-size:18px;font-family:MicrosoftYaHei;font-weight:400;color:rgba(85,85,85,1);padding: 36px 55px;\">您申请的[{type}],[{name}]已经审批通过,请登录<a href=\"{page}\">{page}</a>跟进后续工作</div>\n </div>\n </div>\n</body>\n\n</html>', '2019-07-10 11:35:11', 0, 0, 500, 'http://202.165.179.86:8081/images/WechatIMG5130.png'),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 2, '代办通知', '富茂', '{userName}提交了一个{bustype}待您审批,电脑登陆{page} 查看您的待办。', '2019-04-24 17:20:30', 1, 0, 226, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 3, '审批通知', '富茂', '{userName}同意编号{contract}的{bustype}审批,已呈送至{toUserName},登录{page}查看审批进度。', '2019-05-23 18:18:02', 1, 0, 500, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 4, '通过审批通知', '富茂', '编号{contract}的{bustype}已通过审批,请登录{page} 跟进后续工作。', '2019-04-24 17:20:30', 1, 0, 228, NULL),
((select unix_timestamp(now()) + CEILING(RAND()*90000+10000)), '790', 5, '驳回通知', '富茂', '编号{contract}的{bustype}审批被驳回,请登录{page} 查看审批明细。', '2019-05-23 18:18:02', 1, 0, 500, NULL);

+ 2
- 0
mallinkAdmin/src/main/resources/db/migration/V201907111418__CHANGE_WX_MSG_LIMIT.sql Vedi File

@@ -0,0 +1,2 @@
alter table `wx_msg_limit`
change column `type` `type` smallint (4) DEFAULT '0' COMMENT '1: 短信-验证码(24小时10条)2:短信-营销(24小时3条) 10:prepay_id(7天内3次), 12:form_id(7天内1次), 13.open_id for 小程序统一消息限制(2天内1次),14.open_id for 公众号模板消息限制(2天内1次)';

+ 2
- 0
mallinkAdmin/src/main/resources/db/migration/V201907111507__CHANGE_WX_MSG_LIMIT.sql Vedi File

@@ -0,0 +1,2 @@
alter table `wx_msg_limit`
change column `type` `type` smallint (4) DEFAULT '0' COMMENT '1: 短信-验证码(24小时10条)2:短信-营销(24小时3条) 11:prepay_id(7天内3次), 12:form_id(7天内1次), 21.open_id for 小程序统一消息限制(2天内1次),31.open_id for 公众号模板消息限制(2天内1次)';

+ 1
- 1
mallinkService/src/main/java/com/iformall/domain/po/WxActivityJoin.java Vedi File

@@ -70,7 +70,7 @@ public class WxActivityJoin extends BaseEntity {
@Excel(name = "活动签到", replace = {"未签到_0", "已签到_1"}, width = 10, orderNum = "7")
@io.swagger.annotations.ApiModelProperty(value = "签到状态1签到0未签到", name = "signIn")
private Integer signIn;
@Excel(name = "报名状态", replace = {"未确认_0", "已确认_1", "取消报名_2", "活动过期_3"}, width = 10, orderNum = "8")
@Excel(name = "报名状态", replace = {"未确认_0", "已确认_1", "报名失败_2", "活动过期_3"}, width = 10, orderNum = "8")
@io.swagger.annotations.ApiModelProperty(value = "状态0未确认-报名中1确认-报名成功2取消-报名失败3过期", name = "status")
private Integer status;
@Excel(name = "报名时间", format = "yyyy-MM-dd HH:mm:ss", width = 10, orderNum = "6")


+ 2
- 2
mallinkService/src/main/java/com/iformall/enums/EnumMsgLimitType.java Vedi File

@@ -10,8 +10,8 @@ public enum EnumMsgLimitType {
SMS_SALE(2, "短信-营销"),
WEAPP_PREPAYID(11, "小程序prepayId"),
WEAPP_FORMID(12, "小程序formId"),
WEAPP_OPENID_SEND(101, "小程序发券统一消息"),
WXCHAT_OPENID_SEND(201, "公众号发券消息"),
WEAPP_OPENID_SEND(21, "小程序发券统一消息"),
WXCHAT_OPENID_SEND(31, "公众号发券消息"),
;

public static EnumMsgLimitType getEnum(Integer code) {


+ 3
- 0
mallinkService/src/main/java/com/iformall/mapper/WxCardSpendMapper.java Vedi File

@@ -13,6 +13,9 @@ public interface WxCardSpendMapper extends CommonMapper<WxCardSpend, Long> {

int findCount(WxCardSpend wxCardSpend);

List<Map<String,Object>> getCountByBusinessId(WxCardSpend wxCardSpend);
List<Map<String,Object>> getCountByBusinessIdAndSubId(WxCardSpend wxCardSpend);

List<WxCardSpendVo> findCardSpendVoList(WxCardSpendVo wxCardSpend);

List<Map<String,Object>> sumCardSpendVoForMerchant(WxCardSpendVo wxCardSpend);


+ 2
- 0
mallinkService/src/main/java/com/iformall/mapper/WxCouponOrderMapper.java Vedi File

@@ -26,6 +26,8 @@ public interface WxCouponOrderMapper extends CommonMapper<WxCouponOrder, Long> {

//统一的计数接口
int findCount(WxCouponOrder wxCouponOrder);
List<Map<String, Object>> getCountByBusinessId(WxCouponOrder wxCouponOrder);
List<Map<String, Object>> getCountByBusinessIdAndSubId(WxCouponOrder wxCouponOrder);
//统一额度统计接口
int queryPriceTotal(WxCouponOrder wxCouponOrder);



+ 36
- 8
mallinkService/src/main/java/com/iformall/service/impl/WxCUserTagsServiceImpl.java Vedi File

@@ -368,11 +368,25 @@ public class WxCUserTagsServiceImpl implements WxCUserTagsService {
WxBusiness business = new WxBusiness();
List<WxBusiness> list = wxBusinessMapper.findList(business);

List<Map<String, Object>> cardSpendCountList = wxCardSpendMapper.getCountByBusinessId(wxCardSpend);
List<Map<String, Object>> cardOrderCountList = wxCouponOrderMapper.getCountByBusinessId(wxCouponOrder);

list.stream().forEach(b->{
wxCardSpend.setBusinessId(b.getId());
wxCouponOrder.setBusinessId(b.getId());
int count = wxCardSpendMapper.findCount(wxCardSpend);
count += wxCouponOrderMapper.findCount(wxCouponOrder);
int count = 0;
if(cardSpendCountList.size() > 0) {
for (Map<String, Object> cardSpendCount : cardSpendCountList) {
if (cardSpendCount.get("businessId").equals(b.getId().toString())) {
count += (Integer) cardSpendCount.get("buCount");
}
}
}
if(cardOrderCountList.size() > 0) {
for (Map<String, Object> cardOrderCount : cardOrderCountList) {
if (cardOrderCount.get("business").equals(b.getId().toString())) {
count += (Integer) cardOrderCount.get("buCount");
}
}
}
if (count > 0) {
EnumTag tag = null;
if (b.getId().intValue() >= EnumBusiness.BUSINESS_ID1.getCode() &&
@@ -419,11 +433,25 @@ public class WxCUserTagsServiceImpl implements WxCUserTagsService {
subBusiness.setBusinessId(EnumBusiness.BUSINESS_ID1.getCode());
List<WxSubBusiness> list = wxSubBusinessMapper.findList(subBusiness);

List<Map<String, Object>> cardSpendCountList = wxCardSpendMapper.getCountByBusinessId(wxCardSpend);
List<Map<String, Object>> cardOrderCountList = wxCouponOrderMapper.getCountByBusinessId(wxCouponOrder);

list.stream().forEach(sb->{
wxCardSpend.setSubBusinessId(sb.getId());
wxCouponOrder.setSubBusinessId(sb.getId());
int count = wxCardSpendMapper.findCount(wxCardSpend);
count += wxCouponOrderMapper.findCount(wxCouponOrder);
int count = 0;
if(cardSpendCountList.size() > 0) {
for (Map<String, Object> cardSpendCount : cardSpendCountList) {
if (cardSpendCount.get("subBusinessId").equals(sb.getId().toString())) {
count += (Integer) cardSpendCount.get("buCount");
}
}
}
if(cardOrderCountList.size() > 0) {
for (Map<String, Object> cardOrderCount : cardOrderCountList) {
if (cardOrderCount.get("subBusiness").equals(sb.getId().toString())) {
count += (Integer) cardOrderCount.get("buCount");
}
}
}
if (count > 0) {
EnumTag tag = null;
if (sb.getId().intValue() >= EnumSubBusiness.SUB_BUSINESS_ID1.getCode() &&


+ 8
- 8
mallinkService/src/main/resources/mapper/WxBusinessMapper.xml Vedi File

@@ -86,13 +86,13 @@
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
/100,2) volume,
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
/
(select if(sum(ws.operation_area) is null,0,sum(ws.operation_area))
from wx_merchant m
@@ -119,7 +119,7 @@
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 ) /
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 ) /
(select sum(mtd.trade_count)
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = b.id and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
@@ -134,7 +134,7 @@
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 and m.id = mm.id)
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 and m.id = mm.id)
/
(select if(sum(ws.operation_area) is null,0,sum(ws.operation_area))
from wx_merchant m
@@ -148,7 +148,7 @@
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 and m.id = mm.id)/
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 and m.id = mm.id)/
(select if(sum(ws.operation_area) is null,0,sum(ws.operation_area))
from wx_merchant m
left join wx_merchant_shop mtd on mtd.merchant_id = m.id
@@ -158,7 +158,7 @@
round(
(select if(sum(mtd.trade_amt) is null,0,sum(mtd.trade_amt))
from wx_merchant m
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.create_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
left join wx_merchant_trade_daily mtd on mtd.merchant_id = m.id where m.business_id = #{id} and m.tenant_id=#{tenantId} and mtd.report_date between #{startdate} and #{enddate} and m.status = 1 and m.is_del = 0 )
/
(select if(sum(ws.operation_area) is null,0,sum(ws.operation_area))
from wx_merchant m
@@ -167,7 +167,7 @@
where m.business_id = #{id} and m.tenant_id=#{tenantId} and m.status = 1 and m.is_del = 0 )
/100,2)

,2) devoteRate
*100,2) devoteRate

from wx_merchant mm
left join wx_merchant_trade_daily mtd on mtd.merchant_id = mm.id
@@ -175,7 +175,7 @@
left join wx_shop ws on(wmt.shop_id = ws.id)
where mm.business_id=#{id} and mm.tenant_id=#{tenantId}
and mm.status = 1 and mm.is_del = 0
and mtd.create_date between #{startdate} and #{enddate}
and mtd.report_date between #{startdate} and #{enddate}
group by mm.id
order by devoteRate desc



+ 88
- 0
mallinkService/src/main/resources/mapper/WxCardSpendMapper.xml Vedi File

@@ -165,6 +165,94 @@
</if>
</select>

<select id="getCountByBusinessId" parameterType="com.iformall.domain.po.WxCardSpend" resultType="hashmap">
select m.business_id, count(m.business_id) bu_count
from wx_card_spend cs
inner join wx_merchant m on m.id = cs.merchant_id
where 1 = 1
<if test=" null != ownerId ">
and cs.`owner_id` = #{ownerId}
</if>
<if test=" null != tenantId ">
and cs.`tenant_id` = #{tenantId}
</if>
<if test=" null != startdate and null!=enddate">
and cs.`create_date` between #{startdate} and #{enddate}
</if>
<if test=" 0 == timeSlot">
and date_format(cs.create_date,'%H:%m') &gt;= '06:00'
and date_format(cs.create_date,'%H:%m') &lt; '18:00'
and date_format(cs.create_date,'%w') in (1,2,3,4,5)
</if>

<if test=" 1 == timeSlot">
and ((date_format(cs.create_date,'%H:%m') &gt;= '18:00'
and date_format(cs.create_date,'%w') in (1,2,3,4))
or
((date_format(cs.create_date,'%H:%m') &lt; '06:00')
and date_format(cs.create_date,'%w') in (1,2,3,4,5)))
</if>

<if test=" 2 == timeSlot">
and date_format(cs.create_date,'%H:%m') &gt;= '06:00'
and date_format(cs.create_date,'%H:%m') &lt; '18:00'
and date_format(cs.create_date,'%w') in (0,6)
</if>

<if test=" 3 == timeSlot">
and ((date_format(cs.create_date,'%H:%m') &gt;= '18:00'
and date_format(cs.create_date,'%w') in (5,6,0))
or
((date_format(cs.create_date,'%H:%m') &lt; '06:00')
and date_format(cs.create_date,'%w') in (6,0)))
</if>
group by m.business_id
</select>

<select id="getCountByBusinessIdAndSubId" parameterType="com.iformall.domain.po.WxCardSpend" resultType="hashmap">
select m.business_id, m.sub_business_id, count(m.business_id + '' + m.sub_business_id) bu_count
from wx_card_spend cs
inner join wx_merchant m on m.id = cs.merchant_id
where 1 = 1
<if test=" null != ownerId ">
and cs.`owner_id` = #{ownerId}
</if>
<if test=" null != tenantId ">
and cs.`tenant_id` = #{tenantId}
</if>
<if test=" null != startdate and null!=enddate">
and cs.`create_date` between #{startdate} and #{enddate}
</if>
<if test=" 0 == timeSlot">
and date_format(cs.create_date,'%H:%m') &gt;= '06:00'
and date_format(cs.create_date,'%H:%m') &lt; '18:00'
and date_format(cs.create_date,'%w') in (1,2,3,4,5)
</if>

<if test=" 1 == timeSlot">
and ((date_format(cs.create_date,'%H:%m') &gt;= '18:00'
and date_format(cs.create_date,'%w') in (1,2,3,4))
or
((date_format(cs.create_date,'%H:%m') &lt; '06:00')
and date_format(cs.create_date,'%w') in (1,2,3,4,5)))
</if>

<if test=" 2 == timeSlot">
and date_format(cs.create_date,'%H:%m') &gt;= '06:00'
and date_format(cs.create_date,'%H:%m') &lt; '18:00'
and date_format(cs.create_date,'%w') in (0,6)
</if>

<if test=" 3 == timeSlot">
and ((date_format(cs.create_date,'%H:%m') &gt;= '18:00'
and date_format(cs.create_date,'%w') in (5,6,0))
or
((date_format(cs.create_date,'%H:%m') &lt; '06:00')
and date_format(cs.create_date,'%w') in (6,0)))
</if>
group by m.business_id, m.sub_business_id
</select>


<resultMap id="VoResultMap" type="com.iformall.domain.vo.WxCardSpendVo">
<id column="id" jdbcType="BIGINT" property="id"/>


+ 178
- 0
mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml Vedi File

@@ -329,6 +329,184 @@
</if>
</select>

<select id="getCountByBusinessId" parameterType="com.iformall.domain.po.WxCouponOrder" resultType="hashmap">
select c.business, COUNT(c.business) bu_count
FROM wx_coupon_order co
inner join wx_coupon c on c.id = co.coupon_id
where 1=1
<if test=" null != tenantId">
and co.tenant_id = #{tenantId}
</if>
<if test=" null != couponOrderStatus">
and co.coupon_order_status = #{couponOrderStatus}
</if>
<if test=" null != cUserId">
and co.c_user_id = #{cUserId}
</if>
<if test=" null != couponId ">
and co.coupon_id = #{couponId}
</if>
<if test=" null != couponType ">
and co.coupon_type = #{couponType}
</if>

<if test=" 1 == couponOrderStatus">
<if test=" null != startTime">
and co.update_date &gt;= #{startTime}
</if>
<if test=" null != endTime">
and co.update_date &lt;= #{endTime}
</if>
<if test=" 0 == timeSlot">
and date_format(co.update_date,'%H:%m') &gt;= '06:00'
and date_format(co.update_date,'%H:%m') &lt; '18:00'
and date_format(co.update_date,'%w') in (1,2,3,4,5)
</if>
<if test=" 1 == timeSlot">
and ((date_format(co.update_date,'%H:%m') &gt;= '18:00'
and date_format(co.update_date,'%w') in (1,2,3,4))
or
((date_format(co.update_date,'%H:%m') &lt; '06:00')
and date_format(co.update_date,'%w') in (1,2,3,4,5)))
</if>
<if test=" 2 == timeSlot">
and date_format(co.update_date,'%H:%m') &gt;= '06:00'
and date_format(co.update_date,'%H:%m') &lt; '18:00'
and date_format(co.update_date,'%w') in (0,6)
</if>
<if test=" 3 == timeSlot">
and ((date_format(co.update_date,'%H:%m') &gt;= '18:00'
and date_format(co.update_date,'%w') in (5,6,0))
or
((date_format(co.update_date,'%H:%m') &lt; '06:00')
and date_format(co.update_date,'%w') in (6,0)))
</if>
</if>

<if test=" 1 != couponOrderStatus">
<if test=" null != startTime">
and co.create_date &gt;= #{startTime}
</if>
<if test=" null != endTime">
and co.create_date &lt;= #{endTime}
</if>
<if test=" 0 == timeSlot">
and date_format(co.create_date,'%H:%m') &gt;= '06:00'
and date_format(co.create_date,'%H:%m') &lt; '18:00'
and date_format(co.create_date,'%w') in (1,2,3,4,5)
</if>
<if test=" 1 == timeSlot">
and ((date_format(co.create_date,'%H:%m') &gt;= '18:00'
and date_format(co.create_date,'%w') in (1,2,3,4))
or
((date_format(co.create_date,'%H:%m') &lt; '06:00')
and date_format(co.create_date,'%w') in (1,2,3,4,5)))
</if>
<if test=" 2 == timeSlot">
and date_format(co.create_date,'%H:%m') &gt;= '06:00'
and date_format(co.create_date,'%H:%m') &lt; '18:00'
and date_format(co.create_date,'%w') in (0,6)
</if>
<if test=" 3 == timeSlot">
and ((date_format(co.create_date,'%H:%m') &gt;= '18:00'
and date_format(co.create_date,'%w') in (5,6,0))
or
((date_format(co.create_date,'%H:%m') &lt; '06:00')
and date_format(co.create_date,'%w') in (6,0)))
</if>
</if>
group by c.business
</select>

<select id="getCountByBusinessIdAndSubId" parameterType="com.iformall.domain.po.WxCouponOrder" resultType="hashmap">
select c.business, c.sub_business, COUNT(c.business+''+c.sub_business) bu_count
FROM wx_coupon_order co
inner join wx_coupon c on c.id = co.coupon_id
where 1=1
<if test=" null != tenantId">
and co.tenant_id = #{tenantId}
</if>
<if test=" null != couponOrderStatus">
and co.coupon_order_status = #{couponOrderStatus}
</if>
<if test=" null != cUserId">
and co.c_user_id = #{cUserId}
</if>
<if test=" null != couponId ">
and co.coupon_id = #{couponId}
</if>
<if test=" null != couponType ">
and co.coupon_type = #{couponType}
</if>

<if test=" 1 == couponOrderStatus">
<if test=" null != startTime">
and co.update_date &gt;= #{startTime}
</if>
<if test=" null != endTime">
and co.update_date &lt;= #{endTime}
</if>
<if test=" 0 == timeSlot">
and date_format(co.update_date,'%H:%m') &gt;= '06:00'
and date_format(co.update_date,'%H:%m') &lt; '18:00'
and date_format(co.update_date,'%w') in (1,2,3,4,5)
</if>
<if test=" 1 == timeSlot">
and ((date_format(co.update_date,'%H:%m') &gt;= '18:00'
and date_format(co.update_date,'%w') in (1,2,3,4))
or
((date_format(co.update_date,'%H:%m') &lt; '06:00')
and date_format(co.update_date,'%w') in (1,2,3,4,5)))
</if>
<if test=" 2 == timeSlot">
and date_format(co.update_date,'%H:%m') &gt;= '06:00'
and date_format(co.update_date,'%H:%m') &lt; '18:00'
and date_format(co.update_date,'%w') in (0,6)
</if>
<if test=" 3 == timeSlot">
and ((date_format(co.update_date,'%H:%m') &gt;= '18:00'
and date_format(co.update_date,'%w') in (5,6,0))
or
((date_format(co.update_date,'%H:%m') &lt; '06:00')
and date_format(co.update_date,'%w') in (6,0)))
</if>
</if>

<if test=" 1 != couponOrderStatus">
<if test=" null != startTime">
and co.create_date &gt;= #{startTime}
</if>
<if test=" null != endTime">
and co.create_date &lt;= #{endTime}
</if>
<if test=" 0 == timeSlot">
and date_format(co.create_date,'%H:%m') &gt;= '06:00'
and date_format(co.create_date,'%H:%m') &lt; '18:00'
and date_format(co.create_date,'%w') in (1,2,3,4,5)
</if>
<if test=" 1 == timeSlot">
and ((date_format(co.create_date,'%H:%m') &gt;= '18:00'
and date_format(co.create_date,'%w') in (1,2,3,4))
or
((date_format(co.create_date,'%H:%m') &lt; '06:00')
and date_format(co.create_date,'%w') in (1,2,3,4,5)))
</if>
<if test=" 2 == timeSlot">
and date_format(co.create_date,'%H:%m') &gt;= '06:00'
and date_format(co.create_date,'%H:%m') &lt; '18:00'
and date_format(co.create_date,'%w') in (0,6)
</if>
<if test=" 3 == timeSlot">
and ((date_format(co.create_date,'%H:%m') &gt;= '18:00'
and date_format(co.create_date,'%w') in (5,6,0))
or
((date_format(co.create_date,'%H:%m') &lt; '06:00')
and date_format(co.create_date,'%w') in (6,0)))
</if>
</if>
group by c.business, c.sub_business
</select>

<select id="queryPriceTotalGroup" resultType="com.iformall.domain.vo.CUserDateAmountVo" >
SELECT DATE_FORMAT(create_date,'%Y-%m-%d') as xTime,IFNULL(SUM(coupon_price),0) as price from wx_coupon_order
where tenant_id=#{tenantId} AND create_date &gt;= #{startTime} and create_date &lt; #{endTime} GROUP BY xTime


+ 1
- 1
mallinkService/src/main/resources/mapper/WxMsgLimitMapper.xml Vedi File

@@ -4,7 +4,7 @@
<resultMap id="BaseResultMap" type="com.iformall.domain.po.WxMsgLimit">
<id column="id" jdbcType="BIGINT" property="id"/>
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId"/>
<result column="type" jdbcType="TINYINT" property="type"/>
<result column="type" jdbcType="INTEGER" property="type"/>
<result column="limit_id" jdbcType="VARCHAR" property="limitId"/>
<result column="limit_num" jdbcType="INTEGER" property="limitNum"/>
<result column="limit_date" jdbcType="TIMESTAMP" property="limitDate"/>


Caricamento…
Annulla
Salva