using Atomx.Data;
using Atomx.Data.Services;
using Atomx.Storage.Services;
using MapsterMapper;
using Microsoft.AspNetCore.Mvc;

namespace Atomx.Storage.Controllers
{
    [Route("api/[controller]")]
    [ApiController]
    public class UploadController : ControllerBase
    {
        readonly ILogger<UploadController> _logger;
        readonly IIdentityService _identityService;
        readonly IIdCreatorService _idCreator;
        readonly IMapper _mapper;
        readonly DataContext _dbContext;

        /// <summary>
        /// 
        /// </summary>
        /// <param name="logger"></param>
        /// <param name="identityService"></param>
        /// <param name="idCreator"></param>
        /// <param name="adminService"></param>
        /// <param name="mapper"></param>
        public UploadController(ILogger<UploadController> logger, IIdentityService identityService, IIdCreatorService idCreator, IMapper mapper, DataContext dataContext)
        {
            _logger = logger;
            _identityService = identityService;
            _idCreator = idCreator;
            _mapper = mapper;
            _dbContext = dataContext;
        }

        /// <summary>
        /// 上传图片
        /// </summary>
        /// <returns></returns>
        [HttpPost("image")]
        public IActionResult Images()
        {
            return Ok("Upload Service");
        }

        /// <summary>
        /// 上传文件
        /// </summary>
        /// <returns></returns>
        [HttpPost("file")]
        public IActionResult File()
        {
            return Ok("Upload Service");
        }
    }
}
