package com.rf.psychological.service.impl;

import com.rf.psychological.dao.model.DepressEntity;
import com.rf.psychological.dao.repository.DepressRepository;
import com.rf.psychological.service.DepressService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Sort;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author zzf
 * @description:抑郁焦虑压力量表
 * @date 2021/1/20 18:34
 */
@Service
public class DepressServiceImpl implements DepressService {
    @Autowired
    private DepressRepository depressRepository;
    /**
     * 全量查询
     *
     * @return
     */
    @Override
    public List<DepressEntity> findAll() {
        return this.depressRepository.findAll(Sort.by("no"));
    }
}
