package com.education.business.service.education;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.education.business.mapper.education.StuGoalInfoMapper;
import com.education.business.service.BaseService;
import com.education.common.model.PageInfo;
import com.education.model.dto.StuGoalInfoDto;
import com.education.model.entity.StuGoalInfo;
import com.education.model.request.PageParam;
import org.springframework.stereotype.Service;

/**
 * @author zhangj
 * @version 1.0
 * @create_at
 */
@Service
public class StuGoalInfoService extends BaseService<StuGoalInfoMapper, StuGoalInfo> {

    public PageInfo<StuGoalInfoDto> selectPageList(PageParam pageParam, StuGoalInfo stuGoalInfo) {
        Page<StuGoalInfoDto> page = new Page<>(pageParam.getPageNumber(), pageParam.getPageSize());
        return selectPage(baseMapper.selectPageList(page, stuGoalInfo));
    }

    @Override
    public boolean saveOrUpdate(StuGoalInfo stuGoalInfo) {
        return super.saveOrUpdate(stuGoalInfo);
    }
}