//  Create a model from and entity.
 public SystemAddressModel(SystemAddress entity)
 {
     Type    = new SystemLookupItemValueModel(entity.Type);
     Line1   = entity.Line1;
     Line2   = entity.Line2;
     City    = entity.City;
     State   = new SystemLookupItemValueModel(entity.State);
     Country = new SystemLookupItemValueModel(entity.Country);
 }
 public SystemLookupItemModel(SystemLookupItem entity)
 {
     Id                   = entity.Id;
     CanonicalName        = entity.CanonicalName;
     DisplayName          = entity.DisplayName;
     CloneToAdminDatabase = entity.CloneToAdminDatabase;
     Values               = SystemLookupItemValueModel.Construct(entity.Values);
     Enabled              = entity.Enabled;
 }
 //  Create a model from an entity.
 public SubscriptionModel(Subscription entity)
 {
     Id                = entity.Id;
     CanonicalName     = entity.CanonicalName;
     Description       = entity.Description;
     Price             = entity.Price;
     IsExpired         = entity.IsExpired;
     PromotionCode     = entity.PromotionCode;
     RenewalOccurrence = entity.RenewalOccurrence;
     RenewalTimeframe  = new SystemLookupItemValueModel(entity.RenewalTimeframe);
     Highlights        = entity.Highlights;
 }
 public SystemEmailAddressModel(SystemEmailAddress entity)
 {
     Address = entity.Address;
     Type    = new SystemLookupItemValueModel(entity.Type);
 }
Ejemplo n.º 5
0
 public SystemPhoneNumberModel(SystemPhoneNumber entity)
 {
     Number = entity.Number;
     Type   = new SystemLookupItemValueModel(entity.Type);
 }