[f33b0d4] | 1 | // <auto-generated />
|
---|
| 2 | using System;
|
---|
| 3 | using FarmatikoData;
|
---|
| 4 | using Microsoft.EntityFrameworkCore;
|
---|
| 5 | using Microsoft.EntityFrameworkCore.Infrastructure;
|
---|
| 6 | using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
|
---|
| 7 | using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
|
---|
| 8 |
|
---|
| 9 | namespace FarmatikoData.Migrations
|
---|
| 10 | {
|
---|
| 11 | [DbContext(typeof(FarmatikoDataContext))]
|
---|
| 12 | partial class FarmatikoDataContextModelSnapshot : ModelSnapshot
|
---|
| 13 | {
|
---|
| 14 | protected override void BuildModel(ModelBuilder modelBuilder)
|
---|
| 15 | {
|
---|
| 16 | #pragma warning disable 612, 618
|
---|
| 17 | modelBuilder
|
---|
| 18 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn)
|
---|
| 19 | .HasAnnotation("ProductVersion", "3.1.6")
|
---|
| 20 | .HasAnnotation("Relational:MaxIdentifierLength", 63);
|
---|
| 21 |
|
---|
| 22 | modelBuilder.Entity("FarmatikoData.Models.HealthFacilities", b =>
|
---|
| 23 | {
|
---|
| 24 | b.Property<int>("Id")
|
---|
| 25 | .ValueGeneratedOnAdd()
|
---|
| 26 | .HasColumnType("integer")
|
---|
| 27 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 28 |
|
---|
| 29 | b.Property<string>("Address")
|
---|
| 30 | .IsRequired()
|
---|
| 31 | .HasColumnType("text");
|
---|
| 32 |
|
---|
| 33 | b.Property<DateTime>("CreatedOn")
|
---|
| 34 | .HasColumnType("timestamp without time zone");
|
---|
| 35 |
|
---|
| 36 | b.Property<DateTime>("DeletedOn")
|
---|
| 37 | .HasColumnType("timestamp without time zone");
|
---|
| 38 |
|
---|
| 39 | b.Property<string>("Email")
|
---|
| 40 | .HasColumnType("text");
|
---|
| 41 |
|
---|
| 42 | b.Property<string>("Municipality")
|
---|
| 43 | .IsRequired()
|
---|
| 44 | .HasColumnType("text");
|
---|
| 45 |
|
---|
| 46 | b.Property<string>("Name")
|
---|
| 47 | .IsRequired()
|
---|
| 48 | .HasColumnType("text");
|
---|
| 49 |
|
---|
| 50 | b.Property<string>("Phone")
|
---|
| 51 | .HasColumnType("text");
|
---|
| 52 |
|
---|
| 53 | b.Property<string>("Type")
|
---|
| 54 | .IsRequired()
|
---|
| 55 | .HasColumnType("text");
|
---|
| 56 |
|
---|
| 57 | b.HasKey("Id");
|
---|
| 58 |
|
---|
| 59 | b.ToTable("HealthFacilities");
|
---|
| 60 | });
|
---|
| 61 |
|
---|
| 62 | modelBuilder.Entity("FarmatikoData.Models.HealthcareWorkers", b =>
|
---|
| 63 | {
|
---|
| 64 | b.Property<int>("Id")
|
---|
| 65 | .ValueGeneratedOnAdd()
|
---|
| 66 | .HasColumnType("integer")
|
---|
| 67 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 68 |
|
---|
| 69 | b.Property<string>("Branch")
|
---|
| 70 | .IsRequired()
|
---|
| 71 | .HasColumnType("text");
|
---|
| 72 |
|
---|
| 73 | b.Property<DateTime>("CreatedOn")
|
---|
| 74 | .HasColumnType("timestamp without time zone");
|
---|
| 75 |
|
---|
| 76 | b.Property<DateTime>("DeletedOn")
|
---|
| 77 | .HasColumnType("timestamp without time zone");
|
---|
| 78 |
|
---|
| 79 | b.Property<int>("FacilityId")
|
---|
| 80 | .HasColumnType("integer");
|
---|
| 81 |
|
---|
| 82 | b.Property<string>("Name")
|
---|
| 83 | .IsRequired()
|
---|
| 84 | .HasColumnType("text");
|
---|
| 85 |
|
---|
| 86 | b.Property<string>("Title")
|
---|
| 87 | .HasColumnType("text");
|
---|
| 88 |
|
---|
| 89 | b.HasKey("Id");
|
---|
| 90 |
|
---|
| 91 | b.HasIndex("FacilityId");
|
---|
| 92 |
|
---|
| 93 | b.ToTable("HealthcareWorkers");
|
---|
| 94 | });
|
---|
| 95 |
|
---|
| 96 | modelBuilder.Entity("FarmatikoData.Models.Medicine", b =>
|
---|
| 97 | {
|
---|
| 98 | b.Property<int>("Id")
|
---|
| 99 | .ValueGeneratedOnAdd()
|
---|
| 100 | .HasColumnType("integer")
|
---|
| 101 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 102 |
|
---|
| 103 | b.Property<DateTime>("CreatedOn")
|
---|
| 104 | .HasColumnType("timestamp without time zone");
|
---|
| 105 |
|
---|
| 106 | b.Property<DateTime>("DeletedOn")
|
---|
| 107 | .HasColumnType("timestamp without time zone");
|
---|
| 108 |
|
---|
| 109 | b.Property<string>("Form")
|
---|
| 110 | .HasColumnType("text");
|
---|
| 111 |
|
---|
| 112 | b.Property<string>("Manufacturer")
|
---|
| 113 | .HasColumnType("text");
|
---|
| 114 |
|
---|
| 115 | b.Property<int?>("MedicineListId")
|
---|
| 116 | .HasColumnType("integer");
|
---|
| 117 |
|
---|
| 118 | b.Property<string>("Name")
|
---|
| 119 | .HasColumnType("text");
|
---|
| 120 |
|
---|
| 121 | b.Property<string>("Packaging")
|
---|
| 122 | .HasColumnType("text");
|
---|
| 123 |
|
---|
| 124 | b.Property<float>("Price")
|
---|
| 125 | .HasColumnType("real");
|
---|
| 126 |
|
---|
| 127 | b.Property<string>("Strength")
|
---|
| 128 | .HasColumnType("text");
|
---|
| 129 |
|
---|
| 130 | b.Property<string>("WayOfIssuing")
|
---|
| 131 | .HasColumnType("text");
|
---|
| 132 |
|
---|
| 133 | b.HasKey("Id");
|
---|
| 134 |
|
---|
| 135 | b.HasIndex("MedicineListId");
|
---|
| 136 |
|
---|
| 137 | b.ToTable("Medicines");
|
---|
| 138 | });
|
---|
| 139 |
|
---|
| 140 | modelBuilder.Entity("FarmatikoData.Models.MedicineList", b =>
|
---|
| 141 | {
|
---|
| 142 | b.Property<int>("Id")
|
---|
| 143 | .ValueGeneratedOnAdd()
|
---|
| 144 | .HasColumnType("integer")
|
---|
| 145 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 146 |
|
---|
| 147 | b.Property<DateTime>("CreatedOn")
|
---|
| 148 | .HasColumnType("timestamp without time zone");
|
---|
| 149 |
|
---|
| 150 | b.Property<DateTime>("DeletedOn")
|
---|
| 151 | .HasColumnType("timestamp without time zone");
|
---|
| 152 |
|
---|
| 153 | b.Property<bool>("HasMedicine")
|
---|
| 154 | .HasColumnType("boolean");
|
---|
| 155 |
|
---|
| 156 | b.Property<int?>("MedicineId")
|
---|
| 157 | .HasColumnType("integer");
|
---|
| 158 |
|
---|
| 159 | b.Property<int?>("PharmacyHeadId")
|
---|
| 160 | .HasColumnType("integer");
|
---|
| 161 |
|
---|
| 162 | b.HasKey("Id");
|
---|
| 163 |
|
---|
| 164 | b.HasIndex("MedicineId");
|
---|
| 165 |
|
---|
| 166 | b.HasIndex("PharmacyHeadId");
|
---|
| 167 |
|
---|
| 168 | b.ToTable("MedicineLists");
|
---|
| 169 | });
|
---|
| 170 |
|
---|
| 171 | modelBuilder.Entity("FarmatikoData.Models.Pandemic", b =>
|
---|
| 172 | {
|
---|
| 173 | b.Property<int>("Id")
|
---|
| 174 | .ValueGeneratedOnAdd()
|
---|
| 175 | .HasColumnType("integer")
|
---|
| 176 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 177 |
|
---|
| 178 | b.Property<int>("ActiveGlobal")
|
---|
| 179 | .HasColumnType("integer");
|
---|
| 180 |
|
---|
| 181 | b.Property<int>("ActiveMK")
|
---|
| 182 | .HasColumnType("integer");
|
---|
| 183 |
|
---|
| 184 | b.Property<DateTime>("CreatedOn")
|
---|
| 185 | .HasColumnType("timestamp without time zone");
|
---|
| 186 |
|
---|
| 187 | b.Property<int>("DeathsGlobal")
|
---|
| 188 | .HasColumnType("integer");
|
---|
| 189 |
|
---|
| 190 | b.Property<int>("DeathsMK")
|
---|
| 191 | .HasColumnType("integer");
|
---|
| 192 |
|
---|
| 193 | b.Property<DateTime>("DeletedOn")
|
---|
| 194 | .HasColumnType("timestamp without time zone");
|
---|
| 195 |
|
---|
| 196 | b.Property<string>("Name")
|
---|
| 197 | .HasColumnType("text");
|
---|
| 198 |
|
---|
| 199 | b.Property<int>("NewMK")
|
---|
| 200 | .HasColumnType("integer");
|
---|
| 201 |
|
---|
| 202 | b.Property<int>("TotalGlobal")
|
---|
| 203 | .HasColumnType("integer");
|
---|
| 204 |
|
---|
| 205 | b.Property<int>("TotalMK")
|
---|
| 206 | .HasColumnType("integer");
|
---|
| 207 |
|
---|
| 208 | b.HasKey("Id");
|
---|
| 209 |
|
---|
| 210 | b.ToTable("Pandemics");
|
---|
| 211 | });
|
---|
| 212 |
|
---|
| 213 | modelBuilder.Entity("FarmatikoData.Models.Pharmacy", b =>
|
---|
| 214 | {
|
---|
| 215 | b.Property<int>("Id")
|
---|
| 216 | .ValueGeneratedOnAdd()
|
---|
| 217 | .HasColumnType("integer")
|
---|
| 218 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 219 |
|
---|
| 220 | b.Property<string>("Address")
|
---|
| 221 | .IsRequired()
|
---|
| 222 | .HasColumnType("text");
|
---|
| 223 |
|
---|
| 224 | b.Property<DateTime>("CreatedOn")
|
---|
| 225 | .HasColumnType("timestamp without time zone");
|
---|
| 226 |
|
---|
| 227 | b.Property<DateTime>("DeletedOn")
|
---|
| 228 | .HasColumnType("timestamp without time zone");
|
---|
| 229 |
|
---|
| 230 | b.Property<string>("Location")
|
---|
| 231 | .IsRequired()
|
---|
| 232 | .HasColumnType("text");
|
---|
| 233 |
|
---|
| 234 | b.Property<string>("Name")
|
---|
| 235 | .IsRequired()
|
---|
| 236 | .HasColumnType("text");
|
---|
| 237 |
|
---|
| 238 | b.Property<int?>("PharmacyHeadId")
|
---|
| 239 | .HasColumnType("integer");
|
---|
| 240 |
|
---|
| 241 | b.Property<bool>("WorkAllTime")
|
---|
| 242 | .HasColumnType("boolean");
|
---|
| 243 |
|
---|
| 244 | b.HasKey("Id");
|
---|
| 245 |
|
---|
| 246 | b.HasIndex("PharmacyHeadId");
|
---|
| 247 |
|
---|
| 248 | b.ToTable("Pharmacies");
|
---|
| 249 | });
|
---|
| 250 |
|
---|
| 251 | modelBuilder.Entity("FarmatikoData.Models.PharmacyHead", b =>
|
---|
| 252 | {
|
---|
| 253 | b.Property<int>("Id")
|
---|
| 254 | .ValueGeneratedOnAdd()
|
---|
| 255 | .HasColumnType("integer")
|
---|
| 256 | .HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
|
---|
| 257 |
|
---|
| 258 | b.Property<DateTime>("CreatedOn")
|
---|
| 259 | .HasColumnType("timestamp without time zone");
|
---|
| 260 |
|
---|
| 261 | b.Property<DateTime>("DeletedOn")
|
---|
| 262 | .HasColumnType("timestamp without time zone");
|
---|
| 263 |
|
---|
| 264 | b.Property<string>("Email")
|
---|
| 265 | .HasColumnType("text");
|
---|
| 266 |
|
---|
| 267 | b.Property<string>("Name")
|
---|
| 268 | .HasColumnType("text");
|
---|
| 269 |
|
---|
| 270 | b.Property<string>("Password")
|
---|
| 271 | .HasColumnType("text");
|
---|
| 272 |
|
---|
| 273 | b.Property<int?>("PharmacyId")
|
---|
| 274 | .HasColumnType("integer");
|
---|
| 275 |
|
---|
| 276 | b.Property<int?>("PharmacyMedicinesId")
|
---|
| 277 | .HasColumnType("integer");
|
---|
| 278 |
|
---|
| 279 | b.HasKey("Id");
|
---|
| 280 |
|
---|
| 281 | b.HasIndex("PharmacyId");
|
---|
| 282 |
|
---|
| 283 | b.HasIndex("PharmacyMedicinesId");
|
---|
| 284 |
|
---|
| 285 | b.ToTable("PharmacyHeads");
|
---|
| 286 | });
|
---|
| 287 |
|
---|
| 288 | modelBuilder.Entity("FarmatikoData.Models.HealthcareWorkers", b =>
|
---|
| 289 | {
|
---|
| 290 | b.HasOne("FarmatikoData.Models.HealthFacilities", "Facility")
|
---|
| 291 | .WithMany()
|
---|
| 292 | .HasForeignKey("FacilityId")
|
---|
| 293 | .OnDelete(DeleteBehavior.Cascade)
|
---|
| 294 | .IsRequired();
|
---|
| 295 | });
|
---|
| 296 |
|
---|
| 297 | modelBuilder.Entity("FarmatikoData.Models.Medicine", b =>
|
---|
| 298 | {
|
---|
| 299 | b.HasOne("FarmatikoData.Models.MedicineList", null)
|
---|
| 300 | .WithMany("MedicinesList")
|
---|
| 301 | .HasForeignKey("MedicineListId");
|
---|
| 302 | });
|
---|
| 303 |
|
---|
| 304 | modelBuilder.Entity("FarmatikoData.Models.MedicineList", b =>
|
---|
| 305 | {
|
---|
| 306 | b.HasOne("FarmatikoData.Models.Medicine", "Medicine")
|
---|
| 307 | .WithMany()
|
---|
| 308 | .HasForeignKey("MedicineId");
|
---|
| 309 |
|
---|
| 310 | b.HasOne("FarmatikoData.Models.PharmacyHead", null)
|
---|
| 311 | .WithMany("MedicineLists")
|
---|
| 312 | .HasForeignKey("PharmacyHeadId");
|
---|
| 313 | });
|
---|
| 314 |
|
---|
| 315 | modelBuilder.Entity("FarmatikoData.Models.Pharmacy", b =>
|
---|
| 316 | {
|
---|
| 317 | b.HasOne("FarmatikoData.Models.PharmacyHead", null)
|
---|
| 318 | .WithMany("PharmaciesList")
|
---|
| 319 | .HasForeignKey("PharmacyHeadId");
|
---|
| 320 | });
|
---|
| 321 |
|
---|
| 322 | modelBuilder.Entity("FarmatikoData.Models.PharmacyHead", b =>
|
---|
| 323 | {
|
---|
| 324 | b.HasOne("FarmatikoData.Models.Pharmacy", "Pharmacy")
|
---|
| 325 | .WithMany()
|
---|
| 326 | .HasForeignKey("PharmacyId");
|
---|
| 327 |
|
---|
| 328 | b.HasOne("FarmatikoData.Models.MedicineList", "PharmacyMedicines")
|
---|
| 329 | .WithMany()
|
---|
| 330 | .HasForeignKey("PharmacyMedicinesId");
|
---|
| 331 | });
|
---|
| 332 | #pragma warning restore 612, 618
|
---|
| 333 | }
|
---|
| 334 | }
|
---|
| 335 | }
|
---|