日期:2014-05-18 浏览次数:21326 次
List<CustomerTree> query = db.GroupBy(x => x.fcustno)
.Select(x => new CustomerTree()
{
customerId = x.Key,
orders = db.Where(y => y.fcustno == x.Key)
.Select(y => new orderInfo()
{
orderNo = y.forderno,
orderDate = forderdate
}).ToList()
}).ToList();