コード例 #1
0
        public SetEstimateStatus(int estimateRevisionId, int statusId)
        {
            InitializeComponent();

            _mrsClient = new RetailSystemClient();
            _mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            _estimateRevisionId = estimateRevisionId;
            _statusId           = statusId;

            BusyIndicator1.IsBusy = true;

            if (statusId == (int)EstimateRevisionStatus.WorkInProgress || // Reactivate contract
                statusId == (int)EstimateRevisionStatus.OnHold ||         // Put contract On Hold
                statusId == (int)EstimateRevisionStatus.Cancelled)        // Cancelled contract
            {
                _createNewRevision = false;
            }
            else
            {
                _createNewRevision = true;
            }

            GetEstimateHeader();
        }
コード例 #2
0
ファイル: PrintPreview.xaml.cs プロジェクト: maverick126/MRS
 private void Print()
 {
     if (_estimateVariationDisclaimerCurrentId != _estimateVariationDisclaimerNewId)
     {
         RadWindow win = new RadWindow();
         VariationPrintSelection previewDlg = new VariationPrintSelection(_estimateRevisionId, "Variation Print Disclaimer Update Selection", checkBoxDoNotIncludeProductNameAndCode.IsChecked == false, checkBoxDoNotIncludeUOMAndQuantity.IsChecked == false, checkBoxDoNotIncludeContractPriceOnVariation.IsChecked == false, _estimateVariationDisclaimerCurrentId, _estimateVariationDisclaimerNewId, checkBoxIncludeSpecifications.IsChecked ?? true);
         win.Header = "Variation Print Disclaimer Update Selection";
         win.WindowStartupLocation = Telerik.Windows.Controls.WindowStartupLocation.CenterScreen;
         win.Content = previewDlg;
         win.Closed += new EventHandler <WindowClosedEventArgs>(win_Closed);
         win.ShowDialog();
     }
     else
     {
         if (_printType == "studiom")
         {
             System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintLoading.aspx?merge=0&type=" + _printType + "&EstimateRevisionId=" + _estimateRevisionId.ToString(), UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
             this.DialogResult = true;
             CloseRadWindow();
         }
         else if (_printType == "changeonly")
         {
             System.Windows.Browser.HtmlPage.Window.Navigate(new Uri("../PrintVariation.aspx?merge=0&type=" + _printType + "&EstimateRevisionId=" + _estimateRevisionId.ToString() + "&IncludeProductNameAndCode=" + !checkBoxDoNotIncludeProductNameAndCode.IsChecked + "&IncludeUOMAndQuantity=" + !checkBoxDoNotIncludeUOMAndQuantity.IsChecked + "&IncludeContractPriceOnVariation=" + !checkBoxDoNotIncludeContractPriceOnVariation.IsChecked + "&includeSpecifications=" + checkBoxIncludeSpecifications.IsChecked, UriKind.Relative), "_blank", "toolbar=0,menubar=1,location=0,status=0,top=0,left=0,resizable=1");
             this.DialogResult = true;
             CloseRadWindow();
         }
         else
         {
             _mrsClient = new RetailSystemClient();
             _mrsClient.Endpoint.Address           = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
             _mrsClient.GetAreaSurchargeCompleted += new EventHandler <GetAreaSurchargeCompletedEventArgs>(_mrsClient_GetAreaSurchargeCompleted);
             _mrsClient.GetAreaSurchargeAsync(_estimateRevisionId);
         }
     }
 }
