private void btnOneDaySurgery_Click(object sender, EventArgs e)
        {
            ApplicationStaticConfiguration.InternalReceptionApplication = DB_Application.OneDaySurgeryReception;
            List <GetPatientPreviousInvoices_Result> list = DBCommon.DBContext_External
                                                            .GetPatientPreviousInvoices(ActiveSelectedPatient.Person_CU_ID, false, true, DateTime.Now.Date,
                                                                                        DateTime.Now.Date).OrderBy(item => item.InvoiceCreationDate).ToList();

            if (list.Count > 0)
            {
                PatientMedicalServicesActions_UC patientMedicalServiceActions = new PatientMedicalServicesActions_UC();
                patientMedicalServiceActions.Initialize(ActiveSelectedPatient, this, ParentControl);
                if (ParentForm != null)
                {
                    ParentForm.Close();
                }
                PopupBaseForm.ShowAsPopup(patientMedicalServiceActions, this);
            }
            else
            {
                BaseController <Invoice> .ShowEditorControl(ref _medicalAdmissionInvoiceCreationContainer, this,
                                                            ActiveSelectedPatient, null, EditorContainerType.Regular,
                                                            ViewerName.PatientInvoiceCreation,
                                                            DB_CommonTransactionType.CreateNew,
                                                            ".... الخـدمــــات الطبيــــــة ....",
                                                            true);

                if (ParentForm != null)
                {
                    ParentForm.Close();
                }
            }
        }
Пример #2
0
        private void btnSendToStage_Click(object sender, EventArgs e)
        {
            PEMR_SendToStage_UC sendToStage = new PEMR_SendToStage_UC();

            sendToStage.Initialize(MerkDBBusinessLogicEngine.ActiveStationPointStage, QueueResult);
            PopupBaseForm.ShowAsPopup(sendToStage, this);
        }
 protected override void SetTabPageProperties(int pageIndex, PopupBaseForm shadowForm)
 {
     if (pageIndex == 3)
     {
         XtraTabPage  tabPage  = this.TabControl.TabPages[pageIndex];
         ColorListBox colorBox = CreateColorListBox();
         colorBox.HighlightedItemStyle = Properties.HighlightedItemStyle;
         object[] colors = new object[(this.Properties as RepositoryItemCustomColorEdit).ColorSource.Count];
         for (int i = 0; i < colors.Length; i++)
         {
             colors[i] = (this.Properties as RepositoryItemCustomColorEdit).ColorSource[i];
         }
         colorBox.Items.AddRange(colors);
         colorBox.EnterColor           += new EnterColorEventHandler(OnEnterColor);
         colorBox.SelectedIndexChanged += new EventHandler(OnSelectedIndexChanged);
         colorBox.Size        = GetBestListBoxSize(colorBox);
         tabPage.PageVisible  = (this.Properties as RepositoryItemCustomColorEdit).ShowMyCustomColors;
         colorBox.Dock        = DockStyle.Fill;
         colorBox.BorderStyle = BorderStyles.NoBorder;
         if (Owner.LookAndFeel != null)
         {
             colorBox.LookAndFeel.Assign(Owner.LookAndFeel);
         }
         tabPage.Controls.Add(colorBox);
         return;
     }
     base.SetTabPageProperties(pageIndex, shadowForm);
 }
