package com.hxzk.controller;
|
|
import com.github.pagehelper.PageInfo;
|
import com.hxzk.pojo.TbAcHistoryPower;
|
import com.hxzk.service.TbAcHistoryPowerService;
|
import com.hxzk.util.result;
|
import com.hxzk.util.resultutil;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.PostMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RestController;
|
|
import java.util.List;
|
|
@RestController
|
@RequestMapping("/")
|
public class AcHistoryPowerController {
|
@Autowired
|
TbAcHistoryPowerService acHistoryPowerService;
|
|
@GetMapping("findAcPower")
|
result<List<TbAcHistoryPower>> findanchor(Integer page, Integer limit){
|
PageInfo<TbAcHistoryPower> cz= acHistoryPowerService.findAll(page, limit);
|
return resultutil.returnSuccess(cz.getTotal(), cz.getList());
|
}
|
|
@PostMapping("findAnchorPowerSearch")
|
result<List<TbAcHistoryPower>> findAnchorPowerSearch(Integer page, Integer limit,TbAcHistoryPower acHistoryPower){
|
PageInfo<TbAcHistoryPower> cz= acHistoryPowerService.findSearch(page, limit,acHistoryPower);
|
return resultutil.returnSuccess(cz.getTotal(), cz.getList());
|
}
|
|
}
|