Update Profile.Id type and fix FK mapping in RecAction
Changed the `Id` property in the `Profile` class from `short?` to `long` to support larger values and resolve a type mismatch with the `ProfileId` foreign key in the `RecAction` class. Removed the `[NotMapped]` attribute from the `Profile` navigation property in `RecAction` as the type mismatch issue has been resolved. Also removed the related TODO comment. These changes improve database schema consistency and integrity.
This commit is contained in:
parent
23ccd44bd6
commit
edfbfd8e6c
@ -9,7 +9,7 @@ public class Profile
|
|||||||
[Key]
|
[Key]
|
||||||
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
||||||
[Column("GUID")]
|
[Column("GUID")]
|
||||||
public short? Id { get; set; }
|
public long Id { get; set; }
|
||||||
|
|
||||||
[Column("ACTIVE")]
|
[Column("ACTIVE")]
|
||||||
public bool? Active { get; set; }
|
public bool? Active { get; set; }
|
||||||
|
|||||||
@ -13,8 +13,6 @@ public class RecAction
|
|||||||
[Column("PROFILE_ID")]
|
[Column("PROFILE_ID")]
|
||||||
public long? ProfileId { get; set; }
|
public long? ProfileId { get; set; }
|
||||||
|
|
||||||
// TODO: Remove [NotMapped] once ProfileId FK type mismatch is resolved.
|
|
||||||
[NotMapped]
|
|
||||||
[ForeignKey("ProfileId")]
|
[ForeignKey("ProfileId")]
|
||||||
public Profile? Profile { get; set; }
|
public Profile? Profile { get; set; }
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user