Пример #1
0
        private void listProgram_DoubleClick(object sender, System.EventArgs e)
        {
            if (listProgram.SelectedIndex == -1)
            {
                return;
            }
            Program program = ProgramC.Listt[listProgram.SelectedIndex].Copy();

            if (program.ProgName == "UAppoint")
            {
                FormUAppoint FormU = new FormUAppoint();
                FormU.ProgramCur = program;
                FormU.ShowDialog();
                if (FormU.DialogResult == DialogResult.OK)
                {
                    changed = true;
                    FillList();
                }
                return;
            }
            if (program.ProgName == "eClinicalWorks")
            {
                if (!Security.IsAuthorized(Permissions.SecurityAdmin))
                {
                    return;
                }
                FormEClinicalWorks FormECW = new FormEClinicalWorks();
                FormECW.ProgramCur = program;
                FormECW.ShowDialog();
                if (FormECW.DialogResult == DialogResult.OK)
                {
                    changed = true;
                    FillList();
                }
                return;
            }
            if (program.ProgName == "Mountainside")
            {
                FormMountainside FormM = new FormMountainside();
                FormM.ProgramCur = program;
                FormM.ShowDialog();
                if (FormM.DialogResult == DialogResult.OK)
                {
                    changed = true;
                    FillList();
                }
                return;
            }
            if (program.ProgName == "PayConnect")
            {
                FormPayConnectSetup fpcs = new FormPayConnectSetup();
                fpcs.ShowDialog();
                if (fpcs.DialogResult == DialogResult.OK)
                {
                    changed = true;
                    FillList();
                }
                return;
            }
            if (program.ProgName == "Xcharge")
            {
                FormXchargeSetup fxcs = new FormXchargeSetup();
                fxcs.ShowDialog();
                if (fxcs.DialogResult == DialogResult.OK)
                {
                    changed = true;
                    FillList();
                }
                return;
            }
            FormProgramLinkEdit FormPE = new FormProgramLinkEdit();

            FormPE.ProgramCur = program;
            FormPE.ShowDialog();
            changed = true;
            FillList();
        }
Пример #2
0
        private void gridProgram_CellDoubleClick(object sender, ODGridClickEventArgs e)
        {
            DialogResult dResult = DialogResult.None;
            Program      program = _listPrograms[gridProgram.GetSelectedIndex()].Copy();

            switch (program.ProgName)
            {
            case "UAppoint":
                FormUAppoint FormU = new FormUAppoint();
                FormU.ProgramCur = program;
                dResult          = FormU.ShowDialog();
                break;

            case "eClinicalWorks":
                if (!Security.IsAuthorized(Permissions.SecurityAdmin))
                {
                    break;
                }
                FormEClinicalWorks FormECW = new FormEClinicalWorks();
                FormECW.ProgramCur = program;
                dResult            = FormECW.ShowDialog();
                break;

            case "eRx":
                FormErxSetup FormES = new FormErxSetup();
                dResult = FormES.ShowDialog();
                break;

            case "Mountainside":
                FormMountainside FormM = new FormMountainside();
                FormM.ProgramCur = program;
                dResult          = FormM.ShowDialog();
                break;

            case "PayConnect":
                FormPayConnectSetup fpcs = new FormPayConnectSetup();
                dResult = fpcs.ShowDialog();
                break;

            case "Podium":
                FormPodiumSetup FormPS = new FormPodiumSetup();
                dResult = FormPS.ShowDialog();
                break;

            case "Xcharge":
                FormXchargeSetup fxcs = new FormXchargeSetup();
                dResult = fxcs.ShowDialog();
                break;

            case "FHIR":
                FormFHIRSetup FormFS = new FormFHIRSetup();
                dResult = FormFS.ShowDialog();
                break;

            case "Transworld":
                FormTransworldSetup FormTs = new FormTransworldSetup();
                dResult = FormTs.ShowDialog();
                break;

            case "PaySimple":
                FormPaySimpleSetup formPS = new FormPaySimpleSetup();
                dResult = formPS.ShowDialog();
                break;

            default:
                FormProgramLinkEdit FormPE = new FormProgramLinkEdit();
                if (Programs.IsStatic(program))
                {
                    FormPE.AllowToolbarChanges = false;
                }
                FormPE.ProgramCur = program;
                dResult           = FormPE.ShowDialog();
                break;
            }
            if (dResult == DialogResult.OK)
            {
                changed = true;
                FillList();
            }
        }
Пример #3
0
 private void menuPayConnect_Click(object sender,EventArgs e)
 {
     if(Security.IsAuthorized(Permissions.Setup)) {
         FormPayConnectSetup fpcs=new FormPayConnectSetup();
         if(fpcs.ShowDialog()==DialogResult.OK) {
             CheckUIState();
         }
     }
 }
