Misc bunch of changes (#2815)

This commit is contained in:
Joe Milazzo 2024-03-23 16:20:16 -05:00 committed by GitHub
parent 18792b7b56
commit 63c9bff32e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
81 changed files with 4567 additions and 339 deletions

View file

@ -1,5 +1,6 @@
using System.Threading.Tasks;
using API.Data.ManualMigrations;
using API.DTOs.Progress;
using API.Entities;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Identity;
@ -29,4 +30,15 @@ public class AdminController : BaseApiController
var users = await _userManager.GetUsersInRoleAsync("Admin");
return users.Count > 0;
}
/// <summary>
/// Set the progress information for a particular user
/// </summary>
/// <returns></returns>
[Authorize("RequireAdminRole")]
[HttpPost("update-chapter-progress")]
public async Task<ActionResult<bool>> UpdateChapterProgress(UpdateUserProgressDto dto)
{
return Ok(await Task.FromResult(false));
}
}