示例#1
0
        /// <summary>
        /// Загрузить список операционных сестёр
        /// </summary>
        private void Load()
        {
            _scrubNurseList = new List <CScrubNurse>();
            string allDataStr = CDatabaseEngine.UnpackText(_scrubNursePath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var scrubNurseInfo = new CScrubNurse();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Id":
                        scrubNurseInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Name":
                        scrubNurseInfo.Name = keyValue[1];
                        break;
                    }
                }

                _scrubNurseList.Add(scrubNurseInfo);
            }
        }
        /// <summary>
        /// Загрузить список карт обследования
        /// </summary>
        private void Load()
        {
            _rangeOfMotionCardList = new List <CRangeOfMotionCard>();
            string allDataStr = CDatabaseEngine.UnpackText(_rangeOfMotionCardPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            var errorStr = new StringBuilder();

            try
            {
                // Проходим по всем объектам
                foreach (string objectStr in objectsStr)
                {
                    // Для каждого объекта получаем список значений
                    string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                    var rangeOfMotionCardInfo = new CRangeOfMotionCard();
                    foreach (string dataStr in datasStr)
                    {
                        string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                        switch (keyValue[0])
                        {
                        case "HospitalizationId":
                            rangeOfMotionCardInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "VisitId":
                            rangeOfMotionCardInfo.VisitId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "OppositionFinger":
                            rangeOfMotionCardInfo.OppositionFinger = keyValue[1];
                            break;

                        case "Fields":
                            rangeOfMotionCardInfo.Fields = CConvertEngine.StringToStringArray(keyValue[1]);
                            break;
                        }
                    }

                    _rangeOfMotionCardList.Add(rangeOfMotionCardInfo);
                }
            }
            catch (Exception ex)
            {
                errorStr.Append(ex.Message + "\r\n");
            }

            if (errorStr.Length != 0)
            {
                MessageBox.ShowDialog(errorStr.ToString());
            }
        }
        /// <summary>
        /// Загрузить список переводных эпикризов
        /// </summary>
        private void Load()
        {
            _transferableEpicrisisList = new List <CTransferableEpicrisis>();
            string allDataStr = CDatabaseEngine.UnpackText(_transferableEpicrisisPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var transferableEpicrisisInfo = new CTransferableEpicrisis();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "HospitalizationId":
                        transferableEpicrisisInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "AfterOperationPeriod":
                        transferableEpicrisisInfo.AfterOperationPeriod = keyValue[1];
                        break;

                    case "Plan":
                        transferableEpicrisisInfo.Plan = keyValue[1];
                        break;

                    case "WritingDate":
                        transferableEpicrisisInfo.WritingDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "AdditionalInfo":
                        transferableEpicrisisInfo.AdditionalInfo = keyValue[1];
                        break;

                    case "DisabilityList":
                        transferableEpicrisisInfo.DisabilityList = keyValue[1];
                        break;

                    case "IsIncludeDisabilityList":
                        transferableEpicrisisInfo.IsIncludeDisabilityList = Convert.ToBoolean(keyValue[1]);
                        break;
                    }
                }

                _transferableEpicrisisList.Add(transferableEpicrisisInfo);
            }
        }
        /// <summary>
        /// Загрузить список типов операций
        /// </summary>
        private void Load()
        {
            _operationTypeList = new List <COperationType>();
            string allDataStr = CDatabaseEngine.UnpackText(_operationTypePath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var operationTypeInfo = new COperationType();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Id":
                        operationTypeInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Name":
                        operationTypeInfo.Name = keyValue[1];
                        break;

                    case "IdParent":
                        operationTypeInfo.IdParent = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Type":
                        operationTypeInfo.Type = (NodeType)Enum.Parse(typeof(NodeType), keyValue[1]);
                        break;

                    case "NodeFolderStated":
                        operationTypeInfo.NodeFolderStated = (NodeFolderStated)Enum.Parse(typeof(NodeFolderStated), keyValue[1]);
                        break;
                    }
                }

                _operationTypeList.Add(operationTypeInfo);
            }
        }
