package org.springblade.modules.rhzf.aqxcff.service.impl;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.springblade.core.mp.base.BaseServiceImpl;
import org.springblade.modules.rhzf.aqxcff.excel.RhzfAqxcffExcel;
import org.springblade.modules.rhzf.aqxcff.mapper.RhzfAqxcffMapper;
import org.springblade.modules.rhzf.aqxcff.pojo.entity.RhzfAqxcffEntity;
import org.springblade.modules.rhzf.aqxcff.pojo.vo.RhzfAqxcffVO;
import org.springblade.modules.rhzf.aqxcff.service.IRhzfAqxcffService;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;
import java.util.Map;

/**
 * 入户走访_安全宣传防范 服务实现类
 *
 * @author wth
 * @since 2024-11-14
 */
@Service
public class RhzfAqxcffServiceImpl extends BaseServiceImpl<RhzfAqxcffMapper, RhzfAqxcffEntity> implements IRhzfAqxcffService {

	@Override
	public IPage<RhzfAqxcffVO> selectRhzfAqxcffPage(IPage<RhzfAqxcffVO> page, RhzfAqxcffVO rhzfAqxcff) {
		return page.setRecords(baseMapper.selectRhzfAqxcffPage(page, rhzfAqxcff));
	}

	@Override
	public List<RhzfAqxcffExcel> exportRhzfAqxcff(Wrapper<RhzfAqxcffEntity> queryWrapper) {
		List<RhzfAqxcffExcel> rhzfAqxcffList = baseMapper.exportRhzfAqxcff(queryWrapper);
		//rhzfAqxcffList.forEach(rhzfAqxcff -> {
		//	rhzfAqxcff.setTypeName(DictCache.getValue(DictEnum.YES_NO, RhzfAqxcffEntity.getType()));
		//});
		return rhzfAqxcffList;
	}

	@Override
	public List<RhzfAqxcffEntity> getByDzbm(Map<String, Object> params) {
		return baseMapper.getByDzbm(params);
	}

}
