| | |
| | | endTime += " 23:59:59";
|
| | | }
|
| | |
|
| | | List<Integer> listSource = new ArrayList<>();
|
| | | if (goodsType != null) {
|
| | | listSource.add(goodsType);
|
| | | } |
| | | |
| | | try {
|
| | | // 筛选结果顶部统计
|
| | | String validMoney = "0.00";
|
| | | String invalidMoney = "0.00";
|
| | | if (page == 1) {
|
| | | BigDecimal predictMoney = hongBaoV2CountService.getRewardMoneyByToSearch(uid, dateType, orderType, 1,
|
| | | orderNo, state, goodsType, startTime, endTime);
|
| | | orderNo, state, startTime, endTime, listSource);
|
| | | if (predictMoney != null)
|
| | | validMoney = predictMoney.setScale(2, BigDecimal.ROUND_DOWN).toString();
|
| | |
|
| | | BigDecimal postSaleMoney = hongBaoV2CountService.getRewardMoneyByToSearch(uid, dateType, orderType, 2,
|
| | | orderNo, state, goodsType, startTime, endTime);
|
| | | orderNo, state, startTime, endTime, listSource);
|
| | | if (postSaleMoney != null)
|
| | | invalidMoney = postSaleMoney.setScale(2, BigDecimal.ROUND_DOWN).toString();
|
| | |
|
| | |
| | |
|
| | | // 查询列表
|
| | | List<CommonOrderVO> list = commonOrderService.getOrderByUid(acceptData, page, uid, state, orderType, orderState,
|
| | | orderNo, startTime, endTime, dateType, goodsType);
|
| | | orderNo, startTime, endTime, dateType, listSource);
|
| | | // 统计总数
|
| | | long count = commonOrderService.countGroupOrderNoByUid(uid, state, orderType, orderState, orderNo, startTime,
|
| | | endTime, dateType, goodsType);
|
| | | endTime, dateType, listSource);
|
| | |
|
| | | // 判断是否需要显示订单找回提示 8秒内请求3次触发
|
| | | String orderFindUrl = null;
|
| | |
| | | try {
|
| | | long count = 0;
|
| | | List<CommonOrderVO> list = null;
|
| | | List<ESOrder> listES = esOrderService.multiMatchQuery(key, uid.toString());
|
| | | List<ESOrder> listES = esOrderService.query(key, uid.toString(), null);
|
| | | |
| | | if (listES.size() != 0) {
|
| | | list = commonOrderService.searchOrderByUid(page, Constant.PAGE_SIZE, uid, listES);
|
| | | count = commonOrderService.countSearchOrderByUid(uid, listES);
|
| | | }
|
| | | |
| | | if (list == null) {
|
| | | list = new ArrayList<>();
|
| | | }
|
| | |
| | | * @param acceptData
|
| | | * @param uid
|
| | | * 用户id
|
| | | * type 类型:0全部、1淘宝 2京东、拼多多
|
| | | * @param out
|
| | | */
|
| | | @RequestMapping(value = "getOrderCount", method = RequestMethod.POST)
|
| | |
| | | JSONObject data = new JSONObject();
|
| | | data.put("userInfo", userInfo);
|
| | |
|
| | | List<Integer> listSource = new ArrayList<>();
|
| | | if (type == null || type == 0) {
|
| | | OrderCountVO total = commonOrderService.getOrderCount(uid, null, type);
|
| | | OrderCountVO total = commonOrderService.getOrderCount(uid, null, null);
|
| | | data.put("total", total.getSelf() + total.getShared() + total.getInvite());
|
| | | data.put("self", total.getSelf());
|
| | | data.put("shared", total.getShared());
|
| | |
| | | data.put("self", 0);
|
| | | data.put("shared", 0);
|
| | | data.put("invite", 0);
|
| | | |
| | | listSource.add(type);
|
| | | }
|
| | |
|
| | | // 今天
|
| | | OrderCountVO today = commonOrderService.getOrderCount(uid, 1, type);
|
| | | OrderCountVO today = commonOrderService.getOrderCount(uid, 1, listSource);
|
| | | today.setTotal(today.getSelf() + today.getShared() + today.getInvite());
|
| | | // 昨天
|
| | | OrderCountVO yesterday = commonOrderService.getOrderCount(uid, 2, type);
|
| | | OrderCountVO yesterday = commonOrderService.getOrderCount(uid, 2, listSource);
|
| | | yesterday.setTotal(yesterday.getSelf() + yesterday.getShared() + yesterday.getInvite());
|
| | | // 本月
|
| | | OrderCountVO thisMonth = commonOrderService.getOrderCount(uid, 3, type);
|
| | | OrderCountVO thisMonth = commonOrderService.getOrderCount(uid, 3, listSource);
|
| | | thisMonth.setTotal(thisMonth.getSelf() + thisMonth.getShared() + thisMonth.getInvite());
|
| | | // 上月
|
| | | OrderCountVO lastMonth = commonOrderService.getOrderCount(uid, 4, type);
|
| | | OrderCountVO lastMonth = commonOrderService.getOrderCount(uid, 4, listSource);
|
| | | lastMonth.setTotal(lastMonth.getSelf() + lastMonth.getShared() + lastMonth.getInvite());
|
| | |
|
| | | data.put("today", today);
|
| | |
| | | show = hongBaoV2CountService.getHongBaoCount(uid, null) > 0;
|
| | | }
|
| | |
|
| | | BigDecimal selfMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 1);
|
| | | BigDecimal shareMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 2);
|
| | | BigDecimal inviteMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 3);
|
| | | BigDecimal selfMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 1, null);
|
| | | BigDecimal shareMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 2, null);
|
| | | BigDecimal inviteMoney = hongBaoV2CountService.getRewardMoneyToCount(uid, dateType, 3, null);
|
| | |
|
| | | JSONObject data = new JSONObject();
|
| | | data.put("show", show);
|