DocSpace-client/common/ASC.Core.Common/Migrations/Npgsql/VoipDbContextNpgsql/VoipDbContextModelSnapshot.cs
2020-10-06 14:39:44 +03:00

285 lines
11 KiB
C#

// <auto-generated />
using System;
using ASC.Core.Common.EF.Context;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Npgsql.EntityFrameworkCore.PostgreSQL.Metadata;
namespace ASC.Core.Common.Migrations.Npgsql.VoipDbContextNpgsql
{
[DbContext(typeof(PostgreSqlVoipDbContext))]
partial class VoipDbContextModelSnapshot : ModelSnapshot
{
protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn)
.HasAnnotation("ProductVersion", "3.1.8")
.HasAnnotation("Relational:MaxIdentifierLength", 63);
modelBuilder.Entity("ASC.Core.Common.EF.Model.CrmContact", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd()
.HasColumnName("id")
.HasColumnType("integer")
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.IdentityByDefaultColumn);
b.Property<int>("CompanyId")
.HasColumnName("company_id")
.HasColumnType("integer");
b.Property<string>("CompanyName")
.ValueGeneratedOnAdd()
.HasColumnName("company_name")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL::character varying")
.HasMaxLength(255);
b.Property<int>("ContactTypeId")
.HasColumnName("contact_type_id")
.HasColumnType("integer");
b.Property<Guid>("CreateBy")
.HasColumnName("create_by")
.HasColumnType("uuid")
.IsFixedLength(true)
.HasMaxLength(38);
b.Property<DateTime>("CreateOn")
.HasColumnName("create_on")
.HasColumnType("timestamp without time zone");
b.Property<string>("Currency")
.ValueGeneratedOnAdd()
.HasColumnName("currency")
.HasColumnType("character varying(3)")
.HasDefaultValueSql("NULL")
.HasMaxLength(3);
b.Property<string>("DisplayName")
.ValueGeneratedOnAdd()
.HasColumnName("display_name")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.Property<string>("FirstName")
.ValueGeneratedOnAdd()
.HasColumnName("first_name")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.Property<string>("Industry")
.ValueGeneratedOnAdd()
.HasColumnName("industry")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.Property<bool>("IsCompany")
.HasColumnName("is_company")
.HasColumnType("boolean");
b.Property<bool>("IsShared")
.HasColumnName("is_shared")
.HasColumnType("boolean");
b.Property<Guid>("LastModifedBy")
.ValueGeneratedOnAdd()
.HasColumnName("last_modifed_by")
.HasColumnType("uuid")
.HasDefaultValueSql("NULL")
.HasMaxLength(38);
b.Property<DateTime>("LastModifedOn")
.ValueGeneratedOnAdd()
.HasColumnName("last_modifed_on")
.HasColumnType("timestamp without time zone")
.HasDefaultValueSql("NULL");
b.Property<string>("LastName")
.ValueGeneratedOnAdd()
.HasColumnName("last_name")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.Property<string>("Notes")
.HasColumnName("notes")
.HasColumnType("text");
b.Property<int>("StatusId")
.HasColumnName("status_id")
.HasColumnType("integer");
b.Property<int>("TenantId")
.HasColumnName("tenant_id")
.HasColumnType("integer");
b.Property<string>("Title")
.ValueGeneratedOnAdd()
.HasColumnName("title")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.HasKey("Id");
b.HasIndex("CreateOn")
.HasName("create_on_crm_contact");
b.HasIndex("LastModifedOn", "TenantId")
.HasName("last_modifed_on_crm_contact");
b.HasIndex("TenantId", "CompanyId")
.HasName("company_id");
b.HasIndex("TenantId", "DisplayName")
.HasName("display_name");
b.ToTable("crm_contact","onlyoffice");
});
modelBuilder.Entity("ASC.Core.Common.EF.Model.DbVoipCall", b =>
{
b.Property<string>("Id")
.HasColumnName("id")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<Guid>("AnsweredBy")
.ValueGeneratedOnAdd()
.HasColumnName("answered_by")
.HasColumnType("uuid")
.HasDefaultValueSql("'00000000-0000-0000-0000-000000000000'")
.HasMaxLength(50);
b.Property<int>("ContactId")
.HasColumnName("contact_id")
.HasColumnType("integer");
b.Property<int?>("CrmContactId")
.HasColumnType("integer");
b.Property<DateTime>("DialDate")
.HasColumnName("dial_date")
.HasColumnType("timestamp without time zone");
b.Property<int>("DialDuration")
.HasColumnName("dial_duration")
.HasColumnType("integer");
b.Property<string>("NumberFrom")
.IsRequired()
.HasColumnName("number_from")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<string>("NumberTo")
.IsRequired()
.HasColumnName("number_to")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<string>("ParentCallId")
.IsRequired()
.HasColumnName("parent_call_id")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<decimal>("Price")
.ValueGeneratedOnAdd()
.HasColumnName("price")
.HasColumnType("numeric(10,4)")
.HasDefaultValueSql("NULL");
b.Property<int>("RecordDuration")
.HasColumnName("record_duration")
.HasColumnType("integer");
b.Property<decimal>("RecordPrice")
.HasColumnName("record_price")
.HasColumnType("numeric(10,4)");
b.Property<string>("RecordSid")
.ValueGeneratedOnAdd()
.HasColumnName("record_sid")
.HasColumnType("character varying(50)")
.HasDefaultValueSql("NULL")
.HasMaxLength(50);
b.Property<string>("RecordUrl")
.HasColumnName("record_url")
.HasColumnType("text");
b.Property<int>("Status")
.HasColumnName("status")
.HasColumnType("integer");
b.Property<int>("TenantId")
.HasColumnName("tenant_id")
.HasColumnType("integer");
b.HasKey("Id");
b.HasIndex("CrmContactId");
b.HasIndex("TenantId")
.HasName("tenant_id_crm_voip_calls");
b.HasIndex("ParentCallId", "TenantId")
.HasName("parent_call_id");
b.ToTable("crm_voip_calls","onlyoffice");
});
modelBuilder.Entity("ASC.Core.Common.EF.Model.VoipNumber", b =>
{
b.Property<string>("Id")
.HasColumnName("id")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<string>("Alias")
.ValueGeneratedOnAdd()
.HasColumnName("alias")
.HasColumnType("character varying(255)")
.HasDefaultValueSql("NULL")
.HasMaxLength(255);
b.Property<string>("Number")
.IsRequired()
.HasColumnName("number")
.HasColumnType("character varying(50)")
.HasMaxLength(50);
b.Property<string>("Settings")
.HasColumnName("settings")
.HasColumnType("text");
b.Property<int>("TenantId")
.HasColumnName("tenant_id")
.HasColumnType("integer");
b.HasKey("Id");
b.HasIndex("TenantId")
.HasName("tenant_id_crm_voip_number");
b.ToTable("crm_voip_number","onlyoffice");
});
modelBuilder.Entity("ASC.Core.Common.EF.Model.DbVoipCall", b =>
{
b.HasOne("ASC.Core.Common.EF.Model.CrmContact", "CrmContact")
.WithMany()
.HasForeignKey("CrmContactId");
});
#pragma warning restore 612, 618
}
}
}