示例#5
0
        /// <summary>
        /// Загрузить список анамнезов
        /// </summary>
        private void Load()
        {
            _anamneseList = new List <CAnamnese>();
            string allDataStr = CDatabaseEngine.UnpackText(_anamnesePath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var anamneseInfo = new CAnamnese();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "PatientId":
                        anamneseInfo.PatientId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "AnMorbi":
                        anamneseInfo.AnMorbi = keyValue[1];
                        break;

                    case "TraumaDate":
                        if (!string.IsNullOrEmpty(keyValue[1]))
                        {
                            anamneseInfo.TraumaDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        }
                        else
                        {
                            anamneseInfo.TraumaDate = null;
                        }

                        break;
                    }
                }

                _anamneseList.Add(anamneseInfo);
            }
        }
        /// <summary>
        /// Загрузить список этапных эпикризов
        /// </summary>
        private void Load()
        {
            _lineOfCommunicationEpicrisisList = new List <CLineOfCommunicationEpicrisis>();
            string allDataStr = CDatabaseEngine.UnpackText(_lineOfCommunicationEpicrisisPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var lineOfCommunicationEpicrisisInfo = new CLineOfCommunicationEpicrisis();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "HospitalizationId":
                        lineOfCommunicationEpicrisisInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "AdditionalInfo":
                        lineOfCommunicationEpicrisisInfo.AdditionalInfo = keyValue[1];
                        break;

                    case "Plan":
                        lineOfCommunicationEpicrisisInfo.Plan = keyValue[1];
                        break;

                    case "WritingDate":
                        lineOfCommunicationEpicrisisInfo.WritingDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;
                    }
                }

                _lineOfCommunicationEpicrisisList.Add(lineOfCommunicationEpicrisisInfo);
            }
        }
        /// <summary>
        /// Загрузить список выписных эпикризов
        /// </summary>
        private void Load()
        {
            _dischargeEpicrisisList = new List <CDischargeEpicrisis>();
            string allDataStr = CDatabaseEngine.UnpackText(_dischargeEpicrisisPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var dischargeEpicrisisInfo = new CDischargeEpicrisis();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "HospitalizationId":
                        dischargeEpicrisisInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "AnalysisDate":
                        if (string.IsNullOrEmpty(keyValue[1]))
                        {
                            dischargeEpicrisisInfo.AnalysisDate = null;
                        }
                        else
                        {
                            dischargeEpicrisisInfo.AnalysisDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        }
                        break;

                    case "AfterOperation":
                        dischargeEpicrisisInfo.AfterOperation = keyValue[1];
                        break;

                    case "ConservativeTherapy":
                        dischargeEpicrisisInfo.ConservativeTherapy = keyValue[1];
                        break;

                    case "Ekg":
                        dischargeEpicrisisInfo.Ekg = keyValue[1];
                        break;

                    case "OakEritrocits":
                        dischargeEpicrisisInfo.OakEritrocits = keyValue[1];
                        break;

                    case "OakHb":
                        dischargeEpicrisisInfo.OakHb = keyValue[1];
                        break;

                    case "OakLekocits":
                        dischargeEpicrisisInfo.OakLekocits = keyValue[1];
                        break;

                    case "OakSoe":
                        dischargeEpicrisisInfo.OakSoe = keyValue[1];
                        break;

                    case "OamColor":
                        dischargeEpicrisisInfo.OamColor = keyValue[1];
                        break;

                    case "OamDensity":
                        dischargeEpicrisisInfo.OamDensity = keyValue[1];
                        break;

                    case "OamEritrocits":
                        dischargeEpicrisisInfo.OamEritrocits = keyValue[1];
                        break;

                    case "OamLekocits":
                        dischargeEpicrisisInfo.OamLekocits = keyValue[1];
                        break;

                    case "AdditionalAnalises":
                        dischargeEpicrisisInfo.AdditionalAnalises = keyValue[1];
                        break;

                    case "Recomendations":
                        dischargeEpicrisisInfo.Recomendations = CConvertEngine.StringToStringList(keyValue[1]);
                        break;

                    case "AdditionalRecomendations":
                        dischargeEpicrisisInfo.AdditionalRecomendations = CConvertEngine.StringToStringList(keyValue[1]);
                        break;
                    }
                }

                _dischargeEpicrisisList.Add(dischargeEpicrisisInfo);
            }
        }