コード例 #3
0
ファイル: MainPage.xaml.cs プロジェクト: maverick126/MRS
        /// <summary>
        /// Populate User's details
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        void mrsClient_GetCurrentUserCompleted(object sender, GetCurrentUserCompletedEventArgs e)
        {
            if (e.Error == null)
            {
                User currentUser = e.Result;
                if (currentUser != null)
                {
                    txtFullName.Text = currentUser.FullName;
                    txtRegion.Text   = currentUser.RegionName;

                    _currentApp.CurrentUserFullName      = currentUser.FullName;
                    _currentApp.CurrentUserId            = currentUser.UserId;
                    _currentApp.CurrentRegionId          = currentUser.RegionId;
                    _currentApp.CurrentUserStateID       = currentUser.StateId.ToString();
                    _currentApp.CurrentUserPrimaryRoleId = currentUser.PrimaryRoleId;

                    RetailSystemClient mrsClient = new RetailSystemClient();
                    mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

                    mrsClient.GetUserRolesCompleted += new EventHandler <GetUserRolesCompletedEventArgs>(mrsClient_GetUserRolesCompleted);
                    mrsClient.GetUserRolesAsync(currentUser.UserId);
                }
                else
                {
                    UserValidationError();
                }
            }
            else
            {
                ExceptionHandler.PopUpErrorMessage(e.Error, "GetCurrentUserCompleted");
                UserValidationError();
            }
        }
コード例 #4
0
ファイル: MainPage.xaml.cs プロジェクト: maverick126/MRS
        private void cmbUserRole_SelectionChanged(object sender, Telerik.Windows.Controls.SelectionChangedEventArgs e)
        {
            MessageBoxResult confirm = MessageBox.Show("Do you really want to change your role?\r\nAll unsaved jobs will be reset.", "", MessageBoxButton.OKCancel);

            if (confirm == MessageBoxResult.OK)
            {
                UserRole selectedRole = (UserRole)cmbUserRole.SelectedItem;

                _currentApp.CurrentUserRoleId = selectedRole.RoleId;
                _currentApp.IsManager         = selectedRole.IsManager;

                ResetEditEstimateUserID();

                RetailSystemClient mrsClient = new RetailSystemClient();
                mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

                mrsClient.GetRevisionTypeAccessCompleted += new EventHandler <GetRevisionTypeAccessCompletedEventArgs>(mrsClient_GetRevisionTypeAccessCompleted);
                mrsClient.GetRevisionTypeAccessAsync(selectedRole.RoleId);

                mrsClient.GetRoleAccessModuleCompleted += new EventHandler <GetRoleAccessModuleCompletedEventArgs>(mrsClient_GetRoleAccessModuleCompleted);
                mrsClient.GetRoleAccessModuleAsync(_currentApp.CurrentUserRoleId);
            }
            else
            {
                //Remove SelectionChanged EventHandler before modifying value
                cmbUserRole.SelectionChanged -= new Telerik.Windows.Controls.SelectionChangedEventHandler(cmbUserRole_SelectionChanged);
                //Modify value
                cmbUserRole.SelectedValue = _currentApp.CurrentUserRoleId;
                //Add SelectionChanged EventHandler
                cmbUserRole.SelectionChanged += new Telerik.Windows.Controls.SelectionChangedEventHandler(cmbUserRole_SelectionChanged);
            }
        }
コード例 #5
0
        public void PopulateContent()
        {
            BusyIndicator1.IsBusy = true;

            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            EstimateGridItem item = this.DataContext as EstimateGridItem;

            if (item.RecordType == "EstimateHeader")
            {
                mrsClient.GetEstimateHeaderCompleted += new EventHandler <GetEstimateHeaderCompletedEventArgs>(mrsClient_GetEstimateHeaderCompleted);
                mrsClient.GetEstimateHeaderAsync(item.RecordId);
            }
            else if (item.RecordType == "Queue")
            {
                mrsClient.GetLatestEstimateRevisionIdCompleted += new EventHandler <GetLatestEstimateRevisionIdCompletedEventArgs>(mrsClient_GetLatestEstimateRevisionIdCompleted);
                mrsClient.GetLatestEstimateRevisionIdAsync(item.EstimateId);
            }
            else
            {
                MessageBox.Show("SQS Estimates cannot be viewed here");
                BusyIndicator1.IsBusy = false;
            }
        }
