i want result groupby roleoperation.menuid
my linq code i wirte below code
from roleoperation in db.RoleOperations
join menu in db.Menus
on roleoperation.MenuId equals menu.Id
join asprols in db.aspnet_Roles
on roleoperation.RoleId equals asprols.RoleId
join aspusers in db.aspnet_UsersInRoles
on asprols.RoleId equals aspusers.RoleId
//where aspusers.UserId.Equals(userId) && roleoperation.IsVisible.Equals(true) && roleIds.Contains(roleoperation.RoleId)
where aspusers.UserId.Equals(userId) && roleIds.Contains(roleoperation.RoleId)
orderby menu.Sequence
group roleoperation by roleoperation.MenuId
select new ePP2PL.MenusProperties()
{
Id = menu.Id,
Pagename = menu.PageName,
Tooltip = menu.ToolTip,
Parentid = menu.ParentId,
Sequence = menu.Sequence,
Name = menu.Name,
ParentidName = menu.ParentId,
CRUDAllowed = menu.CRUDAllowed,
IsMandatory = menu.IsMandatory
//prementname = abc.Parentname
};
return menuData;
how can get result group by roleoperation menu id
Nothing is really over,untill the moment stop trying for it...
Amitsp(MCTS,MCP)
sqlreporting.blogspot.com