Пример #4
0
 /// <summary>
 /// 遍历得到SearchLookUpEdit自带GridView中的按钮
 /// </summary>
 /// <param name="Form"></param>
 /// <param name="strName"></param>
 /// <returns></returns>
 public static LayoutControlItem GetFindControlLayoutItem(PopupBaseForm Form, string strName)
 {
     if (Form != null)
     {
         foreach (Control FormC in Form.Controls)
         {
             if (FormC is SearchEditLookUpPopup)
             {
                 SearchEditLookUpPopup SearchPopup = FormC as SearchEditLookUpPopup;
                 foreach (Control SearchPopupC in SearchPopup.Controls)
                 {
                     if (SearchPopupC is LayoutControl)
                     {
                         LayoutControl FormLayout = SearchPopupC as LayoutControl;
                         Control       Button     = FormLayout.GetControlByName(strName);
                         if (Button != null)
                         {
                             return(FormLayout.GetItemByControl(Button));
                         }
                     }
                 }
             }
         }
     }
     return(null);
 }
        private void btnScanPicture_Click(object sender, EventArgs e)
        {
            ScanFiles_UC _scanFilesUc = new ScanFiles_UC();

            switch (ServiceType)
            {
            case DB_ServiceType.InvestigationServices:
                _scanFilesUc.Initialize(PEMRBusinessLogic.ActivePEMRObject.Active_Patient,
                                        ScanningMode.MedicalVisit, MedicalType.InvestigationResult);
                _scanFilesUc.Pass_VisitTiming_InvestigationReservation(
                    (VisitTiming_InvestigationReservation)Selected_PEMR_Element, true);
                break;

            case DB_ServiceType.LabServices:
                _scanFilesUc.Initialize(PEMRBusinessLogic.ActivePEMRObject.Active_Patient,
                                        ScanningMode.MedicalVisit, MedicalType.LabResult);
                _scanFilesUc.Pass_VisitTiming_LabReservation(
                    (VisitTiming_LabReservation)Selected_PEMR_Element, true);
                break;

            case DB_ServiceType.SurgeryService:
                _scanFilesUc.Initialize(PEMRBusinessLogic.ActivePEMRObject.Active_Patient,
                                        ScanningMode.MedicalVisit, MedicalType.SurgeryResult);
                _scanFilesUc.Pass_VisitTiming_SurgeryReservation(
                    (VisitTiming_SurgeryReservation)Selected_PEMR_Element, true);
                break;
            }

            PopupBaseForm.ShowAsPopup(_scanFilesUc, this);

            if (ParentForm != null)
            {
                ParentForm.Close();
            }
        }
        private void btnSearchDiagnosis_Click(object sender, EventArgs e)
        {
            PEMR_SearchPanel_UC searchPanel = new PEMR_SearchPanel_UC();

            searchPanel.Initialize(SearchPanelType.DiagnosisSearch);
            DialogResult result = PopupBaseForm.ShowAsPopup(searchPanel, this);

            switch (result)
            {
            case DialogResult.Cancel:
                if (SelectedDiagnosisFromSearch != null)
                {
                    if (AddedDiagnosisList == null)
                    {
                        AddedDiagnosisList = new List <Diagnosis_cu>();
                    }
                    if (AddedDiagnosisList.Count == 0 || !AddedDiagnosisList.Exists(item =>
                                                                                    Convert.ToInt32(item.ID).Equals(Convert.ToInt32(SelectedDiagnosisFromSearch.ID))))
                    {
                        AddedDiagnosisList.Add(SelectedDiagnosisFromSearch);
                    }

                    TempDiagnosisListToBeAdded = null;
                    CommonViewsActions.FillListBoxControl(lstAddedDiagnosis, AddedDiagnosisList, "DiagnosisFullName");
                    lstAddedDiagnosis.Refresh();
                    SetDiagnosisCount(AddedDiagnosisList);

                    lstDiagnosis.SelectedIndex       = -1;
                    lstDoctorDiagnosis.SelectedIndex = -1;
                    lstAddedDiagnosis.SelectedIndex  = -1;
                }
                break;
            }
        }
Пример #7
0
        private void btnChangeDoctor_Click(object sender, EventArgs e)
        {
            QueueManager_DoctorSelection_UC doctorSelection = new QueueManager_DoctorSelection_UC();

            doctorSelection.Initialize(ActiveInvoiceDetail, ActiveQueueManager);
            PopupBaseForm.ShowAsPopup(doctorSelection, this);
        }
        private void btnGraph_Click(object sender, EventArgs e)
        {
            PEMR_VisionRefractionGraph_UC graph = new PEMR_VisionRefractionGraph_UC();

            graph.Initialize(ReadingsType.EOMReading, PEMRBusinessLogic.ActivePEMRObject.Active_Patient.ID,
                             dtSearchFrom.EditValue, dtSearchTo.EditValue);
            PopupBaseForm.ShowAsPopup(graph, this);
        }
