Ejemplo n.º 1
0
        public Location(Guid siteId,
                        string name,
                        string description,
                        bool active
                        )
        {
            this.Id                 = Guid.NewGuid();
            this.SiteId             = siteId;
            this.Name               = name;
            this.Description        = description;
            this.Active             = active;
            this.Image              = null;
            this.ContactInformation = ContactInformation.Empty();
            this.Address            = Address.Empty();
            this.Geolocation        = Geolocation.Empty();

            this.AdditionalLocationImages = new ObservableCollection <LocationImage>();


            //ApplyChange(new LocationCreatedEvent(
            //         this.Id,
            //         siteId,
            //         name,
            //         description,
            //         contactInformation.ContactName,
            //         contactInformation.EmailAddress,
            //         contactInformation.PrimaryTelephone,
            //         contactInformation.SecondaryTelephone
            //     )
            //);
        }
Ejemplo n.º 2
0
        public Site(Guid tenantId,
                    string siteName,
                    string siteDescription,
                    bool active
                    )
        {
            this.TenantId           = tenantId;
            this.Id                 = Guid.NewGuid();
            this.Name               = siteName;
            this.Description        = siteDescription;
            this.Active             = active;
            this.ContactInformation = ContactInformation.Empty();
            this.Locations          = new ObservableCollection <Location>();
            this.Staffs             = new ObservableCollection <Staff>();

            //Locations = new ObservableCollection<Location>();

            //ApplyChange(new SiteCreatedEvent(this.Id, siteName, siteDescription, active, tenantId.Id, contactInformation.ContactName, contactInformation.PrimaryTelephone, contactInformation.SecondaryTelephone));
        }