package com.ruoyi.novel.service.impl;

import org.springframework.stereotype.Service;

// NovelServiceImpl.java
@Service
public class NovelServiceImpl implements NovelService {

    @Autowired
    private NovelMapper novelMapper;

    @Override
    public List<Novel> selectNovelList(Novel novel) {
        return novelMapper.selectNovelList(novel);
    }

    @Override
    @Transactional
    public int insertNovel(Novel novel) {
        novel.setCreateTime(new Date());
        return novelMapper.insertNovel(novel);
    }

    // 其他CRUD方法...
}