コード例 #6
0
        public UndoThisRevisionConfirmation(object dataContext)
        {
            InitializeComponent();

            EstimateGridItem item = (EstimateGridItem)dataContext;

            _bcContractNumber           = item.ContractNumber;
            _sourceEstimateNo           = item.EstimateId;
            _selectedEstimateRevisionId = item.RecordId;
            _currentRevisionNumber      = item.RevisionNumber;
            _currentRevisionTypeCode    = item.RevisionTypeCode;
            _ownerId = item.OwnerId;

            OKButton.Visibility = Visibility.Collapsed;
            if ((App.Current as App).SelectedStatusId != (int)EstimateRevisionStatus.WorkInProgress && (App.Current as App).SelectedStatusId != (int)EstimateRevisionStatus.Accepted && _currentRevisionTypeCode != "RSTM") // not Split Studio M
            {
                textBlockMessage.Text = "Undo cannot be performed on this status.";
            }
            else if (_ownerId != (App.Current as App).CurrentUserId && !(App.Current as App).IsManager)
            {
                textBlockMessage.Text = "Undo cannot be performed on this user.";
            }
            else
            {
                BusyIndicator1.IsBusy = true;
                OKButton.Visibility   = Visibility.Visible;
                confirmStep           = 1;
                RetailSystemClient mrsClient = new RetailSystemClient();
                mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

                mrsClient.UndoThisRevisionValidateCompleted += new EventHandler <UndoThisRevisionValidateCompletedEventArgs>(mrsClient_UndoThisRevisionValidateCompleted);
                mrsClient.UndoThisRevisionValidateAsync(item.EstimateId, _bcContractNumber, _selectedEstimateRevisionId);
            }
        }
コード例 #7
0
        private void OKButton_Click(object sender, RoutedEventArgs e)
        {
            if (this.txtTempaltename.Text != "")
            {
                if (cmbSalesRegion.SelectedValue.ToString() != "0")
                {
                    RetailSystemClient mrsClient = new RetailSystemClient();
                    mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

                    if (_templateId == 0)
                    {
                        mrsClient.AddNewNotesTemplateCompleted += new EventHandler <AddNewNotesTemplateCompletedEventArgs>(mrsClient_AddNewNotesTemplateCompleted);
                        mrsClient.AddNewNotesTemplateAsync(txtTempaltename.Text, cmbSalesRegion.SelectedValue.ToString(), (App.Current as App).CurrentUserId);
                    }
                    else
                    {
                        mrsClient.CopyNotesTemplateCompleted += new EventHandler <CopyNotesTemplateCompletedEventArgs>(mrsClient_CopyNotesTemplateCompleted);
                        mrsClient.CopyNotesTemplateAsync(txtTempaltename.Text, cmbSalesRegion.SelectedValue.ToString(), (App.Current as App).CurrentUserId, _templateId.ToString());
                    }
                    this.DialogResult = true;
                }
                else
                {
                    RadWindow.Alert("Please select a region.");
                }
            }
            else
            {
                RadWindow.Alert("Please enter a template name.");
            }
        }
コード例 #8
0
ファイル: PrintPreview.xaml.cs プロジェクト: maverick126/MRS
 void win_Closed(object sender, WindowClosedEventArgs e)
 {
     _mrsClient = new RetailSystemClient();
     _mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
     _mrsClient.GetEstimateDisclaimerUpdateDetailsCompleted += new EventHandler <GetEstimateDisclaimerUpdateDetailsCompletedEventArgs>(_mrsClient_GetEstimateDisclaimerUpdateDetailsCompleted);
     _mrsClient.GetEstimateDisclaimerUpdateDetailsAsync(_estimateRevisionId);
 }
