package com.rf.psychological.scale.service.impl;

import com.rf.psychological.scale.dao.model.Precautions;
import com.rf.psychological.scale.dao.repository.PrecautionsRepository;
import com.rf.psychological.scale.service.PrecautionsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 认知任务注意事项关联业务
 */
@Service
public class PrecautionsServiceImpl implements PrecautionsService {

    @Autowired
    private PrecautionsRepository repository;

    /**
     * 获取导认知任务注意事项
     * @param cognitiveId 认知任务id
     * @return
     */
    @Override
    public Precautions findOneByCognitiveId(String cognitiveId) {
        return repository.findPrecautionsByCognitionId(cognitiveId);
    }
}
