Files
hamkadr/src/JobsMedical.Web/Models/RawListing.cs
T

32 lines
1.0 KiB
C#
Raw Normal View History

using System.ComponentModel.DataAnnotations;
namespace JobsMedical.Web.Models;
/// <summary>
/// Staging area for shift listings aggregated from Telegram / Bale / Divar channels.
/// An admin reviews and normalizes these into real <see cref="Shift"/> records.
/// This is how we beat the cold-start problem.
/// </summary>
public class RawListing
{
public int Id { get; set; }
[MaxLength(200)]
public string SourceChannel { get; set; } = ""; // نام کانال/منبع
[Required]
public string RawText { get; set; } = ""; // متن خام آگهی
public string? ParsedJson { get; set; } // نتیجه‌ی تجزیه‌ی خودکار (در صورت وجود)
public RawListingStatus Status { get; set; } = RawListingStatus.New;
public int? LinkedShiftId { get; set; } // شیفت ساخته‌شده از این آگهی
public Shift? LinkedShift { get; set; }
[MaxLength(500)]
public string? SourceUrl { get; set; }
public DateTime FetchedAt { get; set; } = DateTime.UtcNow;
}