Пример #4
0
 private void butPayConnect_Click(object sender,EventArgs e)
 {
     Program prog=Programs.GetCur(ProgramName.PayConnect);
     if(!prog.Enabled) {
         FormPayConnectSetup fpcs=new FormPayConnectSetup();
         fpcs.ShowDialog();
         CheckUIState();
         return;
     }
     if(textAmount.Text=="" || textAmount.Text=="0.00") {
         MsgBox.Show(this,"Please enter an amount first.");
         return;
     }
     CreditCard CCard=null;
     List<CreditCard> creditCards=CreditCards.Refresh(PatCur.PatNum);
     for(int i=0;i<creditCards.Count;i++) {
         if(i==comboCreditCards.SelectedIndex) {
             CCard=creditCards[i];
         }
     }
     FormPayConnect FormP;
     FormP=new FormPayConnect(PaymentCur,PatCur,textAmount.Text,CCard);
     FormP.ShowDialog();
     ArrayList props=ProgramProperties.GetForProgram(prog.ProgramNum);
     ProgramProperty prop=null;
     for(int i=0;i<props.Count;i++) {
         ProgramProperty curProp=(ProgramProperty)props[i];
         if(curProp.PropertyDesc=="PaymentType") {
             prop=curProp;
             break;
         }
     }
     //still need to add functionality for accountingAutoPay
     listPayType.SelectedIndex=DefC.GetOrder(DefCat.PaymentTypes,PIn.Long(prop.PropertyValue));
     SetComboDepositAccounts();
     if(FormP.Response!=null) {
         textNote.Text+=((textNote.Text=="")?"":Environment.NewLine)+Lan.g(this,"Transaction Type")+": "+Enum.GetName(typeof(PayConnectService.transType),FormP.TranType)+Environment.NewLine+
             Lan.g(this,"Status")+": "+FormP.Response.Status.description;
         if(FormP.Response.Status.code==0) { //The transaction succeeded.
             payConnectWarn=true;//Show a warning if user cancels out of window.
             textNote.Text+=Environment.NewLine
                 +Lan.g(this,"Amount")+": "+FormP.AmountCharged+Environment.NewLine
                 +Lan.g(this,"Auth Code")+": "+FormP.Response.AuthCode+Environment.NewLine
                 +Lan.g(this,"Ref Number")+": "+FormP.Response.RefNumber;
             textNote.Select(textNote.Text.Length-1,0);
             textNote.ScrollToCaret();//Scroll to the end of the text box to see the newest notes.
             if(FormP.TranType==PayConnectService.transType.VOID || FormP.TranType==PayConnectService.transType.RETURN) {
                 textAmount.Text="-"+FormP.AmountCharged;
             }
             else if(FormP.TranType==PayConnectService.transType.AUTH) {
                 textAmount.Text=FormP.AmountCharged;
             }
             else if(FormP.TranType==PayConnectService.transType.SALE) {
                 textAmount.Text=FormP.AmountCharged;
                 PaymentCur.Receipt=FormP.ReceiptStr; //There is only a receipt when a sale takes place.
             }
         }
     }
     if(FormP.Response==null || FormP.Response.Status.code!=0) { //The transaction failed.
         if(FormP.TranType==PayConnectService.transType.SALE || FormP.TranType==PayConnectService.transType.AUTH) {
             textAmount.Text=FormP.AmountCharged;//Preserve the amount so the user can try the payment again more easily.
         }
     }
 }
Пример #5
0
		private void listProgram_DoubleClick(object sender, System.EventArgs e) {
			if(listProgram.SelectedIndex==-1){
				return;
			}
			Program program=ProgramC.Listt[listProgram.SelectedIndex].Copy();
			if(program.ProgName=="UAppoint"){
				FormUAppoint FormU=new FormUAppoint();
				FormU.ProgramCur=program;
				FormU.ShowDialog();
				if(FormU.DialogResult==DialogResult.OK){
					changed=true;
					FillList();
				}
				return;
			}
			if(program.ProgName=="eClinicalWorks") {
				if(!Security.IsAuthorized(Permissions.SecurityAdmin)) {
					return;
				}
				FormEClinicalWorks FormECW=new FormEClinicalWorks();
				FormECW.ProgramCur=program;
				FormECW.ShowDialog();
				if(FormECW.DialogResult==DialogResult.OK) {
					changed=true;
					FillList();
				}
				return;
			}
			if(program.ProgName=="Mountainside") {
				FormMountainside FormM=new FormMountainside();
				FormM.ProgramCur=program;
				FormM.ShowDialog();
				if(FormM.DialogResult==DialogResult.OK) {
					changed=true;
					FillList();
				}
				return;
			}
			if(program.ProgName=="PayConnect") {
				FormPayConnectSetup fpcs=new FormPayConnectSetup();
				fpcs.ShowDialog();
				if(fpcs.DialogResult==DialogResult.OK) {
					changed=true;
					FillList();
				}
				return;
			}
			if(program.ProgName=="Xcharge") {
				FormXchargeSetup fxcs=new FormXchargeSetup();
				fxcs.ShowDialog();
				if(fxcs.DialogResult==DialogResult.OK) {
					changed=true;
					FillList();
				}
				return;
			}
			FormProgramLinkEdit FormPE=new FormProgramLinkEdit();
			FormPE.ProgramCur=program;
			FormPE.ShowDialog();
			changed=true;
			FillList();
		}