mirror of
https://gitee.com/dotnetchina/OpenAuth.Net.git
synced 2025-11-09 02:44:44 +08:00
主页加载菜单按钮
重新修改了登陆逻辑
This commit is contained in:
39
OpenAuth.App/MenuApp.cs
Normal file
39
OpenAuth.App/MenuApp.cs
Normal file
@@ -0,0 +1,39 @@
|
||||
// ***********************************************************************
|
||||
// Assembly : OpenAuth.App
|
||||
// Author : yubaolee
|
||||
// Created : 05-19-2015
|
||||
//
|
||||
// Last Modified By : yubaolee
|
||||
// Last Modified On : 05-20-2015
|
||||
// ***********************************************************************
|
||||
// <copyright file="MenuApp.cs" company="Microsoft">
|
||||
// Copyright (c) Microsoft. All rights reserved.
|
||||
// </copyright>
|
||||
// <summary>菜单服务</summary>
|
||||
// ***********************************************************************
|
||||
using System.Collections.Generic;
|
||||
using OpenAuth.App.DTO;
|
||||
using OpenAuth.Domain.Model;
|
||||
using OpenAuth.Domain.Service;
|
||||
|
||||
namespace OpenAuth.App
|
||||
{
|
||||
public class MenuApp
|
||||
{
|
||||
private MenuService _menuService;
|
||||
|
||||
public MenuApp(MenuService service)
|
||||
{
|
||||
_menuService = service;
|
||||
}
|
||||
public MenuForUserResponse LoadFor(MenuForUserRequest request)
|
||||
{
|
||||
var response = new MenuForUserResponse();
|
||||
foreach (var menu in _menuService.GetMenuFor(request.UserId))
|
||||
{
|
||||
response.Menus.Add(menu);
|
||||
}
|
||||
return response;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user