コード例 #1
0
        public int SaveAnesInputData(MED_ANESTHESIA_INPUT_DATA item)
        {
            int result = dapper.Set <MED_ANESTHESIA_INPUT_DATA>().Save(item) == true ? 1 : 0;

            dapper.SaveChanges();

            return(result);
        }
コード例 #2
0
        public RequestResult <MED_ANESTHESIA_INPUT_DATA> GetAnesthestaInputData(string patID, int visitID, int operID)
        {
            MED_ANESTHESIA_INPUT_DATA data = _careDocService.GetAnesthestaInputData(patID, visitID, operID);

            if (data == null)
            {
                return(Failed <MED_ANESTHESIA_INPUT_DATA>("获取信息错误。"));
            }
            else
            {
                return(Success(data));
            }
        }
コード例 #3
0
        public MED_ANESTHESIA_INPUT_DATA GetAnesthestaInputData(string patientid, int visitid, int oprtid)
        {
            MED_ANESTHESIA_INPUT_DATA inputData = operationInfoRepository.GetAnesInputData(patientid, visitid, oprtid).Data;

            if (inputData == null)
            {
                inputData            = new MED_ANESTHESIA_INPUT_DATA();
                inputData.PATIENT_ID = patientid;
                inputData.VISIT_ID   = visitid;
                inputData.OPER_ID    = oprtid;
            }
            return(inputData);
        }
コード例 #4
0
 /// <summary>
 /// 载入数据
 /// </summary>
 public override void LoadData()
 {
     _masterRow = AnesInfoService.ClientInstance.GetOperationMaster(ExtendAppContext.Current.PatientInformationExtend.PATIENT_ID,
                                                                    ExtendAppContext.Current.PatientInformationExtend.VISIT_ID, ExtendAppContext.Current.PatientInformationExtend.OPER_ID);
     if (_masterRow != null && !string.IsNullOrEmpty(_masterRow.PATIENT_ID))
     {
         _anesInputData     = CareDocService.ClientInstance.GetAnesthestaInputData(_masterRow.PATIENT_ID, _masterRow.VISIT_ID, _masterRow.OPER_ID);
         _patsInHospitalRow = AnesInfoService.ClientInstance.GetPatsInHospitalListByID(_masterRow.PATIENT_ID).OrderByDescending(c => c.VISIT_ID).ToList().First();
         _patMasterIndexRow = AnesInfoService.ClientInstance.GetPatMasterIndex(_masterRow.PATIENT_ID).First();
         OPER_ROOM_NO       = _masterRow.OPER_ROOM_NO;
         SEQUENCE           = _masterRow.SEQUENCE;
         PATIENT_ID         = _masterRow.PATIENT_ID;
         INP_NO             = _patsInHospitalRow.INP_NO;
         NAME                      = _patMasterIndexRow.NAME;
         SEX                       = _patMasterIndexRow.SEX;
         DATE_OF_BIRTH             = _patMasterIndexRow.DATE_OF_BIRTH;
         BED_NO                    = _masterRow.BED_NO;
         DEPT_NAME                 = _masterRow.DEPT_NAME;
         AGE                       = DateDiff.CalAge((DateTime)_patMasterIndexRow.DATE_OF_BIRTH, _masterRow.SCHEDULED_DATE_TIME.Value);
         CANCELED_TYPE             = _anesInputData.CANCELED_TYPE == "1" ? true : false;
         SPINAL_ANES_COMP          = _anesInputData.SPINAL_ANES_COMP == 1 ? true : false;
         CONS_DISTURBANCE          = _anesInputData.CONS_DISTURBANCE == 1 ? true : false;
         RES_TRACT_OBSTRUCE        = _anesInputData.RES_TRACT_OBSTRUCE == 1 ? true : false;
         TRACHEA_6H                = _anesInputData.TRACHEA_6H == 1 ? true : false;
         CENTRAL_VENOUS            = _anesInputData.CENTRAL_VENOUS == 1 ? true : false;
         OXYGEN_SATURATION         = _anesInputData.OXYGEN_SATURATION == 1 ? true : false;
         AFTER_ANES_COMA           = _anesInputData.AFTER_ANES_COMA == 1 ? true : false;
         ANES_ANAPHYLAXIS          = _anesInputData.ANES_ANAPHYLAXIS == 1 ? true : false;
         TRACHEA_HOARSE            = _anesInputData.TRACHEA_HOARSE == 1 ? true : false;
         ANES_DEATH                = _anesInputData.ANES_DEATH == 1 ? true : false;
         PACU_3H                   = _anesInputData.PACU_3H == "1" ? true : false;
         PACU_TEMPERATURE          = _anesInputData.PACU_TEMPERATURE == 1 ? true : false;
         NO_PLAN_IN_ICU            = _anesInputData.NO_PLAN_IN_ICU == 1 ? true : false;
         BLOOD_EVENT               = _anesInputData.BLOOD_EVENT == 1 ? true : false;
         OPER_EVENT                = _anesInputData.OPER_EVENT == 1 ? true : false;
         ANES_EVENT                = _anesInputData.ANES_EVENT == 1 ? true : false;
         PAT_INDETIFICATION        = _anesInputData.PAT_INDETIFICATION == 1 ? true : false;
         OTHER_EVENT               = _anesInputData.OTHER_EVENT == 1 ? true : false;
         this.TRACHEA_REMOVE       = _anesInputData.TRACHEA_REMOVE == 1 ? true : false;
         this.ANES_START_24H_DEATH = _anesInputData.ANES_START_24H_DEATH == 1 ? true : false;
         this.ANES_START_24H_STOP  = _anesInputData.ANES_START_24H_STOP == 1 ? true : false;
         UNEXPECT_EVENT_REASON     = _anesInputData.UNEXPECT_EVENT_REASON;
         PREVENT_STEP              = _anesInputData.PREVENT_STEP;
         EVENT_COURSE              = _anesInputData.EVENT_COURSE;
     }
 }