Пример #9
0
        private void btnPrintOrder_Click(object sender, System.EventArgs e)
        {
            PEMR_PrintOrder_UC printOrder = new PEMR_PrintOrder_UC();

            PopupBaseForm.ShowAsPopup(printOrder, this);
            ActiveReport.CreateDocument();
            ActiveReport.Initialize(PEMRBusinessLogic.ActivePEMRObject);
            documentViewer1.DocumentSource = ActiveReport;
        }
 public CustomPopupBaseSizeableFormViewInfo(PopupBaseForm form)
     : base(form)
 {
     buttonSize       = new Size(buttonWidth, buttonHeight);
     imageRect        = Rectangle.Empty;
     okButtonRect     = Rectangle.Empty;
     openButtonRect   = Rectangle.Empty;
     clearButtonRect  = Rectangle.Empty;
     cancelButtonRect = Rectangle.Empty;
 }
Пример #11
0
        private void FormOnSizeChanged(object sender, EventArgs eventArgs)
        {
            PopupBaseForm form = sender as PopupBaseForm;

            foreach (Control control in _controls)
            {
                control.Location = new Point(control.Location.X - _size.Width + form.Width, control.Location.Y - _size.Height + form.Height);
            }
            _size = form.Size;
        }
        private void btnScanner_Click(object sender, EventArgs e)
        {
            ScanFiles_UC scanFiles = new ScanFiles_UC();

            scanFiles.Initialize(ActiveSelectedPatient, ScanningMode.Regular, MedicalType.None);
            if (ParentForm != null)
            {
                ParentForm.Close();
            }
            PopupBaseForm.ShowAsPopup(scanFiles, this);
        }
Пример #13
0
        private void btnContinueOnPreviousInvoice_Click(object sender, EventArgs e)
        {
            PatientNotCompletedPreviousVisits_UC patientPreviousInvoices = new PatientNotCompletedPreviousVisits_UC();

            patientPreviousInvoices.Initialize(ActivePatient, ParentControl, MainPatientInvoiceActions,
                                               PatientNotCompletedPreviousVisitsAction.InvoiceCreation);
            if (ParentForm != null)
            {
                ParentForm.Close();
            }
            PopupBaseForm.ShowAsPopup(patientPreviousInvoices, this);
        }
        public CashBoxTransactionContainer()
        {
            InitializeComponent();

            if (ApplicationStaticConfiguration.ActiveCashBox == null)
            {
                ChooseCashBox_UC chooseCashBox = new ChooseCashBox_UC();
                PopupBaseForm.ShowAsPopup(chooseCashBox, this);
            }

            SetCashBoxDetails();
        }
        private void gridView2_DoubleClick(object sender, EventArgs e)
        {
            if (Selected_VisitTiming_LabReservation == null)
            {
                return;
            }

            PEMR_DiagnosisServicesActions diagnosisActions = new PEMR_DiagnosisServicesActions();

            diagnosisActions.Initialize(DB_ServiceType.LabServices, Selected_VisitTiming_LabReservation, this);
            PopupBaseForm.ShowAsPopup(diagnosisActions, this);
        }
        private void btnInvoiceReviewingOutPatient_Click(object sender, System.EventArgs e)
        {
            PatientNotCompletedPreviousVisits_UC patientPreviousInvoices = new PatientNotCompletedPreviousVisits_UC();

            patientPreviousInvoices.Initialize(ActiveSelectedPatient, ParentControl, this,
                                               PatientNotCompletedPreviousVisitsAction.InvoiceManager);
            if (ParentForm != null)
            {
                ParentForm.Close();
            }
            PopupBaseForm.ShowAsPopup(patientPreviousInvoices, this);
        }
        private void gridView1_DoubleClick(object sender, EventArgs e)
        {
            ActivePatient = CommonViewsActions.GetSelectedRowObject <Patient_cu>(gridView1);
            if (ActivePatient == null)
            {
                return;
            }

            MainPatientInvoiceActions patienActions = new MainPatientInvoiceActions();

            patienActions.Initialize(ActivePatient, ParentControl);
            PopupBaseForm.ShowAsPopup(patienActions, this);
        }
        private void gridView2_DoubleClick(object sender, EventArgs e)
        {
            if (Selected_VisitTiming_EOMReading_Result == null)
            {
                return;
            }

            PEMR_VisionRefractionDetails_UC details = new PEMR_VisionRefractionDetails_UC();

            details.Initialize(Selected_VisitTiming_EOMReading_Result);
            ReadingsMode = ReadingsMode.ViewingPreviousReadings;
            PopupBaseForm.ShowAsPopup(details, this);
            ReadingsMode = ReadingsMode.ViewingActiveAllReadings;
        }
