コード例 #1
0
 public async Task AddConsultationVitals(ConsultationVitals model)
 {
     model.Vitalentrydate = DateTime.Now;
     model.Encodeddate    = DateTime.Now;
     model.Isactive       = 1;
     var result = _context.ConsultationVitals.Add(model);
     await _context.SaveChangesAsync();
 }
コード例 #2
0
        public async Task UpdateVitalSigns(ConsultationVitals model)
        {
            var vitalSigns = await _context.ConsultationVitals.Where(q => q.Patientid == model.Patientid && q.EncounterId == model.EncounterId && q.Id == model.Id).FirstOrDefaultAsync();

            vitalSigns.Abnormal             = model.Abnormal;
            vitalSigns.Anyfall              = model.Anyfall;
            vitalSigns.Bmi                  = model.Bmi;
            vitalSigns.Bpsystolic           = model.Bpdiastolic;
            vitalSigns.Bpsystolic           = model.Bpsystolic;
            vitalSigns.Bsa                  = model.Bsa;
            vitalSigns.Convertedunitid      = model.Convertedunitid;
            vitalSigns.Convertedvalue       = model.Convertedvalue;
            vitalSigns.dizziness            = model.dizziness;
            vitalSigns.Encodedby            = model.Encodedby;
            vitalSigns.Encodeddate          = model.Encodeddate = DateTime.Now;
            vitalSigns.Enteredunitid1       = model.Enteredunitid1;
            vitalSigns.Enteredvalue1        = model.Enteredvalue1;
            vitalSigns.FastingBloodSugar    = model.FastingBloodSugar;
            vitalSigns.fetalheartrate       = model.fetalheartrate;
            vitalSigns.HeadCircumference    = model.HeadCircumference;
            vitalSigns.Height               = model.Height;
            vitalSigns.Isactive             = model.Isactive;
            vitalSigns.meanarterialpressure = model.meanarterialpressure;
            vitalSigns.MidArmCircumference  = model.MidArmCircumference;
            vitalSigns.needhelpstanding     = model.needhelpstanding;
            vitalSigns.PainScore            = model.PainScore;
            vitalSigns.Pulse                = model.Pulse;
            vitalSigns.RandomBloodSugar     = model.RandomBloodSugar;
            vitalSigns.Remarks              = model.Remarks;
            vitalSigns.Respiration          = model.Respiration;
            vitalSigns.Spo2                 = model.Spo2;
            vitalSigns.Temperature          = model.Temperature;
            vitalSigns.Templatefieldid      = model.Templatefieldid;
            vitalSigns.UrinalysisBil        = model.UrinalysisBil;
            vitalSigns.UrinalysisEry        = model.UrinalysisEry;
            vitalSigns.UrinalysisGlu        = model.UrinalysisGlu;
            vitalSigns.UrinalysisHb         = model.UrinalysisHb;
            vitalSigns.UrinalysisKet        = model.UrinalysisKet;
            vitalSigns.UrinalysisLeu        = model.UrinalysisLeu;
            vitalSigns.UrinalysisNit        = model.UrinalysisNit;
            vitalSigns.UrinalysisPh         = model.UrinalysisPh;
            vitalSigns.UrinalysisPro        = model.UrinalysisPro;
            vitalSigns.UrinalysisSg         = model.UrinalysisSg;
            vitalSigns.UrinalysisUbg        = model.UrinalysisUbg;
            vitalSigns.Valueid              = model.Valueid;
            vitalSigns.Vitalentrydate       = model.Vitalentrydate;
            vitalSigns.Weight               = model.Weight;

            _context.Update(vitalSigns);
            await _context.SaveChangesAsync();
        }
コード例 #3
0
        public async Task <IActionResult> UpdateVitalSigns(ConsultationVitals model)
        {
            try
            {
                await _VitalSignsRepository.UpdateVitalSigns(model);

                var status = true;
                return(Ok(status));
            }
            catch (Exception ex)
            {
                var status = false;
                return(BadRequest(status));
            }
        }