| | |
| | | import com.ruoyi.auction.controller.management.dto.MgtScreenBidPage; |
| | | import com.ruoyi.auction.controller.management.dto.MgtScreenSalesroomGoodsDTO; |
| | | import com.ruoyi.auction.controller.management.dto.MgtScreenVideoDTO; |
| | | import com.ruoyi.auction.controller.management.vo.AuctionSalesroomQrCodeVO; |
| | | import com.ruoyi.auction.controller.management.vo.MgtAuctionBidRecordVO; |
| | | import com.ruoyi.auction.controller.management.vo.MgtAuctionSalesroomGoodsVO; |
| | | import com.ruoyi.auction.controller.management.vo.MgtAuctionSalesroomScreenVO; |
| | |
| | | @Override |
| | | public String getQrCode(Long id) throws Exception { |
| | | AuctionSalesroom auctionSalesroom = this.getById(id); |
| | | String auctionSalesroomNo = auctionSalesroom.getAuctionSalesroomNo(); |
| | | if (StringUtils.isBlank(auctionSalesroom.getQrCode())) { |
| | | AuctionSalesroomQrCodeVO vo = new AuctionSalesroomQrCodeVO(); |
| | | Long nextId = IDhelper.getNextId(); |
| | | vo.setAuctionSalesroomNo(nextId.toString()); |
| | | vo.setType(auctionSalesroom.getType().getCode()); |
| | | String url = remoteFileService.obsUpload( |
| | | CreateQrCode.createQRCodeStream(objectMapper.writeValueAsString(vo))).getData(); |
| | | auctionSalesroom.setQrCode(url); |
| | | this.updateById(auctionSalesroom); |
| | | } |
| | | return auctionSalesroom.getQrCode(); |
| | | } |
| | | |
| | |
| | | // 生成唯一编号 |
| | | Long nextId = IDhelper.getNextId(); |
| | | auctionSalesroom.setAuctionSalesroomNo(nextId.toString()); |
| | | AuctionSalesroomQrCodeVO vo = new AuctionSalesroomQrCodeVO(); |
| | | vo.setAuctionSalesroomNo(nextId.toString()); |
| | | vo.setType(auctionSalesroom.getType().getCode()); |
| | | String url = remoteFileService.obsUpload( |
| | | CreateQrCode.createQRCodeStream(nextId.toString())).getData(); |
| | | CreateQrCode.createQRCodeStream(objectMapper.writeValueAsString(vo))).getData(); |
| | | auctionSalesroom.setQrCode(url); |
| | | // 添加 |
| | | this.save(auctionSalesroom); |