Esempio n. 1
0
 public static IEnumerable <InventoryItem> GetItems() => new List <InventoryItem>
 {
     new InventoryItem
     {
         Id           = 1,
         InventoryId  = 1,
         Inventory    = Get().First(i => i.Id == 1),
         Name         = "Liatris spicata seeds",
         OriginId     = 2,
         Origin       = FakeOrigins.Get().Skip(1).First(),
         ItemType     = "Specimen",
         Quantity     = 25,
         Status       = "Available",
         Visibility   = Visibility.Public,
         CreatedBy    = Helpers.UserId,
         ModifiedBy   = null,
         DateAcquired = new DateTime(2020, 03, 31),
         DateCreated  = new DateTime(2020, 06, 15),
         DateModified = null,
         User         = FakeUsers.GetPublic()
     },
     new InventoryItem
     {
         Id           = 2,
         InventoryId  = 1,
         Inventory    = Get().First(i => i.Id == 1),
         Name         = "Liatris spicata plants",
         OriginId     = 2,
         Origin       = FakeOrigins.Get().Skip(1).First(),
         ItemType     = "Specimen",
         Quantity     = 3,
         Status       = "Available",
         Visibility   = Visibility.Contacts,
         CreatedBy    = Helpers.UserId,
         ModifiedBy   = null,
         DateAcquired = new DateTime(2020, 03, 31),
         DateCreated  = new DateTime(2020, 06, 15),
         DateModified = null,
         User         = FakeUsers.GetContact()
     },
     new InventoryItem
     {
         Id           = 3,
         InventoryId  = 1,
         Inventory    = Get().First(i => i.Id == 1),
         Name         = "Mushroom compost",
         OriginId     = 3,
         Origin       = FakeOrigins.Get().Skip(2).First(),
         ItemType     = "Supply",
         Quantity     = 1,
         Status       = "Wishlist",
         Visibility   = Visibility.Hidden,
         CreatedBy    = Helpers.UserId,
         ModifiedBy   = null,
         DateAcquired = null,
         DateCreated  = new DateTime(2020, 06, 15),
         DateModified = null,
         User         = FakeUsers.GetPublic()
     },
     new InventoryItem
     {
         Id           = 4,
         InventoryId  = 1,
         Inventory    = Get().First(i => i.Id == 1),
         Name         = "Morning glory seeds",
         OriginId     = 3,
         Origin       = FakeOrigins.Get().Skip(2).First(),
         ItemType     = "Specimen",
         Quantity     = 1,
         Status       = "Wishlist",
         Visibility   = Visibility.Inherit,
         CreatedBy    = Helpers.PrivateUserId,
         ModifiedBy   = null,
         DateAcquired = null,
         DateCreated  = new DateTime(2020, 06, 15),
         DateModified = null,
         User         = FakeUsers.GetPrivate()
     }
 };
