Пример #1
0
 public void Update(Guid footerId, Footer newFooterData)
 {
     if (FooterRepository.Exists(footerId))
     {
         Footer footerToUpdate = FooterRepository.GetById(footerId);
         if (newFooterData.StyleClass != null && !StyleClassRepository.Exists(newFooterData.StyleClass.Name))
         {
             newFooterData.StyleClass = null;
         }
         footerToUpdate.StyleClass = newFooterData.StyleClass;
         FooterRepository.Update(footerToUpdate);
     }
     else
     {
         throw new MissingFooterException("The footer is not in the database.");
     }
 }
Пример #2
0
 public bool PutProductType(FooterDTO item)
 {
     return(footerRepository.Update(item));
 }