コード例 #9
0
        private void OnDrop(object sender, Telerik.Windows.DragDrop.DragEventArgs e)
        {
            EstimateDetails draggedItem = (EstimateDetails)DragDropPayloadManager.GetDataFromObject(e.Data, "DraggedData");
            var             details     = DragDropPayloadManager.GetDataFromObject(e.Data, "DropDetails") as DropIndicationDetails;
            var             currentRow  = e.OriginalSource as GridViewRow ?? (e.OriginalSource as FrameworkElement).ParentOfType <GridViewRow>();
            EstimateDetails targetItem  = currentRow != null ? (EstimateDetails)currentRow.Item : null;

            if (details == null || draggedItem == null || currentRow == null || targetItem == null)
            {
                return;
            }

            var draggedItemAreaId = draggedItem.NonstandardCategoryID > 0 ? draggedItem.NonstandardCategoryID : draggedItem.AreaId;
            var targetItemAreaId  = targetItem.NonstandardCategoryID > 0 ? targetItem.NonstandardCategoryID : targetItem.AreaId;

            if ((draggedItemAreaId == targetItemAreaId) &&
                (draggedItem.EstimateRevisionDetailsId != targetItem.EstimateRevisionDetailsId))
            {
                var collection = (sender as RadGridView).ItemsSource as IList;
                collection.Remove(draggedItem);
                collection.Insert((sender as RadGridView).Items.IndexOf(currentRow.Item), draggedItem);

                RetailSystemClient mrsClient = new RetailSystemClient();
                mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
                mrsClient.MoveEstimateDetailItemCompleted += new EventHandler <MoveEstimateDetailItemCompletedEventArgs>(mrsClient_MoveEstimateDetailItemCompleted);
                mrsClient.MoveEstimateDetailItemAsync(draggedItem.EstimateRevisionDetailsId, targetItem.EstimateRevisionDetailsId, (App.Current as App).CurrentUserId);
            }
            else
            {
            }

            e.Handled = true;
        }
コード例 #10
0
        private void HyperlinkButton_AddClick(object sender, RoutedEventArgs e)
        {
            Grid gr = (Grid)((HyperlinkButton)e.OriginalSource).Parent;
            ValidationErrorMessage er = ((GridViewCell)(gr.Parent)).ParentRow.DataContext as ValidationErrorMessage;

            RetailSystemClient MRSclient = new RetailSystemClient();

            MRSclient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            MRSclient.SaveSelectedItemCompleted += delegate(object o, SaveSelectedItemCompletedEventArgs es)
            {
                if (es.Error == null)
                {
                    if (es.Result > 0)
                    {
                        RefreshErrorMessage(estimaterevisionid);
                    }
                }
                else
                {
                    ExceptionHandler.PopUpErrorMessage(es.Error, "SaveSelectedItemCompleted");
                }
            };

            MRSclient.SaveSelectedItemAsync(er.HomeDisplayOptionId, estimaterevisionid, er.PagID, (App.Current as App).CurrentUserId);
        }
コード例 #11
0
        public void RefreshErrorMessage(int revisionid)
        {
            List <ValidationErrorMessage> result = new List <ValidationErrorMessage>();
            bool show = true;

            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            mrsClient.ValidateStudioMEstimateCompleted += delegate(object o, ValidateStudioMEstimateCompletedEventArgs es)
            {
                if (es.Error == null)
                {
                    foreach (ValidationErrorMessage s in es.Result)
                    {
                        if (show && !s.AllowGoAhead)
                        {
                            show = false;
                        }
                        result.Add(s);
                    }
                    errorGrid.ItemsSource = result;
                }
                else
                {
                    ExceptionHandler.PopUpErrorMessage(es.Error, "ValidateStudioMEstimateCompleted");
                }
            };

            mrsClient.ValidateStudioMEstimateAsync(revisionid);
        }
