Example #1
0
 public static MvcHtmlString CategoryIconTiny(this HtmlHelper htmlHelper, Category category, object htmlAttributes = null)
 {
     return htmlHelper.Image(UrlToCategoryIconTiny(category.Id), 18, 18, category.Name, htmlAttributes);
 }
Example #2
0
        private void GenerateCategoriesStructure()
        {
            //law and taxes
            var lawAndTaxes = new Category
            {
                Name = "Prawo i podatki",
                Description = "Kategoria związana z zagadnieniami księgowości, prawa karnego, podatkowego, patentowego, autorskiego itp. oraz z zagadnieniami podatków.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 1
            };
            AddPrestigePriceSet(lawAndTaxes.Prices);
            AddLawAndTaxesAttributesSet(lawAndTaxes.Attributes);
            Repository.Category.Add(lawAndTaxes);

            //business and finance
            var businessAndFinance = new Category
            {
                Name = "Biznes i finanse",
                Description = "Inwestycje, kredyty, ubezpieczenia, własna firma oraz inne zagadnienia związane  z biznesem i finansami.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 2
            };
            AddPrestigePriceSet(businessAndFinance.Prices);
            AddBusinessAndFinanceAtrributesSet(businessAndFinance.Attributes);
            Repository.Category.Add(businessAndFinance);

            //animals and veterninary
            var animalsAndVeterninary = new Category
            {
                Name = "Zwierzęta i weterynaria",
                Description = "Psy, koty, rybki lub inne zwierzaki. Pielęgnacja, żywienie oraz choroby zwierzęce.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 7
            };
            AddPrestigePriceSet(animalsAndVeterninary.Prices);
            AddAnimalsAndVeterinaryAtrributesSet(animalsAndVeterninary.Attributes);
            Repository.Category.Add(animalsAndVeterninary);

            //travels
            var travels = new Category
            {
                Name = "Podróże",
                Description = "Ciepłe kraje, wysokie Himalaje oraz wszystkie inne zagadnienia związane z podróżami.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 8
            };
            AddStandardPriceSet(travels.Prices);
            AddTravelsAtrributesSet(travels.Attributes);
            Repository.Category.Add(travels);

            //entertainment and recreation
            var entertainmentAndRecreation = new Category
            {
                Name = "Rozrywka i rekreacja",
                Description = "Filmy, gry komputerowe, sport, muzyka oraz wszystkie inne zagadnienia związane z rozrywką i rekreacją.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 9
            };
            AddLowPriceSet(entertainmentAndRecreation.Prices);
            AddEntertainmentAndRecreationAtrributesSet(entertainmentAndRecreation.Attributes);
            Repository.Category.Add(entertainmentAndRecreation);

            //cookery
            var cookery = new Category
            {
                Name = "Sztuka kulinarna",
                Description = "Kuchnie świata, przepisy oraz diety.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 10
            };
            AddLowPriceSet(cookery.Prices);
            AddCookeryAtrributesSet(cookery.Attributes);
            Repository.Category.Add(cookery);

            //children
            var children = new Category
            {
                Name = "Dzieci",
                Description = "Wychowanie oraz rozwój dzieci.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 11
            };
            AddStandardPriceSet(children.Prices);
            AddChildrenAtrributesSet(children.Attributes);
            Repository.Category.Add(children);

            //events and ceremnonies
            var eventsAndCeremonies = new Category
            {
                Name = "Wydarzenia i ceremonie",
                Description = "Wesela, pogrzeby, urodziny oraz inne wydarzenia. Pytania związane z organizacją i nie tylko.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 12
            };
            AddLowPriceSet(eventsAndCeremonies.Prices);
            AddEventsAndCeremoniesAtrributesSet(eventsAndCeremonies.Attributes);
            Repository.Category.Add(eventsAndCeremonies);
            
            //about me
            var aboutMe = new Category
            {
                Name = "Ja i o mnie",
                Description = "Twoja własna osoba, charakter, wygląd lub inne zagadnienia związane z twoją personą.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 13
            };
            AddStandardPriceSet(aboutMe.Prices);
            AddAboutMeAtrributesSet(aboutMe.Attributes);
            Repository.Category.Add(aboutMe);

            //love and relations
            var loveAndRelations = new Category
            {
                Name = "Miłość i relacje",
                Description = "Relacje międzyludzkie, problemy miłosne.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 3
            };
            AddStandardPriceSet(loveAndRelations.Prices);
            AddLoveAndRelationsAtrributesSet(loveAndRelations.Attributes);
            Repository.Category.Add(loveAndRelations);

            //science
            var science = new Category
            {
                Name = "Nauka",
                Description = "Kategoria związana z naukami ścisłymi, humanistycznymi, przyrodniczymi, a także z językami obcymi.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 4
            };
            AddLowPriceSet(science.Prices);
            AddScienceAtrributesSet(science.Attributes);
            Repository.Category.Add(science);

            //internet and computers
            var internetAndComputers = new Category
            {
                Name = "Komputery i internet",
                Description = "Naprawa komputerów, wybór sprzętu i oprogramowania.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 5
            };
            AddLowPriceSet(internetAndComputers.Prices);
            AddInternetAndComputersAtrributesSet(internetAndComputers.Attributes);
            Repository.Category.Add(internetAndComputers);

            //house
            var house = new Category
            {
                Name = "Dom",
                Description = "Projektowanie, budowa, remont domu. Pytania związane z nieruchomościami, wystrojem wnętrz oraz innymi zagadnieniami związanymi z domem.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 14,
            };
            AddStandardPriceSet(house.Prices);
            AddHouseAtrributesSet(house.Attributes);
            Repository.Category.Add(house);

            //equipment repair
            var equipmentRepair = new Category
            {
                Name = "Sprzęt i naprawa",
                Description = "Naprawa oraz poprawne użytkowanie sprzętu.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 15
            };
            AddStandardPriceSet(equipmentRepair.Prices);
            AddEquipmentRepairAtrributesSet(equipmentRepair.Attributes);
            Repository.Category.Add(equipmentRepair);

            //garden
            var garden = new Category
            {
                Name = "Ogród",
                Description = "Kwiaty i drzewa. Projektowanie oraz pielęgnacja ogrodów.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 16
            };
            AddStandardPriceSet(garden.Prices);
            AddGardenAtrributesSet(garden.Attributes);
            Repository.Category.Add(garden);

            //art and culture
            var artAndCulture = new Category
            {
                Name = "Sztuka i kultura",
                Description = "Sławne obrazy, tradycje azjatycje oraz wszystkie inne zagadnienia związane z kulturą i sztuką.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 17
            };
            AddLowPriceSet(artAndCulture.Prices);
            AddArtAndCultureAtrributesSet(artAndCulture.Attributes);
            Repository.Category.Add(artAndCulture);

            //health and medicine
            var healthAndMedicine = new Category
            {
                Name = "Zdrowie i medycyna",
                Description = "Zdrowie, medycyna oraz choroby",
                LongDescription = "MISSING_LONG_DESC",
                Order = 6
            };
            AddPrestigePriceSet(healthAndMedicine.Prices);
            AddHealthAndMedicineAtrributesSet(healthAndMedicine.Attributes);
            Repository.Category.Add(healthAndMedicine);

            //automotive
            var automotive = new Category
            {
                Name = "Motoryzacja",
                Description = "Samochody, motocykle, ciężarówki oraz inne pojazdy. Naprawa, konserwacja, kupno oraz sprzedaż.",
                LongDescription = "MISSING_LONG_DESC",
                Order = 18
            };
            AddStandardPriceSet(automotive.Prices);
            AddAutomotiveAtrributesSet(automotive.Attributes);
            Repository.Category.Add(automotive);
        }