Пример #19
0
 public PWColorCellsControl(PopupBaseForm shadowForm, int columnCount, int rowCount)
 {
     if (columnCount * rowCount > 64)
     {
         throw new Exception("Incorrect cells count.");
     }
     SetStyle(ControlStyles.UserMouse, false);
     this.shadowForm = shadowForm;
     viewInfo        = new PWColorCellsControlViewInfo(this, columnCount, rowCount);
     painter         = new PWColorCellsControlPainter(columnCount * rowCount);
     properties      = null;
     lockFocus       = false;
     SetStyle(ControlStyles.AllPaintingInWmPaint | ControlConstants.DoubleBuffer, true);
 }
 private void btnPlay_Click(object sender, System.EventArgs e)
 {
     if (ParentInvoiceManagerQueueContainerWithHeaderIcons_UC != null)
     {
         ParentInvoiceManagerQueueContainerWithHeaderIcons_UC.PassInvoice(ActiveInvoice);
         ParentInvoiceManagerQueueContainerWithHeaderIcons_UC.CollapseLeftPanel(true);
         ParentInvoiceManagerQueueContainerWithHeaderIcons_UC.ShowInvoiceContainer(true);
         return;
     }
     if (ParentQueueManagerContainer_UC != null)
     {
         QueueManager_Actions_UC patientActions = new QueueManager_Actions_UC();
         patientActions.Initialize(ActiveInvoice, ActivePatient, ActiveInvoiceDetail, ActiveQueueManager);
         PopupBaseForm.ShowAsPopup(patientActions, this);
     }
 }
        private void gridControl1_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
        {
            var rowObject = CommonViewsActions.GetSelectedRowObject(gridView1);

            if (rowObject is GetInvoiceForAddmission_Result)
            {
                InvoiceObject invoiceObject =
                    MerkDBBusinessLogicEngine.GetInvoiceFullTree(((GetInvoiceForAddmission_Result)rowObject).InvoiceID);
                if (invoiceObject == null)
                {
                    return;
                }

                MainPatientInvoiceActions patienActions = new MainPatientInvoiceActions();
                patienActions.Initialize(invoiceObject);
                PopupBaseForm.ShowAsPopup(patienActions, this);
            }
        }
        private void btnDailyRecords_Click(object sender, EventArgs e)
        {
            if (ApplicationStaticConfiguration.ActiveCashBox == null)
            {
                ChooseCashBox_UC chooseCashBox = new ChooseCashBox_UC();
                PopupBaseForm.ShowAsPopup(chooseCashBox, this);
            }

            SetCashBoxDetails();

            if (ApplicationStaticConfiguration.ActiveCashBox != null)
            {
                BaseController <CashBoxInOutTransaction> .ShowEditorControl(ref _cashInOutTransactionViewer, this, null,
                                                                            null, EditorContainerType.Regular, ViewerName.CashBoxInOutTrasactionViewer,
                                                                            DB_CommonTransactionType.CreateNew, "المعـامـــــلات اليـوميـــــــة", true);
            }

            SetCashBoxDetails();
        }
        private void btnAddedDiagnosisFullScreen_Click(object sender, EventArgs e)
        {
            switch (FullScreenMode)
            {
            case FullScreenMode.NotFullScreen:
                FullScreenMode = FullScreenMode.FullScreen;
                btnAddedDiagnosisFullScreen.Image = Properties.Resources.ExitFullScreen_08_01;
                PopupBaseForm.ShowAsPopup(this, this, colorTouse: Color.White);
                break;

            case FullScreenMode.FullScreen:
                if (ParentForm != null)
                {
                    //CommonViewsActions.ShowUserControl(ref _pemrDiagnosis, ParentControl);
                    ParentForm.Close();
                    ParentControl.Controls.Add(this);
                }
                btnAddedDiagnosisFullScreen.Image = Properties.Resources.FullScreen_1_161;
                FullScreenMode = FullScreenMode.NotFullScreen;
                break;
            }
        }