コード例 #12
0
        private void btnCompare_Click(object sender, RoutedEventArgs e)
        {
            if (cmbRevision1.SelectedItem != null && cmbRevision2.SelectedItem != null)
            {
                BusyIndicator1.IsBusy = true;

                HeaderGrid.Columns[1].Header = ((EstimateGridItem)cmbRevision1.SelectedItem).RevisionDetails;
                HeaderGrid.Columns[2].Header = ((EstimateGridItem)cmbRevision2.SelectedItem).RevisionDetails;

                HeaderCompareGrid.Columns[1].Header = HeaderGrid.Columns[1].Header;
                HeaderCompareGrid.Columns[2].Header = HeaderGrid.Columns[2].Header;

                RetailSystemClient mrsClient = new RetailSystemClient();
                mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

                mrsClient.CompareEstimateHeaderCompleted += new EventHandler <CompareEstimateHeaderCompletedEventArgs>(mrsClient_CompareEstimateHeaderCompleted);
                mrsClient.CompareEstimateHeaderAsync(Convert.ToInt32(cmbRevision1.SelectedValue), Convert.ToInt32(cmbRevision2.SelectedValue));
            }
            else
            {
                DialogParameters param = new DialogParameters();
                param.Header  = "Estimate Revisions Required";
                param.Content = "Please specify both Source and Destination revisions to compare.";
                RadWindow.Alert(param);
            }
        }
コード例 #13
0
        private void HyperlinkButton_AnswerClick(object sender, RoutedEventArgs e)
        {
            RadWindow              win = new RadWindow();
            EstimateDetails        pag = new EstimateDetails();
            Grid                   gr  = (Grid)((HyperlinkButton)e.OriginalSource).Parent;
            ValidationErrorMessage er  = ((GridViewCell)(gr.Parent)).ParentRow.DataContext as ValidationErrorMessage;

            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address     = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            mrsClient.GetPagByIDCompleted += delegate(object o, GetPagByIDCompletedEventArgs es)
            {
                if (es.Error == null)
                {
                    pag = es.Result;
                    AppOptionFromTree acceptDlg = new AppOptionFromTree(pag, "STUDIOM_ANSWER", 0);
                    win.WindowStartupLocation = Telerik.Windows.Controls.WindowStartupLocation.CenterScreen;
                    win.Header  = "Add Option Window";
                    win.Content = acceptDlg;
                    win.Closed += new EventHandler <WindowClosedEventArgs>(win_AddOptionClosed);
                    win.ShowDialog();
                }
                else
                {
                    ExceptionHandler.PopUpErrorMessage(es.Error, "GetPagByIDCompleted");
                }
            };
            mrsClient.GetPagByIDAsync(estimaterevisionid, er.HomeDisplayOptionId);
        }
コード例 #14
0
 private void Print()
 {
     _mrsClient = new RetailSystemClient();
     _mrsClient.Endpoint.Address           = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
     _mrsClient.GetAreaSurchargeCompleted += new EventHandler <GetAreaSurchargeCompletedEventArgs>(_mrsClient_GetAreaSurchargeCompleted);
     _mrsClient.GetAreaSurchargeAsync(_estimateRevisionId);
 }
コード例 #15
0
        public void UpdateNoteTemplateName(int templateid, string templatename)
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.CheckNewNoteTemplateNameExistsCompleted += delegate(object o, CheckNewNoteTemplateNameExistsCompletedEventArgs es)
            {
                if (es.Error == null)
                {
                    if (es.Result.ToString().ToUpper() == "OK")
                    {
                        ((NotesTemplateViewModel)LayoutRoot.DataContext).UpdateNoteTemplateName(templateid, (App.Current as App).CurrentUserId, templatename, "NAME");
                    }
                    else
                    {
                        MessageBox.Show(es.Result.ToString());
                        ((NotesTemplateViewModel)LayoutRoot.DataContext).SearchNotesTemplate();
                    }
                }
                else
                {
                    ExceptionHandler.PopUpErrorMessage(es.Error, "CheckNewNoteTemplateNameExistsCompleted");
                }
            };

            mrsClient.CheckNewNoteTemplateNameExistsAsync(templateid, templatename);
            mrsClient = null;
        }
