Esempio n. 1
0
        private void BtnDetail_Click(object sender, RoutedEventArgs e)
        {
            var obj = DaGr.SelectedItems;
            if (obj == null || obj.Count == 0)
            {
                ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON"), MessageIcon.Exclamation);
                return;
            }

            if (RepayEntity != null)
            {
                RepayApplyForm DetailWin = new RepayApplyForm(FormTypes.Browse, RepayEntity.REPAYAPPLYMASTERID);
                EntityBrowser browser = new EntityBrowser(DetailWin);
                browser.FormType = FormTypes.Browse;
                browser.MinWidth = 800;
                browser.MinHeight = 500;
                //browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent);
                browser.Show<string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { });
                //RepayEntity = null;
            }
            else
            {
                ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON"));
                return;
            }
        }
Esempio n. 2
0
 void btnReSubmit_Click(object sender, RoutedEventArgs e)
 {
     DateTime dt = new DateTime(2012, 2, 18);
     var obj = DaGr.SelectedItems;
     if (obj != null && obj.Count >0)
     {
         if (RepayEntity.CHECKSTATES == (int)CheckStates.UnApproved)
         {
             if (RepayEntity.UPDATEDATE <= dt)   //add zl
             {
                 Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("TIPS"), "2012.2.17号及之前日期的单据不能进行重新提交,请另新建单据!");
                 return;
             }
             RepayApplyForm AddWin = new RepayApplyForm(FormTypes.Resubmit, RepayEntity.REPAYAPPLYMASTERID);
             EntityBrowser browser = new EntityBrowser(AddWin);
             browser.FormType = FormTypes.Resubmit;
             browser.MinWidth = 800;
             browser.MinHeight = 500;
             browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent);
             browser.Show<string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }, true);
         }
         else
         {//todo 
             Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("不能重新提交审核"));
         }
     }
     else
     {
         ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "SUBMITAUDIT"), Utility.GetResourceStr("CONFIRMBUTTON"));
         return;
     }
 }
Esempio n. 3
0
        private void btnEdit_Click(object sender, RoutedEventArgs e)
        {
            if (RepayEntity != null)
            {
                if (SMT.SaaS.FrameworkUI.Common.Utility.ToolBarButtonOperationPermission(RepayEntity, "T_FB_REPAYAPPLYMASTER", OperationType.Edit, SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID))
                {

                    if (RepayEntity.CHECKSTATES == (int)CheckStates.UnSubmit)
                    {

                        RepayApplyForm AddWin = new RepayApplyForm(FormTypes.Edit, RepayEntity.REPAYAPPLYMASTERID);
                        EntityBrowser browser = new EntityBrowser(AddWin);
                        browser.FormType = FormTypes.Edit;
                        browser.MinWidth = 800;
                        browser.MinHeight = 500;
                        browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent);
                        browser.Show<string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }, true);
                        AddWin.Deleted += (ss, ee) => { browser.Close(); GetData(); };
                        //RepayEntity = null;
                    }
                    else
                    {
                        ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("ONLYEDITUNSUBMITDATA"),
                        Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation);//只能修改未提交的数据
                    }
                }
                else
                {
                    //Utility.ShowCustomMessage(MessageTypes.Caution, Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("YOUDONOTHAVEPERMISSIONTOOPERATETHEDATA"));
                    ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("YOUDONOTHAVEPERMISSIONTOOPERATETHEDATA"),
                    Utility.GetResourceStr("CONFIRM"), MessageIcon.Exclamation);
                }

            }
            else
            {
                ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON"));
                return;
            }

        }
Esempio n. 4
0
        void btnAudit_Click(object sender, RoutedEventArgs e)
        {

            if (RepayEntity != null)
            {
                if (!string.IsNullOrEmpty(RepayEntity.REPAYAPPLYMASTERID))
                {
                    RepayApplyForm AddWin = new RepayApplyForm(FormTypes.Audit, RepayEntity.REPAYAPPLYMASTERID);

                    EntityBrowser browser = new EntityBrowser(AddWin);
                    browser.FormType = FormTypes.Audit;
                    //browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent);
                    browser.Show<string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { });
                }
            }
            else
            {
                ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "AUDIT"), Utility.GetResourceStr("CONFIRMBUTTON"));

            }

        }
Esempio n. 5
0
        private void btnNew_Click(object sender, RoutedEventArgs e)
        {
            //SMT.FBAnalysis.UI.Common.Utility.CreateFormFromEngine("143f3aa5-7c52-48d5-abfb-4a9bef57063c", "SMT.FBAnalysis.UI.Form.RepayApplyForm", "Edit");
            RepayApplyForm AddWin = new RepayApplyForm(FormTypes.New, "");
            EntityBrowser browser = new EntityBrowser(AddWin);
            browser.MinWidth = 800;
            browser.MinHeight = 500;
            browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent);
            browser.Show<string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }, true);
            AddWin.Deleted += (ss, ee) => { browser.Close(); GetData(); };

        }