Example #1
0
 private void Init()
 {
     _customer    = new CustomerService();
     _sale        = new SaleService();
     _saleDetail  = new SaleDetailService();
     _product     = new ProductService();
     _paymentMode = new PaymentModeService();
     _tax         = new TaxService();
     _logger      = new ErrorLogService();
 }
Example #2
0
 private void Init()
 {
     _customer    = new CustomerService();
     _sale        = new SaleService();
     _saleDetail  = new SaleDetailService();
     _product     = new ProductService();
     _paymentMode = new PaymentModeService();
     _tax         = new TaxService();
     _company     = new GenericService <Company>().GetAll().FirstOrDefault();
     _logger      = new ErrorLogService();
 }
Example #3
0
        public PaymentModeController(IPaymentModeService PaymentModeService, IDocumentTypeService DocumentTypeService, IPaymentModeLedgerAccountService PaymentModeLedgerAccountService, IExceptionHandler exec,
                                     ILogger log, IModificationCheck modificationCheck, IDocumentValidation DocValidation)
        {
            _PaymentModeService = PaymentModeService;
            _PaymentModeLedgerAccountService = PaymentModeLedgerAccountService;
            _DocumentTypeService             = DocumentTypeService;
            _exception          = exec;
            _documentValidation = DocValidation;
            _logger             = log;
            _modificationCheck  = modificationCheck;

            UserRoles            = (List <string>)System.Web.HttpContext.Current.Session["Roles"];
            logVm.SessionId      = 0;
            logVm.ControllerName = System.Web.HttpContext.Current.Request.RequestContext.RouteData.GetRequiredString("controller");
            logVm.ActionName     = System.Web.HttpContext.Current.Request.RequestContext.RouteData.GetRequiredString("action");
            logVm.User           = System.Web.HttpContext.Current.Request.RequestContext.HttpContext.User.Identity.Name;
        }
Example #4
0
        private void Init()
        {
            _customer    = new CustomerService();
            _sale        = new SaleService();
            _saleDetail  = new SaleDetailService();
            _product     = new ProductService();
            _paymentMode = new PaymentModeService();
            _tax         = new TaxService();
            company      = new GenericService <Company>().GetAll().FirstOrDefault();
            _logger      = new ErrorLogService();

            SuscribeToEvent();

            btnAddRow.Enabled    = false;
            btnRemoveRow.Enabled = false;
            btnDone.Enabled      = false;
            btnCancel.Enabled    = false;
            btnSave.Enabled      = false;
        }
 public PaymentModesController(IPaymentModeService PaymentModeService)
  { _PaymentModeService =  PaymentModeService;  }