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.
udi-wms-java/src/main/java/com/glxp/api/service/thrsys/BasicInsDrugService.java

29 lines
1.1 KiB
Java

package com.glxp.api.service.thrsys;
import com.github.pagehelper.PageHelper;
import com.glxp.api.entity.thrsys.BasicInsChdrugEntity;
import com.glxp.api.req.thrsys.ThrInsChDrugFeeRequest;
import com.glxp.api.req.thrsys.ThrInsDrugFeeRequest;
import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.glxp.api.entity.thrsys.BasicInsDrugEntity;
import com.glxp.api.dao.thrsys.BasicInsDrugMapper;
import java.util.Collections;
import java.util.List;
@Service
public class BasicInsDrugService extends ServiceImpl<BasicInsDrugMapper, BasicInsDrugEntity> {
public List<BasicInsDrugEntity> filterList(ThrInsDrugFeeRequest thrInsDrugFeeRequest) {
if (thrInsDrugFeeRequest == null) {
return Collections.emptyList();
}
if (thrInsDrugFeeRequest.getPage() != null) {
int offset = (thrInsDrugFeeRequest.getPage() - 1) * thrInsDrugFeeRequest.getLimit();
PageHelper.offsetPage(offset, thrInsDrugFeeRequest.getLimit());
}
return super.baseMapper.filterList(thrInsDrugFeeRequest);
}
}