|
|
|
@@ -12,10 +12,7 @@ import io.swagger.annotations.ApiOperation; |
|
|
|
import org.slf4j.Logger; |
|
|
|
import org.slf4j.LoggerFactory; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.web.bind.annotation.GetMapping; |
|
|
|
import org.springframework.web.bind.annotation.ModelAttribute; |
|
|
|
import org.springframework.web.bind.annotation.RequestMapping; |
|
|
|
import org.springframework.web.bind.annotation.RestController; |
|
|
|
import org.springframework.web.bind.annotation.*; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
@@ -29,22 +26,10 @@ public class WxBusinessController extends BaseController { |
|
|
|
@Autowired |
|
|
|
private WxBusinessService wxBusinessService; |
|
|
|
|
|
|
|
@ApiOperation("分页列表接口") |
|
|
|
@GetMapping("list") |
|
|
|
@ApiImplicitParams({ |
|
|
|
@ApiImplicitParam(name = "pageNum", value = "页数", dataType = "int", paramType = "query", required = true), |
|
|
|
@ApiImplicitParam(name = "pageSize", value = "每页条数", dataType = "int", paramType = "query", required = true)}) |
|
|
|
public ResultData list(WxBusiness wxBusiness, Integer pageNum, Integer pageSize) { |
|
|
|
if (null == wxBusiness) wxBusiness = new WxBusiness(); |
|
|
|
final PageInfo<WxBusiness> page = wxBusinessService.listAsPage(wxBusiness, pageNum, pageSize); |
|
|
|
return new ResultData(page); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation("业态全列表接口") |
|
|
|
@GetMapping("listAll") |
|
|
|
public ResultData listAll(@ModelAttribute WxBusiness wxBusiness) { |
|
|
|
final List<WxBusiness> busList = wxBusinessService.findListAll(); |
|
|
|
public ResultData listAll(@RequestParam Integer filter) { |
|
|
|
final List<WxBusiness> busList = wxBusinessService.findListAll(getTenantId(),filter); |
|
|
|
return new ResultData(busList); |
|
|
|
} |
|
|
|
|
|
|
|
|