public ActionResult Delete(int?invoiceLineId, int?masterInvoiceId = null, int?masterTrackId = null)
        {
            InvoiceLineItemModel invoiceLineItemModel = new InvoiceLineItemModel()
            {
                IsSecurityOperations = this.IsSecurityOperations,
                InvoiceLine          = new InvoiceLineViewModel(),
                ControllerAction     = "Delete",
                MasterInvoiceId      = masterInvoiceId, MasterTrackId = masterTrackId
            };

            try
            {
                InvoiceLineDTO invoiceLineDTO = Application.GetById(invoiceLineItemModel.OperationResult, new object[] { invoiceLineId });
                if (invoiceLineDTO != null)
                {
                    invoiceLineItemModel.InvoiceLine = new InvoiceLineViewModel(invoiceLineDTO);
                }
            }
            catch (Exception exception)
            {
                invoiceLineItemModel.OperationResult.ParseException(exception);
            }

            return(PartialView(invoiceLineItemModel));
        }
        public ActionResult Delete(InvoiceLineItemModel invoiceLineItemModel)
        {
            try
            {
                if (Application.Delete(invoiceLineItemModel.OperationResult, (InvoiceLineDTO)invoiceLineItemModel.InvoiceLine.ToDTO()))
                {
                    return(JsonResultSuccess(new { uri = ReadUrlDictionary() }));
                }
            }
            catch (Exception exception)
            {
                invoiceLineItemModel.OperationResult.ParseException(exception);
            }

            return(JsonResultOperationResult(invoiceLineItemModel.OperationResult));
        }
        public ActionResult Delete(InvoiceLineItemModel invoiceLineItemModel)
        {
            try
            {
                if (Application.Delete(invoiceLineItemModel.OperationResult, (InvoiceLineDTO)invoiceLineItemModel.InvoiceLine.ToDTO()))
                {
                    return(RedirectToUrlDictionary());
                }
            }
            catch (Exception exception)
            {
                invoiceLineItemModel.OperationResult.ParseException(exception);
            }

            invoiceLineItemModel.IsSecurityOperations = IsSecurityOperations;

            return(View(invoiceLineItemModel));
        }
        public ActionResult Create(int?masterInvoiceId = null, int?masterTrackId = null)
        {
            InvoiceLineItemModel invoiceLineItemModel = new InvoiceLineItemModel()
            {
                IsSecurityOperations = this.IsSecurityOperations,
                InvoiceLine          = new InvoiceLineViewModel(),
                ControllerAction     = "Create",
                MasterInvoiceId      = masterInvoiceId, MasterTrackId = masterTrackId
            };

            try
            {
                IsCreate(invoiceLineItemModel.OperationResult);
            }
            catch (Exception exception)
            {
                invoiceLineItemModel.OperationResult.ParseException(exception);
            }

            return(PartialView(invoiceLineItemModel));
        }