Changeset f0fc386 for iknow-api/DTOs


Ignore:
Timestamp:
12/08/25 21:51:12 (10 months ago)
Author:
Stefan-Saveski <stefan@…>
Branches:
master
Children:
18e0c10
Parents:
5e22720
Message:

Refactor and enhance application structure

Enhanced error handling in AuthController with detailed exception handling for user registration. Updated UserDTO to improve JSON serialization and renamed enums for clarity. Introduced new entities (Major, PassedSubject, etc.) and seeded initial data in AppDbContext.

Replaced legacy migrations with 20251208203846_InitialCreate, reflecting the updated schema. Fixed typographical errors and improved JSON serialization in Program.cs with case-insensitive property matching and enum handling.

Refactored repository interfaces for better null safety. Improved debugging in AuthService and updated connection strings. Added the PassedSubject entity and cleaned up redundant code and unused imports for better maintainability.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • iknow-api/DTOs/UserDTO.cs

    r5e22720 rf0fc386  
    1 namespace iknow_api.DTOs
     1using System.Text.Json.Serialization;
     2
     3namespace iknow_api.DTOs
    24{
    35    // Login DTO
     
    2527        public UserRole Role { get; set; }
    2628        public float gpa { get; set; }
    27         public Type tip { get; set; }
     29        public HighSchoolType tip { get; set; }
    2830        public string city { get; set; } = string.Empty;
    2931        public string address { get; set; } = string.Empty;
     
    5759        Student
    5860    }
    59     public enum Type
     61    public enum HighSchoolType
    6062    {
    6163        strucen, gimnazija
     
    6567        drzavna, privatna, stipendija
    6668    }
    67     public enum Major
    68     {
    69         SIIS, PIT, KN, KI, IMB, IE, SSP, SEIS
    70     }
    7169}
Note: See TracChangeset for help on using the changeset viewer.