コード例 #5
0
        private void InitalizationData()
        {
            using (BackgroundWorker worker = new BackgroundWorker())
            {
                worker.DoWork += delegate(object sender, DoWorkEventArgs e)
                {
                    _operMaster = operationInfoRepository.GetOperMaster(_patientID, _visitID, _operID).Data;

                    _anesPlan = operationInfoRepository.GetAnesPlan(_patientID, _visitID, _operID).Data;

                    _operMasterExt = operationInfoRepository.GetOperMasterExt(_patientID, _visitID, _operID).Data;

                    _anesInputData = operationInfoRepository.GetAnesInputData(_patientID, _visitID, _operID).Data;

                    _anesEventList = operationInfoRepository.GetAnesEventList(_patientID, _visitID, _operID).Data;
                };
                worker.RunWorkerCompleted += delegate(object sender, RunWorkerCompletedEventArgs e)
                {
                    OutRoomDataLoad();
                };
                worker.RunWorkerAsync();
            }
        }
コード例 #6
0
 public RequestResult <bool> SaveAnesInputData(MED_ANESTHESIA_INPUT_DATA data)
 {
     return(Success(_careDocService.SaveAnesInputData(data)));
 }
コード例 #7
0
        private List <KeyValue> GetFieldNames(string tableName)
        {
            List <KeyValue> list      = new List <KeyValue>();
            DataTable       dataTable = new DataTable();

            if (tableName.ToUpper().Trim().Equals("MED_OPERATION_MASTER"))
            {
                MED_OPERATION_MASTER master = new MED_OPERATION_MASTER();
                foreach (string column in master.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPERATION_MASTER_EXT"))
            {
                MED_OPERATION_MASTER_EXT ext = new MED_OPERATION_MASTER_EXT();
                foreach (string column in ext.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_PAT_MASTER_INDEX"))
            {
                MED_PAT_MASTER_INDEX tmp = new MED_PAT_MASTER_INDEX();
                foreach (string column in tmp.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_PATS_IN_HOSPITAL"))
            {
                MED_PATS_IN_HOSPITAL pats = new MED_PATS_IN_HOSPITAL();
                foreach (string column in pats.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_RECOVER"))
            {
                MED_ANESTHESIA_RECOVER tmp = new MED_ANESTHESIA_RECOVER();
                foreach (string column in tmp.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_INQUIRY"))
            {
                MED_ANESTHESIA_INQUIRY tmp = new MED_ANESTHESIA_INQUIRY();
                foreach (string column in tmp.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_SAFETY_CHECKS"))
            {
                MED_SAFETY_CHECKS safety = new MED_SAFETY_CHECKS();
                foreach (string column in safety.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_PAT_VISIT"))
            {
                MED_PAT_VISIT visit = new MED_PAT_VISIT();
                foreach (string column in visit.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_PLAN"))
            {
                MED_ANESTHESIA_PLAN plan = new MED_ANESTHESIA_PLAN();
                foreach (string column in plan.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_PLAN_EXAM"))
            {
                MED_ANESTHESIA_PLAN_EXAM plan = new MED_ANESTHESIA_PLAN_EXAM();
                foreach (string column in plan.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_PLAN_PMH"))
            {
                MED_ANESTHESIA_PLAN_PMH plan = new MED_ANESTHESIA_PLAN_PMH();
                foreach (string column in plan.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_HIS_USERS"))
            {
                MED_HIS_USERS users = new MED_HIS_USERS();
                foreach (string column in users.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_DEPT_DICT"))
            {
                MED_DEPT_DICT dept = new MED_DEPT_DICT();
                foreach (string column in dept.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_DIAGNOSIS_DICT"))
            {
                MED_DIAGNOSIS_DICT dept = new MED_DIAGNOSIS_DICT();
                foreach (string column in dept.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPERATION_DICT"))
            {
                MED_OPERATION_DICT dept = new MED_OPERATION_DICT();
                foreach (string column in dept.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_DICT"))
            {
                MED_ANESTHESIA_DICT dept = new MED_ANESTHESIA_DICT();
                foreach (string column in dept.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPERATING_ROOM"))
            {
                MED_OPERATING_ROOM dept = new MED_OPERATING_ROOM();
                foreach (string column in dept.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_PREOPERATIVE_EXPANSION"))
            {
                MED_PREOPERATIVE_EXPANSION row = new MED_PREOPERATIVE_EXPANSION();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPERATION_EXTENDED"))
            {
                MED_OPERATION_EXTENDED row = new MED_OPERATION_EXTENDED();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_POSTOPERATIVE_EXTENDED"))
            {
                MED_POSTOPERATIVE_EXTENDED row = new MED_POSTOPERATIVE_EXTENDED();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_PACU_SORCE"))
            {
                MED_PACU_SORCE row = new MED_PACU_SORCE();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPERATION_ANALGESIC_MASTER"))
            {
                MED_OPERATION_ANALGESIC_MASTER row = new MED_OPERATION_ANALGESIC_MASTER();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPER_ANALGESIC_MEDICINE"))
            {
                MED_OPER_ANALGESIC_MEDICINE row = new MED_OPER_ANALGESIC_MEDICINE();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPER_ANALGESIC_TOTAL"))
            {
                MED_OPER_ANALGESIC_TOTAL row = new MED_OPER_ANALGESIC_TOTAL();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_OPER_RISK_ESTIMATE"))
            {
                MED_OPER_RISK_ESTIMATE row = new MED_OPER_RISK_ESTIMATE();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_INPUT_DICT"))
            {
                MED_ANESTHESIA_INPUT_DICT row = new MED_ANESTHESIA_INPUT_DICT();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            else if (tableName.ToUpper().Trim().Equals("MED_ANESTHESIA_INPUT_DATA"))
            {
                MED_ANESTHESIA_INPUT_DATA row = new MED_ANESTHESIA_INPUT_DATA();
                foreach (string column in row.GetPropsName())
                {
                    list.Add(new KeyValue(GetFieldAlias(column), column));
                }
            }
            if (!string.IsNullOrEmpty(_tableName))
            {
                foreach (DataRow row in dataTable.Rows)
                {
                    list.Add(new KeyValue(row[_codeField].ToString(), row[_nameField].ToString()));
                }
            }
            else
            {
                foreach (DataColumn column in dataTable.Columns)
                {
                    list.Add(new KeyValue(GetFieldAlias(column.ColumnName), column.ColumnName));
                }
            }
            return(list);
        }
コード例 #8
0
        private void OutRoomDataLoad()
        {
            if (_operMaster != null)
            {
                lblOperRoom.Text = _operMaster.OPER_ROOM_NO;
                lblSequence.Text = _operMaster.SEQUENCE.Value.ToString();
            }
            else
            {
                _operMaster            = new MED_OPERATION_MASTER();
                _operMaster.PATIENT_ID = _patientID;
                _operMaster.VISIT_ID   = _visitID;
                _operMaster.OPER_ID    = _operID;
            }
            if (_anesPlan != null)
            {
            }
            else
            {
                _anesPlan            = new MED_ANESTHESIA_PLAN();
                _anesPlan.PATIENT_ID = _patientID;
                _anesPlan.VISIT_ID   = _visitID;
                _anesPlan.OPER_ID    = _operID;
            }
            if (_operMasterExt == null)
            {
                _operMasterExt            = new MED_OPERATION_MASTER_EXT();
                _operMasterExt.PATIENT_ID = _patientID;
                _operMasterExt.VISIT_ID   = _visitID;
                _operMasterExt.OPER_ID    = _operID;
            }
            if (_anesInputData == null)
            {
                _anesInputData            = new MED_ANESTHESIA_INPUT_DATA();
                _anesInputData.PATIENT_ID = _patientID;
                _anesInputData.VISIT_ID   = _visitID;
                _anesInputData.OPER_ID    = _operID;
            }
            else
            {
                txtAnesEffect.Text = _anesInputData.ANES_EFFECT;
                if (_anesInputData.AFTER_ANALGESIA.HasValue && _anesInputData.AFTER_ANALGESIA == 1)
                {
                    radioGroupAnalgesia.SelectedIndex = 0;
                }
                txtAnalgesiaMethod.Text = _anesInputData.ANALGESIA_METHOD;
                if (!string.IsNullOrEmpty(_anesInputData.CANCELED_TYPE) && _anesInputData.CANCELED_TYPE == "1")
                {
                    chkCANCELED_TYPE.Checked = true;
                }
                if (_anesInputData.TRACHEA_6H.HasValue && _anesInputData.TRACHEA_6H == 1)
                {
                    chkTRACHEA_6H.Checked = true;
                }
                if (_anesInputData.ANES_ANAPHYLAXIS.HasValue && _anesInputData.ANES_ANAPHYLAXIS == 1)
                {
                    chkANES_ANAPHYLAXIS.Checked = true;
                }
                if (_anesInputData.SPINAL_ANES_COMP.HasValue && _anesInputData.SPINAL_ANES_COMP == 1)
                {
                    chkSPINAL_ANES_COMP.Checked = true;
                }
                if (_anesInputData.CENTRAL_VENOUS.HasValue && _anesInputData.CENTRAL_VENOUS == 1)
                {
                    chkCENTRAL_VENOUS.Checked = true;
                }
                if (_anesInputData.TRACHEA_HOARSE.HasValue && _anesInputData.TRACHEA_HOARSE == 1)
                {
                    chkTRACHEA_HOARSE.Checked = true;
                }
                if (_anesInputData.CONS_DISTURBANCE.HasValue && _anesInputData.CONS_DISTURBANCE == 1)
                {
                    chkCONS_DISTURBANCE.Checked = true;
                }
                if (_anesInputData.ANES_DEATH.HasValue && _anesInputData.ANES_DEATH == 1)
                {
                    chkANES_DEATH.Checked = true;
                }
                if (_anesInputData.OXYGEN_SATURATION.HasValue && _anesInputData.OXYGEN_SATURATION == 1)
                {
                    chkOXYGEN_SATURATION.Checked = true;
                }
                if (_anesInputData.RES_TRACT_OBSTRUCE.HasValue && _anesInputData.RES_TRACT_OBSTRUCE == 1)
                {
                    chkRES_TRACT_OBSTRUCE.Checked = true;
                }
                if (_anesInputData.AFTER_ANES_COMA.HasValue && _anesInputData.AFTER_ANES_COMA == 1)
                {
                    chkAFTER_ANES_COMA.Checked = true;
                }
                if (_anesInputData.OTHER_NOT_EXP.HasValue && _anesInputData.OTHER_NOT_EXP == 1)
                {
                    chkOTHER_NOT_EXP.Checked = true;
                }
            }
            decimal inAll = 0; decimal outAll = 0; decimal inBlood = 0; decimal inZTX = 0;

            if (_anesEventList != null && _anesEventList.Count > 0)
            {
                List <MED_ANESTHESIA_EVENT> eventList = _anesEventList.Where(p => p.EVENT_CLASS_CODE == "3" || p.EVENT_CLASS_CODE == "B").ToList();

                foreach (MED_ANESTHESIA_EVENT row in eventList)
                {
                    if (row.DOSAGE.HasValue)
                    {
                        inAll += row.DOSAGE.Value;
                    }
                }
                eventList = _anesEventList.Where(p => p.EVENT_CLASS_CODE == "D").ToList();

                foreach (MED_ANESTHESIA_EVENT row in eventList)
                {
                    if (row.DOSAGE.HasValue)
                    {
                        outAll += row.DOSAGE.Value;
                    }
                }

                eventList = _anesEventList.Where(p => p.EVENT_CLASS_CODE == "B").ToList();
                foreach (MED_ANESTHESIA_EVENT row in eventList)
                {
                    if (row.DOSAGE.HasValue)
                    {
                        inBlood += row.DOSAGE.Value;
                    }
                }

                eventList = _anesEventList.Where(p => p.EVENT_CLASS_CODE == "B" && p.EVENT_ATTR == "自体血").ToList();
                foreach (MED_ANESTHESIA_EVENT row in eventList)
                {
                    if (row.DOSAGE.HasValue)
                    {
                        inZTX += row.DOSAGE.Value;
                    }
                }
            }
            txtInfluidsAmount.Text  = inAll.ToString("0.00");
            txtOutFluidsAmount.Text = outAll.ToString("0.00");
            txtBolldTransfused.Text = inBlood.ToString("0.00");
            txtCryWather.Text       = inZTX.ToString("0.00");
        }
コード例 #9
0
        /// <summary>
        /// 根据表名从数据库中获取数据
        /// </summary>
        /// <param name="tableName"></param>
        /// <returns></returns>
        private DataTable BuildData(string tableName)
        {
            string    patientId = ExtendApplicationContext.Current.PatientContextExtend.PatientID;
            int       visitId   = ExtendApplicationContext.Current.PatientContextExtend.VisitID;
            int       operId    = ExtendApplicationContext.Current.PatientContextExtend.OperID;
            DataTable data      = null;

            switch (tableName)
            {
            case "MED_PAT_MONITOR_DATA_EXT":

                data = ModelHelper <MED_PAT_MONITOR_DATA_EXT> .ConvertListToDataTable(operationInfoRepository.GetPatMonitorExtList(patientId, visitId, operId).Data);

                break;

            case "MED_OPERATION_MASTER":

                data = ModelHelper <MED_OPERATION_MASTER> .ConvertSingleToDataTable(ExtendApplicationContext.Current.MED_OPERATION_MASTER == null
                                                                                    ?new MED_OPERATION_MASTER()
                {
                    PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                } : operationInfoRepository.GetOperMaster(patientId, visitId, operId).Data);

                break;

            case "MED_PAT_MASTER_INDEX":

                data = ModelHelper <MED_PAT_MASTER_INDEX> .ConvertSingleToDataTable(ExtendApplicationContext.Current.MED_PAT_MASTER_INDEX == null
                                                                                    ?new MED_PAT_MASTER_INDEX()
                {
                    PATIENT_ID = patientId
                } : operationInfoRepository.GetPatMasterIndex(patientId).Data);

                break;

            case "MED_OPERATION_MASTER_EXT":

                data = ModelHelper <MED_OPERATION_MASTER_EXT> .ConvertSingleToDataTable(operationInfoRepository.GetOperMasterExt(patientId, visitId, operId).Data);

                if (data.Rows.Count == 0)
                {
                    MED_OPERATION_MASTER_EXT model = new MED_OPERATION_MASTER_EXT()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_OPERATION_MASTER_EXT> .ConvertSingleToDataTable(model);
                }
                break;

            case "MED_PAT_VISIT":

                data = ModelHelper <MED_PAT_VISIT> .ConvertSingleToDataTable(operationInfoRepository.GetPatVisit(patientId, visitId).Data);

                if (data.Rows.Count == 0)
                {
                    MED_PAT_VISIT model = new MED_PAT_VISIT()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId
                    };

                    data = ModelHelper <MED_PAT_VISIT> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_PATS_IN_HOSPITAL":

                data = ModelHelper <MED_PATS_IN_HOSPITAL> .ConvertSingleToDataTable(docDataRepository.GetPatsInHospital(patientId, visitId));

                if (data.Rows.Count == 0)
                {
                    MED_PATS_IN_HOSPITAL model = new MED_PATS_IN_HOSPITAL()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId
                    };

                    data = ModelHelper <MED_PATS_IN_HOSPITAL> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_SAFETY_CHECKS":
                data = ModelHelper <MED_SAFETY_CHECKS> .ConvertSingleToDataTable(docDataRepository.GetSafetyCheckData(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_SAFETY_CHECKS model = new MED_SAFETY_CHECKS()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_SAFETY_CHECKS> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_ANESTHESIA_PLAN":
                data = ModelHelper <MED_ANESTHESIA_PLAN> .ConvertSingleToDataTable(docDataRepository.GetAnesthesiaPlan(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_PLAN model = new MED_ANESTHESIA_PLAN()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_PLAN> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_ANESTHESIA_PLAN_PMH":

                data = ModelHelper <MED_ANESTHESIA_PLAN_PMH> .ConvertSingleToDataTable(docDataRepository.GetAnesthesiaPlanPMH(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_PLAN_PMH model = new MED_ANESTHESIA_PLAN_PMH()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_PLAN_PMH> .ConvertSingleToDataTable(model);
                }
                break;

            case "MED_ANESTHESIA_PLAN_EXAM":
                data = ModelHelper <MED_ANESTHESIA_PLAN_EXAM> .ConvertSingleToDataTable(docDataRepository.GetAnesthesiaPlanEXAM(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_PLAN_EXAM model = new MED_ANESTHESIA_PLAN_EXAM()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_PLAN_EXAM> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_ANESTHESIA_RECOVER":
                data = ModelHelper <MED_ANESTHESIA_RECOVER> .ConvertSingleToDataTable(docDataRepository.GetAnesRecoverData(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_RECOVER model = new MED_ANESTHESIA_RECOVER()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_RECOVER> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_ANESTHESIA_INQUIRY":
                data = ModelHelper <MED_ANESTHESIA_INQUIRY> .ConvertSingleToDataTable(docDataRepository.GetAnesInquiry(patientId, visitId, operId, false));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_INQUIRY model = new MED_ANESTHESIA_INQUIRY()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_INQUIRY> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_OPERATION_EXTENDED":
                data = ModelHelper <MED_OPERATION_EXTENDED> .ConvertListToDataTable(commonRepository.GetOperExtended(patientId, visitId, operId).Data);

                if (data.Rows.Count == 0)
                {
                    data.Columns.Add(new DataColumn("PATIENT_ID", typeof(string)));
                    data.Columns.Add(new DataColumn("VISIT_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("OPER_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("ITEM_NAME", typeof(string)));
                    data.Columns.Add(new DataColumn("ITEM_VALUE", typeof(string)));
                }

                break;

            case "MED_POSTOPERATIVE_EXTENDED":

                data = ModelHelper <MED_POSTOPERATIVE_EXTENDED> .ConvertListToDataTable(commonRepository.GetPostoperativeExtended(patientId, visitId, operId).Data);

                if (data.Rows.Count == 0)
                {
                    data.Columns.Add(new DataColumn("PATIENT_ID", typeof(string)));
                    data.Columns.Add(new DataColumn("VISIT_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("OPER_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("ITEM_NAME", typeof(string)));
                    data.Columns.Add(new DataColumn("ITEM_VALUE", typeof(string)));
                }

                break;

            case "MED_PREOPERATIVE_EXPANSION":

                data = ModelHelper <MED_PREOPERATIVE_EXPANSION> .ConvertListToDataTable(commonRepository.GetPreoperativeExpansion(patientId, visitId, operId).Data);

                if (data.Rows.Count == 0)
                {
                    data.Columns.Add(new DataColumn("PATIENT_ID", typeof(string)));
                    data.Columns.Add(new DataColumn("VISIT_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("OPER_ID", typeof(int)));
                    data.Columns.Add(new DataColumn("ITEM_NAME", typeof(string)));
                    data.Columns.Add(new DataColumn("ITEM_VALUE", typeof(string)));
                }

                break;

            case "MED_OPERATION_ANALGESIC_MASTER":
                data = ModelHelper <MED_OPERATION_ANALGESIC_MASTER> .ConvertSingleToDataTable(docDataRepository.GetAnalgesicMaster(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_OPERATION_ANALGESIC_MASTER model = new MED_OPERATION_ANALGESIC_MASTER()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_OPERATION_ANALGESIC_MASTER> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_OPER_RISK_ESTIMATE":

                data = ModelHelper <MED_OPER_RISK_ESTIMATE> .ConvertSingleToDataTable(docDataRepository.GetRickEstimate(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_OPER_RISK_ESTIMATE model = new MED_OPER_RISK_ESTIMATE()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_OPER_RISK_ESTIMATE> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_OPER_ANALGESIC_MEDICINE":

                data = ModelHelper <MED_OPER_ANALGESIC_MEDICINE> .ConvertListToDataTable(operationInfoRepository.GetAnalgesicMedicineList(patientId, visitId, operId).Data);

                break;

            case "MED_OPER_ANALGESIC_TOTAL":
                data = ModelHelper <MED_OPER_ANALGESIC_TOTAL> .ConvertListToDataTable(operationInfoRepository.GetAnalgesicTotalList(patientId, visitId, operId).Data);

                break;

            case "MED_QIXIE_QINGDIAN":
                data = ModelHelper <MED_QIXIE_QINGDIAN> .ConvertListToDataTable(operationInfoRepository.GetOperCheckList(patientId, visitId, operId).Data);

                break;

            case "MED_ANESTHESIA_INPUT_DATA":
                data = ModelHelper <MED_ANESTHESIA_INPUT_DATA> .ConvertSingleToDataTable(docDataRepository.GetAnesthestaInputData(patientId, visitId, operId));

                if (data.Rows.Count == 0)
                {
                    MED_ANESTHESIA_INPUT_DATA model = new MED_ANESTHESIA_INPUT_DATA()
                    {
                        PATIENT_ID = patientId, VISIT_ID = visitId, OPER_ID = operId
                    };

                    data = ModelHelper <MED_ANESTHESIA_INPUT_DATA> .ConvertSingleToDataTable(model);
                }

                break;

            case "MED_BJCA_SIGN":

                data = ModelHelper <MED_BJCA_SIGN> .ConvertListToDataTable(commonRepository.GetBjcaSignList(patientId, visitId, operId).Data);

                break;

            default:
                throw new NotImplementedException(string.Format("当前未定义从表{0}中获取数据的方法!", tableName));
            }
            return(data);
        }
コード例 #10
0
 public RequestResult <int> SaveAnesInputData(MED_ANESTHESIA_INPUT_DATA item)
 {
     return(Success(_pacuOperationInfoService.SaveAnesInputData(item)));
 }
コード例 #11
0
        private void PatientInfoLoad()
        {
            if (string.IsNullOrEmpty(PacuRoom))
            {
                List <MED_OPERATING_ROOM> roomList = comnDictRepository.GetOperatingRoomList("1").Data;
                roomList = roomList.Where(p => p.PATIENT_ID == _patientID && p.VISIT_ID == _visitID && p.OPER_ID == _operID).ToList();
                if (roomList != null && roomList.Count > 0)
                {
                    PacuRoom = roomList[0].ROOM_NO;
                }
            }
            _patientCard = patientInfoRepository.GetPatCard(_patientID, _visitID, _operID).Data;

            _anesPlan = operationInfoRepository.GetAnesPlan(_patientID, _visitID, _operID).Data;
            if (_anesPlan != null)
            {
                switch (_anesPlan.PLAN_WHEREABORTS)
                {
                case "60":
                    radioStatusOperTurnTo.SelectedIndex = 0;
                    break;

                case "65":
                    radioStatusOperTurnTo.SelectedIndex = 1;
                    break;

                case "66":
                    radioStatusOperTurnTo.SelectedIndex = 2;
                    break;

                case "67":
                    radioStatusOperTurnTo.SelectedIndex = 3;
                    break;

                default:
                    radioStatusOperTurnTo.SelectedIndex = 0;
                    break;
                }
            }
            if (_patientCard != null)
            {
                lblInPacuTime.Text = _patientCard.IN_PACU_DATE_TIME.Value.ToString("yyyy-MM-dd HH:mm");
            }

            _anesInputData = operationInfoRepository.GetAnesInputData(_patientID, _visitID, _operID).Data;

            if (_patientCard.IN_PACU_DATE_TIME.HasValue && _patientCard.OUT_PACU_DATE_TIME.HasValue)
            {
                TimeSpan ts = (_patientCard.OUT_PACU_DATE_TIME - _patientCard.IN_PACU_DATE_TIME).Value;

                if (_anesInputData != null && string.IsNullOrEmpty(_anesInputData.PACU_3H) && ts.TotalHours > 3)
                {
                    _anesInputData.PACU_3H = "1";
                    chkPACU3H.Checked      = true;
                }
            }

            if (_anesInputData.PACU_3H == "1")
            {
                chkPACU3H.Checked = true;
            }

            if (_anesInputData.PACU_TEMPERATURE.HasValue && _anesInputData.PACU_TEMPERATURE == 1)
            {
                checkPACU_LowTemp.Checked = true;
            }

            if (_anesInputData.NO_PLAN_IN_ICU.HasValue && _anesInputData.NO_PLAN_IN_ICU == 1)
            {
                checkNoPlanToIcu.Checked = true;
            }

            if (_anesInputData.AFTER_ANES_COMA.HasValue && _anesInputData.AFTER_ANES_COMA == 1)
            {
                chkAFTER_ANES_COMA.Checked = true;
            }

            if (_anesInputData.TRACHEA_HOARSE.HasValue && _anesInputData.TRACHEA_HOARSE == 1)
            {
                chkTRACHEA_HOARSE.Checked = true;
            }

            if (_anesInputData.ANES_ANAPHYLAXIS.HasValue && _anesInputData.ANES_ANAPHYLAXIS == 1)
            {
                chkANES_ANAPHYLAXIS.Checked = true;
            }

            if (_anesInputData.SPINAL_ANES_COMP.HasValue && _anesInputData.SPINAL_ANES_COMP == 1)
            {
                chkSPINAL_ANES_COMP.Checked = true;
            }

            if (_anesInputData.OTHER_NOT_EXP.HasValue && _anesInputData.OTHER_NOT_EXP == 1)
            {
                chkOTHER_NOT_EXP.Checked = true;
            }
        }
コード例 #12
0
        private void PatientTree_Load(object sender, EventArgs e)
        {
            MED_PATIENT_CARD cardRow = patientInfoRepository.GetPatCard(patientID, (int)visitID, (int)operID).Data;

            labelName.Text     = GetValue(cardRow.NAME);
            labelBaseInfo.Text = string.Format("{0}    {1}    {2}", GetValue(cardRow.SEX), DateDiff.CalAge(cardRow.DATE_OF_BIRTH.Value, cardRow.SCHEDULED_DATE_TIME.Value), GetValue(cardRow.INP_NO));

            MED_PAT_VISIT patVisit = operationInfoRepository.GetPatVisit(patientID, (int)visitID).Data;

            if (patVisit == null)
            {
                patVisit = new MED_PAT_VISIT();
            }

            string admission_date_time = string.Empty;

            if (patVisit.ADMISSION_DATE_TIME != null)
            {
                admission_date_time = patVisit.ADMISSION_DATE_TIME.Value.ToString("yyyy-MM-dd");
            }

            labelZD.Text = string.Format("{0}{1}{2}", admission_date_time, GetValue(patVisit.PAT_ADM_CONDITION), GetValue(patVisit.INSURANCE_TYPE));

            #region 术后随访
            List <MED_ANESTHESIA_INQUIRY> anesthesia_inquiry = operationInfoRepository.GetAnesInquiryList(patientID, (int)visitID, (int)operID).Data;
            if (anesthesia_inquiry != null && anesthesia_inquiry.Count > 0)
            {
                labelINQUIRY_DATE.Text = anesthesia_inquiry[0].INQUIRY_DATE.ToString("yyyy-MM-dd");
                labelDocName.Text      = RefUsersDT(anesthesia_inquiry[0].INQUIRY_DOCTOR);
            }
            else
            {
                labelINQUIRY_DATE.Text = string.Empty;
                labelDocName.Text      = string.Empty;
            }
            #endregion

            #region 患者复苏

            string[] tempArr = new string[10] {
                "", "", "", "", "", "", "", "", "", ""
            };
            StringBuilder sb = new StringBuilder();
            sb.Append("入室:{0}     出室:{1}\r\n");
            sb.Append("复苏市时长:{2}分钟\r\n");
            sb.Append("入室情况:体温{3}℃ 意识:{4} 呼吸:{5}次/分\r\n");
            sb.Append("苏醒评分:{6}分\r\n");
            sb.Append("出室情况:体温{7}℃ 意识:{8} 呼吸:{9}次/分\r\n");

            if (cardRow.IN_PACU_DATE_TIME != null)
            {
                labelFuSuDate.Text = cardRow.IN_PACU_DATE_TIME.Value.ToString("yyyy-MM-dd");
                tempArr[0]         = cardRow.IN_PACU_DATE_TIME.Value.ToString("HH:mm");
            }
            else
            {
                labelFuSuDate.Text = string.Empty;
            }

            if (cardRow.OUT_PACU_DATE_TIME != null)
            {
                tempArr[1] = cardRow.OUT_PACU_DATE_TIME.Value.ToString("HH:mm");
            }

            if (cardRow.IN_PACU_DATE_TIME != null && cardRow.OUT_PACU_DATE_TIME != null)
            {
                tempArr[2] = (cardRow.OUT_PACU_DATE_TIME.Value - cardRow.IN_PACU_DATE_TIME.Value).Minutes.ToString();
            }
            //入室
            MED_CONFIRMATION_PACU in_confirmation_pacu = operationInfoRepository.GetConfirmationPACU(patientID, (int)visitID, (int)operID, 45).Data;
            if (in_confirmation_pacu != null)
            {
                tempArr[3] = in_confirmation_pacu.BODY_TEMP.Value.ToString();
                tempArr[4] = in_confirmation_pacu.CONSCIOUSNESS;
                tempArr[5] = in_confirmation_pacu.RESP.Value.ToString();
            }
            List <MED_STEWARD_MARK> steward_mark = operationInfoRepository.GetStewardMarkList(patientID, (int)visitID, (int)operID).Data;
            if (steward_mark != null && steward_mark.Count > 0)
            {
                tempArr[6] = steward_mark[steward_mark.Count - 1].TOTAL_MATK.ToString();
            }
            //出室
            MED_CONFIRMATION_PACU out_confirmation_pacu = operationInfoRepository.GetConfirmationPACU(patientID, (int)visitID, (int)operID, 55).Data;
            if (out_confirmation_pacu != null)
            {
                tempArr[7] = out_confirmation_pacu.BODY_TEMP.Value.ToString();
                tempArr[8] = out_confirmation_pacu.CONSCIOUSNESS;
                tempArr[9] = out_confirmation_pacu.RESP.Value.ToString();
            }

            labelPACU.Text = string.Format(sb.ToString(), tempArr);



            #endregion


            #region  术中麻醉
            MED_ANESTHESIA_INPUT_DATA input_data = operationInfoRepository.GetAnesInputData(patientID, (int)visitID, (int)operID).Data;
            if (cardRow.START_DATE_TIME != null)
            {
                labelShouShuZhongDate.Text = cardRow.START_DATE_TIME.Value.ToString("yyyy-MM-dd");
            }
            else
            {
                labelShouShuZhongDate.Text = string.Empty;
            }

            string ANALGESIA_EFFECT = string.Empty;
            if (input_data != null)
            {
                ANALGESIA_EFFECT = input_data.ANALGESIA_EFFECT;
            }

            if (cardRow.OUT_DATE_TIME != null && cardRow.IN_DATE_TIME != null)
            {
                TimeSpan span = (TimeSpan)(cardRow.OUT_DATE_TIME - cardRow.IN_DATE_TIME);
                int      hour = span.Days * 24;
                lbloperTime.Text     = string.Format("手术时长:{0}小时 {1}分钟   麻醉效果:{2}", hour + span.Hours, span.Minutes, ANALGESIA_EFFECT);
                lbInRoomTime.Text    = cardRow.IN_DATE_TIME.Value.ToString("HH:mm");
                lbAnesStartTime.Text = cardRow.ANES_START_TIME.Value.ToString("HH:mm");
                lbOperStartTime.Text = cardRow.START_DATE_TIME.Value.ToString("HH:mm");
                lbOperEndTime.Text   = cardRow.END_DATE_TIME.Value.ToString("HH:mm");
                lbAnesEndTime.Text   = cardRow.ANES_END_TIME.Value.ToString("HH:mm");
                lbOutRomTime.Text    = cardRow.OUT_DATE_TIME.Value.ToString("HH:mm");
            }
            else
            {
                lbloperTime.Text     = string.Format("手术时长:            麻醉效果:");
                lbInRoomTime.Text    = "--:--";
                lbAnesStartTime.Text = "--:--";
                lbAnesStartTime.Text = "--:--";
                lbOperStartTime.Text = "--:--";
                lbOperEndTime.Text   = "--:--";
                lbAnesEndTime.Text   = "--:--";
                lbOutRomTime.Text    = "--:--";
            }

            MED_OPERATION_MASTER_EXT master_ext = operationInfoRepository.GetOperMasterExt(patientID, (int)visitID, (int)operID).Data;

            string[] arrayInOrOut = new string[8] {
                "", "", "", "", "", "", "", ""
            };
            if (master_ext == null)
            {
                master_ext = new MED_OPERATION_MASTER_EXT();
            }
            if (master_ext.INFUSION_TRAN_VOL != null)
            {
                arrayInOrOut[0] = GetValue(master_ext.INFUSION_TRAN_VOL.ToString());
            }

            if (master_ext.OUT_FLUIDS_AMOUNT != null)
            {
                arrayInOrOut[1] = GetValue(master_ext.OUT_FLUIDS_AMOUNT.ToString());
            }

            if (master_ext.BLOOD_TRANSFUSED != null)
            {
                arrayInOrOut[2] = GetValue(master_ext.BLOOD_TRANSFUSED.ToString());
            }

            if (master_ext.CRY_WATHER != null)
            {
                arrayInOrOut[3] = GetValue(master_ext.CRY_WATHER.ToString());
            }


            List <MED_VITAL_SIGN> vitalSignList = new OperationVitalSignRepository().GetVitalSignData(patientID, (int)visitID, (int)operID, "0", false);
            if (vitalSignList != null && vitalSignList.Count > 0)
            {
                DateTime lastTime = vitalSignList[vitalSignList.Count - 1].TIME_POINT;
                vitalSignList = vitalSignList.Where(p => p.TIME_POINT == lastTime).ToList();
                foreach (MED_VITAL_SIGN row in vitalSignList)
                {
                    if (row.ITEM_CODE == "100") //体温
                    {
                        arrayInOrOut[4] = GetValue(row.ITEM_VALUE);
                    }
                    else if (row.ITEM_CODE == "89")//血压高
                    {
                        arrayInOrOut[5] = GetValue(row.ITEM_VALUE);
                    }
                    else if (row.ITEM_CODE == "90")//血压低
                    {
                        arrayInOrOut[6] = GetValue(row.ITEM_VALUE);
                    }
                    else if (row.ITEM_CODE == "44")//脉搏
                    {
                        arrayInOrOut[7] = GetValue(row.ITEM_VALUE);
                    }
                }
            }

            labelInOrOut.Text = string.Format("术中输液:入量:{0}ml 出量:{1}ml\r\n输血:{2}ml 自体血:{3}\r\n出室时:体温:{4}℃ 血压:{5}/{6} 脉搏:{7}", arrayInOrOut);

            MED_OPERATION_MASTER master = operationInfoRepository.GetOperMaster(patientID, (int)visitID, (int)operID).Data;

            labelAnesOper.Text = string.Format("麻:{0}  护:{1}\r\n手:{2}",
                                               RefUsersDT(master.ANES_DOCTOR) + " " + RefUsersDT(master.FIRST_ANES_ASSISTANT),
                                               RefUsersDT(master.FIRST_OPER_NURSE) + " " + RefUsersDT(master.FIRST_SUPPLY_NURSE),
                                               RefUsersDT(master.SURGEON) + " " + RefUsersDT(master.FIRST_OPER_ASSISTANT));

            #endregion

            #region 术前访视
            MED_ANESTHESIA_PLAN_EXAM anesPlanExam = operationInfoRepository.GetAnesPlanExam(patientID, (int)visitID, (int)operID).Data;
            MED_ANESTHESIA_PLAN_PMH  anesPlanPmh  = operationInfoRepository.GetAnesPlanPmh(patientID, (int)visitID, (int)operID).Data;
            MED_ANESTHESIA_PLAN      anesPlan     = operationInfoRepository.GetAnesPlan(patientID, (int)visitID, (int)operID).Data;


            if (anesPlanExam == null)
            {
                anesPlanExam = new MED_ANESTHESIA_PLAN_EXAM();
            }

            if (anesPlanPmh == null)
            {
                anesPlanPmh = new MED_ANESTHESIA_PLAN_PMH();
            }

            if (anesPlan == null)
            {
                anesPlan = new MED_ANESTHESIA_PLAN();
            }


            if (anesPlan.INQUIRY_BEFORE_DATE != null)
            {
                labelFangShiDate.Text = anesPlan.INQUIRY_BEFORE_DATE.Value.ToString("yyyy-MM-dd");
            }
            else
            {
                labelFangShiDate.Text = string.Empty;
            }

            labelFangShiName.Text = GetValue(anesPlan.INQUIRY_DOCTOR);
            labelPatient.Text     = string.Format("{0}cm,{1}kg{2}/{3}mmHg{4}次/分,{5}次/分",
                                                  GetValue(anesPlanPmh.HEIGHT.ToString()), GetValue(anesPlanPmh.WEIGHT.ToString()), GetValue(anesPlanExam.BLOOD_PRESS_HIGH.ToString()),
                                                  GetValue(anesPlanExam.BLOOD_PRESS_LOW.ToString()), GetValue(anesPlanExam.CARDIOTACH.ToString()), GetValue(anesPlanExam.BREATH.ToString()));

            labelSQ1.Text = string.Format("血常规:{0}         心电图:{1}", "", GetValue(anesPlanExam.ECG_EXAM));
            labelSQ2.Text = string.Format("生化:{0}             意识:{1}", "", "");
            labelSQ3.Text = string.Format("{0}         {1}", "", "");
            labelSQ4.Text = string.Format("执行麻醉:{0}         ASA分级:{1}", GetValue(anesPlan.ANESTHESIA_METHOD), GetValue(cardRow.ASA_GRADE));

            #endregion

            List <MED_OPERATION_SCHEDULE> operScheduleList = operationInfoRepository.GetOperScheduleList(patientID, (int)visitID).Data.ToList();
            if (operScheduleList != null && operScheduleList.Count > 0)
            {
                operScheduleList = operScheduleList.Where(x => x.OPER_ID == (int)operID).ToList();
            }

            #region 手术安排

            StringBuilder sbschedule1 = new StringBuilder();
            sbschedule1.Append("手术安排日期:{0}\r\n");
            sbschedule1.Append("麻:{1}\r\n");
            sbschedule1.Append("护:{2}\r\n");
            sbschedule1.Append("手术间:{3}         台次:{4}");
            string[] tempSchedule1Arr = new string[5] {
                "", "", "", "", ""
            };

            if (operScheduleList != null && operScheduleList.Count > 0)
            {
                MED_OPERATION_SCHEDULE tempoperation_schedule1 = operScheduleList[0];
                tempSchedule1Arr[0] = tempoperation_schedule1.SCHEDULED_DATE_TIME.Value.ToString("yyyy-MM-dd");
                StringBuilder sbOperAnes = new StringBuilder();
                sbOperAnes.Append(RefUsersDT(tempoperation_schedule1.ANES_DOCTOR));
                sbOperAnes.Append(RefUsersDT(tempoperation_schedule1.FIRST_ANES_ASSISTANT));
                sbOperAnes.Append(RefUsersDT(tempoperation_schedule1.SECOND_ANES_ASSISTANT));
                sbOperAnes.Append(RefUsersDT(tempoperation_schedule1.THIRD_ANES_ASSISTANT));
                sbOperAnes.Append(RefUsersDT(tempoperation_schedule1.FOURTH_ANES_ASSISTANT));
                tempSchedule1Arr[1] = sbOperAnes.ToString();

                StringBuilder sbOperNurse = new StringBuilder();
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.FIRST_OPER_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.SECOND_OPER_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.THIRD_OPER_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.FOURTH_OPER_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.FIRST_OPER_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.SECOND_SUPPLY_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.THIRD_SUPPLY_NURSE));
                sbOperNurse.Append(RefUsersDT(tempoperation_schedule1.FOURTH_SUPPLY_NURSE));
                tempSchedule1Arr[2] = sbOperNurse.ToString();

                tempSchedule1Arr[3] = GetValue(tempoperation_schedule1.OPER_ROOM_NO);
                if (tempoperation_schedule1.SEQUENCE != null)
                {
                    tempSchedule1Arr[4] = tempoperation_schedule1.SEQUENCE.ToString();
                }
                labelSchedule.Text         = string.Format(sbschedule1.ToString(), tempSchedule1Arr);
                labelOperScheduleTime.Text = tempoperation_schedule1.SCHEDULED_DATE_TIME.Value.ToString("yyyy-MM-dd");
            }
            else
            {
                labelSchedule.Text            = string.Format(sbschedule1.ToString(), tempSchedule1Arr);
                labelOperScheduleTime.Visible = false;
            }
            #endregion

            #region 手术申请
            if (operScheduleList != null && operScheduleList.Count > 0)
            {
                MED_OPERATION_SCHEDULE tempoperation_schedule = operScheduleList[0];

                string[] tempScheduleArr = new string[7] {
                    "", "", "", "", "", "", ""
                };
                tempScheduleArr[0] = RefDeptDT(tempoperation_schedule.DEPT_CODE);
                tempScheduleArr[1] = GetValue(tempoperation_schedule.BED_NO);
                tempScheduleArr[2] = GetValue(tempoperation_schedule.DIAG_BEFORE_OPERATION);
                tempScheduleArr[3] = GetValue(tempoperation_schedule.OPERATION_NAME);
                tempScheduleArr[4] = GetValue(tempoperation_schedule.OPER_SCALE);
                tempScheduleArr[5] = GetValue(tempoperation_schedule.OPER_POSITION);

                labelOperReg.Text = string.Format("{0}{1}\r\n{2}\r\n{3}{4}\r\n{5}", tempScheduleArr);
                StringBuilder sbOper = new StringBuilder();
                sbOper.Append(RefUsersDT(tempoperation_schedule.SURGEON));
                sbOper.Append(RefUsersDT(tempoperation_schedule.FIRST_OPER_ASSISTANT));
                sbOper.Append(RefUsersDT(tempoperation_schedule.SECOND_OPER_ASSISTANT));
                sbOper.Append(RefUsersDT(tempoperation_schedule.THIRD_OPER_ASSISTANT));
                sbOper.Append(RefUsersDT(tempoperation_schedule.FOURTH_ANES_ASSISTANT));
                labelOper.Text = string.Format("手:{0}", sbOper.ToString());

                labelCreateDate.Text = tempoperation_schedule.REQ_DATE_TIME.Value.ToString("yyyy-Mm-dd");

                if (cardRow.EMERGENCY_IND == 1)
                {
                    pictureBoxJZ.Visible = true;
                }
                if (cardRow.RADIATE_IND == 2)
                {
                    pictureBoxFS.Visible = true;
                }
                if (cardRow.ISOLATION_IND == 2)
                {
                    pictureBoxGL.Visible = true;
                }
            }
            else
            {
                labelOperReg.Text    = string.Empty;
                labelOper.Text       = "手:";
                labelCreateDate.Text = string.Empty;
            }
            #endregion
        }
コード例 #13
0
        /// <summary>
        /// 保存麻醉质控数据
        /// </summary>
        /// <returns><![CDATA[RequestResult<string>]]></returns>
        public RequestResult <int> SaveAnesInputData(MED_ANESTHESIA_INPUT_DATA item)
        {
            string address = "PacuOperationInfo/SaveAnesInputData";

            return(BaseRepository.PostCallApi <MED_ANESTHESIA_INPUT_DATA>(address, item));
        }