Exemplo n.º 1
0
        protected void Child_Update()
        {
            Csla.ApplicationContext.GlobalContext["CustomerContactUpdate"] = "Updated  Customer Contact" + GetProperty <string>(FirstNameProperty) + ", " + GetProperty <string>(LastNameProperty);
            CustomerContactList parent      = this.Parent as CustomerContactList;
            Customer            grandParent = parent.MyParent;

            LoadProperty(ParentNameProperty, grandParent.Name);
        }
Exemplo n.º 2
0
 protected void DataPortal_Create(int criteria)
 {
     LoadProperty(IdProperty, criteria);
     LoadProperty(NameProperty, "New Customer for Id: " + criteria.ToString());
     LoadProperty(DateCreatedProperty, new SmartDate(DateTime.Today));
     LoadProperty(DateTimeOffsetNotNullProperty, DateTimeOffset.Now);
     LoadProperty(ContactsProperty, CustomerContactList.GetCustomerContactList(0));
 }
Exemplo n.º 3
0
        protected void Child_Update()
        {
            TestResults.Add("CustomerContactUpdate", "Updated  Customer Contact" + GetProperty <string>(FirstNameProperty) + ", " + GetProperty <string>(LastNameProperty));
            CustomerContactList parent      = this.Parent as CustomerContactList;
            Customer            grandParent = parent.MyParent;

            LoadProperty(ParentNameProperty, grandParent.Name);
        }
Exemplo n.º 4
0
        protected void Child_Update()
        {
#pragma warning disable CS0618 // Type or member is obsolete
            Csla.ApplicationContext.GlobalContext["CustomerContactUpdate"] = "Updated  Customer Contact" + GetProperty <string>(FirstNameProperty) + ", " + GetProperty <string>(LastNameProperty);
#pragma warning restore CS0618 // Type or member is obsolete
            CustomerContactList parent      = this.Parent as CustomerContactList;
            Customer            grandParent = parent.MyParent;
            LoadProperty(ParentNameProperty, grandParent.Name);
        }
Exemplo n.º 5
0
        protected void DataPortal_Fetch(int criteria)
        {
            LoadProperty(IdProperty, criteria);
            LoadProperty(NameProperty, "Customer Name for Id: " + criteria.ToString());
            LoadProperty(DateCreatedProperty, new SmartDate(new DateTime(2000 + criteria, 1, 1)));
            LoadProperty(ContactsProperty, CustomerContactList.GetCustomerContactList(criteria));
            LoadProperty(DateTimeOffsetNotNullProperty, DateTimeOffset.Now);
            LoadProperty(TypeProperty, CustomeType.Inactive);

            if (criteria == customerIDThrowsException)
            {
                throw new ApplicationException("Test for Silverlight DataSource Error!");
            }
        }