package com.emr.service.emrCode;

import com.emr.dao.emrCode.T_Herb_DiagMapper;
import com.emr.entity.emrCode.T_Herb_Diag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.Date;
import java.util.List;

/**
 * @ProjectName:
 * @Description:
 * @Param 传输参数
 * @Return
 * @Author: 曾文和
 * @CreateDate: 2019/6/12 16:34
 * @UpdateUser: 曾文和
 * @UpdateDate: 2019/6/12 16:34
 * @UpdateRemark: 更新说明
 * @Version: 1.0
 */
@Service
@Transactional
public class HerbDiagServiceImpl implements HerbDiagService{
    @Autowired
    private T_Herb_DiagMapper herbDiagMapper;
    @Override
    public List<T_Herb_Diag> selectAllByPatientId(String patientId, Short herbNo) {
        return herbDiagMapper.selectAllByPatientId(patientId, herbNo);
    }

    @Override
    public int insert(T_Herb_Diag record) {
        return herbDiagMapper.insert(record);
    }

    @Override
    public void updateByPrimaryKeySelective(T_Herb_Diag record) {
        herbDiagMapper.updateByPrimaryKeySelective(record);
    }

    @Override
    public void deleteHerbDiagByPatientIdAndHerbNo(String patientId, Short herbNo) {
        herbDiagMapper.deleteHerbDiagByPatientIdAndHerbNo(patientId, herbNo);
    }
}
