@Test public void testQueryOnLotteryInfo() throws Exception { JSONObject object = new JSONObject(); object.put("page",1); post("/api/v1/pub/commodity/onlottery",object.toJSONString()); }
@ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) public JSONObject queryOnLotteryInfo(@RequestParam("page") int page) { List<Map<String, Object>> mapList = cService.selectOnLottery(page); return success(mapList); }
CommoditysController extends BaseController { @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) public JSONObject queryOnLotteryInfo(@RequestParam("page") int page) { List<Map<String, Object>> mapList = cService.selectOnLottery(page); return success(mapList); } }
CommoditysController extends BaseController { @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) public JSONObject queryOnLotteryInfo(@RequestParam("page") int page) { List<Map<String, Object>> mapList = cService.selectOnLottery(page); return success(mapList); }  }
CommoditysController extends BaseController { @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) public JSONObject queryOnLotteryInfo(@RequestParam("page") int page) { List<Map<String, Object>> mapList = cService.selectOnLottery(page); return success(mapList); }  @ResponseBody @ApiOperation("搜索商品信息（默认搜所有）参数：category 类型；commName 商品名; lastCommName 最后一个商品Id") @RequestMapping(value = "/api/v1/pub/commodity/search", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam(name = "categoryId", required = false) Integer categoryId, @RequestParam(name = "commName", required = false) String commName, @RequestParam(name = "lastCommId", required = false) Long lastCommId); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/recommend", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryRecommend(); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/search/category", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam("categoryId") Integer categoryId, @RequestParam("lastCommId") Long lastCommId); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/search/name", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam("name") String name, @RequestParam("lastCommId") Long lastCommId); @ResponseBody @ApiOperation("查看单件商品详情") @RequestMapping(value = "/api/v1/pub/commodity/info", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditysInfo(@RequestParam("commid") Long commodityid); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryOnLotteryInfo(@RequestParam("page") int page); @ResponseBody @ApiOperation("查看单件正在开奖的商品") @RequestMapping(value = "/api/v1/pub/commodity/onlottery/one", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryOnLotteryInfo(@RequestParam("commId") Long commId); @ResponseBody @ApiOperation("最新揭晓") @RequestMapping(value = "/api/v1/pub/commodity/announce", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryNewestAnnounced(@RequestParam("lastCommId") Long lastCommId); }
CommoditysController extends BaseController { @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) public JSONObject queryOnLotteryInfo(@RequestParam("page") int page) { List<Map<String, Object>> mapList = cService.selectOnLottery(page); return success(mapList); }  @ResponseBody @ApiOperation("搜索商品信息（默认搜所有）参数：category 类型；commName 商品名; lastCommName 最后一个商品Id") @RequestMapping(value = "/api/v1/pub/commodity/search", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam(name = "categoryId", required = false) Integer categoryId, @RequestParam(name = "commName", required = false) String commName, @RequestParam(name = "lastCommId", required = false) Long lastCommId); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/recommend", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryRecommend(); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/search/category", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam("categoryId") Integer categoryId, @RequestParam("lastCommId") Long lastCommId); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/search/name", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditys(@RequestParam("name") String name, @RequestParam("lastCommId") Long lastCommId); @ResponseBody @ApiOperation("查看单件商品详情") @RequestMapping(value = "/api/v1/pub/commodity/info", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryCommoditysInfo(@RequestParam("commid") Long commodityid); @ResponseBody @RequestMapping(value = "/api/v1/pub/commodity/onlottery", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryOnLotteryInfo(@RequestParam("page") int page); @ResponseBody @ApiOperation("查看单件正在开奖的商品") @RequestMapping(value = "/api/v1/pub/commodity/onlottery/one", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryOnLotteryInfo(@RequestParam("commId") Long commId); @ResponseBody @ApiOperation("最新揭晓") @RequestMapping(value = "/api/v1/pub/commodity/announce", method = {RequestMethod.POST, RequestMethod.GET}) JSONObject queryNewestAnnounced(@RequestParam("lastCommId") Long lastCommId);  }