コード例 #16
0
        private void OKButton_Click(object sender, RoutedEventArgs e)
        {
            //((NotesTemplateItemsViewModel)LayoutRoot.DataContext).SaveItemsToNoteTempLate();
            int userid = (App.Current as App).CurrentUserId;

            foreach (var item in ((NotesTemplateItemsViewModel)LayoutRoot.DataContext).AvailableNoteTemplateItem)
            {
                if (item.PromotionProduct) // here reuse this column to hold the selection of check box
                {
                    if (selecteditemids == "")
                    {
                        selecteditemids = item.ProductAreaGroupID.ToString();
                    }
                    else
                    {
                        selecteditemids = selecteditemids + "," + item.ProductAreaGroupID.ToString();
                    }
                    //_selectednotetemplateitem.Add(item);
                }
            }
            mrsClient2 = new RetailSystemClient();
            mrsClient2.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient2.AddItemToNotesTemplateCompleted += new EventHandler <AddItemToNotesTemplateCompletedEventArgs>(mrsClient2_AddItemToNotesTemplateCompleted);
            mrsClient2.AddItemToNotesTemplateAsync(AddNotesTempateItems._templateid, selecteditemids, userid);
            mrsClient2 = null;
        }
コード例 #17
0
ファイル: Dashboard.xaml.cs プロジェクト: maverick126/MRS
        /// <summary>
        /// Get User's details from the database
        /// </summary>
        private void GetUser()
        {
            RetailSystemClient mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.GetCurrentUserCompleted += new EventHandler<GetCurrentUserCompletedEventArgs>(mrsClient_GetCurrentUserCompleted);
            mrsClient.GetCurrentUserAsync(_currentApp.CurrentUserLoginName);
        }
コード例 #18
0
        private void OKButton_Click(object sender, RoutedEventArgs e)
        {
            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            //mrsClient.CommenceWorkCompleted += new EventHandler<System.ComponentModel.AsyncCompletedEventArgs>(mrsClient_CommenceWorkCompleted);
            //mrsClient.CommenceWorkAsync(_recordId, (App.Current as App).CurrentUserId);
        }
コード例 #19
0
        public void GetDocuSignHistoryByRevision(string revisionid, string versiontype, string printtype)
        {
            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            mrsClient.DocuSign_GetEnvelopeHistoryByRevisionCompleted += new EventHandler <DocuSign_GetEnvelopeHistoryByRevisionCompletedEventArgs>(DocuSign_GetEnvelopeHistoryByRevisionCompleted);
            mrsClient.DocuSign_GetEnvelopeHistoryByRevisionAsync(revisionid, versiontype, printtype);
        }
コード例 #20
0
        public void GetDocuSignHistory(string envelopeid)
        {
            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            mrsClient.DocuSign_GetEnvelopeHistoryCompleted += new EventHandler <DocuSign_GetEnvelopeHistoryCompletedEventArgs>(DocuSign_DocuSign_GetEnvelopeHistoryCompleted);
            mrsClient.DocuSign_GetEnvelopeHistoryAsync(envelopeid);
        }
コード例 #21
0
 public ChangeHomeName(int revisionid)
 {
     _estimateRevisionId = revisionid;
     InitializeComponent();
     _mrsClient = new RetailSystemClient();
     _mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
     PopulateHomeName();
 }
コード例 #22
0
        public void PushDocumentToProcessingQueue(string revisionid, string printtype, string documenttype, int userid)
        {
            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
            mrsClient.DocuSign_PushDocumentToTheProcessQueueCompleted += new EventHandler <DocuSign_PushDocumentToTheProcessQueueCompletedEventArgs>(DocuSign_PushDocumentToTheProcessQueueCompleted);
            mrsClient.DocuSign_PushDocumentToTheProcessQueueAsync(revisionid, printtype, documenttype, userid);
        }
コード例 #23
0
        public void SearchItem()
        {
            mrsClient2 = new RetailSystemClient();
            mrsClient2.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient2.GetAvailableItemsForNotesTemplateCompleted += new EventHandler <GetAvailableItemsForNotesTemplateCompletedEventArgs>(mrsClient2_GetAvailableItemsForNotesTemplateCompleted);
            mrsClient2.GetAvailableItemsForNotesTemplateAsync(AddNotesTempateItems._templateid, ItemSearchText);
            //mrsClient2 = null;
        }
