Exemplo n.º 1
0
        private void btnSaveConfiguration_Click(object sender, EventArgs e)
        {
            try
            {
                if (MODEL == null)
                {
                    MODEL = new SalesQuotationBOQConfigurationModel();
                }
                MODEL.MATERIAL_SUPPLY_ADD_ON_CHARGES        = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboMaterialAddOnCharges.SelectedItem).ID;
                MODEL.MATERIAL_SUPPLY_PROFIT_MARGIN_CHARGES = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboMaterialProfitMargin.SelectedItem).ID;
                MODEL.MATERIAL_SUPPLY_DISCOUNT_CHARGES      = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboMaterialDiscounts.SelectedItem).ID;
                MODEL.MATERIAL_SUPPLY_GST_CHARGES           = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboMaterialGST.SelectedItem).ID;

                MODEL.INSTALLATION_ADD_ON_CHARGES        = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboInstallationAddOnCharges.SelectedItem).ID;
                MODEL.INSTALLATION_PROFIT_MARGIN_CHARGES = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboInstallationProfitMargin.SelectedItem).ID;
                MODEL.INSTALLATION_DISCOUNT_CHARGES      = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboInstallationDiscount.SelectedItem).ID;
                MODEL.INSTALLATION_GST_CHARGES           = (SALES_QUOTATION_BOQ_CHARGES_TYPE)((SelectListItem)cboInstallationGST.SelectedItem).ID;
            }
            catch (Exception ex)
            {
                string errMessage = ex.Message;
                if (ex.InnerException != null)
                {
                    errMessage += string.Format("\n{0}", ex.InnerException.Message);
                }
                MessageBox.Show(errMessage, "ControlSalesQuotationBOQConfiguration::btnSaveConfiguration_Click", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
Exemplo n.º 2
0
 public ControlSalesQuotationBOQConfiguration(SalesQuotationBOQConfigurationModel configuration)
 {
     InitializeComponent();
     this.MODEL = configuration;
 }