예제 #1
0
 public ActionResult Create(F_BankDTO bank)
 {
     if (ModelState.IsValid)
     {
         bank.CreatedBy = bank.ModifiedBy = this.User.Id;
         this._IF_BankService.Create(bank);
     }
     return(RedirectToAction("index"));
 }
예제 #2
0
 public ActionResult Edit(F_BankDTO bank)
 {
     if (ModelState.IsValid)
     {
         bank.ModifiedBy = this.User.Id;
         this._IF_BankService.Update(new List <F_BankDTO> {
             bank
         });
     }
     return(RedirectToAction("index"));
 }
예제 #3
0
        public F_BankDTO Create(F_BankDTO dto)
        {
            int maxOrder = this._IF_BankRepository.Data.Max(item => item.Order);

            dto.Order = maxOrder + 1;
            var user = base.F_Create <F_BankDTO, F_Bank>(dto
                                                         , _IF_BankRepository
                                                         , dtoAction => { });

            return(user);
        }