Add base repository
This commit is contained in:
@@ -4,8 +4,12 @@ import com.cubetiqs.demo.domain.PostEntity;
|
||||
import com.cubetiqs.demo.repository.BaseRepository;
|
||||
import com.cubetiqs.demo.repository.PostRepository;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Page;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
public class PostServiceImpl extends BaseServiceImpl<PostEntity, Long> implements PostService {
|
||||
private final PostRepository postRepository;
|
||||
@@ -19,4 +23,14 @@ public class PostServiceImpl extends BaseServiceImpl<PostEntity, Long> implement
|
||||
public BaseRepository<PostEntity, Long> getRepository() {
|
||||
return postRepository;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Page<PostEntity> findAll(Pageable pageable, String q) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PostEntity> findAllActives() {
|
||||
return postRepository.findAllActives();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user