package com.td.Dawa.game.excelcharacterattri.service;

import com.td.Dawa.common.service.*;
import com.td.Dawa.game.excelcharacterattri.pojo.ExcelCharacterAttri;
import com.td.Dawa.game.excelcharacterattri.vo.ExcelCharacterAttriVo;
import com.td.Dawa.game.excelcharacterattri.repository.ExcelCharacterAttriRepository;
import com.td.Dawa.game.excelcharactercreate.service.ExcelCharacterCreateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;

@Service
@Transactional
public class ExcelCharacterAttriServiceImpl extends CommonServiceImpl<ExcelCharacterAttriVo, ExcelCharacterAttri, Integer> implements ExcelCharacterAttriService{

    @PersistenceContext
    private EntityManager em;
    @Autowired
    private ExcelCharacterAttriRepository excelCharacterAttriRepository;

    @Autowired
    private ExcelCharacterCreateService excelCharacterCreateService;

    @Override
    public ExcelCharacterAttri findByRoleType(Integer roleType) {
        return excelCharacterAttriRepository.findByRoleType(roleType).orElse(null);
    }




}
