예제 #1
0
 public static Branch ToEntity(this BranchModel model, Branch destination)
 {
     return Mapper.Map(model, destination);
 }
예제 #2
0
 public void UpdateBranch(Branch branch)
 {
     _branchRepository.Update(branch);
 }
예제 #3
0
        protected void UpdateLocales(Branch branch, BranchModel model)
        {
            foreach (var localized in model.Locales)
            {
                _localizedEntityService.SaveLocalizedValue(branch,
                                                               x => x.Title,
                                                               localized.Title,
                                                               localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                          x => x.Short,
                                                          localized.MetaKeywords,
                                                          localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                          x => x.Full,
                                                          localized.MetaKeywords,
                                                          localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                           x => x.MetaKeywords,
                                                           localized.MetaKeywords,
                                                           localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                           x => x.MetaDescription,
                                                           localized.MetaDescription,
                                                           localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                           x => x.MetaTitle,
                                                           localized.MetaTitle,
                                                           localized.LanguageId);

                _localizedEntityService.SaveLocalizedValue(branch,
                                                           x => x.SeName,
                                                           localized.SeName,
                                                           localized.LanguageId);
            }
        }
예제 #4
0
 public void InsertBranch(Branch branch)
 {
     _branchRepository.Insert(branch);
 }