| | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.apache.shiro.SecurityUtils; |
| | | import org.jeecg.common.api.vo.Result; |
| | | import org.jeecg.common.aspect.annotation.AutoLog; |
| | | import org.jeecg.common.system.base.controller.JeecgController; |
| | | import org.jeecg.common.system.vo.LoginUser; |
| | | import org.jeecg.modules.mdc.entity.MdcTorqueConfig; |
| | | import org.jeecg.modules.mdc.service.IMdcTorqueConfigService; |
| | | import org.jeecg.modules.mdc.service.impl.MdcTorqueConfigServiceImpl; |
| | |
| | | */ |
| | | @AutoLog(value = "扭矩配置管理-分页查询") |
| | | @ApiOperation(value = "扭矩配置管理-分页查询",notes = "扭矩配置管理-分页查询") |
| | | @GetMapping("/queryWrapper") |
| | | public Result<?> queryWrapper(MdcTorqueConfig mdcTorqueConfig, |
| | | @GetMapping("/pageList") |
| | | public Result pageList(MdcTorqueConfig mdcTorqueConfig, |
| | | @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo, |
| | | @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize, |
| | | HttpServletRequest req) { |
| | | Page<MdcTorqueConfig> page=new Page<>(pageNo,pageSize); |
| | | IPage<MdcTorqueConfig> mdcTorqueConfigIPage= mdcTorqueConfigService.queryPageList(page,req); |
| | | if (mdcTorqueConfig==null){ |
| | | return Result.error("请传递有效参数"); |
| | | } |
| | | LoginUser user= (LoginUser) SecurityUtils.getSubject().getPrincipal(); |
| | | String userId= user.getId(); |
| | | Page page=new Page(pageNo,pageSize); |
| | | IPage<MdcTorqueConfig> mdcTorqueConfigIPage= mdcTorqueConfigService.pageList(userId,page,req,mdcTorqueConfig); |
| | | return Result.ok(mdcTorqueConfigIPage); |
| | | } |
| | | } |