using DS.Module.Core;
using DS.WMS.Core.System.Dtos;
using DS.WMS.Core.System.Interface;
using Microsoft.AspNetCore.Mvc;
namespace DS.WMS.AdminApi.Controllers;
///
/// 用户模块
///
public class UserController : ApiController
{
private readonly IUserService _invokeService;
///
/// 构造函数
///
///
public UserController(IUserService invokeService)
{
_invokeService = invokeService;
}
///
/// 用户列表
///
///
///
[HttpPost]
[Route("GetUserList")]
public DataResult> GetUserList([FromBody] PageRequest request)
{
var res = _invokeService.GetListByPage(request);
return res;
}
///
/// 获取用户信息
///
///
///
[HttpGet]
[Route("GetUserInfo")]
public DataResult GetUserInfo([FromQuery] string id)
{
var res = _invokeService.GetUserInfo(id);
return res;
}
///
/// 编辑
///
///
///
[HttpPost]
[Route("EditUser")]
public DataResult EditUser([FromBody] UserReq model)
{
var res = _invokeService.EditUser(model);
return res;
}
}