Esempio n. 2
0
        public static IEnumerable <PlantInfo> Get()
        {
            var plantInfos = new List <PlantInfo>
            {
                new PlantInfo
                {
                    LifeformId       = 1,
                    Id               = 1,
                    OriginId         = 1,
                    Origin           = FakeOrigins.Get().First(),
                    TaxonId          = Taxon().Id,
                    Taxon            = Taxon(),
                    CommonName       = "Dense Blazing Star",
                    ScientificName   = "Liatris spicata",
                    MinimumBloomTime = 7,
                    MaximumBloomTime = 8,
                    MinimumHeight    = 1,
                    MaximumHeight    = 2,
                    HeightUnit       = "Feet",
                    MinimumSpread    = 0.75,
                    MaximumSpread    = 1.5,
                    SpreadUnit       = "Feet",
                    MinimumWater     = "Medium",
                    MaximumWater     = "Medium",
                    MinimumLight     = "FullShade",
                    MaximumLight     = "FullSun",
                    MinimumZone      = new Zone {
                        Id = 7, Name = "3"
                    },
                    MaximumZone = new Zone {
                        Id = 22, Name = "8"
                    },
                    StratificationStages = "[{\"Step\":\"1\",\"DayLength\":\"30\",\"StratificationType\":\"ColdMoist\"}]",
                    SoilTypes            = "[\"Loamy\",\"Rocky\",\"Clay\"]",
                    WildlifeEffects      = "[{\"Wildlife\":\"Bees\",\"Effect\":\"Food\"}]",
                    Notes = "Liatris spicata, the dense blazing star or prairie gay feather, is an herbaceous perennial flowering plant in the sunflower and daisy family " +
                            "Asteraceae. It is native to eastern North America where it grows in moist prairies and sedge meadows. The plants have tall spikes of purple flowers " +
                            "resembling bottle brushes or feathers that grow one to five feet tall. The species grows in hardiness zones 3 - 8, stretching from the Midwest " +
                            "to the East Coast, eastern and western Canada.",
                    Visibility     = Visibility.Contacts,
                    CreatedBy      = Helpers.UserId,
                    ModifiedBy     = Helpers.UserId,
                    DateCreated    = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateModified   = Helpers.Today.AddHours(1).AddMinutes(5),
                    User           = FakeUsers.GetContact(),
                    PlantLocations = FakePlantLocations.Get(),
                    Lifeform       = FakeLifeforms.Get().First()
                },
                new PlantInfo
                {
                    LifeformId       = 2,
                    Id               = 2,
                    OriginId         = 2,
                    Origin           = FakeOrigins.Get().Skip(1).First(),
                    TaxonId          = Taxon().Id,
                    Taxon            = Taxon(),
                    CommonName       = "White wild indigo",
                    ScientificName   = "Baptisia alba",
                    MinimumBloomTime = 4,
                    MaximumBloomTime = 5,
                    MinimumHeight    = 3,
                    MaximumHeight    = 5,
                    HeightUnit       = "Feet",
                    MinimumSpread    = 2,
                    MaximumSpread    = 2.5,
                    SpreadUnit       = "Feet",
                    MinimumWater     = "Dry",
                    MaximumWater     = "Medium",
                    MinimumLight     = "PartShade",
                    MaximumLight     = "FullSun",
                    MinimumZone      = new Zone {
                        Id = 13, Name = "5"
                    },
                    MaximumZone = new Zone {
                        Id = 22, Name = "8"
                    },
                    StratificationStages = "[{\"Step\":\"1\",\"DayLength\":\"1\",\"StratificationType\":\"AbrasionScarify\"},{\"Step\":\"2\",\"DayLength\":\"10\",\"StratificationType\":\"ColdMoist\"}]",
                    WildlifeEffects      = "[{\"Wildlife\":\"Butterflies\",\"Effect\":\"Host\"},{\"Wildlife\":\"Bees\",\"Effect\":\"Food\"}]",
                    Notes = "Baptisia alba, commonly called white wild indigo or white false indigo, is a herbaceous plant in the bean family Fabaceae. It is native from central and " +
                            "eastern North America. There are two varieties, Baptisia alba var. alba and Baptisia alba var. macrophylla.",
                    Visibility   = Visibility.Public,
                    CreatedBy    = Helpers.UserId,
                    ModifiedBy   = Helpers.UserId,
                    DateCreated  = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateModified = Helpers.Today.AddHours(1).AddMinutes(5),
                    User         = FakeUsers.GetPublic(),
                    Lifeform     = FakeLifeforms.Get().Skip(1).First()
                },
                new PlantInfo
                {
                    LifeformId       = 1,
                    Id               = 3,
                    OriginId         = 2,
                    Origin           = FakeOrigins.Get().Skip(2).First(),
                    TaxonId          = Taxon().Id,
                    Taxon            = Taxon(),
                    CommonName       = "Dense Blazing Star",
                    ScientificName   = "Liatris spicata",
                    MinimumBloomTime = 7,
                    MaximumBloomTime = 8,
                    MinimumHeight    = 1,
                    MaximumHeight    = 2,
                    HeightUnit       = "Feet",
                    MinimumSpread    = 0.75,
                    MaximumSpread    = 1.5,
                    SpreadUnit       = "Feet",
                    MinimumWater     = "Medium",
                    MaximumWater     = "Medium",
                    MinimumLight     = "PartSun",
                    MaximumLight     = "FullSun",
                    MinimumZone      = new Zone {
                        Id = 7, Name = "3"
                    },
                    MaximumZone = new Zone {
                        Id = 22, Name = "8"
                    },
                    StratificationStages = "[{\"Step\":\"1\",\"DayLength\":\"30\",\"StratificationType\":\"ColdMoist\"}]",
                    WildlifeEffects      = "[{\"Wildlife\":\"Birds\",\"Effect\":\"Food\"}]",
                    Notes = "Liatris spicata, the dense blazing star or prairie gay feather, is an herbaceous perennial flowering plant in the sunflower and daisy family " +
                            "Asteraceae. It is native to eastern North America where it grows in moist prairies and sedge meadows. The plants have tall spikes of purple flowers " +
                            "resembling bottle brushes or feathers that grow one to five feet tall. The species grows in hardiness zones 3 - 8, stretching from the Midwest " +
                            "to the East Coast, eastern and western Canada.",
                    Visibility   = Visibility.Inherit,
                    CreatedBy    = FakeUsers.GetPrivate().UserId,
                    ModifiedBy   = FakeUsers.GetPrivate().UserId,
                    DateCreated  = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateModified = Helpers.Today.AddHours(1).AddMinutes(5),
                    User         = FakeUsers.GetPrivate(),
                    Lifeform     = FakeLifeforms.Get().First()
                }
            };

            return(plantInfos);
        }