Пример #24
0
 // constructor
 public PopupFormCustomButtonsViewInfo(PopupBaseForm ownerPopupForm) : base(ownerPopupForm)
 {
 }
        private void barButtonItem1_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
        {
            ChangeTheme_UC changeTheme = new ChangeTheme_UC();

            PopupBaseForm.ShowAsPopup(changeTheme, this);
        }
Пример #26
0
 public PWColorCellsControl(PopupBaseForm shadowForm)
     : this(shadowForm, 8, 8)
 {
 }
Пример #27
0
        protected override void SetTabPageProperties(int pageIndex, PopupBaseForm shadowForm)
        {
            BaseControl  control  = null;
            XtraTabPage  tabPage  = this.TabControl.TabPages[pageIndex];
            ColorListBox colorBox = null;

            control      = new PWColorCellsControl(shadowForm);
            control.Size = (control as PWColorCellsControl).GetBestSize();
            switch (pageIndex)
            {
            case 0:
                tabPage.Text = Localizer.Active.GetLocalizedString(StringId.ColorTabCustom);
                control      = new PWColorCellsControl(shadowForm);
                (control as PWColorCellsControl).Properties  = Owner.Properties;
                (control as PWColorCellsControl).EnterColor += new EnterColorEventHandler(OnEnterColor);
                control.Size        = (control as PWColorCellsControl).GetBestSize();
                tabPage.PageVisible = Properties.ShowCustomColors;
                break;

            case 1:
                tabPage.Text = Localizer.Active.GetLocalizedString(StringId.ColorTabWeb);
                colorBox     = CreateColorListBox();
                colorBox.HighlightedItemStyle = Properties.HighlightedItemStyle;

                if (signType.HasValue && signType.Value != SignType.RGB)
                {
                    colorBox.Items.AddRange(MonoColorList);
                }
                else
                {
                    colorBox.Items.AddRange(ColorListBoxViewInfo.WebColors);
                }
                colorBox.EnterColor           += new EnterColorEventHandler(OnEnterColor);
                colorBox.SelectedIndexChanged += new EventHandler(OnSelectedIndexChanged);
                colorBox.Size = control.Size;
                //colorBox.Size = GetBestListBoxSize(colorBox);
                control             = colorBox;
                tabPage.PageVisible = Properties.ShowWebColors;
                break;

            case 2:
                tabPage.Text = Localizer.Active.GetLocalizedString(StringId.ColorTabSystem);
                colorBox     = CreateColorListBox();
                colorBox.HighlightedItemStyle = Properties.HighlightedItemStyle;
                colorBox.Items.AddRange(ColorListBoxViewInfo.SystemColors);
                colorBox.EnterColor           += new EnterColorEventHandler(OnEnterColor);
                colorBox.SelectedIndexChanged += new EventHandler(OnSelectedIndexChanged);
                colorBox.Size = control.Size;
                //colorBox.Size = GetBestListBoxSize(colorBox);
                control             = colorBox;
                tabPage.PageVisible = false;
                break;
            }
            if (control == null)
            {
                return;
            }
            control.Dock        = DockStyle.Fill;
            control.BorderStyle = BorderStyles.NoBorder;
            if (Owner.LookAndFeel != null)
            {
                control.LookAndFeel.Assign(Owner.LookAndFeel);
            }
            tabPage.Controls.Add(control);
        }
 public MyCustomBlobPopupFormViewInfo(PopupBaseForm form) : base(form)
 {
 }