Ejemplo n.º 1
0
        public ActionResult Role()
        {
            TS_ROLEDTO rDto = new TS_ROLEDTO();
            //获取完成工差列表
            PageResult <TS_ROLE> ef = basicsService.GetRoles(rDto);
            //获取分页数据
            BASEPAGE page = AUTOMAPING.Mapping <BASEPAGE>(ef);

            this.HttpContext.Session["Page"] = page;
            //EF实体数据转换为DTO
            rDto.Roles = MAPPING.ConvertEntityToDtoList <TS_ROLE, TS_ROLEDTO>(ef.DataList);
            return(View(rDto));
        }