Пример #1
0
        private void BtnSave_Click(object sender, RoutedEventArgs e)
        {
            if (dgSelect.SelectedItems == null)
            {
                ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "复制"), Utility.GetResourceStr("CONFIRMBUTTON"), MessageIcon.Exclamation);
                return;
            }

            if (dgSelect.SelectedItems.Count == 0)
            {
                ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "复制"), Utility.GetResourceStr("CONFIRMBUTTON"), MessageIcon.Exclamation);
                return;
            }
            T_OA_TRAVELSOLUTIONS ent = new T_OA_TRAVELSOLUTIONS();

            ent = (dgSelect.SelectedItems[0] as T_OA_TRAVELSOLUTIONS);

            if (ent != null)
            {
                if (this.SelectSolutionComplete != null)
                {
                    SelectSolutionEventArgs arg = new SelectSolutionEventArgs(ent);
                    SelectSolutionComplete(this, arg);
                }
                //Save(ent);
            }
            RefreshUI(RefreshedTypes.CloseAndReloadData);
        }
Пример #2
0
        private void BtnSave_Click(object sender, RoutedEventArgs e)
        {
            if (dgSelect.SelectedItems == null)
            {
                ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "复制"), Utility.GetResourceStr("CONFIRMBUTTON"), MessageIcon.Exclamation);
                return;
            }

            if (dgSelect.SelectedItems.Count == 0)
            {
                ComfirmWindow.ConfirmationBoxs(Utility.GetResourceStr("TIPS"), Utility.GetResourceStr("SELECTERROR", "复制"), Utility.GetResourceStr("CONFIRMBUTTON"), MessageIcon.Exclamation);
                return;
            }
            T_OA_TRAVELSOLUTIONS ent = new T_OA_TRAVELSOLUTIONS();
            ent = (dgSelect.SelectedItems[0] as T_OA_TRAVELSOLUTIONS);

            if (ent != null)
            {
                if (this.SelectSolutionComplete != null)
                {
                    SelectSolutionEventArgs arg=new SelectSolutionEventArgs(ent);
                    SelectSolutionComplete(this, arg);
                }
                //Save(ent);
            }
            RefreshUI(RefreshedTypes.CloseAndReloadData);
        }