示例#8
0
        /// <summary>
        /// Загрузить список осмотров в отделении
        /// </summary>
        private void Load()
        {
            _medicalInspectionList = new List <CMedicalInspection>();
            string allDataStr = CDatabaseEngine.UnpackText(_medicalInspectionPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var medicalInspectionInfo = new CMedicalInspection();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "HospitalizationId":
                        medicalInspectionInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "AnamneseAnMorbi":
                        medicalInspectionInfo.AnamneseAnMorbi = keyValue[1];
                        break;

                    case "AnamneseAnVitae":
                        medicalInspectionInfo.AnamneseAnVitae = CConvertEngine.StringToBoolArray(keyValue[1]);
                        break;

                    case "AnamneseCheckboxes":
                        medicalInspectionInfo.AnamneseCheckboxes = CConvertEngine.StringToBoolArray(keyValue[1]);
                        break;

                    case "AnamneseTextBoxes":
                        medicalInspectionInfo.AnamneseTextBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "Complaints":
                        medicalInspectionInfo.Complaints = keyValue[1];
                        break;

                    case "ExpertAnamnese":
                        medicalInspectionInfo.ExpertAnamnese = Convert.ToInt32(keyValue[1]);
                        break;

                    case "InspectionPlan":
                        medicalInspectionInfo.InspectionPlan = keyValue[1];
                        break;

                    case "StLocalisDescription":
                        medicalInspectionInfo.StLocalisDescription = keyValue[1];
                        break;

                    case "StLocalisRentgen":
                        medicalInspectionInfo.StLocalisRentgen = keyValue[1];
                        break;

                    case "IsAnamneseActive":
                        medicalInspectionInfo.IsAnamneseActive = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "IsPlanEnabled":
                        medicalInspectionInfo.IsPlanEnabled = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "IsStLocalisPart1Enabled":
                        medicalInspectionInfo.IsStLocalisPart1Enabled = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "IsStLocalisPart2Enabled":
                        medicalInspectionInfo.IsStLocalisPart2Enabled = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "LnFirstDateStart":
                        medicalInspectionInfo.LnFirstDateStart = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "LnWithNumberDateEnd":
                        medicalInspectionInfo.LnWithNumberDateEnd = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "LnWithNumberDateStart":
                        medicalInspectionInfo.LnWithNumberDateStart = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "StLocalisPart1Fields":
                        medicalInspectionInfo.StLocalisPart1Fields = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StLocalisPart1OppositionFinger":
                        medicalInspectionInfo.StLocalisPart1OppositionFinger = keyValue[1];
                        break;

                    case "StLocalisPart2ComboBoxes":
                        medicalInspectionInfo.StLocalisPart2ComboBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StLocalisPart2LeftHand":
                        medicalInspectionInfo.StLocalisPart2LeftHand = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StLocalisPart2NumericUpDown":
                        medicalInspectionInfo.StLocalisPart2NumericUpDown = Convert.ToInt32(keyValue[1]);
                        break;

                    case "StLocalisPart2RightHand":
                        medicalInspectionInfo.StLocalisPart2RightHand = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StLocalisPart2TextBoxes":
                        medicalInspectionInfo.StLocalisPart2TextBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StLocalisPart2WhichHand":
                        medicalInspectionInfo.StLocalisPart2WhichHand = keyValue[1];
                        break;

                    case "StPraesensComboBoxes":
                        medicalInspectionInfo.StPraesensComboBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "StPraesensNumericUpDowns":
                        medicalInspectionInfo.StPraesensNumericUpDowns = CConvertEngine.StringToIntArray(keyValue[1]);
                        break;

                    case "StPraesensTextBoxes":
                        medicalInspectionInfo.StPraesensTextBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                        break;

                    case "TeoRisk":
                        medicalInspectionInfo.TeoRisk = keyValue[1];
                        break;
                    }
                }

                _medicalInspectionList.Add(medicalInspectionInfo);
            }
        }
