Release v1.0.0 #16
.editorconfig.envDbInitializer.csDependencyInjection.csnuget.config
.gitea/workflows
.gitignoreApiDto
ApiDto.csproj
Backend.slnDockerfileCommon
AuthRoles.csCacheType.csCronUpdateSkip.csDatabaseType.csOAuthAction.csOAuthProvider.csPairPeriodTime.csPasswordPolicy.csTwoFactorAuthentication.cs
Requests
Responses
AvailableOAuthProvidersResponse.csCampusBasicInfoResponse.csCampusDetailsResponse.cs
Configuration
DisciplineResponse.csFacultyResponse.csGroupDetailsResponse.csGroupResponse.csLectureHallDetailsResponse.csLectureHallResponse.csLessonTypeResponse.csProfessorResponse.csScheduleResponse.csTotpKeyResponse.csUserResponse.csEndpoint
Backend.httpISaveSettings.cs
README.mdCommon
Attributes
BadRequestResponseAttribute.csCacheMaxAgeAttribute.csLocalhostAttribute.csMaintenanceModeIgnoreAttribute.csNotFoundResponseAttribute.csSwaggerDefaultAttribute.csTokenAuthenticationAttribute.cs
Exceptions
Interfaces
MapperDto
AvailableProvidersConverter.csCronUpdateSkipConverter.csPairPeriodTimeConverter.csPasswordPolicyConverter.csTwoFactorAuthenticationConverter.csUserConverter.cs
Services
Configuration
Core
BackgroundTasks
Middleware
CacheMaxAgeMiddleware.csCookieAuthorizationMiddleware.csCustomExceptionHandlerMiddleware.csJwtRevocationMiddleware.csMaintenanceModeMiddleware.cs
Startup
Model
SwaggerOptions
ActionResultSchemaFilter.csConfigureSwaggerOptions.csDefaultValues.csEnumSchemaFilter.csExampleFilter.csTagSchemeFilter.cs
Validation
Controllers
BaseController.csConfigurationBaseController.cs
Endpoint.csprojProgram.csSetupConfiguration
V1
AuthController.csCampusController.cs
WeatherForecastController.csConfiguration
DisciplineController.csFacultyController.csGroupController.csImportController.csLectureHallController.csLessonTypeController.csProfessorController.csScheduleController.csSecurityController.csSync
WeatherForecast.cswwwroot
css
swagger
Security
Common
CookieNames.cs
DependencyInjection.csDomain
Interfaces
Model
OAuth2
ViewModel
Properties
Security.csprojServices
SqlData
Application
Application.csprojDependencyInjection.cs
Common
Cqrs
Campus
Queries
Discipline
Queries
Faculty
Queries
Group
Queries
LectureHall
Queries
Professor
Queries
GetProfessorDetails
GetProfessorDetailsBySearch
GetProfessorList
Schedule
Queries
TypeOfOccupation
Interfaces
Domain
Domain.csproj
Schedule
Migrations
MysqlMigrations
Migrations
20240601023106_InitialMigration.Designer.cs20240601023106_InitialMigration.cs20241027034820_RemoveUnusedRef.Designer.cs20241027034820_RemoveUnusedRef.csUberDbContextModelSnapshot.cs
MysqlMigrations.csprojPsqlMigrations
Migrations
20240601021702_InitialMigration.Designer.cs20240601021702_InitialMigration.cs20241027032753_RemoveUnusedRef.Designer.cs20241027032753_RemoveUnusedRef.csUberDbContextModelSnapshot.cs
PsqlMigrations.csprojSqliteMigrations
Persistence
Common
BaseDbContext.csConfigurationResolver.csDatabaseProvider.csDbContextFactory.csModelBuilderExtensions.cs
Contexts
Schedule
EntityTypeConfigurations
Persistence.csprojUberDbContext.cs@ -46,7 +46,7 @@ public class ScheduleController(ILogger<ScheduleController> logger, IOptionsSnap
|
|||||||
/// <returns>Cron expression and the list of next scheduled task dates.</returns>
|
/// <returns>Cron expression and the list of next scheduled task dates.</returns>
|
||||||
/// <exception cref="ControllerArgumentException">Thrown if the provided cron expression is invalid.</exception>
|
/// <exception cref="ControllerArgumentException">Thrown if the provided cron expression is invalid.</exception>
|
||||||
[HttpPost("CronUpdateSchedule")]
|
[HttpPost("CronUpdateSchedule")]
|
||||||
public ActionResult<CronUpdateScheduleResponse> CronUpdateSchedule([FromBody] string cron)
|
public ActionResult<CronUpdateScheduleResponse> CronUpdateSchedule([FromQuery] string cron)
|
||||||
{
|
{
|
||||||
cron = cron.Trim();
|
cron = cron.Trim();
|
||||||
if (!CronExpression.TryParse(cron, CronFormat.Standard, out _))
|
if (!CronExpression.TryParse(cron, CronFormat.Standard, out _))
|
||||||
@ -77,7 +77,7 @@ public class ScheduleController(ILogger<ScheduleController> logger, IOptionsSnap
|
|||||||
/// <returns>Success or failure.</returns>
|
/// <returns>Success or failure.</returns>
|
||||||
/// <exception cref="ControllerArgumentException">Thrown if the start term date is more than 6 months in the past or future.</exception>
|
/// <exception cref="ControllerArgumentException">Thrown if the start term date is more than 6 months in the past or future.</exception>
|
||||||
[HttpPost("StartTerm")]
|
[HttpPost("StartTerm")]
|
||||||
public ActionResult StartTerm([FromBody] DateOnly startTerm, [FromQuery] bool force = false)
|
public ActionResult StartTerm([FromQuery] DateOnly startTerm, [FromQuery] bool force = false)
|
||||||
{
|
{
|
||||||
var differentByTime = DateTime.Now - startTerm.ToDateTime(new TimeOnly(0, 0, 0));
|
var differentByTime = DateTime.Now - startTerm.ToDateTime(new TimeOnly(0, 0, 0));
|
||||||
if (differentByTime > TimeSpan.FromDays(190) || differentByTime.Multiply(-1) > TimeSpan.FromDays(190))
|
if (differentByTime > TimeSpan.FromDays(190) || differentByTime.Multiply(-1) > TimeSpan.FromDays(190))
|
||||||
|
Reference in New Issue
Block a user