nettier deepload

 CustomerService service = new CustomerService();
            var customer = service.GetByCustomerId(customerId);
            if (customer != null)
            {
                // 1 
                service.DeepLoad(customer, true, DeepLoadType.IncludeChildren, new Type[] { typeof(Company)});

	       if (customer.CompanyIdSource != null)
                {
                    CompanyService cService = new CompanyService();
                    cService.DeepLoad(customer.CompanyIdSource, true, DeepLoadType.IncludeChildren, typeof(TaxStatus));
                } 
              // 2
                service.DeepLoad(customer, true, DeepLoadType.IncludeChildren, new Type[] { typeof(Company), typeof(TaxStatus) });
	    }

發佈了79 篇原創文章 · 獲贊 1 · 訪問量 5萬+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章