package com.fs.his.service.impl;

import java.util.List;
import com.fs.common.utils.DateUtils;
import com.fs.his.param.FsDoctorBillListSParam;
import com.fs.his.param.FsDoctorBillParam;
import com.fs.his.vo.FsDoctorBillListSVO;
import com.fs.his.vo.FsDoctorBillVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.fs.his.mapper.FsDoctorBillMapper;
import com.fs.his.domain.FsDoctorBill;
import com.fs.his.service.IFsDoctorBillService;

/**
 * 医生账单记录Service业务层处理
 *
 * @author fs
 * @date 2023-06-25
 */
@Service
public class FsDoctorBillServiceImpl implements IFsDoctorBillService
{
    @Autowired
    private FsDoctorBillMapper fsDoctorBillMapper;

    /**
     * 查询医生账单记录
     *
     * @param billId 医生账单记录主键
     * @return 医生账单记录
     */
    @Override
    public FsDoctorBill selectFsDoctorBillByBillId(Long billId)
    {
        return fsDoctorBillMapper.selectFsDoctorBillByBillId(billId);
    }

    /**
     * 查询医生账单记录列表
     *
     * @param fsDoctorBill 医生账单记录
     * @return 医生账单记录
     */
    @Override
    public List<FsDoctorBill> selectFsDoctorBillList(FsDoctorBill fsDoctorBill)
    {
        return fsDoctorBillMapper.selectFsDoctorBillList(fsDoctorBill);
    }

    /**
     * 新增医生账单记录
     *
     * @param fsDoctorBill 医生账单记录
     * @return 结果
     */
    @Override
    public int insertFsDoctorBill(FsDoctorBill fsDoctorBill)
    {
        fsDoctorBill.setCreateTime(DateUtils.getNowDate());
        return fsDoctorBillMapper.insertFsDoctorBill(fsDoctorBill);
    }

    /**
     * 修改医生账单记录
     *
     * @param fsDoctorBill 医生账单记录
     * @return 结果
     */
    @Override
    public int updateFsDoctorBill(FsDoctorBill fsDoctorBill)
    {
        return fsDoctorBillMapper.updateFsDoctorBill(fsDoctorBill);
    }

    /**
     * 批量删除医生账单记录
     *
     * @param billIds 需要删除的医生账单记录主键
     * @return 结果
     */
    @Override
    public int deleteFsDoctorBillByBillIds(Long[] billIds)
    {
        return fsDoctorBillMapper.deleteFsDoctorBillByBillIds(billIds);
    }

    /**
     * 删除医生账单记录信息
     *
     * @param billId 医生账单记录主键
     * @return 结果
     */
    @Override
    public int deleteFsDoctorBillByBillId(Long billId)
    {
        return fsDoctorBillMapper.deleteFsDoctorBillByBillId(billId);
    }

    @Override
    public List<FsDoctorBillVO> selectFsDoctorBillListVO(FsDoctorBillParam fsDoctorBill) {
        return fsDoctorBillMapper.selectFsDoctorBillListVO(fsDoctorBill);
    }

    @Override
    public List<FsDoctorBillListSVO> selectFsDoctorBillListSVO(FsDoctorBillListSParam param) {
        return fsDoctorBillMapper.selectFsDoctorBillListSVO(param);
    }
}