示例#9
0
        /// <summary>
        /// Загрузить список консультаций
        /// </summary>
        private void Load()
        {
            _visitList = new List <CVisit>();
            string allDataStr = CDatabaseEngine.UnpackText(_visitPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var visitInfo = new CVisit();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Id":
                        visitInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "PatientId":
                        visitInfo.PatientId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "VisitDate":
                        visitInfo.VisitDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "Diagnose":
                        visitInfo.Diagnose = keyValue[1];
                        break;

                    case "Evenly":
                        visitInfo.Evenly = keyValue[1];
                        break;

                    case "Recommendation":
                        visitInfo.Recommendation = keyValue[1];
                        break;

                    case "Comments":
                        visitInfo.Comments = keyValue[1];
                        break;

                    case "Doctor":
                        visitInfo.Doctor = keyValue[1];
                        break;

                    case "IsLastParagraphForCertificateNeeded":
                        visitInfo.IsLastParagraphForCertificateNeeded = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "IsLastOdkbParagraphForCertificateNeeded":
                        visitInfo.IsLastOdkbParagraphForCertificateNeeded = Convert.ToBoolean(keyValue[1]);
                        break;
                    }
                }

                _visitList.Add(visitInfo);
            }
        }
        /// <summary>
        /// Загрузить список акушерских анамнезов
        /// </summary>
        private void Load()
        {
            _obstetricHistoryList = new List <CObstetricHistory>();
            string allDataStr = CDatabaseEngine.UnpackText(_obstetricHistoryPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var obstetricHistoryInfo = new CObstetricHistory();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "PatientId":
                        obstetricHistoryInfo.PatientId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Chronology":
                        obstetricHistoryInfo.Chronology = CConvertEngine.StringToBoolArray(keyValue[1]);
                        break;

                    case "ApgarScore":
                        obstetricHistoryInfo.ApgarScore = keyValue[1];
                        break;

                    case "BirthInjury":
                        obstetricHistoryInfo.BirthInjury = keyValue[1];
                        break;

                    case "ChildbirthWeeks":
                        obstetricHistoryInfo.ChildbirthWeeks = keyValue[1];
                        break;

                    case "ComplicationsDuringChildbirth":
                        obstetricHistoryInfo.ComplicationsDuringChildbirth = keyValue[1];
                        break;

                    case "ComplicationsInPregnancy":
                        obstetricHistoryInfo.ComplicationsInPregnancy = keyValue[1];
                        break;

                    case "DrugsInPregnancy":
                        obstetricHistoryInfo.DrugsInPregnancy = keyValue[1];
                        break;

                    case "DurationOfLabor":
                        obstetricHistoryInfo.DurationOfLabor = keyValue[1];
                        break;

                    case "Fetal":
                        obstetricHistoryInfo.Fetal = keyValue[1];
                        break;

                    case "HeightAtBirth":
                        obstetricHistoryInfo.HeightAtBirth = keyValue[1];
                        break;

                    case "HospitalTreatment":
                        obstetricHistoryInfo.HospitalTreatment = keyValue[1];
                        break;

                    case "IsTongsUsing":
                        obstetricHistoryInfo.IsTongsUsing = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "IsVacuumUsing":
                        obstetricHistoryInfo.IsVacuumUsing = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "ObstetricParalysis":
                        obstetricHistoryInfo.ObstetricParalysis = keyValue[1];
                        break;

                    case "OutpatientCare":
                        obstetricHistoryInfo.OutpatientCare = keyValue[1];
                        break;

                    case "WeightAtBirth":
                        obstetricHistoryInfo.WeightAtBirth = keyValue[1];
                        break;
                    }
                }

                _obstetricHistoryList.Add(obstetricHistoryInfo);
            }
        }
