コード例 #1
0
        public void RemoveByModuleThemeLayoutZoneWidget(string moduleName, string theme, string layout, string zone, string widget)
        {
            var entity = _entityRepository.Query().FirstOrDefault(
                x => x.ModuleName == moduleName &&
                x.ThemeId == theme &&
                x.LayoutName == layout &&
                x.Zone == zone &&
                x.WidgetId == widget
                );

            if (entity != null)
            {
                _entityRepository.Remove(entity);
                _entityRepository.SaveChange();
            }
        }
コード例 #2
0
 public NccWebSiteWidget Save(NccWebSiteWidget entity)
 {
     _entityRepository.Add(entity);
     _entityRepository.SaveChange();
     return(entity);
 }