配置返回测试数据

20230922-ljl-fixBug
wangchaoxu 1 year ago
parent 074db939f3
commit 181975a3f2

@ -68,7 +68,28 @@ public class SearchChooseSourceProductListService extends SPIBaseService impleme
ret.put("total", productToDsItemPager.getTotal()); ret.put("total", productToDsItemPager.getTotal());
ret.put("page", productToDsItemPager.getPage()); ret.put("page", productToDsItemPager.getPage());
ret.put("pageSize", productToDsItemPager.getPageSize()); ret.put("pageSize", productToDsItemPager.getPageSize());
if (productToDsItemPager.getTotal()==0) {
ret = new HashMap();
List<ChooseSourceProductDTO> list = new ArrayList<>();
ChooseSourceProductDTO dto1 = new ChooseSourceProductDTO();
ChooseSourceProductDTO dto2 = new ChooseSourceProductDTO();
dto1.setName("开发商品名字11111");
dto1.setProductId("911111111");
dto1.setPrice(99.99);
dto1.setStatus(0L);
dto1.setImg("https://cbu01.alicdn.com/img/ibank/O1CN01XQ4vkl1V78Qnhpvxl_!!939772605-0-cib.jpg");
dto1.setName("开发商品名字2");
dto1.setProductId("9222222");
dto1.setPrice(81.0);
dto1.setStatus(0L);
dto1.setImg("https://cbu01.alicdn.com/img/ibank/O1CN01XQ4vkl1V78Qnhpvxl_!!939772605-0-cib.jpg");
list.add(dto1);
list.add(dto2);
ret.put("productList", list);
ret.put("total", 2);
ret.put("page", productToDsItemPager.getPage());
ret.put("pageSize", productToDsItemPager.getPageSize());
}
return R.ok(Ret.success(ret)); return R.ok(Ret.success(ret));
} }
} }

@ -59,6 +59,7 @@ if (sourceSellersObject.size() == 0) {
b.put("sellerName", "开发人员的店2"); b.put("sellerName", "开发人员的店2");
b.put("sellerIdMd5", "2234567890qwertyuio"); b.put("sellerIdMd5", "2234567890qwertyuio");
b.put("isEncryptLogisticsOrderSupportDouyin", 0); b.put("isEncryptLogisticsOrderSupportDouyin", 0);
sourceSellerList.add(a);
sourceSellerList.add(b); sourceSellerList.add(b);
} }
JSONObject retObj = new JSONObject(); JSONObject retObj = new JSONObject();

Loading…
Cancel
Save