using PoJun.Dapper;
using ASHermed.SinoInterface.Api.IRepository.Test;
using ASHermed.SinoInterface.Entity.Test;
using ASHermed.SinoInterface.Repository.MySql;
using ASHermed.SinoInterface.Tools;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ASHermed.SinoInterface.Api.ContractModel.App;
using ASHermed.SinoInterface.Api.IRepository;

namespace ASHermed.SinoInterface.Api.MySqlRepository
{

    public class OutDoctorStatusInfoRepository : BaseRepositoryToASHermed_SinoInterface<Out_Doctor_Status_Info>, IOutDoctorStatusInfoRepository
    {

        public Out_Doctor_Status_Info SelectByDoc(int doctorId)
        {
            var parms = new Dictionary<string, object>();
            StringBuilder str = new StringBuilder();
            str.Append(@" select * from out_doctor_status_info
                                  where `STATUS`=1 and DOCTOR_ID=@DOCTOR_ID");
            parms.Add("@DOCTOR_ID", doctorId);

            var result = Query<Out_Doctor_Status_Info>(str.ToString(), parms);
            return result.FirstOrDefault();
        }




    }


}