コード例 #24
0
 public CopyEstimate(int revisionid, int destinationEstimateNo)
 {
     estimaterevisionid     = revisionid;
     _destinationEstimateNo = destinationEstimateNo;
     InitializeComponent();
     _mrsClient = new RetailSystemClient();
     _mrsClient.Endpoint.Address   = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());
     txtSourceEstimateNumber.Value = null;
 }
コード例 #25
0
ファイル: MainPage.xaml.cs プロジェクト: maverick126/MRS
        private void GetStatuses()
        {
            RetailSystemClient mrsClient = new RetailSystemClient();

            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.GetEstimateStatusesCompleted += new EventHandler <GetEstimateStatusesCompletedEventArgs>(mrsClient_GetEstimateStatusesCompleted);
            mrsClient.GetEstimateStatusesAsync();
        }
コード例 #26
0
        public void SearchNotesTemplate()
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.GetAdditionalNotesTemplateAndProductsByRegionCompleted += new EventHandler <GetAdditionalNotesTemplateAndProductsByRegionCompletedEventArgs>(mrsClient_AdditionalNotesTemplateAndProductsByRegionCompleted);
            mrsClient.GetAdditionalNotesTemplateAndProductsByRegionAsync(TemplateNameSearchText, SelectedRegionId.ToString(), userid, SelectedStatus, (App.Current as App).CurrentUserRoleId);
            mrsClient = null;
        }
コード例 #27
0
        public void loadData()
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.GetSalesRegionByStateCompleted += new EventHandler <GetSalesRegionByStateCompletedEventArgs>(mrsClient_GetSalesRegionByStateCompleted);
            mrsClient.GetSalesRegionByStateAsync((App.Current as App).CurrentUserStateID);
            mrsClient = null;
        }
コード例 #28
0
        public void UpdateNoteTemplateName(int templateid, int userid, string templatename, string action)
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.UpdateNoteTemplateCompleted += new EventHandler <UpdateNoteTemplateCompletedEventArgs>(mrsClient_UpdateNoteTemplateCompleted);
            mrsClient.UpdateNoteTemplateAsync(templateid, templatename, 1, userid, action);
            mrsClient = null;
        }
コード例 #29
0
        //public void UpdateNoteTemplateItem(string templateid, string productareagroupid, decimal quantity, decimal price, string extradescription, int userid)
        //{
        //    mrsClient = new RetailSystemClient();
        //    mrsClient.UpdateNotesTemplateItemCompleted += new EventHandler<UpdateNotesTemplateItemCompletedEventArgs>(mrsClient_UpdateNotesTemplateItemCompleted);
        //    mrsClient.UpdateNotesTemplateItemAsync(templateid,productareagroupid, quantity, price, extradescription, userid);
        //    mrsClient = null;
        //}
        public void UpdateNoteTemplateItem(EstimateDetails pag)
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.UpdateNotesTemplateItemCompleted += new EventHandler <UpdateNotesTemplateItemCompletedEventArgs>(mrsClient_UpdateNotesTemplateItemCompleted);
            mrsClient.UpdateNotesTemplateItemAsync(pag.TemplateID, pag.ProductAreaGroupID.ToString(), pag.Quantity, pag.Price, pag.ExtraDescription, pag.InternalDescription, pag.AdditionalNotes, userid, pag.UseDefaultQuantity);
            mrsClient = null;
        }
コード例 #30
0
        public void RemoveNoteTemplate(NoteTemplate template)
        {
            mrsClient = new RetailSystemClient();
            mrsClient.Endpoint.Address = new System.ServiceModel.EndpointAddress(Internal.Utilities.GetMetriconRetailSystemWcfClientEndpointUrl());

            mrsClient.RemoveNotesTemplateCompleted += new EventHandler <RemoveNotesTemplateCompletedEventArgs>(mrsClient_RemoveNotesTemplateCompleted);
            mrsClient.RemoveNotesTemplateAsync(template.TemplateID.ToString(), userid);
            mrsClient = null;
        }