コード例 #1
0
        private void GenerateExpertOpinions()
        {
            var categories = Repository.Category.All();
            var category1 = categories.First();
            var category2 = categories.Last();

            var expertOpinion = new Opinion
                                    {
                                        Name = "dr Lubicz",
                                        OpinionContent = "Zarabiam hajsu jak lodu i jeszcze więcej.",
                                        AddressCity = "Warszawa",
                                        OpinionMark = OpinionMark.Positive,
                                        IsGeneral = true,
                                        AuthorType = AuthorType.Expert
                                    };
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "dr Zosia",
                                    OpinionContent = "Kobieta jak ja, niezależna i obsceniczna może się tu realizować.",
                                    AddressCity = "Leśna Góra",
                                    OpinionMark = OpinionMark.Positive,
                                    IsGeneral = true,
                                    AuthorType = AuthorType.Expert
                                };
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "prof. Miodek",
                                    OpinionContent = "Zero poprawności językowej ci pytający mają, co za rzeźnia...",
                                    AddressCity = "Charków",
                                    OpinionMark = OpinionMark.Negative,
                                    IsGeneral = true,
                                    AuthorType = AuthorType.Expert
                                };
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "WWO",
                                    OpinionContent = "Każdy ponad każdym, innego traktuje jakby był niczym, wszyscy najmądrzejsi...",
                                    AddressCity = "Poznań",
                                    OpinionMark = OpinionMark.Negative,
                                    IsGeneral = true,
                                    AuthorType = AuthorType.Expert
                                };
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "Shakira",
                                    OpinionContent = "Waka waka e e e, caminamina he-e he",
                                    AddressCity = "Kongo",
                                    OpinionMark = OpinionMark.Positive,
                                    IsGeneral = true,
                                    AuthorType = AuthorType.Expert
                                };
            expertOpinion.Categories.Add(category1);
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "Franciszek Smuda",
                                    OpinionContent = "Nasza reprezentacja reprezentacja, przegrała choć była dobra dobra.",
                                    AddressCity = "Łódź",
                                    OpinionMark = OpinionMark.Negative,
                                    IsGeneral = false,
                                    AuthorType = AuthorType.Expert
                                };

            expertOpinion.Categories.Add(category1);
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "Pani Ania",
                                    OpinionContent = "Lubię krzyżówki, rebusy i szarady, system jest jak wszystkie trzy w jednym.",
                                    AddressCity = "Półtusk",
                                    OpinionMark = OpinionMark.Positive,
                                    IsGeneral = false,
                                    AuthorType = AuthorType.Expert
                                };
            expertOpinion.Categories.Add(category1);
            expertOpinion.Categories.Add(category2);
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "Krzysztof Ibisz",
                                    OpinionContent = "Dzięki systemowi jestem im starszy tym młodszy - kochani.",
                                    AddressCity = "Warszawa",
                                    OpinionMark = OpinionMark.Positive,
                                    IsGeneral = false,
                                    AuthorType = AuthorType.Expert
                                };
            expertOpinion.Categories.Add(category2);
            Repository.Opinion.Add(expertOpinion);

            expertOpinion = new Opinion
                                {
                                    Name = "Wojciech Jaruzelski",
                                    OpinionContent = "Towarzysze, gdybyśmy mieli taki system w stanie wojennym, nic by nie było problemem.",
                                    AddressCity = "Zakład Karny w Radzionkowie",
                                    OpinionMark = OpinionMark.Negative,
                                    IsGeneral = false,
                                    AuthorType = AuthorType.Expert
                                };
            expertOpinion.Categories.Add(category2);
            Repository.Opinion.Add(expertOpinion);
        }
コード例 #2
0
        private void GenerateUserOpinions()
        {
            var categories = Repository.Category.All();
            var category1 = categories.First();
            var category2 = categories.Last();

            var userOpinion = new Opinion
                                  {
                                      Name = "Zdziś",
                                      OpinionContent = "Takie to kolorowe jakieś srakieś.",
                                      AddressCity = "zapiździów wielki",
                                      OpinionMark = OpinionMark.Negative,
                                      IsGeneral = true,
                                      AuthorType = AuthorType.User
                                  };
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "Marian",
                                  OpinionContent = "Jo to bym dodoł kolorów tu.",
                                  AddressCity = "zapiździów mniejszy",
                                  OpinionMark = OpinionMark.Negative,
                                  IsGeneral = true,
                                  AuthorType = AuthorType.User
                              };
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "debil jakiś",
                                  OpinionContent = "Jakie to fajne.",
                                  AddressCity = "nju jork",
                                  OpinionMark = OpinionMark.Positive,
                                  IsGeneral = true,
                                  AuthorType = AuthorType.User
                              };
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "brzęczyszczykiewicz",
                                  OpinionContent = "rzeżuchą jedzie na sto metrów.",
                                  AddressCity = "powiat łękołody",
                                  OpinionMark = OpinionMark.Positive,
                                  IsGeneral = true,
                                  AuthorType = AuthorType.User
                              };
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "no-name-dude",
                                  OpinionContent = "blaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.",
                                  AddressCity = "wawa",
                                  OpinionMark = OpinionMark.Positive,
                                  IsGeneral = true,
                                  AuthorType = AuthorType.User
                              };
            userOpinion.Categories.Add(category1);
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "janusz",
                                  OpinionContent = "totalna kaszana, ściema jak się patrzy",
                                  AddressCity = "królówka",
                                  OpinionMark = OpinionMark.Negative,
                                  IsGeneral = false,
                                  AuthorType = AuthorType.User
                              };

            userOpinion.Categories.Add(category1);
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "zbyszek",
                                  OpinionContent = "poszło gładko, jak po maśle z wazeliną",
                                  AddressCity = "ciechomin",
                                  OpinionMark = OpinionMark.Positive,
                                  IsGeneral = false,
                                  AuthorType = AuthorType.User
                              };
            userOpinion.Categories.Add(category1);
            userOpinion.Categories.Add(category2);
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "Tom",
                                  OpinionContent = "rozstanie było ciężkie, pomogliście mi się podnieść",
                                  AddressCity = "LA",
                                  OpinionMark = OpinionMark.Positive,
                                  IsGeneral = false,
                                  AuthorType = AuthorType.User
                              };
            userOpinion.Categories.Add(category2);
            Repository.Opinion.Add(userOpinion);

            userOpinion = new Opinion
                              {
                                  Name = "Katie",
                                  OpinionContent = "wróć do mnie - tomek!",
                                  AddressCity = "LA",
                                  OpinionMark = OpinionMark.Negative,
                                  IsGeneral = false,
                                  AuthorType = AuthorType.User
                              };
            userOpinion.Categories.Add(category2);
            Repository.Opinion.Add(userOpinion);
        }