public ProductDetailsVc(IProduct prodRepository, ISubCategory subCatRepository, IAttributeGroup attrGroupRepository, IOneAttribute oneAttrRepository) { prodRepo = prodRepository; subCatRepo = subCatRepository; attrGroupRepo = attrGroupRepository; OneAttributeRepo = oneAttrRepository; }
public SubCategoryController(ICategory Categoryrepo, ICoreBase coreRepo, ISubCategory SubCategoryrepo, IWebHostEnvironment webHostEnvironment) { _coreRepo = coreRepo; _SubCategoryrepo = SubCategoryrepo; _webHostEnvironment = webHostEnvironment; _Categoryrepo = Categoryrepo; }
public SubCategoryStat(ISubCategory subcat) { Name = subcat.Name; this.subcat = subcat; optionStats = new List <PercentualStat>(); localPlayersStats = new Dictionary <string, List <PlayersStats> >(); visitorPlayersStats = new Dictionary <string, List <PlayersStats> >(); }
public ProductController(IProduct prodRepository, ISubCategory subCatRepository, IAttributeGroup attrGrRepository, IProductOneAttributeValues prodOneattrValRepository, IPredefinedAttrList predefAttrListRepository, IPredefinedAttributeListOptions predefAttrListOptionsRepository) { prodRepo = prodRepository; subCatRepo = subCatRepository; attrGrRepo = attrGrRepository; prodOneAttrValRepo = prodOneattrValRepository; predefAttrListRepo = predefAttrListRepository; predefAttrListOptionsRepo = predefAttrListOptionsRepository; }
public void FilterSubCategory(Category cat, ISubCategory subcat, string option, bool filtered) { SubCategoryTags tsub = categoriesFilter[cat].Find(s => s.SubCategory == subcat); if (filtered) { tsub.Add(option); } else { tsub.Remove(option); } }
public UnitOfWork(DbContext context) { this.context = context; category = new CategoryRepo(context); chair = new ChairRepo(context); consumer = new ConsumerRepo(context); customer = new CustomerRepo(context); theater = new HomeTheaterRepo(context); product = new ProductRepo(context); subCategory = new SubCategoryRepo(context); table = new TableRepo(context); tv = new TVRepo(context); user = new UserRepo(context); }
void MigrateCat_2_0(Categories cats) { /* * Migrate templates: in this version game periods are a common * tag for all sub-categories. We need to remove the old Period * string tag from all categories and add a GamePeriod string list * with the same values */ List <string> periods = null; Log.Information("Migrating categories template " + cats.Name + " to 2.1"); foreach (Category cat in cats) { ISubCategory toDelete = null; foreach (ISubCategory subcat in cat.SubCategories) { TagSubCategory tagSubcat = subcat as TagSubCategory; if (tagSubcat == null) { continue; } if (subcat.Name == Catalog.GetString("Period")) { if (periods == null) { periods = new List <string>(); foreach (string tag in tagSubcat) { periods.Add(tag); } } toDelete = subcat; Log.Debug("Migrated Period for category " + cat.Name); break; } } if (toDelete != null) { cat.SubCategories.Remove(toDelete); } } cats.Version = new Version(2, 1); templates.CategoriesTemplateProvider.Update(cats); Log.Information("Migration to 2.1 done"); }
protected override bool OnButtonPressEvent(EventButton evnt) { if ((evnt.Type == EventType.ButtonPress) && (evnt.Button == 3)) { TreePath path; GetPathAtPos((int)evnt.X, (int)evnt.Y, out path); if (path != null) { Model.GetIter(out selectedIter, path); selectedSubcat = (ISubCategory)Model.GetValue(selectedIter, 0); edit.Sensitive = selectedSubcat is TagSubCategory; menu.Popup(); } } return(base.OnButtonPressEvent(evnt)); }
public void SetUp() { subCategoryList = new List <SubCategory> { new SubCategory(23, "Test1", 1), new SubCategory(24, "Test2", 1), new SubCategory(25, "Test3", 1) }; subcatListAdmin = new List <SubCategoryAdmin> { new SubCategoryAdmin(26, "Test1", 1, "Test1"), new SubCategoryAdmin(27, "Test2", 1, "Test2"), new SubCategoryAdmin(28, "Test3", 1, "Test3") }; validation = Substitute.For <ISubCategory>(); subCategoryController = new SubCategoryController(validation); }
protected override void RenderColumn(TreeViewColumn column, CellRenderer cell, TreeModel model, TreeIter iter) { object obj = store.GetValue(iter, 0); string text = ""; if (obj is Category) { Category cat = obj as Category; text = cat.Name; } else if (obj is ISubCategory) { ISubCategory subCat = obj as ISubCategory; text = subCat.Name; } else if (obj is StringObject) { text = (obj as StringObject).Value; } (cell as CellRendererText).Text = text; }
public void RemoveBySubcategory(ISubCategory subcat) { tagsList.RemoveAll(t => t.SubCategory == subcat); }
public SubCategoryApiController(ICoreBase repoCore, ISubCategory SubCategory) { _repoCore = repoCore; _SubCategory = SubCategory; }
public SubCategoriesController(ISubCategory repo, IMapper mapper) { _repo = repo; _mapper = mapper; }
public SubCategoryController(ISubCategory subCategoryService) { _subCategoryService = subCategoryService; }
public SubCategoryController(ISubCategory blsubcategory) { _blsubcategory = blsubcategory; }
public AttributeGroupController(IAttributeGroup attrGroupRepository, ISubCategory subCatRepository, IOneAttribute oneAttrRepository) { attrGroupRepo = attrGroupRepository; subCatRepo = subCatRepository; oneAttrRepo = oneAttrRepository; }
public SubCategoryController(ISubCategory subCategory, IMapper mapper) { _subCategoryServices = subCategory; _mapper = mapper; }
// GET: SubCategory public SubCategoryController(ISubCategory subCategory, ICategory category) { _db = subCategory; Category = category; }
protected virtual void OnSubcategorySelected(ISubCategory subcat) { EditSubCategoryTags((TagSubCategory)subcat, false); }
public List <T> GetTags(ISubCategory subCategory) { return((from tag in tagsList where tag.SubCategory.Equals(subCategory) select tag).ToList()); }
public SubCategoryController(ILogger <SubCategoryController> logger, ISubCategory subSubCategoryService) { _logger = logger; _subSubCategoryService = subSubCategoryService; }
public SubCategoryCrudVc(ISubCategory subCatRepository) { subCatRepo = subCatRepository; }
public SubCategoryController(ISubCategory subCatRepository, ICategory catRepository, IAttributeGroup attrGroupRepository) { subCatrepo = subCatRepository; catRepo = catRepository; attrGroupRepo = attrGroupRepository; }
public SubCategoryController() { repo = new SubCategoryRepo(); }
protected override bool OnButtonPressEvent(EventButton evnt) { if((evnt.Type == EventType.ButtonPress) && (evnt.Button == 3)) { TreePath path; GetPathAtPos((int)evnt.X,(int)evnt.Y,out path); if(path!=null) { Model.GetIter(out selectedIter,path); selectedSubcat = (ISubCategory) Model.GetValue(selectedIter, 0); edit.Sensitive = selectedSubcat is TagSubCategory; menu.Popup(); } } return base.OnButtonPressEvent(evnt); }