示例#1
0
        public override UiView Details(long?id, IMDResponse res = null)
        {
            if (id == null)
            {
                return(new ViewBuilder <EmployeeVM>(DetailsPage, res).Details());
            }
            var vm = uw.QueryEntity <Employee>().GetByID <EmployeeVM>(id, false, IncludeProps.ToArray());

            if (vm != null)
            {
                vm.UserAccountVM = vm.UserAccount.To <UserAccountVM>();
            }
            return(new ViewBuilder <EmployeeVM>(DetailsPage, res).Details(vm));
        }
示例#2
0
 public virtual UiView Details(long?id, IMDResponse res    = null)
 => (id.HasValue) ? new ViewBuilder <TViewModel>(DetailsPage, res).Details(uw.QueryEntity <TEntity>().GetByID <TViewModel>(id, false, IncludeProps?.ToArray()))
         : new ViewBuilder <TViewModel>(DetailsPage, res).Details();
示例#3
0
 public virtual UiView List(TViewModel vm, IMDResponse res = null)
 => new ViewBuilder <TViewModel>(ListPage, res).List(uw.QueryEntity <TEntity>().GetListFiltered <TViewModel>(Filters, IncludeProps?.ToArray()));