4ab6ce29c9
We captured Divar's privacy-fuzzed coords on RawListing but discarded them for the listings that need them: unnamed-facility shifts/jobs dropped them (to avoid piling on the shared placeholder) and applicants had no coordinate field at all. - Add Lat/Lng to Shift, JobOpening, TalentListing (migration ListingApproxCoords). - Publish stores the source ad's approx coords on each aggregated listing. - Detail pages render the map from the listing's own coords (fallback: facility), and aggregated coords show as a shaded «محدودهٔ تقریبی» circle (not a precise pin) via _NeshanMap data-approx, with a disclaimer. Applicants get a map card (they had none) + the page now loads the Neshan key. Only Divar provides coords; the map needs NeshanMapKey set in admin settings. Existing rows get coords once reprocessed (RawListing already has them). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1633 lines
57 KiB
C#
1633 lines
57 KiB
C#
// <auto-generated />
|
|
using System;
|
|
using JobsMedical.Web.Data;
|
|
using Microsoft.EntityFrameworkCore;
|
|
using Microsoft.EntityFrameworkCore.Infrastructure;
|
|
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
|
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
|
|
|
#nullable disable
|
|
|
|
namespace JobsMedical.Web.Migrations
|
|
{
|
|
[DbContext(typeof(AppDbContext))]
|
|
partial class AppDbContextModelSnapshot : ModelSnapshot
|
|
{
|
|
protected override void BuildModel(ModelBuilder modelBuilder)
|
|
{
|
|
#pragma warning disable 612, 618
|
|
modelBuilder
|
|
.HasAnnotation("ProductVersion", "10.0.0")
|
|
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
|
|
|
NpgsqlModelBuilderExtensions.UseIdentityByDefaultColumns(modelBuilder);
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.AppSetting", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("AiApiKey")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<bool>("AiAutoApprove")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("AiEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("AiEndpoint")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<string>("AiModel")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<string>("AiSystemPrompt")
|
|
.IsRequired()
|
|
.HasMaxLength(4000)
|
|
.HasColumnType("character varying(4000)");
|
|
|
|
b.Property<bool>("AiUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("AutoIngestEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<int>("AutoPublishMinConfidence")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("BaleBotToken")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<bool>("BaleEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("BaleUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("DemoMode")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("DivarCity")
|
|
.HasMaxLength(60)
|
|
.HasColumnType("character varying(60)");
|
|
|
|
b.Property<bool>("DivarEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("DivarQueries")
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("character varying(2000)");
|
|
|
|
b.Property<bool>("DivarUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<int>("IngestIntervalMinutes")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IngestProxyEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("IngestProxyUrl")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("InstagramHashtags")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<bool>("MedjobsEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<int>("MedjobsMaxAds")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("MedjobsUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<int>("Mode")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("NeshanMapKey")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<bool>("PushEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("SmsApiKey")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<bool>("SmsEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("SmsSender")
|
|
.HasMaxLength(30)
|
|
.HasColumnType("character varying(30)");
|
|
|
|
b.Property<string>("SmsTemplate")
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<string>("SocialBaleBotToken")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("SocialBaleChatId")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<bool>("SocialBaleEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("SocialEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("SocialFooter")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<string>("SocialHeader")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<bool>("SocialInstagramEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<DateTime?>("SocialLastPostedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int>("SocialPostsPerDay")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("SocialTelegramBotToken")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("SocialTelegramChatId")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<bool>("SocialTelegramEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("SocialUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("TelegramChannels")
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("character varying(2000)");
|
|
|
|
b.Property<bool>("TelegramEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("TelegramUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<DateTime>("UpdatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("VapidPrivateKey")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("VapidPublicKey")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("VapidSubject")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<bool>("WebNotificationsEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("WebsiteUrls")
|
|
.HasMaxLength(4000)
|
|
.HasColumnType("character varying(4000)");
|
|
|
|
b.Property<bool>("WebsitesEnabled")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("WebsitesUseProxy")
|
|
.HasColumnType("boolean");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("AppSettings");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Application", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int>("DoctorId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Message")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int>("ShiftId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("DoctorId");
|
|
|
|
b.HasIndex("ShiftId", "DoctorId")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Applications");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.City", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<bool>("IsActive")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Name")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<string>("Province")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("Cities");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.ContactMethod", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<int?>("JobOpeningId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("ShiftId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("SortOrder")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("TalentListingId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Type")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Value")
|
|
.IsRequired()
|
|
.HasMaxLength(250)
|
|
.HasColumnType("character varying(250)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("JobOpeningId");
|
|
|
|
b.HasIndex("ShiftId");
|
|
|
|
b.HasIndex("TalentListingId");
|
|
|
|
b.ToTable("ContactMethods");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.District", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<int>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsActive")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Name")
|
|
.IsRequired()
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("CityId");
|
|
|
|
b.ToTable("Districts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.DoctorProfile", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Bio")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<int?>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsVerified")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("LicenseNo")
|
|
.HasMaxLength(20)
|
|
.HasColumnType("character varying(20)");
|
|
|
|
b.Property<int?>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Specialty")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<int>("UserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("YearsExperience")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("CityId");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("UserId")
|
|
.IsUnique();
|
|
|
|
b.ToTable("DoctorProfiles");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Facility", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Address")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<string>("BaleId")
|
|
.HasMaxLength(50)
|
|
.HasColumnType("character varying(50)");
|
|
|
|
b.Property<int>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int?>("DistrictId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsDemo")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("IsVerified")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<double?>("Lat")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<double?>("Lng")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<string>("Name")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<int?>("OwnerUserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Phone")
|
|
.HasMaxLength(20)
|
|
.HasColumnType("character varying(20)");
|
|
|
|
b.Property<int>("Type")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Verification")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("VerificationNote")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<DateTime?>("VerificationRequestedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("CityId");
|
|
|
|
b.HasIndex("DistrictId");
|
|
|
|
b.HasIndex("OwnerUserId");
|
|
|
|
b.ToTable("Facilities");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.FacilityDocument", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("ContentType")
|
|
.IsRequired()
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<byte[]>("Data")
|
|
.IsRequired()
|
|
.HasColumnType("bytea");
|
|
|
|
b.Property<int>("FacilityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("FileName")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<long>("Size")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<DateTime>("UploadedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("FacilityId");
|
|
|
|
b.ToTable("FacilityDocuments");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.IngestionRun", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Detail")
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("character varying(2000)");
|
|
|
|
b.Property<int>("Duplicates")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Fetched")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Flagged")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Published")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Queued")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<DateTime>("RunAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int>("Spam")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("IngestionRuns");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.InterestEvent", b =>
|
|
{
|
|
b.Property<long>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("bigint");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<long>("Id"));
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int>("EventType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("JobOpeningId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("ShiftId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("VisitorId")
|
|
.IsRequired()
|
|
.HasColumnType("character varying(36)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("JobOpeningId");
|
|
|
|
b.HasIndex("ShiftId");
|
|
|
|
b.HasIndex("VisitorId", "CreatedAt");
|
|
|
|
b.ToTable("InterestEvents");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.JobAlert", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<int?>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int?>("DistrictId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("EmploymentType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsActive")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Label")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<long?>("MinPay")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<int?>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Scope")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("ShiftType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("UserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("CityId");
|
|
|
|
b.HasIndex("IsActive");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.ToTable("JobAlerts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.JobOpening", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("Description")
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("character varying(2000)");
|
|
|
|
b.Property<int>("EmploymentType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("FacilityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("GenderRequirement")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<double?>("Lat")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<double?>("Lng")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<string>("Requirements")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<int>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<long?>("SalaryMax")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<long?>("SalaryMin")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<int>("Source")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("SourceUrl")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Title")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("FacilityId");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("Status");
|
|
|
|
b.ToTable("JobOpenings");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Notification", b =>
|
|
{
|
|
b.Property<long>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("bigint");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<long>("Id"));
|
|
|
|
b.Property<string>("Body")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<bool>("IsRead")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Title")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("Url")
|
|
.HasMaxLength(300)
|
|
.HasColumnType("character varying(300)");
|
|
|
|
b.Property<int>("UserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("UserId", "IsRead", "CreatedAt");
|
|
|
|
b.ToTable("Notifications");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.RawListing", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<int>("Confidence")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("ContentHash")
|
|
.HasMaxLength(64)
|
|
.HasColumnType("character varying(64)");
|
|
|
|
b.Property<DateTime>("FetchedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<double?>("Lat")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<int?>("LinkedShiftId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("LinkedTalentId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<double?>("Lng")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<string>("ParsedJson")
|
|
.HasColumnType("text");
|
|
|
|
b.Property<string>("RawText")
|
|
.IsRequired()
|
|
.HasColumnType("text");
|
|
|
|
b.Property<string>("SourceChannel")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("SourceUrl")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("ValidationNotes")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("ContentHash");
|
|
|
|
b.HasIndex("LinkedShiftId");
|
|
|
|
b.HasIndex("LinkedTalentId");
|
|
|
|
b.HasIndex("Status");
|
|
|
|
b.ToTable("RawListings");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Report", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("Reason")
|
|
.IsRequired()
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int?>("ReporterUserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("ReporterVisitorId")
|
|
.HasMaxLength(36)
|
|
.HasColumnType("character varying(36)");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("TargetId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("TargetLabel")
|
|
.HasMaxLength(160)
|
|
.HasColumnType("character varying(160)");
|
|
|
|
b.Property<int>("TargetType")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Status");
|
|
|
|
b.ToTable("Reports");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Review", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Comment")
|
|
.HasMaxLength(1000)
|
|
.HasColumnType("character varying(1000)");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int>("FacilityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsApproved")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<int>("Stars")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("UserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.HasIndex("FacilityId", "UserId")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Reviews");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Role", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Category")
|
|
.IsRequired()
|
|
.HasMaxLength(50)
|
|
.HasColumnType("character varying(50)");
|
|
|
|
b.Property<bool>("IsActive")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Name")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<int>("SortOrder")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("Roles");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Shift", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<DateOnly>("Date")
|
|
.HasColumnType("date");
|
|
|
|
b.Property<string>("Description")
|
|
.HasMaxLength(1500)
|
|
.HasColumnType("character varying(1500)");
|
|
|
|
b.Property<TimeOnly>("EndTime")
|
|
.HasColumnType("time without time zone");
|
|
|
|
b.Property<int>("FacilityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("GenderRequirement")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<double?>("Lat")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<double?>("Lng")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<long?>("PayAmount")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<int>("PayType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("SharePercent")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("ShiftType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Source")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("SourceUrl")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<string>("SpecialtyRequired")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<TimeOnly>("StartTime")
|
|
.HasColumnType("time without time zone");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("FacilityId");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("Date", "Status");
|
|
|
|
b.ToTable("Shifts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.TalentListing", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("AreaNote")
|
|
.HasMaxLength(150)
|
|
.HasColumnType("character varying(150)");
|
|
|
|
b.Property<int?>("Availability")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("Description")
|
|
.HasMaxLength(2000)
|
|
.HasColumnType("character varying(2000)");
|
|
|
|
b.Property<int?>("DistrictId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Gender")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<bool>("IsLicensed")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<double?>("Lat")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<double?>("Lng")
|
|
.HasColumnType("double precision");
|
|
|
|
b.Property<long?>("PayAmount")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<int>("PayType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("PersonName")
|
|
.HasMaxLength(150)
|
|
.HasColumnType("character varying(150)");
|
|
|
|
b.Property<string>("Phone")
|
|
.HasMaxLength(30)
|
|
.HasColumnType("character varying(30)");
|
|
|
|
b.Property<int>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("SharePercent")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Source")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("SourceUrl")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int>("Status")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<string>("Tags")
|
|
.HasMaxLength(500)
|
|
.HasColumnType("character varying(500)");
|
|
|
|
b.Property<int?>("YearsExperience")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("DistrictId");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("Status");
|
|
|
|
b.HasIndex("CityId", "RoleId");
|
|
|
|
b.ToTable("TalentListings");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.User", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<byte[]>("Avatar")
|
|
.HasColumnType("bytea");
|
|
|
|
b.Property<string>("AvatarContentType")
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<string>("BanReason")
|
|
.HasMaxLength(300)
|
|
.HasColumnType("character varying(300)");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("FullName")
|
|
.HasMaxLength(150)
|
|
.HasColumnType("character varying(150)");
|
|
|
|
b.Property<bool>("IsBanned")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<bool>("IsPhoneVerified")
|
|
.HasColumnType("boolean");
|
|
|
|
b.Property<string>("Phone")
|
|
.IsRequired()
|
|
.HasMaxLength(20)
|
|
.HasColumnType("character varying(20)");
|
|
|
|
b.Property<byte[]>("Resume")
|
|
.HasColumnType("bytea");
|
|
|
|
b.Property<string>("ResumeContentType")
|
|
.HasMaxLength(120)
|
|
.HasColumnType("character varying(120)");
|
|
|
|
b.Property<string>("ResumeFileName")
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<int>("Role")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Phone")
|
|
.IsUnique();
|
|
|
|
b.ToTable("Users");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.UserPreferences", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<int?>("CityId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int>("Gender")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<long?>("MinPay")
|
|
.HasColumnType("bigint");
|
|
|
|
b.Property<int?>("PreferredShiftType")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<int?>("RoleId")
|
|
.HasColumnType("integer");
|
|
|
|
b.Property<DateTime>("UpdatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("VisitorId")
|
|
.IsRequired()
|
|
.HasColumnType("character varying(36)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("CityId");
|
|
|
|
b.HasIndex("RoleId");
|
|
|
|
b.HasIndex("VisitorId")
|
|
.IsUnique();
|
|
|
|
b.ToTable("UserPreferences");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Visitor", b =>
|
|
{
|
|
b.Property<string>("Id")
|
|
.HasMaxLength(36)
|
|
.HasColumnType("character varying(36)");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<DateTime>("LastSeenAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<int?>("UserId")
|
|
.HasColumnType("integer");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("UserId");
|
|
|
|
b.ToTable("Visitors");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.WebPushSubscription", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("Auth")
|
|
.IsRequired()
|
|
.HasMaxLength(100)
|
|
.HasColumnType("character varying(100)");
|
|
|
|
b.Property<DateTime>("CreatedAt")
|
|
.HasColumnType("timestamp with time zone");
|
|
|
|
b.Property<string>("Endpoint")
|
|
.IsRequired()
|
|
.HasMaxLength(600)
|
|
.HasColumnType("character varying(600)");
|
|
|
|
b.Property<string>("P256dh")
|
|
.IsRequired()
|
|
.HasMaxLength(200)
|
|
.HasColumnType("character varying(200)");
|
|
|
|
b.Property<string>("VisitorId")
|
|
.HasMaxLength(36)
|
|
.HasColumnType("character varying(36)");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.HasIndex("Endpoint")
|
|
.IsUnique();
|
|
|
|
b.ToTable("WebPushSubscriptions");
|
|
});
|
|
|
|
modelBuilder.Entity("Microsoft.AspNetCore.DataProtection.EntityFrameworkCore.DataProtectionKey", b =>
|
|
{
|
|
b.Property<int>("Id")
|
|
.ValueGeneratedOnAdd()
|
|
.HasColumnType("integer");
|
|
|
|
NpgsqlPropertyBuilderExtensions.UseIdentityByDefaultColumn(b.Property<int>("Id"));
|
|
|
|
b.Property<string>("FriendlyName")
|
|
.HasColumnType("text");
|
|
|
|
b.Property<string>("Xml")
|
|
.HasColumnType("text");
|
|
|
|
b.HasKey("Id");
|
|
|
|
b.ToTable("DataProtectionKeys");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Application", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.User", "Doctor")
|
|
.WithMany("Applications")
|
|
.HasForeignKey("DoctorId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Shift", "Shift")
|
|
.WithMany("Applications")
|
|
.HasForeignKey("ShiftId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Doctor");
|
|
|
|
b.Navigation("Shift");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.ContactMethod", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.JobOpening", "JobOpening")
|
|
.WithMany("Contacts")
|
|
.HasForeignKey("JobOpeningId")
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Shift", "Shift")
|
|
.WithMany("Contacts")
|
|
.HasForeignKey("ShiftId")
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.TalentListing", "TalentListing")
|
|
.WithMany("Contacts")
|
|
.HasForeignKey("TalentListingId")
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
b.Navigation("JobOpening");
|
|
|
|
b.Navigation("Shift");
|
|
|
|
b.Navigation("TalentListing");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.District", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany()
|
|
.HasForeignKey("CityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("City");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.DoctorProfile", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany()
|
|
.HasForeignKey("CityId");
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany()
|
|
.HasForeignKey("RoleId");
|
|
|
|
b.HasOne("JobsMedical.Web.Models.User", "User")
|
|
.WithOne("DoctorProfile")
|
|
.HasForeignKey("JobsMedical.Web.Models.DoctorProfile", "UserId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("City");
|
|
|
|
b.Navigation("Role");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Facility", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany("Facilities")
|
|
.HasForeignKey("CityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.District", "District")
|
|
.WithMany("Facilities")
|
|
.HasForeignKey("DistrictId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.User", "OwnerUser")
|
|
.WithMany()
|
|
.HasForeignKey("OwnerUserId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.Navigation("City");
|
|
|
|
b.Navigation("District");
|
|
|
|
b.Navigation("OwnerUser");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.FacilityDocument", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.Facility", "Facility")
|
|
.WithMany("Documents")
|
|
.HasForeignKey("FacilityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Facility");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.InterestEvent", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.JobOpening", "JobOpening")
|
|
.WithMany()
|
|
.HasForeignKey("JobOpeningId")
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Shift", "Shift")
|
|
.WithMany()
|
|
.HasForeignKey("ShiftId")
|
|
.OnDelete(DeleteBehavior.Cascade);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Visitor", "Visitor")
|
|
.WithMany("Events")
|
|
.HasForeignKey("VisitorId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("JobOpening");
|
|
|
|
b.Navigation("Shift");
|
|
|
|
b.Navigation("Visitor");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.JobAlert", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany()
|
|
.HasForeignKey("CityId");
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany()
|
|
.HasForeignKey("RoleId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.User", "User")
|
|
.WithMany()
|
|
.HasForeignKey("UserId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("City");
|
|
|
|
b.Navigation("Role");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.JobOpening", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.Facility", "Facility")
|
|
.WithMany()
|
|
.HasForeignKey("FacilityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany()
|
|
.HasForeignKey("RoleId")
|
|
.OnDelete(DeleteBehavior.Restrict)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Facility");
|
|
|
|
b.Navigation("Role");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Notification", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.User", "User")
|
|
.WithMany()
|
|
.HasForeignKey("UserId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.RawListing", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.Shift", "LinkedShift")
|
|
.WithMany()
|
|
.HasForeignKey("LinkedShiftId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.TalentListing", "LinkedTalent")
|
|
.WithMany()
|
|
.HasForeignKey("LinkedTalentId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.Navigation("LinkedShift");
|
|
|
|
b.Navigation("LinkedTalent");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Review", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.Facility", "Facility")
|
|
.WithMany()
|
|
.HasForeignKey("FacilityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.User", "User")
|
|
.WithMany()
|
|
.HasForeignKey("UserId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Facility");
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Shift", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.Facility", "Facility")
|
|
.WithMany("Shifts")
|
|
.HasForeignKey("FacilityId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany("Shifts")
|
|
.HasForeignKey("RoleId")
|
|
.OnDelete(DeleteBehavior.Restrict)
|
|
.IsRequired();
|
|
|
|
b.Navigation("Facility");
|
|
|
|
b.Navigation("Role");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.TalentListing", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany()
|
|
.HasForeignKey("CityId")
|
|
.OnDelete(DeleteBehavior.Restrict)
|
|
.IsRequired();
|
|
|
|
b.HasOne("JobsMedical.Web.Models.District", "District")
|
|
.WithMany()
|
|
.HasForeignKey("DistrictId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany()
|
|
.HasForeignKey("RoleId")
|
|
.OnDelete(DeleteBehavior.Restrict)
|
|
.IsRequired();
|
|
|
|
b.Navigation("City");
|
|
|
|
b.Navigation("District");
|
|
|
|
b.Navigation("Role");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.UserPreferences", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.City", "City")
|
|
.WithMany()
|
|
.HasForeignKey("CityId");
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Role", "Role")
|
|
.WithMany()
|
|
.HasForeignKey("RoleId");
|
|
|
|
b.HasOne("JobsMedical.Web.Models.Visitor", "Visitor")
|
|
.WithOne("Preferences")
|
|
.HasForeignKey("JobsMedical.Web.Models.UserPreferences", "VisitorId")
|
|
.OnDelete(DeleteBehavior.Cascade)
|
|
.IsRequired();
|
|
|
|
b.Navigation("City");
|
|
|
|
b.Navigation("Role");
|
|
|
|
b.Navigation("Visitor");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Visitor", b =>
|
|
{
|
|
b.HasOne("JobsMedical.Web.Models.User", "User")
|
|
.WithMany()
|
|
.HasForeignKey("UserId")
|
|
.OnDelete(DeleteBehavior.SetNull);
|
|
|
|
b.Navigation("User");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.City", b =>
|
|
{
|
|
b.Navigation("Facilities");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.District", b =>
|
|
{
|
|
b.Navigation("Facilities");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Facility", b =>
|
|
{
|
|
b.Navigation("Documents");
|
|
|
|
b.Navigation("Shifts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.JobOpening", b =>
|
|
{
|
|
b.Navigation("Contacts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Role", b =>
|
|
{
|
|
b.Navigation("Shifts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Shift", b =>
|
|
{
|
|
b.Navigation("Applications");
|
|
|
|
b.Navigation("Contacts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.TalentListing", b =>
|
|
{
|
|
b.Navigation("Contacts");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.User", b =>
|
|
{
|
|
b.Navigation("Applications");
|
|
|
|
b.Navigation("DoctorProfile");
|
|
});
|
|
|
|
modelBuilder.Entity("JobsMedical.Web.Models.Visitor", b =>
|
|
{
|
|
b.Navigation("Events");
|
|
|
|
b.Navigation("Preferences");
|
|
});
|
|
#pragma warning restore 612, 618
|
|
}
|
|
}
|
|
}
|