示例#11
0
        /// <summary>
        /// Загрузить список карт обследования
        /// </summary>
        private void Load()
        {
            _obstetricParalysisCardList = new List <CObstetricParalysisCard>();
            string allDataStr = CDatabaseEngine.UnpackText(_obstetricParalysisCardPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            var errorStr = new StringBuilder();

            try
            {
                // Проходим по всем объектам
                foreach (string objectStr in objectsStr)
                {
                    // Для каждого объекта получаем список значений
                    string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                    var obstetricParalysisCardInfo = new CObstetricParalysisCard();
                    foreach (string dataStr in datasStr)
                    {
                        string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                        switch (keyValue[0])
                        {
                        case "HospitalizationId":
                            obstetricParalysisCardInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "VisitId":
                            obstetricParalysisCardInfo.VisitId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "CardSide":
                            obstetricParalysisCardInfo.SideOfCard = CConvertEngine.StringToCardSide(keyValue[1]);
                            break;

                        case "GlobalAbductionPicturesSelection":
                            obstetricParalysisCardInfo.GlobalAbductionPicturesSelection = CConvertEngine.StringToBoolArray(keyValue[1]);
                            break;

                        case "GlobalExternalRotationPicturesSelection":
                            obstetricParalysisCardInfo.GlobalExternalRotationPicturesSelection = CConvertEngine.StringToBoolArray(keyValue[1]);
                            break;

                        case "HandToMouthPicturesSelection":
                            obstetricParalysisCardInfo.HandToMouthPicturesSelection = CConvertEngine.StringToBoolArray(keyValue[1]);
                            break;

                        case "HandToNeckPicturesSelection":
                            obstetricParalysisCardInfo.HandToNeckPicturesSelection = CConvertEngine.StringToBoolArray(keyValue[1]);
                            break;

                        case "HandToSpinePicturesSelection":
                            obstetricParalysisCardInfo.HandToSpinePicturesSelection = CConvertEngine.StringToBoolArray(keyValue[1]);
                            break;

                        case "ComboBoxes":
                            obstetricParalysisCardInfo.ComboBoxes = CConvertEngine.StringToStringArray(keyValue[1]);
                            break;
                        }
                    }

                    _obstetricParalysisCardList.Add(obstetricParalysisCardInfo);
                }
            }
            catch (Exception ex)
            {
                errorStr.Append(ex.Message + "\r\n");
            }

            if (errorStr.Length != 0)
            {
                MessageBox.ShowDialog(errorStr.ToString());
            }
        }
示例#12
0
        /// <summary>
        /// Загрузить список карт обследования
        /// </summary>
        private void Load()
        {
            _cardList = new List <CCard>();
            string allDataStr = CDatabaseEngine.UnpackText(_cardPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            var errorStr = new StringBuilder();

            try
            {
                // Проходим по всем объектам
                foreach (string objectStr in objectsStr)
                {
                    // Для каждого объекта получаем список значений
                    string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                    var cardInfo = new CCard();
                    foreach (string dataStr in datasStr)
                    {
                        string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                        switch (keyValue[0])
                        {
                        case "HospitalizationId":
                            cardInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "VisitId":
                            cardInfo.VisitId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "CardSide":
                            cardInfo.CurrentSideOfCard = CConvertEngine.StringToCardSide(keyValue[1]);
                            break;

                        case "CurrentCardType":
                            cardInfo.CurrentCardType = CConvertEngine.StringToCardType(keyValue[1]);
                            break;
                        }
                    }

                    string picturePath = GetPicturePath(cardInfo.GetPictureFileName());
                    if (!File.Exists(picturePath))
                    {
                        PutDefaultPictureFile(cardInfo.CurrentCardType, picturePath);
                    }

                    cardInfo.Picture = CDatabaseEngine.GetBitmapFromFile(picturePath);

                    _cardList.Add(cardInfo);
                }
            }
            catch (Exception ex)
            {
                errorStr.Append(ex.Message + "\r\n");
            }

            if (errorStr.Length != 0)
            {
                MessageBox.ShowDialog(errorStr.ToString());
            }
        }
示例#13
0
        /// <summary>
        /// Загрузить список госпитализаций
        /// </summary>
        private void Load()
        {
            _hospitalizationList = new List <CHospitalization>();
            string allDataStr = CDatabaseEngine.UnpackText(_hospitalizationPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var hospitalizationInfo = new CHospitalization();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Id":
                        hospitalizationInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "PatientId":
                        hospitalizationInfo.PatientId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "DeliveryDate":
                        hospitalizationInfo.DeliveryDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "ReleaseDate":
                        if (string.IsNullOrEmpty(keyValue[1]))
                        {
                            hospitalizationInfo.ReleaseDate = null;
                        }
                        else
                        {
                            hospitalizationInfo.ReleaseDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        }

                        break;

                    case "NumberOfCaseHistory":
                        hospitalizationInfo.NumberOfCaseHistory = keyValue[1];
                        break;

                    case "Diagnose":
                        hospitalizationInfo.Diagnose = keyValue[1];
                        break;

                    case "DoctorInChargeOfTheCase":
                        hospitalizationInfo.DoctorInChargeOfTheCase = keyValue[1];
                        break;

                    case "FotoFolderName":
                        hospitalizationInfo.FotoFolderName = keyValue[1];
                        break;
                    }
                }

                _hospitalizationList.Add(hospitalizationInfo);
            }
        }
