| | |
| | | wrapper2.orderByAsc(AuctionSalesroomGoods::getSortNum); |
| | | wrapper2.last("limit 1"); |
| | | AuctionSalesroomGoods auctionSalesroomGoods = this.getOne(wrapper2); |
| | | auctionSalesroomGoods.setStatus(AuctionGoodsStatusEnum.IN_PROGRESS); |
| | | auctionSalesroomGoods.setStartTime(LocalDateTime.now()); |
| | | this.updateById(auctionSalesroomGoods); |
| | | if(auctionSalesroomGoods!=null){ |
| | | auctionSalesroomGoods.setStatus(AuctionGoodsStatusEnum.IN_PROGRESS); |
| | | auctionSalesroomGoods.setStartTime(LocalDateTime.now()); |
| | | this.updateById(auctionSalesroomGoods); |
| | | } |
| | | |
| | | |
| | | Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | map.put("notification_type", NotificationTypeConstant.AUCTION_SALESROOM); |
| | | map.put("auctionSalesroomId", auctionSalesroom.getId()); |
| | | map.put("AuctionTypeEnum",auctionSalesroom.getStatus()); |
| | | map.put("message_type", "start"); |
| | | map.put("type", "1"); |
| | | String msg = null; |
| | | try { |
| | | msg = objectMapper.writeValueAsString(map); |
| | | } catch (JsonProcessingException e) { |
| | | } |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.AUCTIONEER.getCode(), msg); |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); |
| | | |
| | | } |
| | | |
| | |
| | | |
| | | Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | map.put("notification_type", NotificationTypeConstant.AUCTION_SALESROOM); |
| | | map.put("AuctionTypeEnum",auctionSalesroom.getStatus()); |
| | | map.put("auctionSalesroomId", auctionSalesroom.getId()); |
| | | map.put("message_type", "end"); |
| | | map.put("type", "1"); |
| | | String msg = null; |
| | | try { |
| | | msg = objectMapper.writeValueAsString(map); |
| | | } catch (JsonProcessingException e) { |
| | | } |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.AUCTIONEER.getCode(), msg); |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); |
| | | } |
| | | |
| | | |
| | |
| | | auctionSalesroomGoods.setStatus(AuctionGoodsStatusEnum.IN_PROGRESS); |
| | | this.updateById(auctionSalesroomGoods); |
| | | |
| | | /* Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | map.put("notification_type", NotificationTypeConstant.AUCTION_SALESROOM_GOODS); |
| | | map.put("notification_time", LocalDateTime.now()); |
| | | map.put("goodsSkuId", auctionSalesroomGoods.getId()); |
| | | map.put("message_type", "start"); |
| | | map.put("type",2); |
| | | map.put("AuctionGoodsStatusEnum",auctionSalesroomGoods.getStatus()); |
| | | String msg = null; |
| | | try { |
| | | msg = objectMapper.writeValueAsString(map); |
| | | } catch (JsonProcessingException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.AUCTIONEER.getCode(), msg);*/ |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); |
| | | } |
| | | |
| | | |
| | |
| | | auctionSalesroomGoods.setStatus(AuctionGoodsStatusEnum.ENDED); |
| | | this.updateById(auctionSalesroomGoods); |
| | | |
| | | /* Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | Map<String, Object> map = new ConcurrentHashMap<>(); |
| | | map.put("notification_type", NotificationTypeConstant.AUCTION_SALESROOM_GOODS); |
| | | map.put("notification_time", LocalDateTime.now()); |
| | | map.put("goodsSkuId", auctionSalesroomGoods.getId()); |
| | | map.put("message_type", "end"); |
| | | map.put("type",2); |
| | | map.put("AuctionGoodsStatusEnum",auctionSalesroomGoods.getStatus()); |
| | | String msg = null; |
| | | try { |
| | | msg = objectMapper.writeValueAsString(map); |
| | | } catch (JsonProcessingException e) { |
| | | throw new RuntimeException(e); |
| | | } |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.AUCTIONEER.getCode(), msg);*/ |
| | | WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); |
| | | |
| | | } |
| | | |