|
@@ -36,7 +36,7 @@ namespace FileStorage.Host.Controllers
|
|
|
return Ok(new { Id = file.Id, fileName = file.FileName });
|
|
|
}
|
|
|
|
|
|
- [HttpGet("getfileurl/{id}")]
|
|
|
+ [HttpGet("getfileurl")]
|
|
|
public async Task<IActionResult> GetFileUrl([FromQuery] UploadGetDto dto)
|
|
|
{
|
|
|
var uri = await _fileStorage.GetFileUrlAsync(dto.Id, dto.Source ?? string.Empty);
|
|
@@ -44,7 +44,7 @@ namespace FileStorage.Host.Controllers
|
|
|
}
|
|
|
|
|
|
|
|
|
- [HttpGet("downloadfile/{id}")]
|
|
|
+ [HttpGet("downloadfile")]
|
|
|
public async Task<IActionResult> DownLoadFile([FromQuery] UploadGetDto dto)
|
|
|
{
|
|
|
var (stream, content, fileName) = _fileStorage.DownLoadFile(dto.Id, dto.Source ?? string.Empty);
|
|
@@ -55,7 +55,7 @@ namespace FileStorage.Host.Controllers
|
|
|
return null;
|
|
|
}
|
|
|
|
|
|
- [HttpGet("delfile/{id}")]
|
|
|
+ [HttpGet("delfile")]
|
|
|
public async Task<bool> DelFile([FromQuery] UploadGetDto dto)
|
|
|
{
|
|
|
return await _fileStorage.DelFileAsync(dto.Id, dto.Source ?? string.Empty);
|