You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
1.2 KiB
Java
35 lines
1.2 KiB
Java
11 months ago
|
package com.glxp.api.service.inout;
|
||
|
|
||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||
|
import com.github.pagehelper.PageHelper;
|
||
|
import com.glxp.api.dao.inout.IoSplitFifoCodeMapper;
|
||
|
import com.glxp.api.entity.inout.IoSplitFifoCodeEntity;
|
||
|
import com.glxp.api.req.inout.IoSplitFifoCodeRequest;
|
||
|
import com.glxp.api.res.inout.IoSplitCodeResponse;
|
||
|
import org.springframework.stereotype.Service;
|
||
|
|
||
|
import javax.annotation.Resource;
|
||
|
import java.util.Collections;
|
||
|
import java.util.List;
|
||
|
|
||
|
@Service
|
||
|
public class IoSplitFifoCodeService extends ServiceImpl<IoSplitFifoCodeMapper, IoSplitFifoCodeEntity> {
|
||
|
|
||
|
@Resource
|
||
|
IoSplitFifoCodeMapper splitFifoCodeMapper;
|
||
|
|
||
|
public List<IoSplitCodeResponse> filterList(IoSplitFifoCodeRequest splitFifoCodeRequest) {
|
||
|
if (splitFifoCodeRequest == null) {
|
||
|
return Collections.emptyList();
|
||
|
}
|
||
|
if (splitFifoCodeRequest.getPage() != null) {
|
||
|
int offset = (splitFifoCodeRequest.getPage() - 1) * splitFifoCodeRequest.getLimit();
|
||
|
PageHelper.offsetPage(offset, splitFifoCodeRequest.getLimit());
|
||
|
}
|
||
|
return super.baseMapper.filterList(splitFifoCodeRequest);
|
||
|
|
||
|
}
|
||
|
|
||
|
|
||
|
}
|