Esempio n. 3
0
 public static IEnumerable <Origin> Get() => new List <Origin>
 {
     new Origin
     {
         Id          = 1,
         Name        = "Plant Finder - Missouri Botanical Garden",
         Description = "Look up, view a photo and read about the over 7,500 plants which are growing or have been grown in the Kemper Center display " +
                       "gardens (plus selected additions) by scientific name, common name and/or selected plant characteristics.",
         Type          = "Website",
         Uri           = new Uri("http://www.missouribotanicalgarden.org/plantfinder/plantfindersearch.aspx"),
         Authors       = "fred",
         AltExternalId = "44",
         ExternalId    = "222",
         Location      = FakeLocations.Get().First(),
         Visibility    = Visibility.Contacts,
         CreatedBy     = FakeUsers.GetPublic().UserId,
         ModifiedBy    = FakeUsers.GetPublic().UserId,
         DateCreated   = Helpers.Today.AddMonths(-1).AddDays(-5),
         DateModified  = Helpers.Today.AddMonths(-1).AddDays(5),
         User          = FakeUsers.GetPublic()
     },
     new Origin
     {
         Id             = 2,
         ParentOriginId = 3,
         Type           = "Nursery",
         Name           = "Botany Yards",
         Description    = "",
         Authors        = "",
         AltExternalId  = "444",
         ExternalId     = "srtyhs",
         Location       = FakeLocations.Get().First(),
         Visibility     = Visibility.Public,
         CreatedBy      = FakeUsers.GetPublic().UserId,
         ModifiedBy     = null,
         DateCreated    = Helpers.Today.AddMonths(-1).AddDays(5),
         DateModified   = null,
         User           = FakeUsers.GetPublic()
     },
     new Origin
     {
         Id          = 3,
         Type        = "Event",
         Name        = "GNPS Symposium 2020",
         Description = "Our 25th annual Symposium is all about connections between native plants and the fauna that rely upon them. Inspired by the " +
                       "February book release of Nature’s Best Hope: A New Approach to Conservation that Starts in Your Yard from Doug Tallamy, we invite you to " +
                       "be among the first to hear his new message. Growing more native plants to sustain all of nature is more urgent than ever.",
         Uri           = new Uri("https://gnps.org/2020-georgia-native-plant-society-annual-symposium/"),
         Authors       = "linda",
         AltExternalId = "#$%#^",
         ExternalId    = "GGGGGGGGG",
         Location      = FakeLocations.Get().First(),
         Visibility    = Visibility.Hidden,
         CreatedBy     = FakeUsers.GetPublic().UserId,
         ModifiedBy    = FakeUsers.GetPublic().UserId,
         DateCreated   = Helpers.Today.AddMonths(-1).AddDays(-5),
         DateModified  = Helpers.Today.AddMonths(-1).AddDays(5),
         User          = FakeUsers.GetPublic()
     },
     new Origin
     {
         Id             = 4,
         ParentOriginId = 3,
         Type           = "Nursery",
         Name           = "Botany Yards",
         Description    = "",
         Authors        = "",
         AltExternalId  = "444",
         ExternalId     = "srtyhs",
         Location       = FakeLocations.Get().First(),
         Visibility     = Visibility.Inherit,
         CreatedBy      = FakeUsers.GetPrivate().UserId,
         ModifiedBy     = null,
         DateCreated    = Helpers.Today.AddMonths(-1).AddDays(5),
         DateModified   = null,
         User           = FakeUsers.GetPrivate()
     }
 };
