From 21a9aa320b3eeb072bcd7d3fa883587d57b6ccbb Mon Sep 17 00:00:00 2001 From: fuliqi <fuliqi@qq.com> Date: 星期五, 31 五月 2024 14:52:33 +0800 Subject: [PATCH] 日志指定表名,试卷实体类修改 --- src/main/java/com/ycl/jxkg/service/impl/SubjectServiceImpl.java | 23 +++++------------------ 1 files changed, 5 insertions(+), 18 deletions(-) diff --git a/src/main/java/com/ycl/jxkg/service/impl/SubjectServiceImpl.java b/src/main/java/com/ycl/jxkg/service/impl/SubjectServiceImpl.java index 63a67fb..d4e4a80 100644 --- a/src/main/java/com/ycl/jxkg/service/impl/SubjectServiceImpl.java +++ b/src/main/java/com/ycl/jxkg/service/impl/SubjectServiceImpl.java @@ -1,36 +1,23 @@ package com.ycl.jxkg.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; import com.ycl.jxkg.domain.Subject; import com.ycl.jxkg.mapper.SubjectMapper; import com.ycl.jxkg.service.SubjectService; import com.ycl.jxkg.vo.admin.education.SubjectPageRequestVO; import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageInfo; +import lombok.RequiredArgsConstructor; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import java.util.List; @Service -public class SubjectServiceImpl extends BaseServiceImpl<Subject> implements SubjectService { +@RequiredArgsConstructor +public class SubjectServiceImpl extends ServiceImpl<SubjectMapper,Subject> implements SubjectService { private final SubjectMapper subjectMapper; - - @Autowired - public SubjectServiceImpl(SubjectMapper subjectMapper) { - super(subjectMapper); - this.subjectMapper = subjectMapper; - } - - @Override - public Subject selectById(Integer id) { - return super.selectById(id); - } - - @Override - public int updateByIdFilter(Subject record) { - return super.updateByIdFilter(record); - } @Override public List<Subject> getSubjectByLevel(Integer level) { @@ -44,7 +31,7 @@ @Override public Integer levelBySubjectId(Integer id) { - return this.selectById(id).getLevel(); + return baseMapper.selectById(id).getLevel(); } @Override -- Gitblit v1.8.0