示例#14
0
        /// <summary>
        /// Загрузить список операций
        /// </summary>
        private void Load()
        {
            _operationList = new List <COperation>();
            string allDataStr = CDatabaseEngine.UnpackText(_operationPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var operationInfo = new COperation();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Id":
                        operationInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "HospitalizationId":
                        operationInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "PatientId":
                        operationInfo.PatientId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "DateOfOperation":
                        operationInfo.DateOfOperation = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "StartTimeOfOperation":
                        operationInfo.StartTimeOfOperation = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "EndTimeOfOperation":
                        if (string.IsNullOrEmpty(keyValue[1]))
                        {
                            operationInfo.EndTimeOfOperation = null;
                        }
                        else
                        {
                            operationInfo.EndTimeOfOperation = CConvertEngine.StringToDateTime(keyValue[1]);
                        }

                        break;

                    case "Name":
                        operationInfo.Name = keyValue[1];
                        break;

                    case "Surgeons":
                        operationInfo.Surgeons = CConvertEngine.StringToStringList(keyValue[1]);
                        break;

                    case "Assistents":
                        operationInfo.Assistents = CConvertEngine.StringToStringList(keyValue[1]);
                        break;

                    case "OperationTypes":
                        operationInfo.OperationTypes = CConvertEngine.StringToStringList(keyValue[1]);
                        break;

                    case "HeAnaesthetist":
                        operationInfo.HeAnaesthetist = keyValue[1];
                        break;

                    case "SheAnaesthetist":
                        operationInfo.SheAnaesthetist = keyValue[1];
                        break;

                    case "ScrubNurse":
                        operationInfo.ScrubNurse = keyValue[1];
                        break;

                    case "Orderly":
                        operationInfo.Orderly = keyValue[1];
                        break;
                    }
                }

                _operationList.Add(operationInfo);
            }
        }
        /// <summary>
        /// Загрузить список карт обследования
        /// </summary>
        private void Load()
        {
            _brachialPlexusCardList = new List <CBrachialPlexusCard>();
            string allDataStr = CDatabaseEngine.UnpackText(_brachialPlexusCardPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            var errorStr = new StringBuilder();

            try
            {
                // Проходим по всем объектам
                foreach (string objectStr in objectsStr)
                {
                    // Для каждого объекта получаем список значений
                    string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                    var brachialPlexusCardInfo = new CBrachialPlexusCard();
                    foreach (string dataStr in datasStr)
                    {
                        string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                        switch (keyValue[0])
                        {
                        case "HospitalizationId":
                            brachialPlexusCardInfo.HospitalizationId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "VisitId":
                            brachialPlexusCardInfo.VisitId = Convert.ToInt32(keyValue[1]);
                            break;

                        case "Diaphragm":
                            brachialPlexusCardInfo.Diaphragm = keyValue[1];
                            break;

                        case "EMNG":
                            brachialPlexusCardInfo.EMNG = keyValue[1];
                            break;

                        case "EMNGDate":
                            brachialPlexusCardInfo.EMNGDate = CConvertEngine.StringToDateTime(keyValue[1]);
                            break;

                        case "HornersSyndrome":
                            brachialPlexusCardInfo.HornersSyndrome = keyValue[1];
                            break;

                        case "IsEMNGEnabled":
                            brachialPlexusCardInfo.IsEMNGEnabled = Convert.ToBoolean(keyValue[1]);
                            break;

                        case "IsMyelographyEnabled":
                            brachialPlexusCardInfo.IsMyelographyEnabled = Convert.ToBoolean(keyValue[1]);
                            break;

                        case "Myelography":
                            brachialPlexusCardInfo.Myelography = keyValue[1];
                            break;

                        case "MyelographyDate":
                            brachialPlexusCardInfo.MyelographyDate = CConvertEngine.StringToDateTime(keyValue[1]);
                            break;

                        case "MyelographyType":
                            brachialPlexusCardInfo.MyelographyType = keyValue[1];
                            break;

                        case "TinelsSymptom":
                            brachialPlexusCardInfo.TinelsSymptom = keyValue[1];
                            break;

                        case "VascularStatus":
                            brachialPlexusCardInfo.VascularStatus = keyValue[1];
                            break;

                        case "CardSide":
                            brachialPlexusCardInfo.SideOfCard = CConvertEngine.StringToCardSide(keyValue[1]);
                            break;
                        }
                    }

                    string picturePath = GetPicturePath(brachialPlexusCardInfo.GetPictureFileName());
                    if (!File.Exists(picturePath))
                    {
                        PutDefaultPictureFile(picturePath);
                    }

                    brachialPlexusCardInfo.Picture = CDatabaseEngine.GetBitmapFromFile(picturePath);

                    _brachialPlexusCardList.Add(brachialPlexusCardInfo);
                }
            }
            catch (Exception ex)
            {
                errorStr.Append(ex.Message + "\r\n");
            }

            if (errorStr.Length != 0)
            {
                MessageBox.ShowDialog(errorStr.ToString());
            }
        }
示例#16
0
        /// <summary>
        /// Загрузить список пациентов
        /// </summary>
        private void Load()
        {
            _patientList = new List <CPatient>();
            string allDataStr = CDatabaseEngine.UnpackText(_patientPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var patientInfo = new CPatient();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "Birthday":
                        patientInfo.Birthday = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "BuildingNumber":
                        patientInfo.BuildingNumber = keyValue[1];
                        break;

                    case "CityName":
                        patientInfo.CityName = keyValue[1];
                        break;

                    case "FlatNumber":
                        patientInfo.FlatNumber = keyValue[1];
                        break;

                    case "HomeNumber":
                        patientInfo.HomeNumber = keyValue[1];
                        break;

                    case "Id":
                        patientInfo.Id = Convert.ToInt32(keyValue[1]);
                        break;

                    case "LastName":
                        patientInfo.LastName = keyValue[1];
                        break;

                    case "Name":
                        patientInfo.Name = keyValue[1];
                        break;

                    case "Nosology":
                        patientInfo.NosologyList = new List <string> {
                            keyValue[1]
                        };
                        break;

                    case "NosologyList":
                        patientInfo.NosologyList = CConvertEngine.StringToStringList(keyValue[1]);
                        break;

                    case "Patronymic":
                        patientInfo.Patronymic = keyValue[1];
                        break;

                    case "Phone":
                        patientInfo.Phone = keyValue[1];
                        break;

                    case "PrivateFolder":
                        patientInfo.PrivateFolder = keyValue[1];
                        break;

                    case "Relatives":
                        patientInfo.Relatives = keyValue[1];
                        break;

                    case "IsSpecifyLegalRepresent":
                        patientInfo.IsSpecifyLegalRepresent = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "LegalRepresent":
                        patientInfo.LegalRepresent = keyValue[1];
                        break;

                    case "WorkPlace":
                        patientInfo.WorkPlace = keyValue[1];
                        break;

                    case "EMail":
                        patientInfo.EMail = keyValue[1];
                        break;

                    case "InsuranceSeries":
                        patientInfo.InsuranceSeries = keyValue[1];
                        break;

                    case "InsuranceNumber":
                        patientInfo.InsuranceNumber = keyValue[1];
                        break;

                    case "InsuranceType":
                        patientInfo.InsuranceType = keyValue[1];
                        break;

                    case "InsuranceName":
                        patientInfo.InsuranceName = keyValue[1];
                        break;

                    case "PassInformation":
                        patientInfo.PassInformation = new CPassportInformation(keyValue[1]);
                        break;

                    case "StreetName":
                        patientInfo.StreetName = keyValue[1];
                        break;
                    }
                }

                patientInfo.Nosology = _workersKeeper.NosologyWorker.GetNosologyDisplayName(patientInfo.NosologyList);
                _patientList.Add(patientInfo);
            }
        }
        /// <summary>
        /// Загрузить список операционных протоколов
        /// </summary>
        private void Load()
        {
            _operationProtocolList = new List <COperationProtocol>();
            string allDataStr = CDatabaseEngine.UnpackText(_operationProtocolPath);

            // Получаем набор объектов
            string[] objectsStr = allDataStr.Split(new[] { ObjSplitStr }, StringSplitOptions.RemoveEmptyEntries);

            // Проходим по всем объектам
            foreach (string objectStr in objectsStr)
            {
                // Для каждого объекта получаем список значений
                string[] datasStr = objectStr.Split(new[] { DataSplitStr }, StringSplitOptions.RemoveEmptyEntries);

                var operationProtocolInfo = new COperationProtocol();
                foreach (string dataStr in datasStr)
                {
                    string[] keyValue = dataStr.Split(new[] { '=' }, 2);
                    switch (keyValue[0])
                    {
                    case "OperationId":
                        operationProtocolInfo.OperationId = Convert.ToInt32(keyValue[1]);
                        break;

                    case "TreatmentPlanInspection":
                        operationProtocolInfo.TreatmentPlanInspection = keyValue[1];
                        break;

                    case "TreatmentPlanDate":
                        operationProtocolInfo.TreatmentPlanDate = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "IsTreatmentPlanActiveInOperationProtocol":
                        operationProtocolInfo.IsTreatmentPlanActiveInOperationProtocol = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "ADFirst":
                        operationProtocolInfo.ADFirst = Convert.ToInt32(keyValue[1]);
                        break;

                    case "ADSecond":
                        operationProtocolInfo.ADSecond = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Breath":
                        operationProtocolInfo.Breath = keyValue[1];
                        break;

                    case "ChDD":
                        operationProtocolInfo.ChDD = Convert.ToInt32(keyValue[1]);
                        break;

                    case "Complaints":
                        operationProtocolInfo.Complaints = keyValue[1];
                        break;

                    case "State":
                        operationProtocolInfo.State = keyValue[1];
                        break;

                    case "HeartRhythm":
                        operationProtocolInfo.HeartRhythm = keyValue[1];
                        break;

                    case "HeartSounds":
                        operationProtocolInfo.HeartSounds = keyValue[1];
                        break;

                    case "IsDairyEnabled":
                        operationProtocolInfo.IsDairyEnabled = Convert.ToBoolean(keyValue[1]);
                        break;

                    case "Pulse":
                        operationProtocolInfo.Pulse = Convert.ToInt32(keyValue[1]);
                        break;

                    case "StLocalis":
                        operationProtocolInfo.StLocalis = keyValue[1];
                        break;

                    case "Stomach":
                        operationProtocolInfo.Stomach = keyValue[1];
                        break;

                    case "Stool":
                        operationProtocolInfo.Stool = keyValue[1];
                        break;

                    case "Temperature":
                        operationProtocolInfo.Temperature = keyValue[1];
                        break;

                    case "TimeWriting":
                        operationProtocolInfo.TimeWriting = CConvertEngine.StringToDateTime(keyValue[1]);
                        break;

                    case "Urination":
                        operationProtocolInfo.Urination = keyValue[1];
                        break;

                    case "Wheeze":
                        operationProtocolInfo.Wheeze = keyValue[1];
                        break;

                    case "OperationCourse":
                        operationProtocolInfo.OperationCourse = keyValue[1];
                        break;
                    }
                }

                _operationProtocolList.Add(operationProtocolInfo);
            }
        }