I18n через jsonb-поля
This commit is contained in:
@@ -22,7 +22,6 @@ namespace Pf2eModel.Migrations
|
||||
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
||||
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "action_category", new[] { "unknown", "archetype", "class-feature", "class-feat", "offensive", "defensive", "interaction", "familiar", "army_tactic", "army_war_action", "kingdom_activity", "kingdom_feat", "kingdom_feature" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "alias_type", new[] { "legacy", "english", "legacy_english", "hobby", "other" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "ancestry_vision", new[] { "normal", "low-light-vision", "dark-vision" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "attribute_values", new[] { "free", "str", "dex", "con", "int", "wis", "cha" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "class_progression_type", new[] { "entity", "ancestry_feat", "class_feat", "general_feat", "skill_feat", "skill_increase" });
|
||||
@@ -34,6 +33,7 @@ namespace Pf2eModel.Migrations
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "entity_type", new[] { "unknown", "trait", "action", "ancestry", "archetype", "background", "backpack", "campaign_feature", "class", "condition", "deity", "feat", "heritage", "spell", "language" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "feat_action_type", new[] { "passive", "action", "reaction", "free" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "feat_category", new[] { "uncategorized", "ancestry-feature", "class-feature", "calling", "class", "skill", "general", "ancestry", "bonus", "deityboon", "curse", "pfsboon", "campaign-feature" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "locale_type", new[] { "english", "legacy_english", "russian", "legacy", "hobby", "other" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "size", new[] { "tiny", "small", "medium", "large" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "source_category", new[] { "rulebook", "adventure-path", "lost-omens", "adventures", "comics", "blog-posts", "society" });
|
||||
NpgsqlModelBuilderExtensions.HasPostgresEnum(modelBuilder, "spell_area_type", new[] { "burst", "emanation", "cone", "line", "square", "cube", "cylinder" });
|
||||
@@ -139,8 +139,7 @@ namespace Pf2eModel.Migrations
|
||||
|
||||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasMaxLength(255)
|
||||
.HasColumnType("character varying(255)")
|
||||
.HasColumnType("jsonb")
|
||||
.HasColumnName("name")
|
||||
.HasColumnOrder(2)
|
||||
.HasComment("Отображаемое имя");
|
||||
@@ -170,31 +169,6 @@ namespace Pf2eModel.Migrations
|
||||
b.ToTable("entities", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Pf2eModel.Model.Base.EntityAlias", b =>
|
||||
{
|
||||
b.Property<int>("EntityId")
|
||||
.HasColumnType("integer")
|
||||
.HasColumnName("entity_id")
|
||||
.HasColumnOrder(1);
|
||||
|
||||
b.Property<AliasType>("Type")
|
||||
.HasColumnType("alias_type")
|
||||
.HasColumnName("type")
|
||||
.HasColumnOrder(2);
|
||||
|
||||
b.Property<string>("Alias")
|
||||
.IsRequired()
|
||||
.HasMaxLength(255)
|
||||
.HasColumnType("character varying(255)")
|
||||
.HasColumnName("alias")
|
||||
.HasColumnOrder(3);
|
||||
|
||||
b.HasKey("EntityId", "Type")
|
||||
.HasName("pk_entity_aliases");
|
||||
|
||||
b.ToTable("entity_aliases", (string)null);
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Pf2eModel.Model.Base.Keywords.Keyword", b =>
|
||||
{
|
||||
b.Property<int>("Id")
|
||||
@@ -1533,18 +1507,6 @@ namespace Pf2eModel.Migrations
|
||||
.HasConstraintName("fk_entity_trait_traits_traits_id");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Pf2eModel.Model.Base.EntityAlias", b =>
|
||||
{
|
||||
b.HasOne("Pf2eModel.Model.Base.Entity", "Entity")
|
||||
.WithMany("Aliases")
|
||||
.HasForeignKey("EntityId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired()
|
||||
.HasConstraintName("fk_entity_aliases_entities_entity_id");
|
||||
|
||||
b.Navigation("Entity");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("Pf2eModel.Model.Base.Keywords.KeywordAlias", b =>
|
||||
{
|
||||
b.HasOne("Pf2eModel.Model.Base.Keywords.Keyword", "Keyword")
|
||||
@@ -2053,8 +2015,6 @@ namespace Pf2eModel.Migrations
|
||||
|
||||
modelBuilder.Entity("Pf2eModel.Model.Base.Entity", b =>
|
||||
{
|
||||
b.Navigation("Aliases");
|
||||
|
||||
b.Navigation("Externals");
|
||||
|
||||
b.Navigation("Sources");
|
||||
|
||||
Reference in New Issue
Block a user