Esempio n. 4
0
        public static IEnumerable <Activity> Get()
        {
            var activities = new List <Activity>
            {
                new Activity
                {
                    Id            = 1,
                    ActivityType  = "Stratification",
                    SpecimenId    = 1,
                    Specimen      = FakeSpecimens.Get().Where(s => s.Id == 1).First(),
                    Name          = "Liatris spicata Seeds Stratification",
                    Description   = "Stratify in fridge in woody mix",
                    Quantity      = 3,
                    AssignedTo    = Helpers.UserId,
                    Visibility    = Visibility.Public,
                    ModifiedBy    = Helpers.UserId,
                    CreatedBy     = Helpers.UserId,
                    DateScheduled = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateOccurred  = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateCreated   = Helpers.Today,
                    DateModified  = Helpers.Today.AddHours(1).AddMinutes(5),
                    User          = FakeUsers.GetPublic()
                },
                new Activity
                {
                    Id            = 2,
                    ActivityType  = "Germination",
                    SpecimenId    = 1,
                    Specimen      = FakeSpecimens.Get().Where(s => s.Id == 1).First(),
                    Name          = "Germinate: Liatris spicata ",
                    Description   = "Put outside in greenhouse",
                    Quantity      = 2,
                    AssignedTo    = Helpers.UserId,
                    Visibility    = Visibility.Contacts,
                    ModifiedBy    = Helpers.UserId,
                    CreatedBy     = Helpers.UserId,
                    DateScheduled = null,
                    DateOccurred  = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateCreated   = Helpers.Today,
                    DateModified  = Helpers.Today.AddHours(1).AddMinutes(5),
                    User          = FakeUsers.GetContact()
                },
                new Activity
                {
                    Id                 = 3,
                    ActivityType       = "Custom",
                    CustomActivityType = "Divide",
                    SpecimenId         = 10,
                    Specimen           = FakeSpecimens.Get().Where(s => s.Id == 1).First(),
                    Name               = "Divide: Liatris spicata",
                    Description        = "Split about 15 seedlings into 2\" containers with woody mix",
                    Quantity           = 3,
                    AssignedTo         = Helpers.UserId,
                    Visibility         = Visibility.Inherit,
                    ModifiedBy         = null,
                    CreatedBy          = Helpers.UserId,
                    DateScheduled      = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateOccurred       = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateCreated        = Helpers.Today,
                    DateModified       = null,
                    User               = FakeUsers.GetPublic()
                }
                ,
                new Activity
                {
                    Id                 = 4,
                    ActivityType       = "Custom",
                    CustomActivityType = "Divide",
                    SpecimenId         = 10,
                    Specimen           = FakeSpecimens.Get().Where(s => s.Id == 4).First(),
                    Name               = "Divide: Liatris spicata",
                    Description        = "Split about 15 seedlings into 2\" containers with woody mix",
                    Quantity           = 3,
                    AssignedTo         = FakeUsers.GetPrivate().UserId,
                    Visibility         = Visibility.Inherit,
                    ModifiedBy         = null,
                    CreatedBy          = FakeUsers.GetPrivate().UserId,
                    DateScheduled      = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateOccurred       = Helpers.Today.AddDays(Helpers.GetRandom()),
                    DateCreated        = Helpers.Today,
                    DateModified       = null,
                    User               = FakeUsers.GetPrivate()
                }
            };

            return(activities);
        }