| | |
| | | |
| | | /** |
| | | * 单个商品加入选品库 |
| | | * |
| | | * @param callback |
| | | * @param storageIds |
| | | * |
| | | * id数组 |
| | | * @param out |
| | | */ |
| | | @RequestMapping(value = "accordtorage", method = RequestMethod.POST) |
| | | public void accordtorage(AcceptData acceptData, Long uid, Long auctionId, PrintWriter out) { |
| | | public void accordtorage(AcceptData acceptData, Long uid, String auctionId, PrintWriter out) { |
| | | |
| | | if (auctionId == null) { |
| | | out.print(JsonUtil.loadFalseResult("未选择商品")); |
| | |
| | | userGoodsStorageService.deleteByPrimaryKey(userGoodsStorage.getId()); |
| | | } else { |
| | | // 加入选品库 |
| | | Set<Long> set = new HashSet<Long>(); |
| | | Set<String> set = new HashSet<>(); |
| | | set.add(auctionId); |
| | | userGoodsStorageService.save(uid, set, Constant.SOURCE_TYPE_TAOBAO); |
| | | storageState = true; |
| | |
| | | * @param acceptData |
| | | * @param uid |
| | | * 用户id |
| | | * @param auctionId |
| | | * 淘宝商品id |
| | | * @param out |
| | | */ |
| | |
| | | public void addStorage(AcceptData acceptData, Long uid, String auctionIds, Integer goodsType,PrintWriter out) { |
| | | try { |
| | | Gson gson = new Gson(); |
| | | Set<Long> set = gson.fromJson(auctionIds, new TypeToken<HashSet<Long>>() {}.getType()); |
| | | Set<String> set = gson.fromJson(auctionIds, new TypeToken<HashSet<String>>() {}.getType()); |
| | | if (set == null || set.size() == 0) { |
| | | out.print(JsonUtil.loadFalseResult("未选择商品")); |
| | | return; |
| | |
| | | |
| | | /** |
| | | * 删除 |
| | | * |
| | | * @param callback |
| | | * |
| | | * @param storageIds |
| | | * id数组 |
| | | * @param out |
| | |
| | | |
| | | /** |
| | | * 分享商品返回二维码图片 |
| | | * |
| | | * @param callback |
| | | * |
| | | * @param storageIds |
| | | * id数组 |
| | | * @param out |