Ejemplo n.º 1
0
        public ActionResult AddMonthlyImportExceptionRule(MonthlyImportFundExceptionRule model)
        {
            if (ModelState.IsValid)
            {
                _monthlyImportExceptionRuleService.Add(model);

                Success($"<strong>{model.OriginalFundId} - {model.NewFundId}</strong> was successfully saved.");
                return(RedirectToAction("JournalVoucherReport"));
            }
            return(View(model));
        }
Ejemplo n.º 2
0
 public ActionResult EditMonthlyImportExceptionRule(MonthlyImportFundExceptionRule model)
 {
     if (ModelState.IsValid)
     {
         var result = _monthlyImportExceptionRuleService.Get(model.Id);
         if (result == null)
         {
             return(HttpNotFound());
         }
         result.NewFundId      = model.NewFundId;
         result.OriginalFundId = model.OriginalFundId;
         result = _monthlyImportExceptionRuleService.Update(result);
         if (result == null)
         {
             return(HttpNotFound());
         }
         return(RedirectToAction("JournalVoucherReport"));
     }
     ModelState.AddModelError("", "An error occurred.");
     return(View());
 }
Ejemplo n.º 3
0
 public void Add(MonthlyImportFundExceptionRule entity)
 {
     _monthlyImportExceptionRuleRepository.Add(entity);
     _uow.Commit();
 }
Ejemplo n.º 4
0
 public MonthlyImportFundExceptionRule Update(MonthlyImportFundExceptionRule monthlyImportFundExceptionRule)
 {
     _monthlyImportExceptionRuleRepository.Update(monthlyImportFundExceptionRule);
     _uow.Commit();
     return(monthlyImportFundExceptionRule);
 }
Ejemplo n.º 5
0
        public ActionResult AddMonthlyImportExceptionRule()
        {
            var model = new MonthlyImportFundExceptionRule();

            return(View(model));
        }