34 lines
1.2 KiB
C#
Executable File
34 lines
1.2 KiB
C#
Executable File
using Microsoft.AspNetCore.Authorization;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
using Opsoft.NetCore.O3App.Domain.UnitOfWork.BaseData.IServices;
|
|
using Opsoft.NetCore.O3App.Domain.UnitOfWork.BaseData.Model;
|
|
using Opsoft.NetCore.O3App.Shared;
|
|
using Opsoft.NetCore.O3App.WebApi.Models;
|
|
using System.Collections.Generic;
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
namespace Opsoft.NetCore.O3App.WebApi.Controllers.BaseData
|
|
{
|
|
[Authorize]
|
|
public class AssetinventoryController : BaseApiController<AssetinventoryController>
|
|
{
|
|
private readonly IAssetinventoryServices _service;
|
|
public AssetinventoryController(IMapper mapper, ILogger<AssetinventoryController> logger, IAssetinventoryServices Service)
|
|
: base(mapper, logger)
|
|
{
|
|
_service = Service;
|
|
}
|
|
[HttpGet]
|
|
public async Task<BaseResponse<List<IAS_ASSETSINVENTORY>>> GetAllAssetinventoryUnRead(int pageNum, int pageCount)
|
|
{
|
|
|
|
var data = new { pageNum = pageNum, pageCount = pageCount };
|
|
return await TryProcess(async input =>
|
|
{
|
|
return await _service.GetAllAssetinventoryUnRead(data.ToJson());
|
|
}, data);
|
|
}
|
|
}
|
|
}
|