package com.ssj.service.sys.imlibuser.service;

import com.ssj.bean.sys.imlibuser.TbClass;
import com.ssj.framework.core.common.service.BaseService;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

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

public interface TbClassService extends BaseService<TbClass, String> {
	
	 TbClass getTbClassByLibId(String libId,String className);
	 TbClass getTbClassGradeByLibId(String libId,String grade,String className);
	 
	 Page<Map<String, Object>> findClassByPage(Map<String, Object> searchParam, Pageable pageable);

	/**
	 * 查询默认班级， 如果不存在，则新建
	 * @param libId
	 * @return
	 */
	TbClass getDefaultTbClassByLibId(String libId);

	List<TbClass> getTbClassListByLibId(String libId);

	List<TbClass> getTbClassSchoolNameByLibId(String libId);

	List<TbClass> getTbClassListByClassName(String libId,String className);
	
	/*
	 *创建默认班级时候， 同步学生数据
	 */
	void syncTbClassServiceByStudent(String libId,TbClass tbClass);
	
	/*
	 * 创建默认班级时候，同步老师数据
	 */
	void syncTbClassServiceByTeacher(String libId,TbClass tbClass);

	/**
	 * 查找馆里默认班级
	 * @param libId
	 * @return
	 */
	TbClass findDefaultClass(String libId);

	/**
	 * 更新班级
	 */
	void updateByClassIdAndClassName(String classId,String className);


	/**
	 * 查询班级列表
	 */

	 
}
