| | |
| | | import com.yeshi.fanli.util.Constant;
|
| | | import com.yeshi.fanli.util.StringUtil;
|
| | | import com.yeshi.fanli.util.TimeUtil;
|
| | | import com.yeshi.fanli.util.account.UserUtil;
|
| | | import com.yeshi.fanli.vo.msg.ClientTextStyleVO;
|
| | | import com.yeshi.fanli.vo.msg.CommonMsgItemVO;
|
| | | import com.yeshi.fanli.vo.msg.CommonMsgItemVOFactory;
|
| | |
|
| | | public class MsgOrderDetailFactory {
|
| | |
|
| | | |
| | | |
| | |
|
| | | |
| | | |
| | | |
| | |
|
| | | /**
|
| | | * 创建订单被统计消息
|
| | |
| | | MsgTypeOrderTypeEnum typeEnum = null;
|
| | | String sourceName = Constant.getSourceName(source);
|
| | | if (Constant.TYPE_REBATE == type) {
|
| | | fanliName = "返利:";
|
| | | fanliName = "预估返利:";
|
| | | sourceName += "-返利订单";
|
| | | typeEnum = MsgTypeOrderTypeEnum.fanli;
|
| | | } else if (Constant.TYPE_SHAER == type) {
|
| | | fanliName = "奖金:";
|
| | | fanliName = "预估奖金:";
|
| | | sourceName += "-分享订单";
|
| | | typeEnum = MsgTypeOrderTypeEnum.share;
|
| | | } else if (Constant.TYPE_INVITE == type) {
|
| | | fanliName = "收益:";
|
| | | fanliName = "预估收益:";
|
| | | sourceName += "-团队订单";
|
| | | typeEnum = MsgTypeOrderTypeEnum.invite;
|
| | | }
|
| | |
| | | List<CommonMsgItemVO> listMsg = new ArrayList<>();
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单详情", ClientTextStyleVO.COLOR_TITLE),
|
| | | new ClientTextStyleVO(sourceName, ClientTextStyleVO.COLOR_CONTENT)));
|
| | | // 订单号可点击
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单号", ClientTextStyleVO.COLOR_TITLE),
|
| | | new ClientTextStyleVO(orderId, ClientTextStyleVO.COLOR_CONTENT), true));
|
| | | |
| | | if (Constant.TYPE_INVITE == type) {
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单号", ClientTextStyleVO.COLOR_TITLE),
|
| | | new ClientTextStyleVO(UserUtil.filterOrderId(orderId), ClientTextStyleVO.COLOR_CONTENT), true));
|
| | | } else {
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单号", ClientTextStyleVO.COLOR_TITLE),
|
| | | new ClientTextStyleVO(orderId, ClientTextStyleVO.COLOR_CONTENT), true));
|
| | | }
|
| | |
|
| | | List<ClientTextStyleVO> contentList = new ArrayList<>();
|
| | | contentList
|
| | | .add(new ClientTextStyleVO("下单时间:" + TimeUtil.formatDate(downTime), ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("-商品数量:共", ClientTextStyleVO.COLOR_CONTENT));
|
| | | .add(new ClientTextStyleVO("下单时间:" + TimeUtil.formatDate(downTime), ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("-商品数量:共", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO(goodsCount + "", ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("件商品", ClientTextStyleVO.COLOR_CONTENT));
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单相关", ClientTextStyleVO.COLOR_TITLE),
|
| | | contentList));
|
| | |
|
| | | List<ClientTextStyleVO> contentList2 = new ArrayList<>();
|
| | | contentList2.add(new ClientTextStyleVO("实付款:", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("实付款:", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("¥" + filterMoney(payMoney), ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("&" + fanliName, ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("¥" + filterMoney(money), ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | |
| | | String fanliName = "";
|
| | | String sourceName = Constant.getSourceName(source);
|
| | | if (Constant.TYPE_REBATE == type) {
|
| | | fanliName = "返利:";
|
| | | fanliName = "预估返利:";
|
| | | sourceName += "-返利订单";
|
| | | } else if (Constant.TYPE_SHAER == type) {
|
| | | fanliName = "奖金:";
|
| | | fanliName = "预估奖金:";
|
| | | sourceName += "-分享订单";
|
| | | }
|
| | |
|
| | |
| | | new ClientTextStyleVO(orderId, ClientTextStyleVO.COLOR_CONTENT), true));
|
| | |
|
| | | List<ClientTextStyleVO> contentList = new ArrayList<>();
|
| | | contentList.add(new ClientTextStyleVO("提交时间:" + TimeUtil.formatDate(submitTime), ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("-商品数量:共", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("提交时间:" + TimeUtil.formatDate(submitTime), ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("-商品数量:共", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO(goodsCount + "", ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | | contentList.add(new ClientTextStyleVO("件商品", ClientTextStyleVO.COLOR_CONTENT));
|
| | | listMsg.add(CommonMsgItemVOFactory.createMsgItemVO(new ClientTextStyleVO("订单相关", ClientTextStyleVO.COLOR_TITLE),contentList));
|
| | |
|
| | | List<ClientTextStyleVO> contentList2 = new ArrayList<>();
|
| | | contentList2.add(new ClientTextStyleVO("实付款:", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("实付款:", ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("¥" + filterMoney(payMoney), ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("&" + fanliName, ClientTextStyleVO.COLOR_CONTENT));
|
| | | contentList2.add(new ClientTextStyleVO("¥" + filterMoney(money), ClientTextStyleVO.COLOR_HIGHLIGHT_CONTENT));
|
| | |
| | |
|
| | |
|
| | | MsgOrderDetail detail = new MsgOrderDetail();
|
| | | detail.setOrderId(orderId);
|
| | | detail.setBeiZhu(beiZhu);
|
| | | detail.setCreateTime(new Date());
|
| | | detail.setOrderType(source);
|