Generator Changes at 9/27/2025 11:07:17 PM
This commit is contained in:
17
src/CMSMicroservice.Domain/Entities/OtpToken.cs
Normal file
17
src/CMSMicroservice.Domain/Entities/OtpToken.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
namespace CMSMicroservice.Domain.Entities;
|
||||
//توکن Otp
|
||||
public class OtpToken : BaseAuditableEntity
|
||||
{
|
||||
//موبایل مقصد
|
||||
public string Mobile { get; set; }
|
||||
//مقصود
|
||||
public string Purpose { get; set; }
|
||||
//کد هش شده
|
||||
public string CodeHash { get; set; }
|
||||
//زمان انقضا
|
||||
public DateTime ExpiresAt { get; set; }
|
||||
//شمارش تلاشها
|
||||
public int Attempts { get; set; }
|
||||
//موفق بود؟
|
||||
public bool IsUsed { get; set; }
|
||||
}
|
||||
@@ -16,12 +16,18 @@ public class User : BaseAuditableEntity
|
||||
public long? ParentId { get; set; }
|
||||
//User Navigation Property
|
||||
public virtual User? Parent { get; set; }
|
||||
//User Collection Navigation Reference
|
||||
public virtual ICollection<User> Users { get; set; }
|
||||
//کد ارجاع
|
||||
public string ReferralCode { get; set; }
|
||||
//موبایل فعال شده؟
|
||||
public bool IsMobileVerified { get; set; }
|
||||
//تاریخ فعال سازی موبایل
|
||||
public DateTime? MobileVerifiedAt { get; set; }
|
||||
//UserAddress Collection Navigation Reference
|
||||
public virtual ICollection<UserAddress> UserAddresss { get; set; }
|
||||
//UserOrder Collection Navigation Reference
|
||||
public virtual ICollection<UserOrder> UserOrders { get; set; }
|
||||
//UserRole Collection Navigation Reference
|
||||
public virtual ICollection<UserRole> UserRoles { get; set; }
|
||||
//User Collection Navigation Reference
|
||||
public virtual ICollection<User> Users { get; set; }
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
namespace CMSMicroservice.Domain.Events;
|
||||
public class CreateNewOtpTokenEvent : BaseEvent
|
||||
{
|
||||
public CreateNewOtpTokenEvent(OtpToken item)
|
||||
{
|
||||
Item = item;
|
||||
}
|
||||
|
||||
public OtpToken Item { get; }
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
namespace CMSMicroservice.Domain.Events;
|
||||
public class VerifyOtpTokenEvent : BaseEvent
|
||||
{
|
||||
public VerifyOtpTokenEvent(OtpToken item)
|
||||
{
|
||||
Item = item;
|
||||
}
|
||||
|
||||
public OtpToken Item { get; }
|
||||
}
|
||||
Reference in New Issue
Block a user