package org.springblade.swzdr.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.swzdr.excel.RyXsExcel;
import org.springblade.swzdr.mapper.RyXsMapper;
import org.springblade.swzdr.pojo.entity.RyXsEntity;
import org.springblade.swzdr.pojo.vo.RyXsVO;
import org.springblade.swzdr.service.IRyXsService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 人员_写实记录 服务实现类
 *
 * @author BladeX
 * @since 2024-09-13
 */
@Service
public class RyXsServiceImpl extends BaseServiceImpl<RyXsMapper, RyXsEntity> implements IRyXsService {

	@Override
	public IPage<RyXsVO> selectRyXsPage(IPage<RyXsVO> page, RyXsVO ryXs) {
		return page.setRecords(baseMapper.selectRyXsPage(page, ryXs));
	}

	@Override
	public List<RyXsExcel> exportRyXs(Wrapper<RyXsEntity> queryWrapper) {
		List<RyXsExcel> ryXsList = baseMapper.exportRyXs(queryWrapper);
		//ryXsList.forEach(ryXs -> {
		//	ryXs.setTypeName(DictCache.getValue(DictEnum.YES_NO, RyXs.getType()));
		//});
		return ryXsList;
	}

}
