Implemented the ability to correct a match from UI and further scans will show that new Series name.
This commit is contained in:
parent
5186508aff
commit
c6e1fec9f2
11 changed files with 806 additions and 18 deletions
|
@ -1,4 +1,5 @@
|
|||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using API.Data;
|
||||
|
@ -42,9 +43,32 @@ namespace API.Controllers
|
|||
file.Page = page;
|
||||
file.MangaFileName = mangaFile.FilePath;
|
||||
file.NeedsSplitting = file.Width > file.Height;
|
||||
|
||||
// TODO: Validate if sending page whole (not base64 encoded) fixes Tablet issue
|
||||
//Response.Headers.Add("Transfer-Encoding", "gzip");
|
||||
|
||||
return Ok(file);
|
||||
}
|
||||
|
||||
[HttpGet("image2")]
|
||||
public async Task<ActionResult> GetImage2(int chapterId, int page)
|
||||
{
|
||||
// Temp let's iterate the directory each call to get next image
|
||||
var chapter = await _cacheService.Ensure(chapterId);
|
||||
|
||||
if (chapter == null) return BadRequest("There was an issue finding image file for reading");
|
||||
|
||||
var (path, mangaFile) = await _cacheService.GetCachedPagePath(chapter, page);
|
||||
if (string.IsNullOrEmpty(path)) return BadRequest($"No such image for page {page}");
|
||||
var file = await _directoryService.ReadImageAsync(path);
|
||||
file.Page = page;
|
||||
file.MangaFileName = mangaFile.FilePath;
|
||||
file.NeedsSplitting = file.Width > file.Height;
|
||||
|
||||
// TODO: Validate if sending page whole (not base64 encoded) fixes Tablet issue
|
||||
|
||||
return File(file.Content, "image/jpeg", mangaFile.FilePath);
|
||||
}
|
||||
|
||||
[HttpGet("get-bookmark")]
|
||||
public async Task<ActionResult<int>> GetBookmark(int chapterId)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue