Exemplo n.º 1
0
    protected void uxDeleteButton_Click(object sender, EventArgs e)
    {
        try
        {
            bool deleted = false;
            foreach (GridViewRow row in uxItemGrid.Rows)
            {
                CheckBox deleteCheck = (CheckBox)row.FindControl("uxCheck");
                if (deleteCheck.Checked)
                {
                    HiddenField hd = (HiddenField)row.FindControl("uxHidden");
                    string      id = hd.Value;

                    DataAccessContext.OrderItemRepository.Delete(id);
                    deleted = true;
                }
            }

            if (deleted)
            {
                uxMessage.DisplayMessage(Resources.OrdersMessages.DeleteSuccess);
            }
        }
        catch (Exception ex)
        {
            uxMessage.DisplayException(ex);
        }

        OrderEditService orderEditService = new OrderEditService();

        orderEditService.RefreshOrderAmount(CurrentOrderID);

        uxFormView.DataBind();
        uxItemGrid.DataBind();
    }
Exemplo n.º 2
0
    private void RefreshOrderPricing()
    {
        OrderEditService orderEditService = new OrderEditService();

        orderEditService.RefreshOrderAmount(CurrentOrderID);
    }