| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768 |
- package cn.com.goldenwater.dcproj.service.impl.zhejiang;
- import cn.com.goldenwater.dcproj.constValue.StateEnum;
- import cn.com.goldenwater.dcproj.dao.AttCwsBaseDao;
- import cn.com.goldenwater.dcproj.dao.BisZhejiangCountryFeeDao;
- import cn.com.goldenwater.dcproj.dao.BisZhejiangVillRgstrDao;
- import cn.com.goldenwater.dcproj.model.AttCwsBase;
- import cn.com.goldenwater.dcproj.model.BisZhejiangCountryFee;
- import cn.com.goldenwater.dcproj.model.BisZhejiangVillRgstr;
- import cn.com.goldenwater.dcproj.param.BisZhejiangCountryFeeParam;
- import cn.com.goldenwater.dcproj.param.CwsParam;
- import cn.com.goldenwater.dcproj.service.BisZhejiangCountryFeeService;
- import cn.com.goldenwater.core.service.AbstractCrudService;
- import com.github.pagehelper.PageHelper;
- import com.github.pagehelper.PageInfo;
- import org.apache.commons.lang3.StringUtils;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.stereotype.Service;
- import org.springframework.transaction.annotation.Transactional;
- import java.util.List;
- /**
- * @author lune
- * @date 2020-5-11
- */
- @Service
- @Transactional
- public class BisZhejiangCountryFeeServiceImpl extends AbstractCrudService<BisZhejiangCountryFee, BisZhejiangCountryFeeParam> implements BisZhejiangCountryFeeService {
- @Autowired
- private BisZhejiangCountryFeeDao bisZhejiangCountryFeeDao;
- @Autowired
- private BisZhejiangVillRgstrDao bisZhejiangVillRgstrDao;
- @Autowired
- private AttCwsBaseDao attCwsBaseDao;
- public BisZhejiangCountryFeeServiceImpl(BisZhejiangCountryFeeDao bisZhejiangCountryFeeDao) {
- super(bisZhejiangCountryFeeDao);
- this.bisZhejiangCountryFeeDao = bisZhejiangCountryFeeDao;
- }
- @Override
- public void updateWaterOrPay(String regstrId) {
- if(StringUtils.isBlank(regstrId)){
- return;
- }
- BisZhejiangCountryFeeParam countryFeeParam=new BisZhejiangCountryFeeParam();
- countryFeeParam.setRgstrId(regstrId);
- countryFeeParam.setStatus(StateEnum.COMASTSTATE.getKey());
- BisZhejiangVillRgstr bisNewVillRgstr=new BisZhejiangVillRgstr();
- List<BisZhejiangCountryFee> countryFeeList=bisZhejiangCountryFeeDao.findList(countryFeeParam);
- if(!countryFeeList.isEmpty()){
- bisNewVillRgstr.setId(regstrId);
- bisNewVillRgstr.setWaterSafeOrPay(StateEnum.COMASTSTATE.getKey());
- bisZhejiangVillRgstrDao.update(bisNewVillRgstr);
- }
- }
- @Override
- public PageInfo<AttCwsBase> pageNotDC(CwsParam cwsParam) {
- PageHelper.startPage(cwsParam.getPageNum(), cwsParam.getPageSize());
- List<AttCwsBase> bisInspBaseDtos = attCwsBaseDao.queryListByRegstrIdNotDC(cwsParam);
- PageInfo page = new PageInfo(bisInspBaseDtos);
- return page;
- }
- }
|