Example #1
0
 public ServiceForm()
 {
     InitializeComponent(); if (DesignMode || (Site != null && Site.DesignMode))
     {
         return;
     }
     CntrlCN = DBControllersFactory.Contract();
     CntrlCG = DBControllersFactory.BillingCategory();
     CntrlCU = DBControllersFactory.Currency();
     CntrlVT = DBControllersFactory.VAT();
     //template
     Mapper["Id"]        = txtId;
     Mapper["CreatedBy"] = txtCreatedBy;
     Mapper["CreatedOn"] = txtCreatedOn;
     Mapper["UpdatedBy"] = txtUpdatedBy;
     Mapper["UpdatedOn"] = txtUpdatedOn;
     Mapper["ReadOnly"]  = chkReadOnly;
     //data
     Mapper["BillingCategoryId"] = txtBillingCategoryId;
     Mapper["ContractId"]        = txtContractId;
     Mapper["CurrencyId"]        = txtCurrencyId;
     Mapper["Price"]             = txtPrice;
     Mapper["Expired"]           = chkExpired;
     Mapper["EffectiveFromDate"] = txtEffectiveFromDate;
     Mapper["VATId"]             = txtVATId;
     //actions
     SaveButton   = btnSave;
     DeleteButton = btnDelete;
     NewButton    = btnNew;
     //pick lists
     PickList[btnPLContract] = txtContractId;
     PickList[btnPLCurrency] = txtCurrencyId;
     PickList[btnPLService]  = txtId;
     PickList[btnPLVAT]      = txtVATId;
 }