protected void lnkDontIgnore_Click(object sender, EventArgs e) { // Get the last status if (_lstOrderAddressLogItems.Count > 1) { Model.MigrationStatuses enmLastStatus = (Model.MigrationStatuses)_lstOrderAddressLogItems[1].MigrationStatusID; // Revert the status BLL.OrderAddressProcessor objOrderAddressProcessor = new BLL.OrderAddressProcessor(); if (objOrderAddressProcessor.Load(_objOrderAddress.OrderAddressID.Value) == false) { lblErrorMessage.Text += String.Concat("There was an error while trying to load the record from the database for processing. Error Message = [", String.Join(",", objOrderAddressProcessor.ErrorMessages.ToArray()), "]"); //logUserAction(false, "Load of the ATI File for subsequent tranmission to SAT via Indicium."); return; } if (objOrderAddressProcessor.AdjustStatus(enmLastStatus, true, Page.User.Identity.Name) == false) { lblErrorMessage.Text += String.Concat("There was an error while trying to adjust the migration status on the record. Error Message = [", String.Join(",", objOrderAddressProcessor.ErrorMessages.ToArray()), "]"); //logUserAction(false, "ATI File tranmission to SAT via Indicium."); } else { //logUserAction(true, "ATI File tranmission to SAT via Indicium."); Response.Redirect(HttpContext.Current.Request.Url.AbsoluteUri); } } else { lblErrorMessage.Text += String.Concat("The record is not in a state that will allow for its status to be reverted."); } }
protected void lnkSetToIgnored_Click(object sender, EventArgs e) { // Bump the status BLL.OrderAddressProcessor objOrderAddressProcessor = new BLL.OrderAddressProcessor(); if (objOrderAddressProcessor.Load(_objOrderAddress.OrderAddressID.Value) == false) { lblErrorMessage.Text += String.Concat("There was an error while trying to load the record from the database for processing. Error Message = [", String.Join(",", objOrderAddressProcessor.ErrorMessages.ToArray()), "]"); //logUserAction(false, "Load of the ATI File for subsequent tranmission to SAT via Indicium."); return; } if (objOrderAddressProcessor.AdjustStatus(Model.MigrationStatuses.IGNORED_indefinitely, true, Page.User.Identity.Name) == false) { lblErrorMessage.Text += String.Concat("There was an error while trying to adjust the migration status of the record. Error Message = [", String.Join(",", objOrderAddressProcessor.ErrorMessages.ToArray()), "]"); //logUserAction(false, "ATI File tranmission to SAT via Indicium."); } else { //logUserAction(true, "ATI File tranmission to SAT via Indicium."); Response.Redirect(HttpContext.Current.Request.Url.AbsoluteUri); } }