From 07df03c0c105935b5ac0c834c25b9f6526d1366f Mon Sep 17 00:00:00 2001 From: hyeon Date: Tue, 17 Oct 2023 22:15:54 +0900 Subject: [PATCH 01/13] Add item enhancement result --- ...25653_AddItemEnhancementResult.Designer.cs | 2829 +++++++++++++++++ ...20231017125653_AddItemEnhancementResult.cs | 45 + .../NineChroniclesContextModelSnapshot.cs | 9 + .../DataRendering/itemEnhancementData.cs | 10 +- .../Store/Models/ItemEnhancementModel.cs | 7 +- 5 files changed, 2897 insertions(+), 3 deletions(-) create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.Designer.cs create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.cs diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.Designer.cs b/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.Designer.cs new file mode 100644 index 00000000..450e634e --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.Designer.cs @@ -0,0 +1,2829 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using NineChronicles.DataProvider.Store; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + [DbContext(typeof(NineChroniclesContext))] + [Migration("20231017125653_AddItemEnhancementResult")] + partial class AddItemEnhancementResult + { + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "6.0.1") + .HasAnnotation("Relational:MaxIdentifierLength", 64); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AbilityRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("AbilityRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AgentModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.HasKey("Address"); + + b.ToTable("Agents"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Exception") + .HasColumnType("longtext"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummonFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.Property("SummonResult") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummons"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.HasKey("Address"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Avatars"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("EnemyAvatarAddress") + .HasColumnType("longtext"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("TicketCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaRankingModel", b => + { + b.Property("AdditionalTicketPrice") + .HasColumnType("bigint"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArenaType") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EndBlockIndex") + .HasColumnType("bigint"); + + b.Property("EntranceFee") + .HasColumnType("bigint"); + + b.Property("LossCount") + .HasColumnType("int"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("PurchasedTicketCount") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("RequiredMedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("Score") + .HasColumnType("int"); + + b.Property("StartBlockIndex") + .HasColumnType("bigint"); + + b.Property("Ticket") + .HasColumnType("int"); + + b.Property("TicketPrice") + .HasColumnType("bigint"); + + b.Property("TicketResetCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.Property("WinCount") + .HasColumnType("int"); + + b.ToTable("BattleArenaRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EnemyAvatarAddress") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("GrandFinaleId") + .HasColumnType("int"); + + b.Property("GrandFinaleScore") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleGrandFinales"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BlockModel", b => + { + b.Property("Hash") + .HasColumnType("varchar(255)"); + + b.Property("Difficulty") + .HasColumnType("bigint"); + + b.Property("Index") + .HasColumnType("bigint"); + + b.Property("Miner") + .HasColumnType("longtext"); + + b.Property("Nonce") + .HasColumnType("longtext"); + + b.Property("PreviousHash") + .HasColumnType("longtext"); + + b.Property("ProtocolVersion") + .HasColumnType("int"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("StateRootHash") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TotalDifficulty") + .HasColumnType("bigint"); + + b.Property("TxCount") + .HasColumnType("int"); + + b.Property("TxHash") + .HasColumnType("longtext"); + + b.HasKey("Hash"); + + b.ToTable("Blocks"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApPotionCount") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimRewardAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ClaimStakeEndBlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("HourGlassCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.ToTable("ClaimStakeRewards"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("SubRecipeId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingInputModel", b => + { + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CraftCount") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.HasKey("AvatarAddress"); + + b.ToTable("CraftRankings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingOutputModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CraftCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("CraftRankingsOutput"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.HasKey("ItemId"); + + b.ToTable("Equipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("EventConsumableItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("RequiredItem1Count") + .HasColumnType("int"); + + b.Property("RequiredItem1Id") + .HasColumnType("int"); + + b.Property("RequiredItem2Count") + .HasColumnType("int"); + + b.Property("RequiredItem2Id") + .HasColumnType("int"); + + b.Property("RequiredItem3Count") + .HasColumnType("int"); + + b.Property("RequiredItem3Id") + .HasColumnType("int"); + + b.Property("RequiredItem4Count") + .HasColumnType("int"); + + b.Property("RequiredItem4Id") + .HasColumnType("int"); + + b.Property("RequiredItem5Count") + .HasColumnType("int"); + + b.Property("RequiredItem5Id") + .HasColumnType("int"); + + b.Property("RequiredItem6Count") + .HasColumnType("int"); + + b.Property("RequiredItem6Id") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventConsumableItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("EventDungeonId") + .HasColumnType("int"); + + b.Property("EventDungeonStageId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("FoodsCount") + .HasColumnType("int"); + + b.Property("RemainingTickets") + .HasColumnType("int"); + + b.Property("RewardItem10Count") + .HasColumnType("int"); + + b.Property("RewardItem10Id") + .HasColumnType("int"); + + b.Property("RewardItem1Count") + .HasColumnType("int"); + + b.Property("RewardItem1Id") + .HasColumnType("int"); + + b.Property("RewardItem2Count") + .HasColumnType("int"); + + b.Property("RewardItem2Id") + .HasColumnType("int"); + + b.Property("RewardItem3Count") + .HasColumnType("int"); + + b.Property("RewardItem3Id") + .HasColumnType("int"); + + b.Property("RewardItem4Count") + .HasColumnType("int"); + + b.Property("RewardItem4Id") + .HasColumnType("int"); + + b.Property("RewardItem5Count") + .HasColumnType("int"); + + b.Property("RewardItem5Id") + .HasColumnType("int"); + + b.Property("RewardItem6Count") + .HasColumnType("int"); + + b.Property("RewardItem6Id") + .HasColumnType("int"); + + b.Property("RewardItem7Count") + .HasColumnType("int"); + + b.Property("RewardItem7Id") + .HasColumnType("int"); + + b.Property("RewardItem8Count") + .HasColumnType("int"); + + b.Property("RewardItem8Id") + .HasColumnType("int"); + + b.Property("RewardItem9Count") + .HasColumnType("int"); + + b.Property("RewardItem9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventDungeonBattles"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EventMaterialItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("Material10Count") + .HasColumnType("int"); + + b.Property("Material10Id") + .HasColumnType("int"); + + b.Property("Material11Count") + .HasColumnType("int"); + + b.Property("Material11Id") + .HasColumnType("int"); + + b.Property("Material12Count") + .HasColumnType("int"); + + b.Property("Material12Id") + .HasColumnType("int"); + + b.Property("Material1Count") + .HasColumnType("int"); + + b.Property("Material1Id") + .HasColumnType("int"); + + b.Property("Material2Count") + .HasColumnType("int"); + + b.Property("Material2Id") + .HasColumnType("int"); + + b.Property("Material3Count") + .HasColumnType("int"); + + b.Property("Material3Id") + .HasColumnType("int"); + + b.Property("Material4Count") + .HasColumnType("int"); + + b.Property("Material4Id") + .HasColumnType("int"); + + b.Property("Material5Count") + .HasColumnType("int"); + + b.Property("Material5Id") + .HasColumnType("int"); + + b.Property("Material6Count") + .HasColumnType("int"); + + b.Property("Material6Id") + .HasColumnType("int"); + + b.Property("Material7Count") + .HasColumnType("int"); + + b.Property("Material7Id") + .HasColumnType("int"); + + b.Property("Material8Count") + .HasColumnType("int"); + + b.Property("Material8Id") + .HasColumnType("int"); + + b.Property("Material9Count") + .HasColumnType("int"); + + b.Property("Material9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventMaterialItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Crystal") + .HasColumnType("decimal(65,30)"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("Grindings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionPoint") + .HasColumnType("int"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApStoneCount") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("WorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashSweeps"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("GachaCount") + .HasColumnType("int"); + + b.Property("HasStageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffId") + .HasColumnType("int"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasWithRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("GainedCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("MaterialItemId") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancementFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Exp") + .HasColumnType("bigint"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("MaterialId") + .HasColumnType("longtext"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("SheetId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArenaRound") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("JoinArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("MigrationAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("MigrationStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("StakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("MigrateMonsterCollections"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntSoulStone") + .HasColumnType("decimal(65,30)"); + + b.Property("ChangedLevel") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("OutputPetLevel") + .HasColumnType("int"); + + b.Property("PetId") + .HasColumnType("int"); + + b.Property("PreviousPetLevel") + .HasColumnType("int"); + + b.Property("TargetLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("PetEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RaiderModel", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("Address") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarName") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CreatedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("PurchaseCount") + .HasColumnType("int"); + + b.Property("RaidId") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.Property("UpdatedAt") + .ValueGeneratedOnAddOrUpdate() + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("RaidId", "Address") + .IsUnique(); + + b.ToTable("Raiders"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("HourglassCount") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RapidCombinations"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("ReplacedMaterialCount") + .HasColumnType("int"); + + b.Property("ReplacedMaterialId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ReplaceCombinationEquipmentMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RequestPledgeModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("PledgeAgentAddress") + .HasColumnType("longtext"); + + b.Property("RefillMead") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxSigner") + .HasColumnType("longtext"); + + b.HasKey("TxId"); + + b.ToTable("RequestPledges"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntRune") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("OutputRuneLevel") + .HasColumnType("int"); + + b.Property("PreviousRuneLevel") + .HasColumnType("int"); + + b.Property("RuneId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TryCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RuneEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("varchar(255)"); + + b.Property("TickerType") + .HasColumnType("varchar(255)"); + + b.Property("AcquiredRune") + .HasColumnType("decimal(65,30)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id", "ActionType", "TickerType"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.HasIndex("Id", "ActionType", "TickerType") + .IsUnique(); + + b.ToTable("RunesAcquired"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopConsumableModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopCostumeModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopEquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryConsumableModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryCostumeModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryEquipmentModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryFungibleAssetValueModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("Quantity") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Ticker") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryFungibleAssetValues"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryMaterialModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopMaterialModel", b => + { + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.ToTable("ShopMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StageRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClearedStageId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("StageRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("NewAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("NewStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PrevStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PreviousAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("RemainingNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Stakings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransactionModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("longtext"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("Nonce") + .HasColumnType("bigint"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("Signer") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UpdatedAddressesCount") + .HasColumnType("int"); + + b.HasKey("TxId"); + + b.ToTable("Transactions"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransferAssetModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("Amount") + .HasColumnType("decimal(65,30)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Recipient") + .HasColumnType("longtext"); + + b.Property("Sender") + .HasColumnType("longtext"); + + b.Property("TickerType") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.ToTable("TransferAssets"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockEquipmentRecipeId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockEquipmentRecipes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockRuneSlots"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockWorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockWorlds"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossRankingModel", b => + { + b.Property("Address") + .HasColumnType("longtext"); + + b.Property("AvatarName") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.ToTable("WorldBossRankings", null, t => t.ExcludeFromMigrations()); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossSeasonMigrationModel", b => + { + b.Property("RaidId") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("MigratedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.HasKey("RaidId"); + + b.HasIndex("RaidId") + .IsUnique(); + + b.ToTable("WorldBossSeasonMigrationModels"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.cs b/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.cs new file mode 100644 index 00000000..44a2d715 --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231017125653_AddItemEnhancementResult.cs @@ -0,0 +1,45 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + public partial class AddItemEnhancementResult : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.AddColumn( + name: "Exp", + table: "ItemEnhancements", + type: "bigint", + nullable: true); + + migrationBuilder.AddColumn( + name: "Level", + table: "ItemEnhancements", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "SheetId", + table: "ItemEnhancements", + type: "int", + nullable: true); + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropColumn( + name: "Exp", + table: "ItemEnhancements"); + + migrationBuilder.DropColumn( + name: "Level", + table: "ItemEnhancements"); + + migrationBuilder.DropColumn( + name: "SheetId", + table: "ItemEnhancements"); + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs index b8aa0cff..36de3aea 100644 --- a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs +++ b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs @@ -1148,15 +1148,24 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntNCG") .HasColumnType("decimal(65,30)"); + b.Property("Exp") + .HasColumnType("bigint"); + b.Property("ItemId") .HasColumnType("longtext"); + b.Property("Level") + .HasColumnType("int"); + b.Property("MaterialId") .HasColumnType("longtext"); b.Property("MaterialIdsCount") .HasColumnType("int"); + b.Property("SheetId") + .HasColumnType("int"); + b.Property("SlotIndex") .HasColumnType("int"); diff --git a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs index 0308a564..9088adf1 100644 --- a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs +++ b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs @@ -33,7 +33,10 @@ long blockIndex ncgCurrency); var burntNCG = prevNCGBalance - outputNCGBalance; - var itemenhancementModel = new ItemEnhancementModel() + var equipment = outputStates.GetAvatarState(avatarAddress).inventory.Equipments + .First(e => e.ItemId == itemId); + + var itemEnhancementModel = new ItemEnhancementModel() { Id = actionId.ToString(), AgentAddress = signer.ToString(), @@ -44,9 +47,12 @@ long blockIndex SlotIndex = slotIndex, BurntNCG = Convert.ToDecimal(burntNCG.GetQuantityString()), BlockIndex = blockIndex, + SheetId = equipment.Id, + Level = equipment.level, + Exp = equipment.Exp, }; - return itemenhancementModel; + return itemEnhancementModel; } } } diff --git a/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs b/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs index b978f1d1..fcc809ed 100644 --- a/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs +++ b/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs @@ -1,6 +1,5 @@ namespace NineChronicles.DataProvider.Store.Models { - using System.Collections.Generic; using System.ComponentModel.DataAnnotations; public class ItemEnhancementModel @@ -27,5 +26,11 @@ public class ItemEnhancementModel public decimal BurntNCG { get; set; } public long BlockIndex { get; set; } + + public int? SheetId { get; set; } + + public int? Level { get; set; } + + public long? Exp { get; set; } } } From 432e8be11754335af7a7797ee39cea151f3464af Mon Sep 17 00:00:00 2001 From: Submodule Updater Date: Wed, 18 Oct 2023 01:44:07 +0000 Subject: [PATCH 02/13] Update NineChronicles.Headless submodule to planetarium/NineChronicles.Headless@ba9828361d22625a0b47c706c7cdf4a3b57b811a This commit was automatically generated by Submodule Updater. --- NineChronicles.Headless | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NineChronicles.Headless b/NineChronicles.Headless index 41a28956..ba982836 160000 --- a/NineChronicles.Headless +++ b/NineChronicles.Headless @@ -1 +1 @@ -Subproject commit 41a289568e991046b0644505ffa2d3b66f343922 +Subproject commit ba9828361d22625a0b47c706c7cdf4a3b57b811a From 730b08db49711b9c7cd35c3b71fcddb952d73c2b Mon Sep 17 00:00:00 2001 From: Say Cheong Date: Wed, 18 Oct 2023 10:59:43 +0900 Subject: [PATCH 03/13] Bump 9c-headless --- NineChronicles.Headless | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NineChronicles.Headless b/NineChronicles.Headless index 41a28956..ba982836 160000 --- a/NineChronicles.Headless +++ b/NineChronicles.Headless @@ -1 +1 @@ -Subproject commit 41a289568e991046b0644505ffa2d3b66f343922 +Subproject commit ba9828361d22625a0b47c706c7cdf4a3b57b811a From d29ea874d3dfe9e8e32234184b04e431fd367038 Mon Sep 17 00:00:00 2001 From: area363 Date: Fri, 20 Oct 2023 16:21:41 +0900 Subject: [PATCH 04/13] add ranking tables --- .../Store/NineChroniclesContext.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs index 6423bc44..f1036cb9 100644 --- a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs +++ b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs @@ -42,6 +42,21 @@ public NineChroniclesContext(DbContextOptions options) // Table for ranking avatars' equipment combat points public DbSet? EquipmentRanking { get; set; } + // Table for ranking avatars' armor combat points + public DbSet? EquipmentRankingArmor { get; set; } + + // Table for ranking avatars' belt combat points + public DbSet? EquipmentRankingBelt { get; set; } + + // Table for ranking avatars' necklace combat points + public DbSet? EquipmentRankingNecklace { get; set; } + + // Table for ranking avatars' ring combat points + public DbSet? EquipmentRankingRing { get; set; } + + // Table for ranking avatars' weapon combat points + public DbSet? EquipmentRankingWeapon { get; set; } + // Table for ranking avatars' total combat points public DbSet? AbilityRanking { get; set; } From 0324d90200743ec2c4e6383fcb631544939ea45b Mon Sep 17 00:00:00 2001 From: "Kidon (Don) Seo" Date: Tue, 24 Oct 2023 09:59:33 +0900 Subject: [PATCH 05/13] Increase `maxRetryCount` from 10 to 20 To make sure no data is left out. --- NineChronicles.DataProvider.Executable/Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NineChronicles.DataProvider.Executable/Program.cs b/NineChronicles.DataProvider.Executable/Program.cs index 8fae96df..ca68931f 100644 --- a/NineChronicles.DataProvider.Executable/Program.cs +++ b/NineChronicles.DataProvider.Executable/Program.cs @@ -198,7 +198,7 @@ public async Task Run() { mySqlOptions .EnableRetryOnFailure( - maxRetryCount: 10, + maxRetryCount: 20, maxRetryDelay: TimeSpan.FromSeconds(10), errorNumbersToAdd: null); } From 157b587405478c8982386043dc0b3996599e445e Mon Sep 17 00:00:00 2001 From: area363 Date: Tue, 31 Oct 2023 15:39:29 +0900 Subject: [PATCH 06/13] update equipment ranking models --- .../Models/EquipmentRankingArmorModel.cs | 32 +++++++++++++++++++ .../Store/Models/EquipmentRankingBeltModel.cs | 32 +++++++++++++++++++ .../Models/EquipmentRankingNecklaceModel.cs | 32 +++++++++++++++++++ .../Store/Models/EquipmentRankingRingModel.cs | 32 +++++++++++++++++++ .../Models/EquipmentRankingWeaponModel.cs | 32 +++++++++++++++++++ .../Store/NineChroniclesContext.cs | 15 ++++++--- 6 files changed, 170 insertions(+), 5 deletions(-) create mode 100644 NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs new file mode 100644 index 00000000..b2f647ac --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs @@ -0,0 +1,32 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System.ComponentModel.DataAnnotations; + + public class EquipmentRankingArmorModel + { + [Key] + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public int EquipmentId { get; set; } + + public int Cp { get; set; } + + public int Level { get; set; } + + public string? ItemSubType { get; set; } + + public string? Name { get; set; } + + public int? AvatarLevel { get; set; } + + public int? TitleId { get; set; } + + public int? ArmorId { get; set; } + + public int Ranking { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs new file mode 100644 index 00000000..3d2afa67 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs @@ -0,0 +1,32 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System.ComponentModel.DataAnnotations; + + public class EquipmentRankingBeltModel + { + [Key] + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public int EquipmentId { get; set; } + + public int Cp { get; set; } + + public int Level { get; set; } + + public string? ItemSubType { get; set; } + + public string? Name { get; set; } + + public int? AvatarLevel { get; set; } + + public int? TitleId { get; set; } + + public int? ArmorId { get; set; } + + public int Ranking { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs new file mode 100644 index 00000000..a6527a7c --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs @@ -0,0 +1,32 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System.ComponentModel.DataAnnotations; + + public class EquipmentRankingNecklaceModel + { + [Key] + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public int EquipmentId { get; set; } + + public int Cp { get; set; } + + public int Level { get; set; } + + public string? ItemSubType { get; set; } + + public string? Name { get; set; } + + public int? AvatarLevel { get; set; } + + public int? TitleId { get; set; } + + public int? ArmorId { get; set; } + + public int Ranking { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs new file mode 100644 index 00000000..ce8f3932 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs @@ -0,0 +1,32 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System.ComponentModel.DataAnnotations; + + public class EquipmentRankingRingModel + { + [Key] + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public int EquipmentId { get; set; } + + public int Cp { get; set; } + + public int Level { get; set; } + + public string? ItemSubType { get; set; } + + public string? Name { get; set; } + + public int? AvatarLevel { get; set; } + + public int? TitleId { get; set; } + + public int? ArmorId { get; set; } + + public int Ranking { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs new file mode 100644 index 00000000..f9c2a606 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs @@ -0,0 +1,32 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System.ComponentModel.DataAnnotations; + + public class EquipmentRankingWeaponModel + { + [Key] + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public int EquipmentId { get; set; } + + public int Cp { get; set; } + + public int Level { get; set; } + + public string? ItemSubType { get; set; } + + public string? Name { get; set; } + + public int? AvatarLevel { get; set; } + + public int? TitleId { get; set; } + + public int? ArmorId { get; set; } + + public int Ranking { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs index f1036cb9..1bfb5fa1 100644 --- a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs +++ b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs @@ -43,19 +43,19 @@ public NineChroniclesContext(DbContextOptions options) public DbSet? EquipmentRanking { get; set; } // Table for ranking avatars' armor combat points - public DbSet? EquipmentRankingArmor { get; set; } + public DbSet? EquipmentRankingArmor { get; set; } // Table for ranking avatars' belt combat points - public DbSet? EquipmentRankingBelt { get; set; } + public DbSet? EquipmentRankingBelt { get; set; } // Table for ranking avatars' necklace combat points - public DbSet? EquipmentRankingNecklace { get; set; } + public DbSet? EquipmentRankingNecklace { get; set; } // Table for ranking avatars' ring combat points - public DbSet? EquipmentRankingRing { get; set; } + public DbSet? EquipmentRankingRing { get; set; } // Table for ranking avatars' weapon combat points - public DbSet? EquipmentRankingWeapon { get; set; } + public DbSet? EquipmentRankingWeapon { get; set; } // Table for ranking avatars' total combat points public DbSet? AbilityRanking { get; set; } @@ -190,6 +190,11 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); From f0a2b6c8cfac6ca8830dc049910cff61e7b5ea81 Mon Sep 17 00:00:00 2001 From: area363 Date: Tue, 31 Oct 2023 15:39:52 +0900 Subject: [PATCH 07/13] add migrations --- ...0231031063724_AddRankingTables.Designer.cs | 3034 +++++++++++++++++ .../20231031063724_AddRankingTables.cs | 165 + .../NineChroniclesContextModelSnapshot.cs | 205 ++ 3 files changed, 3404 insertions(+) create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.Designer.cs create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.cs diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.Designer.cs b/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.Designer.cs new file mode 100644 index 00000000..73716cac --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.Designer.cs @@ -0,0 +1,3034 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using NineChronicles.DataProvider.Store; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + [DbContext(typeof(NineChroniclesContext))] + [Migration("20231031063724_AddRankingTables")] + partial class AddRankingTables + { + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "6.0.1") + .HasAnnotation("Relational:MaxIdentifierLength", 64); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AbilityRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("AbilityRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AgentModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.HasKey("Address"); + + b.ToTable("Agents"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Exception") + .HasColumnType("longtext"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummonFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.Property("SummonResult") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummons"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.HasKey("Address"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Avatars"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("EnemyAvatarAddress") + .HasColumnType("longtext"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("TicketCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaRankingModel", b => + { + b.Property("AdditionalTicketPrice") + .HasColumnType("bigint"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArenaType") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EndBlockIndex") + .HasColumnType("bigint"); + + b.Property("EntranceFee") + .HasColumnType("bigint"); + + b.Property("LossCount") + .HasColumnType("int"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("PurchasedTicketCount") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("RequiredMedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("Score") + .HasColumnType("int"); + + b.Property("StartBlockIndex") + .HasColumnType("bigint"); + + b.Property("Ticket") + .HasColumnType("int"); + + b.Property("TicketPrice") + .HasColumnType("bigint"); + + b.Property("TicketResetCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.Property("WinCount") + .HasColumnType("int"); + + b.ToTable("BattleArenaRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EnemyAvatarAddress") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("GrandFinaleId") + .HasColumnType("int"); + + b.Property("GrandFinaleScore") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleGrandFinales"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BlockModel", b => + { + b.Property("Hash") + .HasColumnType("varchar(255)"); + + b.Property("Difficulty") + .HasColumnType("bigint"); + + b.Property("Index") + .HasColumnType("bigint"); + + b.Property("Miner") + .HasColumnType("longtext"); + + b.Property("Nonce") + .HasColumnType("longtext"); + + b.Property("PreviousHash") + .HasColumnType("longtext"); + + b.Property("ProtocolVersion") + .HasColumnType("int"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("StateRootHash") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TotalDifficulty") + .HasColumnType("bigint"); + + b.Property("TxCount") + .HasColumnType("int"); + + b.Property("TxHash") + .HasColumnType("longtext"); + + b.HasKey("Hash"); + + b.ToTable("Blocks"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApPotionCount") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimRewardAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ClaimStakeEndBlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("HourGlassCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.ToTable("ClaimStakeRewards"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("SubRecipeId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingInputModel", b => + { + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CraftCount") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.HasKey("AvatarAddress"); + + b.ToTable("CraftRankings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingOutputModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CraftCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("CraftRankingsOutput"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.HasKey("ItemId"); + + b.ToTable("Equipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingArmorModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingArmor"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingBeltModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingBelt"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingNecklaceModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingNecklace"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingRingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingRing"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingWeaponModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingWeapon"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("EventConsumableItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("RequiredItem1Count") + .HasColumnType("int"); + + b.Property("RequiredItem1Id") + .HasColumnType("int"); + + b.Property("RequiredItem2Count") + .HasColumnType("int"); + + b.Property("RequiredItem2Id") + .HasColumnType("int"); + + b.Property("RequiredItem3Count") + .HasColumnType("int"); + + b.Property("RequiredItem3Id") + .HasColumnType("int"); + + b.Property("RequiredItem4Count") + .HasColumnType("int"); + + b.Property("RequiredItem4Id") + .HasColumnType("int"); + + b.Property("RequiredItem5Count") + .HasColumnType("int"); + + b.Property("RequiredItem5Id") + .HasColumnType("int"); + + b.Property("RequiredItem6Count") + .HasColumnType("int"); + + b.Property("RequiredItem6Id") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventConsumableItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("EventDungeonId") + .HasColumnType("int"); + + b.Property("EventDungeonStageId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("FoodsCount") + .HasColumnType("int"); + + b.Property("RemainingTickets") + .HasColumnType("int"); + + b.Property("RewardItem10Count") + .HasColumnType("int"); + + b.Property("RewardItem10Id") + .HasColumnType("int"); + + b.Property("RewardItem1Count") + .HasColumnType("int"); + + b.Property("RewardItem1Id") + .HasColumnType("int"); + + b.Property("RewardItem2Count") + .HasColumnType("int"); + + b.Property("RewardItem2Id") + .HasColumnType("int"); + + b.Property("RewardItem3Count") + .HasColumnType("int"); + + b.Property("RewardItem3Id") + .HasColumnType("int"); + + b.Property("RewardItem4Count") + .HasColumnType("int"); + + b.Property("RewardItem4Id") + .HasColumnType("int"); + + b.Property("RewardItem5Count") + .HasColumnType("int"); + + b.Property("RewardItem5Id") + .HasColumnType("int"); + + b.Property("RewardItem6Count") + .HasColumnType("int"); + + b.Property("RewardItem6Id") + .HasColumnType("int"); + + b.Property("RewardItem7Count") + .HasColumnType("int"); + + b.Property("RewardItem7Id") + .HasColumnType("int"); + + b.Property("RewardItem8Count") + .HasColumnType("int"); + + b.Property("RewardItem8Id") + .HasColumnType("int"); + + b.Property("RewardItem9Count") + .HasColumnType("int"); + + b.Property("RewardItem9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventDungeonBattles"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EventMaterialItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("Material10Count") + .HasColumnType("int"); + + b.Property("Material10Id") + .HasColumnType("int"); + + b.Property("Material11Count") + .HasColumnType("int"); + + b.Property("Material11Id") + .HasColumnType("int"); + + b.Property("Material12Count") + .HasColumnType("int"); + + b.Property("Material12Id") + .HasColumnType("int"); + + b.Property("Material1Count") + .HasColumnType("int"); + + b.Property("Material1Id") + .HasColumnType("int"); + + b.Property("Material2Count") + .HasColumnType("int"); + + b.Property("Material2Id") + .HasColumnType("int"); + + b.Property("Material3Count") + .HasColumnType("int"); + + b.Property("Material3Id") + .HasColumnType("int"); + + b.Property("Material4Count") + .HasColumnType("int"); + + b.Property("Material4Id") + .HasColumnType("int"); + + b.Property("Material5Count") + .HasColumnType("int"); + + b.Property("Material5Id") + .HasColumnType("int"); + + b.Property("Material6Count") + .HasColumnType("int"); + + b.Property("Material6Id") + .HasColumnType("int"); + + b.Property("Material7Count") + .HasColumnType("int"); + + b.Property("Material7Id") + .HasColumnType("int"); + + b.Property("Material8Count") + .HasColumnType("int"); + + b.Property("Material8Id") + .HasColumnType("int"); + + b.Property("Material9Count") + .HasColumnType("int"); + + b.Property("Material9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventMaterialItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Crystal") + .HasColumnType("decimal(65,30)"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("Grindings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionPoint") + .HasColumnType("int"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApStoneCount") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("WorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashSweeps"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("GachaCount") + .HasColumnType("int"); + + b.Property("HasStageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffId") + .HasColumnType("int"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasWithRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("GainedCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("MaterialItemId") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancementFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Exp") + .HasColumnType("bigint"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("MaterialId") + .HasColumnType("longtext"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("SheetId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArenaRound") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("JoinArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("MigrationAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("MigrationStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("StakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("MigrateMonsterCollections"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntSoulStone") + .HasColumnType("decimal(65,30)"); + + b.Property("ChangedLevel") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("OutputPetLevel") + .HasColumnType("int"); + + b.Property("PetId") + .HasColumnType("int"); + + b.Property("PreviousPetLevel") + .HasColumnType("int"); + + b.Property("TargetLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("PetEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RaiderModel", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("Address") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarName") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CreatedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("PurchaseCount") + .HasColumnType("int"); + + b.Property("RaidId") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.Property("UpdatedAt") + .ValueGeneratedOnAddOrUpdate() + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("RaidId", "Address") + .IsUnique(); + + b.ToTable("Raiders"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("HourglassCount") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RapidCombinations"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("ReplacedMaterialCount") + .HasColumnType("int"); + + b.Property("ReplacedMaterialId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ReplaceCombinationEquipmentMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RequestPledgeModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("PledgeAgentAddress") + .HasColumnType("longtext"); + + b.Property("RefillMead") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxSigner") + .HasColumnType("longtext"); + + b.HasKey("TxId"); + + b.ToTable("RequestPledges"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntRune") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("OutputRuneLevel") + .HasColumnType("int"); + + b.Property("PreviousRuneLevel") + .HasColumnType("int"); + + b.Property("RuneId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TryCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RuneEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("varchar(255)"); + + b.Property("TickerType") + .HasColumnType("varchar(255)"); + + b.Property("AcquiredRune") + .HasColumnType("decimal(65,30)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id", "ActionType", "TickerType"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.HasIndex("Id", "ActionType", "TickerType") + .IsUnique(); + + b.ToTable("RunesAcquired"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopConsumableModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopCostumeModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopEquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryConsumableModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryCostumeModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryEquipmentModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryFungibleAssetValueModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("Quantity") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Ticker") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryFungibleAssetValues"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryMaterialModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopMaterialModel", b => + { + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.ToTable("ShopMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StageRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClearedStageId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("StageRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("NewAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("NewStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PrevStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PreviousAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("RemainingNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Stakings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransactionModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("longtext"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("Nonce") + .HasColumnType("bigint"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("Signer") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UpdatedAddressesCount") + .HasColumnType("int"); + + b.HasKey("TxId"); + + b.ToTable("Transactions"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransferAssetModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("Amount") + .HasColumnType("decimal(65,30)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Recipient") + .HasColumnType("longtext"); + + b.Property("Sender") + .HasColumnType("longtext"); + + b.Property("TickerType") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.ToTable("TransferAssets"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockEquipmentRecipeId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockEquipmentRecipes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockRuneSlots"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockWorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockWorlds"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossRankingModel", b => + { + b.Property("Address") + .HasColumnType("longtext"); + + b.Property("AvatarName") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.ToTable("WorldBossRankings", null, t => t.ExcludeFromMigrations()); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossSeasonMigrationModel", b => + { + b.Property("RaidId") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("MigratedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.HasKey("RaidId"); + + b.HasIndex("RaidId") + .IsUnique(); + + b.ToTable("WorldBossSeasonMigrationModels"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.cs b/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.cs new file mode 100644 index 00000000..a3a47d0a --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231031063724_AddRankingTables.cs @@ -0,0 +1,165 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + public partial class AddRankingTables : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "EquipmentRankingArmor", + columns: table => new + { + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + EquipmentId = table.Column(type: "int", nullable: false), + Cp = table.Column(type: "int", nullable: false), + Level = table.Column(type: "int", nullable: false), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + TitleId = table.Column(type: "int", nullable: true), + ArmorId = table.Column(type: "int", nullable: true), + Ranking = table.Column(type: "int", nullable: false) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "EquipmentRankingBelt", + columns: table => new + { + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + EquipmentId = table.Column(type: "int", nullable: false), + Cp = table.Column(type: "int", nullable: false), + Level = table.Column(type: "int", nullable: false), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + TitleId = table.Column(type: "int", nullable: true), + ArmorId = table.Column(type: "int", nullable: true), + Ranking = table.Column(type: "int", nullable: false) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "EquipmentRankingNecklace", + columns: table => new + { + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + EquipmentId = table.Column(type: "int", nullable: false), + Cp = table.Column(type: "int", nullable: false), + Level = table.Column(type: "int", nullable: false), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + TitleId = table.Column(type: "int", nullable: true), + ArmorId = table.Column(type: "int", nullable: true), + Ranking = table.Column(type: "int", nullable: false) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "EquipmentRankingRing", + columns: table => new + { + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + EquipmentId = table.Column(type: "int", nullable: false), + Cp = table.Column(type: "int", nullable: false), + Level = table.Column(type: "int", nullable: false), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + TitleId = table.Column(type: "int", nullable: true), + ArmorId = table.Column(type: "int", nullable: true), + Ranking = table.Column(type: "int", nullable: false) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "EquipmentRankingWeapon", + columns: table => new + { + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + EquipmentId = table.Column(type: "int", nullable: false), + Cp = table.Column(type: "int", nullable: false), + Level = table.Column(type: "int", nullable: false), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + TitleId = table.Column(type: "int", nullable: true), + ArmorId = table.Column(type: "int", nullable: true), + Ranking = table.Column(type: "int", nullable: false) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "EquipmentRankingArmor"); + + migrationBuilder.DropTable( + name: "EquipmentRankingBelt"); + + migrationBuilder.DropTable( + name: "EquipmentRankingNecklace"); + + migrationBuilder.DropTable( + name: "EquipmentRankingRing"); + + migrationBuilder.DropTable( + name: "EquipmentRankingWeapon"); + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs index 36de3aea..3a8bdba0 100644 --- a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs +++ b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs @@ -563,6 +563,88 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.ToTable("Equipments"); }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingArmorModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingArmor"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingBeltModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingBelt"); + }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingModel", b => { b.Property("AgentAddress") @@ -604,6 +686,129 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.ToTable("EquipmentRanking"); }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingNecklaceModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingNecklace"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingRingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingRing"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingWeaponModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingWeapon"); + }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => { b.Property("Id") From 45b52d7cf22593c8377f4513d39bbeceeb2c7006 Mon Sep 17 00:00:00 2001 From: area363 Date: Tue, 31 Oct 2023 16:44:36 +0900 Subject: [PATCH 08/13] use GetAvatarStateV2 --- .../DataRendering/itemEnhancementData.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs index 9088adf1..4ce8e21c 100644 --- a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs +++ b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs @@ -33,7 +33,7 @@ long blockIndex ncgCurrency); var burntNCG = prevNCGBalance - outputNCGBalance; - var equipment = outputStates.GetAvatarState(avatarAddress).inventory.Equipments + var equipment = outputStates.GetAvatarStateV2(avatarAddress).inventory.Equipments .First(e => e.ItemId == itemId); var itemEnhancementModel = new ItemEnhancementModel() From 55f4e2b99a735040cc8c32a0e088e7e984fc4a1a Mon Sep 17 00:00:00 2001 From: Suho Lee Date: Fri, 3 Nov 2023 14:12:01 +0900 Subject: [PATCH 09/13] fix: read `appsettings.json` with path --- .../Program.cs | 38 +++++++++++++++++-- 1 file changed, 34 insertions(+), 4 deletions(-) diff --git a/NineChronicles.DataProvider.Executable/Program.cs b/NineChronicles.DataProvider.Executable/Program.cs index ca68931f..4c5da0d9 100644 --- a/NineChronicles.DataProvider.Executable/Program.cs +++ b/NineChronicles.DataProvider.Executable/Program.cs @@ -1,4 +1,11 @@ +#nullable enable using System.Collections.Concurrent; +using System.Collections.Generic; +using System.Collections.Immutable; +using System.IO; +using System.Linq; +using System.Net.Http; +using Libplanet.Headless.Hosting; using Nekoyume.Action.Loader; using IPAddress = System.Net.IPAddress; @@ -73,12 +80,35 @@ public static IHostBuilder CreateHostBuilder(string[] args) }); [PrimaryCommand] - public async Task Run() + public async Task Run( + [Option(Description = "The path of the appsettings JSON file.")] string? configPath = null) { // Get configuration - var configurationBuilder = new ConfigurationBuilder() - .AddJsonFile("appsettings.json") - .AddEnvironmentVariables("NC_"); + var configurationBuilder = new ConfigurationBuilder(); + if (configPath != null) + { + if (Uri.IsWellFormedUriString(configPath, UriKind.Absolute)) + { + HttpClient client = new HttpClient(); + HttpResponseMessage resp = await client.GetAsync(configPath); + resp.EnsureSuccessStatusCode(); + Stream body = await resp.Content.ReadAsStreamAsync(); + configurationBuilder.AddJsonStream(body) + .AddEnvironmentVariables("NC_"); + } + else + { + configurationBuilder.AddJsonFile(configPath!) + .AddEnvironmentVariables("NC_"); + } + } + else + { + configurationBuilder + .AddJsonFile("appsettings.json") + .AddEnvironmentVariables("NC_"); + } + IConfiguration config = configurationBuilder.Build(); var headlessConfig = new Configuration(); config.Bind(headlessConfig); From 83f1608dc6015bbfff9a3e48a044c156008020d3 Mon Sep 17 00:00:00 2001 From: Suho Lee Date: Fri, 3 Nov 2023 14:12:19 +0900 Subject: [PATCH 10/13] introduce: Pluggable AEV --- .../Program.cs | 37 ++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/NineChronicles.DataProvider.Executable/Program.cs b/NineChronicles.DataProvider.Executable/Program.cs index 4c5da0d9..ec28d08d 100644 --- a/NineChronicles.DataProvider.Executable/Program.cs +++ b/NineChronicles.DataProvider.Executable/Program.cs @@ -140,6 +140,40 @@ public async Task Run( builder.UseUrls($"http://{headlessConfig.GraphQLHost}:{headlessConfig.GraphQLPort}/"); }); + IActionEvaluatorConfiguration GetActionEvaluatorConfiguration(IConfiguration configuration) + { + if (!(configuration.GetValue("Type") is { } actionEvaluatorType)) + { + return null; + } + + return actionEvaluatorType switch + { + ActionEvaluatorType.Default => new DefaultActionEvaluatorConfiguration(), + ActionEvaluatorType.RemoteActionEvaluator => new RemoteActionEvaluatorConfiguration + { + StateServiceEndpoint = configuration.GetValue("StateServiceEndpoint"), + }, + ActionEvaluatorType.ForkableActionEvaluator => new ForkableActionEvaluatorConfiguration + { + Pairs = (configuration.GetSection("Pairs") ?? + throw new KeyNotFoundException()).GetChildren().Select(pair => + { + var range = new ForkableActionEvaluatorRange(); + pair.Bind("Range", range); + var actionEvaluatorConfiguration = + GetActionEvaluatorConfiguration(pair.GetSection("ActionEvaluator")) ?? + throw new KeyNotFoundException(); + return (range, actionEvaluatorConfiguration); + }).ToImmutableArray() + }, + _ => throw new InvalidOperationException("Unexpected type."), + }; + } + + var actionEvaluatorConfiguration = + GetActionEvaluatorConfiguration(config.GetSection("Headless").GetSection("ActionEvaluator")); + var properties = NineChroniclesNodeServiceProperties .GenerateLibplanetNodeServiceProperties( headlessConfig.AppProtocolVersionToken, @@ -162,7 +196,8 @@ public async Task Run( minimumBroadcastTarget: headlessConfig.MinimumBroadcastTarget, bucketSize: headlessConfig.BucketSize, render: headlessConfig.Render, - preload: headlessConfig.Preload); + preload: headlessConfig.Preload, + actionEvaluatorConfiguration: actionEvaluatorConfiguration); IActionLoader actionLoader = new NCActionLoader(); From 2b6f99c11e474c2872f8d2b075e1c9df5e17d69a Mon Sep 17 00:00:00 2001 From: area363 Date: Mon, 6 Nov 2023 20:52:13 +0900 Subject: [PATCH 11/13] add and update models --- .../DataRendering/BattleArenaData.cs | 1 + .../DataRendering/BlockData.cs | 2 + .../DataRendering/ClaimStakeRewardData.cs | 1 + .../CombinationConsumableData.cs | 5 ++- .../DataRendering/CombinationEquipmentData.cs | 5 ++- .../DataRendering/EquipmentData.cs | 5 ++- .../EventConsumableItemCraftsData.cs | 1 + .../DataRendering/EventDungeonBattleData.cs | 1 + .../DataRendering/GrindingData.cs | 1 + .../DataRendering/HackAndSlashData.cs | 2 + .../HackAndSlashRandomBuffData.cs | 1 + .../DataRendering/HackAndSlashSweepData.cs | 1 + .../DataRendering/HasWithRandomBuffData.cs | 1 + .../DataRendering/JoinArenaData.cs | 1 + .../MigrateMonsterCollectionData.cs | 1 + ...ReplaceCombinationEquipmentMaterialData.cs | 1 + .../DataRendering/StakeData.cs | 1 + .../UnlockEquipmentRecipeData.cs | 1 + .../DataRendering/UnlockWorldData.cs | 1 + .../DataRendering/itemEnhancementData.cs | 5 ++- .../DataRendering/itemEnhancementFailData.cs | 1 + .../GraphTypes/CraftRankingType.cs | 2 +- .../RenderSubscriber.cs | 21 ++++++--- .../Store/Models/AuraSummonModel.cs | 4 +- .../Store/Models/BattleArenaModel.cs | 2 + .../Store/Models/BlockModel.cs | 2 + .../Store/Models/ClaimStakeRewardModel.cs | 2 + .../Models/CombinationConsumableModel.cs | 5 +++ .../Store/Models/CombinationEquipmentModel.cs | 5 +++ .../Store/Models/CraftRankingInputModel.cs | 18 -------- ...ingOutputModel.cs => CraftRankingModel.cs} | 6 +-- .../Store/Models/EquipmentModel.cs | 3 ++ .../Models/EquipmentRankingArmorModel.cs | 4 +- .../Store/Models/EquipmentRankingBeltModel.cs | 4 +- .../Store/Models/EquipmentRankingModel.cs | 4 +- .../Models/EquipmentRankingNecklaceModel.cs | 4 +- .../Store/Models/EquipmentRankingRingModel.cs | 4 +- .../Models/EquipmentRankingWeaponModel.cs | 4 +- .../Models/EventConsumableItemCraftsModel.cs | 2 + .../Store/Models/EventDungeonBattleModel.cs | 2 + .../Store/Models/GrindingModel.cs | 2 + .../Store/Models/HackAndSlashModel.cs | 13 ++++-- .../Store/Models/HackAndSlashSweepModel.cs | 2 + .../Store/Models/HasRandomBuffModel.cs | 2 + .../Store/Models/HasWithRandomBuffModel.cs | 2 + .../Store/Models/ItemEnhancementFailModel.cs | 2 + .../Store/Models/ItemEnhancementModel.cs | 13 ++++-- .../Store/Models/JoinArenaModel.cs | 2 + .../Models/MigrateMonsterCollectionModel.cs | 2 + ...eplaceCombinationEquipmentMaterialModel.cs | 2 + .../Store/Models/StageRankingModel.cs | 8 ++-- .../Store/Models/StakeModel.cs | 2 + .../Models/UnlockEquipmentRecipeModel.cs | 2 + .../Store/Models/UnlockWorldModel.cs | 2 + .../Store/Models/UserConsumablesModel.cs | 43 ++++++++++++++++++ .../Store/Models/UserCostumesModel.cs | 41 +++++++++++++++++ .../Store/Models/UserCrystalsModel.cs | 17 +++++++ .../Store/Models/UserEquipmentsModel.cs | 45 +++++++++++++++++++ .../Store/Models/UserMaterialsModel.cs | 33 ++++++++++++++ .../Models/UserMonsterCollectionsModel.cs | 27 +++++++++++ .../Store/Models/UserNCGsModel.cs | 17 +++++++ .../Store/Models/UserRunesModel.cs | 23 ++++++++++ .../Store/Models/UserStakingsModel.cs | 23 ++++++++++ .../Store/MySqlStore.cs | 10 ++--- .../Store/NineChroniclesContext.cs | 33 ++++++++++++-- 65 files changed, 437 insertions(+), 68 deletions(-) delete mode 100644 NineChronicles.DataProvider/Store/Models/CraftRankingInputModel.cs rename NineChronicles.DataProvider/Store/Models/{CraftRankingOutputModel.cs => CraftRankingModel.cs} (93%) create mode 100644 NineChronicles.DataProvider/Store/Models/UserConsumablesModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserCostumesModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserCrystalsModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserEquipmentsModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserMaterialsModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserMonsterCollectionsModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserNCGsModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserRunesModel.cs create mode 100644 NineChronicles.DataProvider/Store/Models/UserStakingsModel.cs diff --git a/NineChronicles.DataProvider/DataRendering/BattleArenaData.cs b/NineChronicles.DataProvider/DataRendering/BattleArenaData.cs index 105a2525..d72acc35 100644 --- a/NineChronicles.DataProvider/DataRendering/BattleArenaData.cs +++ b/NineChronicles.DataProvider/DataRendering/BattleArenaData.cs @@ -92,6 +92,7 @@ DateTimeOffset blockTime BurntNCG = Convert.ToDecimal(burntNCG.GetQuantityString()), Victory = currentArenaScore.Score > previousArenaScore.Score, MedalCount = medalCount, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/BlockData.cs b/NineChronicles.DataProvider/DataRendering/BlockData.cs index 5f681637..e5aea7e9 100644 --- a/NineChronicles.DataProvider/DataRendering/BlockData.cs +++ b/NineChronicles.DataProvider/DataRendering/BlockData.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.DataRendering { + using System; using System.Linq; using Libplanet.Action; using Libplanet.Types.Blocks; @@ -25,6 +26,7 @@ public static BlockModel GetBlockInfo( TotalDifficulty = 0, TxCount = block.Transactions.Count(), TxHash = block.TxHash.ToString(), + Date = DateOnly.FromDateTime(block.Timestamp.DateTime), TimeStamp = block.Timestamp.UtcDateTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/ClaimStakeRewardData.cs b/NineChronicles.DataProvider/DataRendering/ClaimStakeRewardData.cs index 9b7f5e21..7f16c420 100644 --- a/NineChronicles.DataProvider/DataRendering/ClaimStakeRewardData.cs +++ b/NineChronicles.DataProvider/DataRendering/ClaimStakeRewardData.cs @@ -64,6 +64,7 @@ DateTimeOffset blockTime ApPotionCount = outputApPotionCount - previousApPotionCount, ClaimStakeStartBlockIndex = claimStakeStartBlockIndex, ClaimStakeEndBlockIndex = claimStakeEndBlockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/CombinationConsumableData.cs b/NineChronicles.DataProvider/DataRendering/CombinationConsumableData.cs index f66d1e3b..a115c664 100644 --- a/NineChronicles.DataProvider/DataRendering/CombinationConsumableData.cs +++ b/NineChronicles.DataProvider/DataRendering/CombinationConsumableData.cs @@ -17,7 +17,8 @@ public static CombinationConsumableModel GetCombinationConsumableInfo( int recipeId, int slotIndex, Guid actionId, - long blockIndex + long blockIndex, + DateTimeOffset blockTime ) { var combinationConsumableModel = new CombinationConsumableModel() @@ -28,6 +29,8 @@ long blockIndex RecipeId = recipeId, SlotIndex = slotIndex, BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), + TimeStamp = blockTime.UtcDateTime, }; return combinationConsumableModel; diff --git a/NineChronicles.DataProvider/DataRendering/CombinationEquipmentData.cs b/NineChronicles.DataProvider/DataRendering/CombinationEquipmentData.cs index 6a85f08d..c110be53 100644 --- a/NineChronicles.DataProvider/DataRendering/CombinationEquipmentData.cs +++ b/NineChronicles.DataProvider/DataRendering/CombinationEquipmentData.cs @@ -18,7 +18,8 @@ public static CombinationEquipmentModel GetCombinationEquipmentInfo( int slotIndex, int? subRecipeId, Guid actionId, - long blockIndex + long blockIndex, + DateTimeOffset blockTime ) { var combinationEquipmentModel = new CombinationEquipmentModel() @@ -30,6 +31,8 @@ long blockIndex SlotIndex = slotIndex, SubRecipeId = subRecipeId ?? 0, BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), + TimeStamp = blockTime.UtcDateTime, }; return combinationEquipmentModel; diff --git a/NineChronicles.DataProvider/DataRendering/EquipmentData.cs b/NineChronicles.DataProvider/DataRendering/EquipmentData.cs index 061aa3c4..3f2ba027 100644 --- a/NineChronicles.DataProvider/DataRendering/EquipmentData.cs +++ b/NineChronicles.DataProvider/DataRendering/EquipmentData.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.DataRendering { + using System; using Libplanet; using Libplanet.Crypto; using Nekoyume.Battle; @@ -11,7 +12,8 @@ public static class EquipmentData public static EquipmentModel GetEquipmentInfo( Address agentAddress, Address avatarAddress, - Equipment equipment + Equipment equipment, + DateTimeOffset blockTime ) { var cp = CPHelper.GetCP(equipment); @@ -24,6 +26,7 @@ Equipment equipment Cp = cp, Level = equipment.level, ItemSubType = equipment.ItemSubType.ToString(), + TimeStamp = blockTime.UtcDateTime, }; return equipmentModel; diff --git a/NineChronicles.DataProvider/DataRendering/EventConsumableItemCraftsData.cs b/NineChronicles.DataProvider/DataRendering/EventConsumableItemCraftsData.cs index 6062343d..00b0a6e6 100644 --- a/NineChronicles.DataProvider/DataRendering/EventConsumableItemCraftsData.cs +++ b/NineChronicles.DataProvider/DataRendering/EventConsumableItemCraftsData.cs @@ -89,6 +89,7 @@ DateTimeOffset blockTime RequiredItem6Id = requiredItemData["requiredItem6Id"], RequiredItem6Count = requiredItemData["requiredItem6Count"], BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), Timestamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/EventDungeonBattleData.cs b/NineChronicles.DataProvider/DataRendering/EventDungeonBattleData.cs index badbdf61..fc78e5bb 100644 --- a/NineChronicles.DataProvider/DataRendering/EventDungeonBattleData.cs +++ b/NineChronicles.DataProvider/DataRendering/EventDungeonBattleData.cs @@ -124,6 +124,7 @@ is Bencodex.Types.List serializedEventDungeonInfoList RewardItem10Id = rewardItemData["rewardItem10Id"], RewardItem10Count = rewardItemData["rewardItem10Count"], BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), Timestamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/GrindingData.cs b/NineChronicles.DataProvider/DataRendering/GrindingData.cs index 6196dd67..21a856dd 100644 --- a/NineChronicles.DataProvider/DataRendering/GrindingData.cs +++ b/NineChronicles.DataProvider/DataRendering/GrindingData.cs @@ -92,6 +92,7 @@ DateTimeOffset blockTime EquipmentLevel = equipment.level, Crystal = Convert.ToDecimal(crystal.GetQuantityString()), BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }); } diff --git a/NineChronicles.DataProvider/DataRendering/HackAndSlashData.cs b/NineChronicles.DataProvider/DataRendering/HackAndSlashData.cs index d0b7d6e6..f49603e3 100644 --- a/NineChronicles.DataProvider/DataRendering/HackAndSlashData.cs +++ b/NineChronicles.DataProvider/DataRendering/HackAndSlashData.cs @@ -34,6 +34,8 @@ DateTimeOffset blockTime Cleared = isClear, Mimisbrunnr = stageId > 10000000, BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), + Timestamp = blockTime, }; return hasModel; diff --git a/NineChronicles.DataProvider/DataRendering/HackAndSlashRandomBuffData.cs b/NineChronicles.DataProvider/DataRendering/HackAndSlashRandomBuffData.cs index 7aa98d8d..bb3b870d 100644 --- a/NineChronicles.DataProvider/DataRendering/HackAndSlashRandomBuffData.cs +++ b/NineChronicles.DataProvider/DataRendering/HackAndSlashRandomBuffData.cs @@ -41,6 +41,7 @@ DateTimeOffset blockTime HasStageId = currentStageId, GachaCount = !advancedGacha ? 5 : 10, BurntCrystal = Convert.ToDecimal(burntCrystal.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/HackAndSlashSweepData.cs b/NineChronicles.DataProvider/DataRendering/HackAndSlashSweepData.cs index 26112a33..4547b49d 100644 --- a/NineChronicles.DataProvider/DataRendering/HackAndSlashSweepData.cs +++ b/NineChronicles.DataProvider/DataRendering/HackAndSlashSweepData.cs @@ -44,6 +44,7 @@ DateTimeOffset blockTime Cleared = isClear, Mimisbrunnr = stageId > 10000000, BlockIndex = blockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), Timestamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/HasWithRandomBuffData.cs b/NineChronicles.DataProvider/DataRendering/HasWithRandomBuffData.cs index be410edb..4f7eef16 100644 --- a/NineChronicles.DataProvider/DataRendering/HasWithRandomBuffData.cs +++ b/NineChronicles.DataProvider/DataRendering/HasWithRandomBuffData.cs @@ -35,6 +35,7 @@ DateTimeOffset blockTime StageId = stageId, BuffId = (int)stageBuffId!, Cleared = isClear, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/JoinArenaData.cs b/NineChronicles.DataProvider/DataRendering/JoinArenaData.cs index 9eb057c8..0f44bce6 100644 --- a/NineChronicles.DataProvider/DataRendering/JoinArenaData.cs +++ b/NineChronicles.DataProvider/DataRendering/JoinArenaData.cs @@ -44,6 +44,7 @@ DateTimeOffset blockTime ArenaRound = round, ChampionshipId = championshipId, BurntCrystal = Convert.ToDecimal(burntCrystal.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/MigrateMonsterCollectionData.cs b/NineChronicles.DataProvider/DataRendering/MigrateMonsterCollectionData.cs index e36c41c8..b1b0b2f3 100644 --- a/NineChronicles.DataProvider/DataRendering/MigrateMonsterCollectionData.cs +++ b/NineChronicles.DataProvider/DataRendering/MigrateMonsterCollectionData.cs @@ -37,6 +37,7 @@ DateTimeOffset blockTime MigrationAmount = Convert.ToDecimal(migrationAmount.GetQuantityString()), MigrationStartBlockIndex = migrationStartBlockIndex, StakeStartBlockIndex = stakeStartBlockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/ReplaceCombinationEquipmentMaterialData.cs b/NineChronicles.DataProvider/DataRendering/ReplaceCombinationEquipmentMaterialData.cs index ba0f52e0..920e723c 100644 --- a/NineChronicles.DataProvider/DataRendering/ReplaceCombinationEquipmentMaterialData.cs +++ b/NineChronicles.DataProvider/DataRendering/ReplaceCombinationEquipmentMaterialData.cs @@ -114,6 +114,7 @@ public static List GetReplaceCombinati ReplacedMaterialCount = requiredCount - itemCount, BurntCrystal = Convert.ToDecimal(burntCrystal.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }); } diff --git a/NineChronicles.DataProvider/DataRendering/StakeData.cs b/NineChronicles.DataProvider/DataRendering/StakeData.cs index 5737a8d6..72e6ca79 100644 --- a/NineChronicles.DataProvider/DataRendering/StakeData.cs +++ b/NineChronicles.DataProvider/DataRendering/StakeData.cs @@ -56,6 +56,7 @@ DateTimeOffset blockTime RemainingNCG = Convert.ToDecimal(balance.GetQuantityString()), PrevStakeStartBlockIndex = prevStakeStartBlockIndex, NewStakeStartBlockIndex = newStakeStartBlockIndex, + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; diff --git a/NineChronicles.DataProvider/DataRendering/UnlockEquipmentRecipeData.cs b/NineChronicles.DataProvider/DataRendering/UnlockEquipmentRecipeData.cs index b5074d9e..ef94bfdd 100644 --- a/NineChronicles.DataProvider/DataRendering/UnlockEquipmentRecipeData.cs +++ b/NineChronicles.DataProvider/DataRendering/UnlockEquipmentRecipeData.cs @@ -42,6 +42,7 @@ DateTimeOffset blockTime AvatarAddress = avatarAddress.ToString(), UnlockEquipmentRecipeId = recipeId, BurntCrystal = Convert.ToDecimal(burntCrystal.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }); } diff --git a/NineChronicles.DataProvider/DataRendering/UnlockWorldData.cs b/NineChronicles.DataProvider/DataRendering/UnlockWorldData.cs index 6f3e902d..fb230141 100644 --- a/NineChronicles.DataProvider/DataRendering/UnlockWorldData.cs +++ b/NineChronicles.DataProvider/DataRendering/UnlockWorldData.cs @@ -42,6 +42,7 @@ DateTimeOffset blockTime AvatarAddress = avatarAddress.ToString(), UnlockWorldId = worldId, BurntCrystal = Convert.ToDecimal(burntCrystal.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }); } diff --git a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs index 4ce8e21c..bb8c1ea6 100644 --- a/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs +++ b/NineChronicles.DataProvider/DataRendering/itemEnhancementData.cs @@ -21,7 +21,8 @@ public static ItemEnhancementModel GetItemEnhancementInfo( List materialIds, Guid itemId, Guid actionId, - long blockIndex + long blockIndex, + DateTimeOffset blockTime ) { Currency ncgCurrency = outputStates.GetGoldCurrency(); @@ -50,6 +51,8 @@ long blockIndex SheetId = equipment.Id, Level = equipment.level, Exp = equipment.Exp, + Date = DateOnly.FromDateTime(blockTime.DateTime), + TimeStamp = blockTime, }; return itemEnhancementModel; diff --git a/NineChronicles.DataProvider/DataRendering/itemEnhancementFailData.cs b/NineChronicles.DataProvider/DataRendering/itemEnhancementFailData.cs index f17f8b51..22b7ea8f 100644 --- a/NineChronicles.DataProvider/DataRendering/itemEnhancementFailData.cs +++ b/NineChronicles.DataProvider/DataRendering/itemEnhancementFailData.cs @@ -76,6 +76,7 @@ DateTimeOffset blockTime EquipmentLevel = outputEquipmentLevel, GainedCrystal = Convert.ToDecimal(gainedCrystal.GetQuantityString()), BurntNCG = Convert.ToDecimal(burntNCG.GetQuantityString()), + Date = DateOnly.FromDateTime(blockTime.DateTime), TimeStamp = blockTime, }; } diff --git a/NineChronicles.DataProvider/GraphTypes/CraftRankingType.cs b/NineChronicles.DataProvider/GraphTypes/CraftRankingType.cs index 6c72abe3..3350dc12 100644 --- a/NineChronicles.DataProvider/GraphTypes/CraftRankingType.cs +++ b/NineChronicles.DataProvider/GraphTypes/CraftRankingType.cs @@ -3,7 +3,7 @@ using GraphQL.Types; using NineChronicles.DataProvider.Store.Models; - public class CraftRankingType : ObjectGraphType + public class CraftRankingType : ObjectGraphType { public CraftRankingType() { diff --git a/NineChronicles.DataProvider/RenderSubscriber.cs b/NineChronicles.DataProvider/RenderSubscriber.cs index 86015f88..177ae7fd 100644 --- a/NineChronicles.DataProvider/RenderSubscriber.cs +++ b/NineChronicles.DataProvider/RenderSubscriber.cs @@ -401,7 +401,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) combinationConsumable.recipeId, combinationConsumable.slotIndex, combinationConsumable.Id, - ev.BlockIndex)); + ev.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Log.Debug("Stored CombinationConsumable action in block #{index}. Time Taken: {time} ms.", ev.BlockIndex, (end - start).Milliseconds); } @@ -431,7 +432,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) combinationEquipment.slotIndex, combinationEquipment.subRecipeId, combinationEquipment.Id, - ev.BlockIndex)); + ev.BlockIndex, + _blockTimeOffset)); if (combinationEquipment.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -468,7 +470,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) _eqList.Add(EquipmentData.GetEquipmentInfo( ev.Signer, combinationEquipment.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -520,7 +523,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) itemEnhancement.materialIds, itemEnhancement.itemId, itemEnhancement.Id, - ev.BlockIndex)); + ev.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Log.Debug("Stored ItemEnhancement action in block #{index}. Time Taken: {time} ms.", ev.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -534,7 +538,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) _eqList.Add(EquipmentData.GetEquipmentInfo( ev.Signer, itemEnhancement.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -600,7 +605,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) _eqList.Add(EquipmentData.GetEquipmentInfo( ev.Signer, buy.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -704,7 +710,8 @@ protected override Task ExecuteAsync(CancellationToken stoppingToken) _eqList.Add(EquipmentData.GetEquipmentInfo( ev.Signer, buy.AvatarAddress, - equipment)); + equipment, + _blockTimeOffset)); } break; diff --git a/NineChronicles.DataProvider/Store/Models/AuraSummonModel.cs b/NineChronicles.DataProvider/Store/Models/AuraSummonModel.cs index 84f147d6..cc0cab53 100644 --- a/NineChronicles.DataProvider/Store/Models/AuraSummonModel.cs +++ b/NineChronicles.DataProvider/Store/Models/AuraSummonModel.cs @@ -19,8 +19,8 @@ public class AuraSummonModel public int SummonCount { get; set; } - public string? SummonResult { get; set; } - public long BlockIndex { get; set; } + + public string? SummonResult { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/BattleArenaModel.cs b/NineChronicles.DataProvider/Store/Models/BattleArenaModel.cs index 65078674..e72051e1 100644 --- a/NineChronicles.DataProvider/Store/Models/BattleArenaModel.cs +++ b/NineChronicles.DataProvider/Store/Models/BattleArenaModel.cs @@ -34,6 +34,8 @@ public class BattleArenaModel public int MedalCount { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/BlockModel.cs b/NineChronicles.DataProvider/Store/Models/BlockModel.cs index a4e2a958..3974c521 100644 --- a/NineChronicles.DataProvider/Store/Models/BlockModel.cs +++ b/NineChronicles.DataProvider/Store/Models/BlockModel.cs @@ -30,6 +30,8 @@ public class BlockModel public string? TxHash { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/ClaimStakeRewardModel.cs b/NineChronicles.DataProvider/Store/Models/ClaimStakeRewardModel.cs index f161f174..3b0f0e17 100644 --- a/NineChronicles.DataProvider/Store/Models/ClaimStakeRewardModel.cs +++ b/NineChronicles.DataProvider/Store/Models/ClaimStakeRewardModel.cs @@ -24,6 +24,8 @@ public class ClaimStakeRewardModel public long ClaimStakeEndBlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/CombinationConsumableModel.cs b/NineChronicles.DataProvider/Store/Models/CombinationConsumableModel.cs index f42fc4a2..dcaa6bf3 100644 --- a/NineChronicles.DataProvider/Store/Models/CombinationConsumableModel.cs +++ b/NineChronicles.DataProvider/Store/Models/CombinationConsumableModel.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.Store.Models { + using System; using System.ComponentModel.DataAnnotations; public class CombinationConsumableModel @@ -20,5 +21,9 @@ public class CombinationConsumableModel public int SlotIndex { get; set; } public long BlockIndex { get; set; } + + public DateOnly Date { get; set; } + + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/CombinationEquipmentModel.cs b/NineChronicles.DataProvider/Store/Models/CombinationEquipmentModel.cs index eaa7b251..905d2165 100644 --- a/NineChronicles.DataProvider/Store/Models/CombinationEquipmentModel.cs +++ b/NineChronicles.DataProvider/Store/Models/CombinationEquipmentModel.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.Store.Models { + using System; using System.ComponentModel.DataAnnotations; public class CombinationEquipmentModel @@ -22,5 +23,9 @@ public class CombinationEquipmentModel public int? SubRecipeId { get; set; } public long BlockIndex { get; set; } + + public DateOnly Date { get; set; } + + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/CraftRankingInputModel.cs b/NineChronicles.DataProvider/Store/Models/CraftRankingInputModel.cs deleted file mode 100644 index 1aef4ba9..00000000 --- a/NineChronicles.DataProvider/Store/Models/CraftRankingInputModel.cs +++ /dev/null @@ -1,18 +0,0 @@ -namespace NineChronicles.DataProvider.Store.Models -{ - using System.ComponentModel.DataAnnotations; - - public class CraftRankingInputModel - { - [Key] - public string? AvatarAddress { get; set; } - - public string? AgentAddress { get; set; } - - public long BlockIndex { get; set; } - - public int CraftCount { get; set; } - - public int Ranking { get; set; } - } -} diff --git a/NineChronicles.DataProvider/Store/Models/CraftRankingOutputModel.cs b/NineChronicles.DataProvider/Store/Models/CraftRankingModel.cs similarity index 93% rename from NineChronicles.DataProvider/Store/Models/CraftRankingOutputModel.cs rename to NineChronicles.DataProvider/Store/Models/CraftRankingModel.cs index 4b934678..d86663ea 100644 --- a/NineChronicles.DataProvider/Store/Models/CraftRankingOutputModel.cs +++ b/NineChronicles.DataProvider/Store/Models/CraftRankingModel.cs @@ -2,17 +2,17 @@ { using System.ComponentModel.DataAnnotations; - public class CraftRankingOutputModel + public class CraftRankingModel { [Key] public string? AvatarAddress { get; set; } public string? AgentAddress { get; set; } - public long BlockIndex { get; set; } - public int CraftCount { get; set; } + public long BlockIndex { get; set; } + public string? Name { get; set; } public int? AvatarLevel { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentModel.cs index 14296bfd..a887fba0 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentModel.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.Store.Models { + using System; using System.ComponentModel.DataAnnotations; public class EquipmentModel @@ -18,5 +19,7 @@ public class EquipmentModel public int Level { get; set; } public string? ItemSubType { get; set; } + + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs index b2f647ac..e5a4ad59 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingArmorModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingArmorModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs index 3d2afa67..f28a9896 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingBeltModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingBeltModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingModel.cs index 9ba806a5..fee6b56d 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs index a6527a7c..d4eaa7cf 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingNecklaceModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingNecklaceModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs index ce8f3932..9538380d 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingRingModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingRingModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs b/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs index f9c2a606..d8c56ed4 100644 --- a/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EquipmentRankingWeaponModel.cs @@ -7,10 +7,10 @@ public class EquipmentRankingWeaponModel [Key] public string? ItemId { get; set; } - public string? AgentAddress { get; set; } - public string? AvatarAddress { get; set; } + public string? AgentAddress { get; set; } + public int EquipmentId { get; set; } public int Cp { get; set; } diff --git a/NineChronicles.DataProvider/Store/Models/EventConsumableItemCraftsModel.cs b/NineChronicles.DataProvider/Store/Models/EventConsumableItemCraftsModel.cs index 868c8f11..6efdcf7e 100644 --- a/NineChronicles.DataProvider/Store/Models/EventConsumableItemCraftsModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EventConsumableItemCraftsModel.cs @@ -48,6 +48,8 @@ public class EventConsumableItemCraftsModel public long BlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset Timestamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/EventDungeonBattleModel.cs b/NineChronicles.DataProvider/Store/Models/EventDungeonBattleModel.cs index ae4506b2..4ec92c02 100644 --- a/NineChronicles.DataProvider/Store/Models/EventDungeonBattleModel.cs +++ b/NineChronicles.DataProvider/Store/Models/EventDungeonBattleModel.cs @@ -76,6 +76,8 @@ public class EventDungeonBattleModel public long BlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset Timestamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/GrindingModel.cs b/NineChronicles.DataProvider/Store/Models/GrindingModel.cs index 6f49ca95..322d7473 100644 --- a/NineChronicles.DataProvider/Store/Models/GrindingModel.cs +++ b/NineChronicles.DataProvider/Store/Models/GrindingModel.cs @@ -26,6 +26,8 @@ public class GrindingModel public decimal Crystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/HackAndSlashModel.cs b/NineChronicles.DataProvider/Store/Models/HackAndSlashModel.cs index 8a3469a2..2fb8b836 100644 --- a/NineChronicles.DataProvider/Store/Models/HackAndSlashModel.cs +++ b/NineChronicles.DataProvider/Store/Models/HackAndSlashModel.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.Store.Models { + using System; using System.ComponentModel.DataAnnotations; public class HackAndSlashModel @@ -7,14 +8,14 @@ public class HackAndSlashModel [Key] public string? Id { get; set; } - public string? AgentAddress { get; set; } - - public AgentModel? Agent { get; set; } - public string? AvatarAddress { get; set; } public AvatarModel? Avatar { get; set; } + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + public int StageId { get; set; } public bool Cleared { get; set; } @@ -22,5 +23,9 @@ public class HackAndSlashModel public bool Mimisbrunnr { get; set; } public long BlockIndex { get; set; } + + public DateOnly Date { get; set; } + + public DateTimeOffset Timestamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/HackAndSlashSweepModel.cs b/NineChronicles.DataProvider/Store/Models/HackAndSlashSweepModel.cs index fb2bf9b6..dc1b8db9 100644 --- a/NineChronicles.DataProvider/Store/Models/HackAndSlashSweepModel.cs +++ b/NineChronicles.DataProvider/Store/Models/HackAndSlashSweepModel.cs @@ -34,6 +34,8 @@ public class HackAndSlashSweepModel public long BlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset Timestamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/HasRandomBuffModel.cs b/NineChronicles.DataProvider/Store/Models/HasRandomBuffModel.cs index c8c67a32..d9e566d8 100644 --- a/NineChronicles.DataProvider/Store/Models/HasRandomBuffModel.cs +++ b/NineChronicles.DataProvider/Store/Models/HasRandomBuffModel.cs @@ -24,6 +24,8 @@ public class HasRandomBuffModel public decimal BurntCrystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/HasWithRandomBuffModel.cs b/NineChronicles.DataProvider/Store/Models/HasWithRandomBuffModel.cs index 29159f85..0974cc14 100644 --- a/NineChronicles.DataProvider/Store/Models/HasWithRandomBuffModel.cs +++ b/NineChronicles.DataProvider/Store/Models/HasWithRandomBuffModel.cs @@ -24,6 +24,8 @@ public class HasWithRandomBuffModel public bool Cleared { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/ItemEnhancementFailModel.cs b/NineChronicles.DataProvider/Store/Models/ItemEnhancementFailModel.cs index 257db984..9153e4b8 100644 --- a/NineChronicles.DataProvider/Store/Models/ItemEnhancementFailModel.cs +++ b/NineChronicles.DataProvider/Store/Models/ItemEnhancementFailModel.cs @@ -31,6 +31,8 @@ public class ItemEnhancementFailModel public decimal BurntNCG { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs b/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs index fcc809ed..f11be61d 100644 --- a/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs +++ b/NineChronicles.DataProvider/Store/Models/ItemEnhancementModel.cs @@ -1,5 +1,6 @@ namespace NineChronicles.DataProvider.Store.Models { + using System; using System.ComponentModel.DataAnnotations; public class ItemEnhancementModel @@ -7,14 +8,14 @@ public class ItemEnhancementModel [Key] public string? Id { get; set; } - public string? AgentAddress { get; set; } - - public AgentModel? Agent { get; set; } - public string? AvatarAddress { get; set; } public AvatarModel? Avatar { get; set; } + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + public string? ItemId { get; set; } public string? MaterialId { get; set; } @@ -32,5 +33,9 @@ public class ItemEnhancementModel public int? Level { get; set; } public long? Exp { get; set; } + + public DateOnly Date { get; set; } + + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/JoinArenaModel.cs b/NineChronicles.DataProvider/Store/Models/JoinArenaModel.cs index 23986582..0b4add4b 100644 --- a/NineChronicles.DataProvider/Store/Models/JoinArenaModel.cs +++ b/NineChronicles.DataProvider/Store/Models/JoinArenaModel.cs @@ -26,6 +26,8 @@ public class JoinArenaModel public decimal BurntCrystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/MigrateMonsterCollectionModel.cs b/NineChronicles.DataProvider/Store/Models/MigrateMonsterCollectionModel.cs index fd2cf327..82586802 100644 --- a/NineChronicles.DataProvider/Store/Models/MigrateMonsterCollectionModel.cs +++ b/NineChronicles.DataProvider/Store/Models/MigrateMonsterCollectionModel.cs @@ -18,6 +18,8 @@ public class MigrateMonsterCollectionModel public long StakeStartBlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/ReplaceCombinationEquipmentMaterialModel.cs b/NineChronicles.DataProvider/Store/Models/ReplaceCombinationEquipmentMaterialModel.cs index 4f78b8e8..63791e70 100644 --- a/NineChronicles.DataProvider/Store/Models/ReplaceCombinationEquipmentMaterialModel.cs +++ b/NineChronicles.DataProvider/Store/Models/ReplaceCombinationEquipmentMaterialModel.cs @@ -24,6 +24,8 @@ public class ReplaceCombinationEquipmentMaterialModel public decimal BurntCrystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/StageRankingModel.cs b/NineChronicles.DataProvider/Store/Models/StageRankingModel.cs index 548e699d..7248a6c5 100644 --- a/NineChronicles.DataProvider/Store/Models/StageRankingModel.cs +++ b/NineChronicles.DataProvider/Store/Models/StageRankingModel.cs @@ -4,15 +4,13 @@ public class StageRankingModel { - public int Ranking { get; set; } - - public int ClearedStageId { get; set; } - [Key] public string? AvatarAddress { get; set; } public string? AgentAddress { get; set; } + public int ClearedStageId { get; set; } + public string? Name { get; set; } public int? AvatarLevel { get; set; } @@ -24,5 +22,7 @@ public class StageRankingModel public int? Cp { get; set; } public long BlockIndex { get; set; } + + public int Ranking { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/StakeModel.cs b/NineChronicles.DataProvider/Store/Models/StakeModel.cs index 91bf89c8..fbe7f8dd 100644 --- a/NineChronicles.DataProvider/Store/Models/StakeModel.cs +++ b/NineChronicles.DataProvider/Store/Models/StakeModel.cs @@ -21,6 +21,8 @@ public class StakeModel public long NewStakeStartBlockIndex { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/UnlockEquipmentRecipeModel.cs b/NineChronicles.DataProvider/Store/Models/UnlockEquipmentRecipeModel.cs index c2153a32..ebf29d95 100644 --- a/NineChronicles.DataProvider/Store/Models/UnlockEquipmentRecipeModel.cs +++ b/NineChronicles.DataProvider/Store/Models/UnlockEquipmentRecipeModel.cs @@ -22,6 +22,8 @@ public class UnlockEquipmentRecipeModel public decimal BurntCrystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/UnlockWorldModel.cs b/NineChronicles.DataProvider/Store/Models/UnlockWorldModel.cs index c5f4bdca..f0ca1ff2 100644 --- a/NineChronicles.DataProvider/Store/Models/UnlockWorldModel.cs +++ b/NineChronicles.DataProvider/Store/Models/UnlockWorldModel.cs @@ -22,6 +22,8 @@ public class UnlockWorldModel public decimal BurntCrystal { get; set; } + public DateOnly Date { get; set; } + public DateTimeOffset TimeStamp { get; set; } } } diff --git a/NineChronicles.DataProvider/Store/Models/UserConsumablesModel.cs b/NineChronicles.DataProvider/Store/Models/UserConsumablesModel.cs new file mode 100644 index 00000000..26d76817 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserConsumablesModel.cs @@ -0,0 +1,43 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserConsumablesModel + { + public long? BlockIndex { get; set; } + + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public string? AvatarAddress { get; set; } + + public AvatarModel? Avatar { get; set; } + + public string? ItemType { get; set; } + + public string? ItemSubType { get; set; } + + public int? Id { get; set; } + + public int? BuffSkillCount { get; set; } + + public string? ElementalType { get; set; } + + public int? Grade { get; set; } + + public int? SkillsCount { get; set; } + + public long? RequiredBlockIndex { get; set; } + + public string? NonFungibleId { get; set; } + + public string? TradableId { get; set; } + + public string? MainStat { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserCostumesModel.cs b/NineChronicles.DataProvider/Store/Models/UserCostumesModel.cs new file mode 100644 index 00000000..f0ae9e43 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserCostumesModel.cs @@ -0,0 +1,41 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserCostumesModel + { + public long? BlockIndex { get; set; } + + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public string? AvatarAddress { get; set; } + + public AvatarModel? Avatar { get; set; } + + public string? ItemType { get; set; } + + public string? ItemSubType { get; set; } + + public int? Id { get; set; } + + public string? ElementalType { get; set; } + + public int? Grade { get; set; } + + public bool? Equipped { get; set; } + + public string? SpineResourcePath { get; set; } + + public long? RequiredBlockIndex { get; set; } + + public string? NonFungibleId { get; set; } + + public string? TradableId { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserCrystalsModel.cs b/NineChronicles.DataProvider/Store/Models/UserCrystalsModel.cs new file mode 100644 index 00000000..0b4c0f16 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserCrystalsModel.cs @@ -0,0 +1,17 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserCrystalsModel + { + public long? BlockIndex { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public decimal? CrystalBalance { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserEquipmentsModel.cs b/NineChronicles.DataProvider/Store/Models/UserEquipmentsModel.cs new file mode 100644 index 00000000..f993c034 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserEquipmentsModel.cs @@ -0,0 +1,45 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserEquipmentsModel + { + public long? BlockIndex { get; set; } + + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public string? AvatarAddress { get; set; } + + public string? ItemType { get; set; } + + public string? ItemSubType { get; set; } + + public int? Id { get; set; } + + public int? BuffSkillCount { get; set; } + + public string? ElementalType { get; set; } + + public int? Grade { get; set; } + + public int? Level { get; set; } + + public int? SetId { get; set; } + + public int? SkillsCount { get; set; } + + public string? SpineResourcePath { get; set; } + + public long? RequiredBlockIndex { get; set; } + + public string? NonFungibleId { get; set; } + + public string? TradableId { get; set; } + + public string? UniqueStatType { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserMaterialsModel.cs b/NineChronicles.DataProvider/Store/Models/UserMaterialsModel.cs new file mode 100644 index 00000000..2ace0b92 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserMaterialsModel.cs @@ -0,0 +1,33 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserMaterialsModel + { + public long? BlockIndex { get; set; } + + public string? ItemId { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public string? AvatarAddress { get; set; } + + public AvatarModel? Avatar { get; set; } + + public string? ItemType { get; set; } + + public string? ItemSubType { get; set; } + + public int? Count { get; set; } + + public int? Id { get; set; } + + public string? ElementalType { get; set; } + + public int? Grade { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserMonsterCollectionsModel.cs b/NineChronicles.DataProvider/Store/Models/UserMonsterCollectionsModel.cs new file mode 100644 index 00000000..04c22b1c --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserMonsterCollectionsModel.cs @@ -0,0 +1,27 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserMonsterCollectionsModel + { + public long? BlockIndex { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public decimal? MonsterCollectionAmount { get; set; } + + public int? Level { get; set; } + + public long? RewardLevel { get; set; } + + public long? StartedBlockIndex { get; set; } + + public long? ReceivedBlockIndex { get; set; } + + public long? ExpiredBlockIndex { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserNCGsModel.cs b/NineChronicles.DataProvider/Store/Models/UserNCGsModel.cs new file mode 100644 index 00000000..09996c3d --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserNCGsModel.cs @@ -0,0 +1,17 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserNCGsModel + { + public long? BlockIndex { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public decimal? NCGBalance { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserRunesModel.cs b/NineChronicles.DataProvider/Store/Models/UserRunesModel.cs new file mode 100644 index 00000000..a2534e76 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserRunesModel.cs @@ -0,0 +1,23 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserRunesModel + { + public long? BlockIndex { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public string? AvatarAddress { get; set; } + + public AvatarModel? Avatar { get; set; } + + public string? Ticker { get; set; } + + public decimal? RuneBalance { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/Models/UserStakingsModel.cs b/NineChronicles.DataProvider/Store/Models/UserStakingsModel.cs new file mode 100644 index 00000000..7b59bde2 --- /dev/null +++ b/NineChronicles.DataProvider/Store/Models/UserStakingsModel.cs @@ -0,0 +1,23 @@ +namespace NineChronicles.DataProvider.Store.Models +{ + using System; + + public class UserStakingsModel + { + public long? BlockIndex { get; set; } + + public string? AgentAddress { get; set; } + + public AgentModel? Agent { get; set; } + + public decimal? StakeAmount { get; set; } + + public long? StartedBlockIndex { get; set; } + + public long? ReceivedBlockIndex { get; set; } + + public long? CancellableBlockIndex { get; set; } + + public DateTimeOffset? TimeStamp { get; set; } + } +} diff --git a/NineChronicles.DataProvider/Store/MySqlStore.cs b/NineChronicles.DataProvider/Store/MySqlStore.cs index fd8fb45f..ceb166d7 100644 --- a/NineChronicles.DataProvider/Store/MySqlStore.cs +++ b/NineChronicles.DataProvider/Store/MySqlStore.cs @@ -593,7 +593,7 @@ public void StoreCombinationConsumable( else { ctx.CraftRankings!.Add( - new CraftRankingInputModel() + new CraftRankingModel() { AgentAddress = agentAddress.ToString(), AvatarAddress = avatarAddress.ToString(), @@ -697,7 +697,7 @@ public void StoreCombinationEquipment( else { ctx.CraftRankings!.Add( - new CraftRankingInputModel() + new CraftRankingModel() { AgentAddress = agentAddress.ToString(), AvatarAddress = avatarAddress.ToString(), @@ -979,7 +979,7 @@ public void StoreItemEnhancement( else { ctx.CraftRankings!.Add( - new CraftRankingInputModel() + new CraftRankingModel() { AgentAddress = agentAddress.ToString(), AvatarAddress = avatarAddress.ToString(), @@ -1950,12 +1950,12 @@ public void StorePetEnhancementList(List petEnhancementList } } - public IEnumerable GetCraftRanking( + public IEnumerable GetCraftRanking( Address? avatarAddress = null, int? limit = null) { using NineChroniclesContext ctx = _dbContextFactory.CreateDbContext(); - var query = ctx.Set() + var query = ctx.Set() .FromSqlRaw("SELECT * FROM CraftRankings ORDER BY Ranking "); if (avatarAddress is { } avatarAddressNotNull) diff --git a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs index 1bfb5fa1..e58e998d 100644 --- a/NineChronicles.DataProvider/Store/NineChroniclesContext.cs +++ b/NineChronicles.DataProvider/Store/NineChroniclesContext.cs @@ -26,9 +26,7 @@ public NineChroniclesContext(DbContextOptions options) public DbSet? ItemEnhancements { get; set; } // Table for ranking avatars' total craft counts - public DbSet? CraftRankings { get; set; } - - public DbSet? CraftRankingsOutput { get; set; } + public DbSet? CraftRankings { get; set; } // Table for storing avatar information public DbSet? Avatars { get; set; } @@ -180,6 +178,24 @@ public NineChroniclesContext(DbContextOptions options) public DbSet AuraSummonFails => Set(); + public DbSet UserConsumables => Set(); + + public DbSet UserCostumes => Set(); + + public DbSet UserCrystals => Set(); + + public DbSet UserEquipments => Set(); + + public DbSet UserMaterials => Set(); + + public DbSet UserMonsterCollections => Set(); + + public DbSet UserNCGs => Set(); + + public DbSet UserRunes => Set(); + + public DbSet UserStakings => Set(); + /* * This override method enables EF database update & migration when certain models are required for data querying, * but tables constructed by these models are not needed. @@ -188,7 +204,7 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) { modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); - modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); modelBuilder.Entity().HasNoKey(); @@ -206,6 +222,15 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) modelBuilder.Entity() .HasNoKey() .ToTable("WorldBossRankings", t => t.ExcludeFromMigrations()); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); + modelBuilder.Entity().HasNoKey(); } } } From fed9b44af5d3bf2c5db3384cdf1440cc3933e721 Mon Sep 17 00:00:00 2001 From: area363 Date: Mon, 6 Nov 2023 20:52:41 +0900 Subject: [PATCH 12/13] add migrations --- .../Commands/MySqlMigration.cs | 222 +- ...231106114947_AddUserDataTables.Designer.cs | 3525 +++++++++++++++++ .../20231106114947_AddUserDataTables.cs | 774 ++++ .../NineChroniclesContextModelSnapshot.cs | 539 ++- 4 files changed, 4962 insertions(+), 98 deletions(-) create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.Designer.cs create mode 100644 NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.cs diff --git a/NineChronicles.DataProvider.Executable/Commands/MySqlMigration.cs b/NineChronicles.DataProvider.Executable/Commands/MySqlMigration.cs index 47431a1c..bf0f6263 100644 --- a/NineChronicles.DataProvider.Executable/Commands/MySqlMigration.cs +++ b/NineChronicles.DataProvider.Executable/Commands/MySqlMigration.cs @@ -1045,7 +1045,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable.recipeId, combinationConsumable.slotIndex, combinationConsumable.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1061,7 +1062,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable7.recipeId, combinationConsumable7.slotIndex, combinationConsumable7.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1077,7 +1079,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable6.recipeId, combinationConsumable6.slotIndex, combinationConsumable6.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1093,7 +1096,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable5.recipeId, combinationConsumable5.slotIndex, combinationConsumable5.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1109,7 +1113,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable4.recipeId, combinationConsumable4.slotIndex, combinationConsumable4.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1125,7 +1130,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable3.recipeId, combinationConsumable3.slotIndex, combinationConsumable3.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1141,7 +1147,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable2.recipeId, combinationConsumable2.slotIndex, combinationConsumable2.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1157,7 +1164,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationConsumable0.recipeId, combinationConsumable0.slotIndex, combinationConsumable0.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing CombinationConsumable action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); } @@ -1174,7 +1182,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment.slotIndex, combinationEquipment.subRecipeId, combinationEquipment.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); if (combinationEquipment.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -1211,7 +1220,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1234,7 +1244,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment15.slotIndex, combinationEquipment15.subRecipeId, combinationEquipment15.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); if (combinationEquipment15.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -1271,7 +1282,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment15.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1294,7 +1306,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment14.slotIndex, combinationEquipment14.subRecipeId, combinationEquipment14.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); if (combinationEquipment14.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -1331,7 +1344,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment14.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1354,7 +1368,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment13.slotIndex, combinationEquipment13.subRecipeId, combinationEquipment13.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); if (combinationEquipment13.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -1391,7 +1406,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment13.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1414,7 +1430,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment12.slotIndex, combinationEquipment12.subRecipeId, combinationEquipment12.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); if (combinationEquipment12.payByCrystal) { var replaceCombinationEquipmentMaterialList = ReplaceCombinationEquipmentMaterialData @@ -1451,7 +1468,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment12.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1474,7 +1492,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment11.slotIndex, combinationEquipment11.subRecipeId, combinationEquipment11.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1492,7 +1511,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment11.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1515,7 +1535,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment10.slotIndex, combinationEquipment10.subRecipeId, combinationEquipment10.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1533,7 +1554,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment10.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1556,7 +1578,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment9.slotIndex, combinationEquipment9.subRecipeId, combinationEquipment9.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1574,7 +1597,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment9.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1597,7 +1621,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment8.slotIndex, combinationEquipment8.subRecipeId, combinationEquipment8.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1615,7 +1640,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment8.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1638,7 +1664,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment7.SlotIndex, combinationEquipment7.SubRecipeId, combinationEquipment7.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1656,7 +1683,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment7.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1679,7 +1707,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment6.SlotIndex, combinationEquipment6.SubRecipeId, combinationEquipment6.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1697,7 +1726,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment6.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1720,7 +1750,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment5.SlotIndex, combinationEquipment5.SubRecipeId, combinationEquipment5.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1738,7 +1769,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment5.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1761,7 +1793,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment4.SlotIndex, combinationEquipment4.SubRecipeId, combinationEquipment4.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1779,7 +1812,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment4.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1802,7 +1836,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment3.SlotIndex, combinationEquipment3.SubRecipeId, combinationEquipment3.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1820,7 +1855,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment3.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1843,7 +1879,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment2.SlotIndex, combinationEquipment2.SubRecipeId, combinationEquipment2.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1861,7 +1898,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment2.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1884,7 +1922,8 @@ private void ProcessTasks(Task>[] taskArray, IB combinationEquipment0.SlotIndex, combinationEquipment0.SubRecipeId, combinationEquipment0.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine( @@ -1902,7 +1941,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, combinationEquipment0.AvatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1941,7 +1981,8 @@ private void ProcessTasks(Task>[] taskArray, IB itemEnhancement.materialIds, itemEnhancement.itemId, itemEnhancement.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -1955,7 +1996,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -1994,7 +2036,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement10.itemId, itemEnhancement10.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2008,7 +2051,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement10.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2047,7 +2091,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement9.itemId, itemEnhancement9.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2061,7 +2106,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement9.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2100,7 +2146,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement8.itemId, itemEnhancement8.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2114,7 +2161,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement8.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2153,7 +2201,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement7.itemId, itemEnhancement7.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2167,7 +2216,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement7.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2206,7 +2256,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement6.itemId, itemEnhancement6.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2220,7 +2271,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement6.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2259,7 +2311,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement5.itemId, itemEnhancement5.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2273,7 +2326,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement5.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2312,7 +2366,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement4.itemId, itemEnhancement4.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2326,7 +2381,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement4.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2365,7 +2421,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement3.itemId, itemEnhancement3.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2379,7 +2436,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement3.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2418,7 +2476,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement2.itemId, itemEnhancement2.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2432,7 +2491,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement2.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2471,7 +2531,8 @@ private void ProcessTasks(Task>[] taskArray, IB new List(), itemEnhancement0.itemId, itemEnhancement0.Id, - ae.InputContext.BlockIndex)); + ae.InputContext.BlockIndex, + _blockTimeOffset)); var end = DateTimeOffset.UtcNow; Console.WriteLine("Writing ItemEnhancement action in block #{0}. Time Taken: {1} ms.", ae.InputContext.BlockIndex, (end - start).Milliseconds); start = DateTimeOffset.UtcNow; @@ -2485,7 +2546,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, itemEnhancement0.avatarAddress, - (Equipment)slotState.Result.itemUsable)); + (Equipment)slotState.Result.itemUsable, + _blockTimeOffset)); } end = DateTimeOffset.UtcNow; @@ -2585,7 +2647,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -2687,7 +2750,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy11.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -2789,7 +2853,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy10.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -2891,7 +2956,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy9.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -2993,7 +3059,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy8.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -3095,7 +3162,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy7.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -3197,7 +3265,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy6.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -3299,7 +3368,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy5.buyerAvatarAddress, - equipmentNotNull)); + equipmentNotNull, + _blockTimeOffset)); } } } @@ -3333,7 +3403,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy4.buyerAvatarAddress, - equipment)); + equipment, + _blockTimeOffset)); } if (shopItem.ItemUsable.ItemType == ItemType.Costume) @@ -3407,7 +3478,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy3.buyerAvatarAddress, - equipment)); + equipment, + _blockTimeOffset)); } if (shopItem.ItemUsable.ItemType == ItemType.Costume) @@ -3481,7 +3553,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy2.buyerAvatarAddress, - equipment)); + equipment, + _blockTimeOffset)); } if (shopItem.ItemUsable.ItemType == ItemType.Costume) @@ -3555,7 +3628,8 @@ private void ProcessTasks(Task>[] taskArray, IB _equipmentList.Add(EquipmentData.GetEquipmentInfo( ae.InputContext.Signer, buy0.buyerAvatarAddress, - equipment)); + equipment, + _blockTimeOffset)); } if (shopItem.ItemUsable.ItemType == ItemType.Costume) diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.Designer.cs b/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.Designer.cs new file mode 100644 index 00000000..4708e01b --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.Designer.cs @@ -0,0 +1,3525 @@ +// +using System; +using Microsoft.EntityFrameworkCore; +using Microsoft.EntityFrameworkCore.Infrastructure; +using Microsoft.EntityFrameworkCore.Migrations; +using Microsoft.EntityFrameworkCore.Storage.ValueConversion; +using NineChronicles.DataProvider.Store; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + [DbContext(typeof(NineChroniclesContext))] + [Migration("20231106114947_AddUserDataTables")] + partial class AddUserDataTables + { + protected override void BuildTargetModel(ModelBuilder modelBuilder) + { +#pragma warning disable 612, 618 + modelBuilder + .HasAnnotation("ProductVersion", "6.0.1") + .HasAnnotation("Relational:MaxIdentifierLength", 64); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AbilityRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("AbilityRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AgentModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.HasKey("Address"); + + b.ToTable("Agents"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Exception") + .HasColumnType("longtext"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummonFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("GroupId") + .HasColumnType("int"); + + b.Property("SummonCount") + .HasColumnType("int"); + + b.Property("SummonResult") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("AuraSummons"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.Property("Address") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.HasKey("Address"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Avatars"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EnemyAvatarAddress") + .HasColumnType("longtext"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("TicketCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaRankingModel", b => + { + b.Property("AdditionalTicketPrice") + .HasColumnType("bigint"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArenaType") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EndBlockIndex") + .HasColumnType("bigint"); + + b.Property("EntranceFee") + .HasColumnType("bigint"); + + b.Property("LossCount") + .HasColumnType("int"); + + b.Property("MedalCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("PurchasedTicketCount") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("RequiredMedalCount") + .HasColumnType("int"); + + b.Property("Round") + .HasColumnType("int"); + + b.Property("Score") + .HasColumnType("int"); + + b.Property("StartBlockIndex") + .HasColumnType("bigint"); + + b.Property("Ticket") + .HasColumnType("int"); + + b.Property("TicketPrice") + .HasColumnType("bigint"); + + b.Property("TicketResetCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.Property("WinCount") + .HasColumnType("int"); + + b.ToTable("BattleArenaRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EnemyAvatarAddress") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("GrandFinaleId") + .HasColumnType("int"); + + b.Property("GrandFinaleScore") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("Victory") + .HasColumnType("tinyint(1)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("BattleGrandFinales"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BlockModel", b => + { + b.Property("Hash") + .HasColumnType("varchar(255)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Difficulty") + .HasColumnType("bigint"); + + b.Property("Index") + .HasColumnType("bigint"); + + b.Property("Miner") + .HasColumnType("longtext"); + + b.Property("Nonce") + .HasColumnType("longtext"); + + b.Property("PreviousHash") + .HasColumnType("longtext"); + + b.Property("ProtocolVersion") + .HasColumnType("int"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("StateRootHash") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TotalDifficulty") + .HasColumnType("bigint"); + + b.Property("TxCount") + .HasColumnType("int"); + + b.Property("TxHash") + .HasColumnType("longtext"); + + b.HasKey("Hash"); + + b.ToTable("Blocks"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApPotionCount") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimRewardAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ClaimStakeEndBlockIndex") + .HasColumnType("bigint"); + + b.Property("ClaimStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("HourGlassCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.ToTable("ClaimStakeRewards"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("RecipeId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("SubRecipeId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("CombinationEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CraftCount") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("CraftRankings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("ItemId"); + + b.ToTable("Equipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingArmorModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingArmor"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingBeltModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingBelt"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingNecklaceModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingNecklace"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingRingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingRing"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentRankingWeaponModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("EquipmentRankingWeapon"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EventConsumableItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("RequiredItem1Count") + .HasColumnType("int"); + + b.Property("RequiredItem1Id") + .HasColumnType("int"); + + b.Property("RequiredItem2Count") + .HasColumnType("int"); + + b.Property("RequiredItem2Id") + .HasColumnType("int"); + + b.Property("RequiredItem3Count") + .HasColumnType("int"); + + b.Property("RequiredItem3Id") + .HasColumnType("int"); + + b.Property("RequiredItem4Count") + .HasColumnType("int"); + + b.Property("RequiredItem4Id") + .HasColumnType("int"); + + b.Property("RequiredItem5Count") + .HasColumnType("int"); + + b.Property("RequiredItem5Id") + .HasColumnType("int"); + + b.Property("RequiredItem6Count") + .HasColumnType("int"); + + b.Property("RequiredItem6Id") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventConsumableItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("EventDungeonId") + .HasColumnType("int"); + + b.Property("EventDungeonStageId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("FoodsCount") + .HasColumnType("int"); + + b.Property("RemainingTickets") + .HasColumnType("int"); + + b.Property("RewardItem10Count") + .HasColumnType("int"); + + b.Property("RewardItem10Id") + .HasColumnType("int"); + + b.Property("RewardItem1Count") + .HasColumnType("int"); + + b.Property("RewardItem1Id") + .HasColumnType("int"); + + b.Property("RewardItem2Count") + .HasColumnType("int"); + + b.Property("RewardItem2Id") + .HasColumnType("int"); + + b.Property("RewardItem3Count") + .HasColumnType("int"); + + b.Property("RewardItem3Id") + .HasColumnType("int"); + + b.Property("RewardItem4Count") + .HasColumnType("int"); + + b.Property("RewardItem4Id") + .HasColumnType("int"); + + b.Property("RewardItem5Count") + .HasColumnType("int"); + + b.Property("RewardItem5Id") + .HasColumnType("int"); + + b.Property("RewardItem6Count") + .HasColumnType("int"); + + b.Property("RewardItem6Id") + .HasColumnType("int"); + + b.Property("RewardItem7Count") + .HasColumnType("int"); + + b.Property("RewardItem7Id") + .HasColumnType("int"); + + b.Property("RewardItem8Count") + .HasColumnType("int"); + + b.Property("RewardItem8Id") + .HasColumnType("int"); + + b.Property("RewardItem9Count") + .HasColumnType("int"); + + b.Property("RewardItem9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventDungeonBattles"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("EventMaterialItemRecipeId") + .HasColumnType("int"); + + b.Property("EventScheduleId") + .HasColumnType("int"); + + b.Property("Material10Count") + .HasColumnType("int"); + + b.Property("Material10Id") + .HasColumnType("int"); + + b.Property("Material11Count") + .HasColumnType("int"); + + b.Property("Material11Id") + .HasColumnType("int"); + + b.Property("Material12Count") + .HasColumnType("int"); + + b.Property("Material12Id") + .HasColumnType("int"); + + b.Property("Material1Count") + .HasColumnType("int"); + + b.Property("Material1Id") + .HasColumnType("int"); + + b.Property("Material2Count") + .HasColumnType("int"); + + b.Property("Material2Id") + .HasColumnType("int"); + + b.Property("Material3Count") + .HasColumnType("int"); + + b.Property("Material3Id") + .HasColumnType("int"); + + b.Property("Material4Count") + .HasColumnType("int"); + + b.Property("Material4Id") + .HasColumnType("int"); + + b.Property("Material5Count") + .HasColumnType("int"); + + b.Property("Material5Id") + .HasColumnType("int"); + + b.Property("Material6Count") + .HasColumnType("int"); + + b.Property("Material6Id") + .HasColumnType("int"); + + b.Property("Material7Count") + .HasColumnType("int"); + + b.Property("Material7Id") + .HasColumnType("int"); + + b.Property("Material8Count") + .HasColumnType("int"); + + b.Property("Material8Id") + .HasColumnType("int"); + + b.Property("Material9Count") + .HasColumnType("int"); + + b.Property("Material9Id") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("EventMaterialItemCrafts"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Crystal") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EquipmentId") + .HasColumnType("int"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("Grindings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionPoint") + .HasColumnType("int"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ApStoneCount") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("CostumesCount") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EquipmentsCount") + .HasColumnType("int"); + + b.Property("Mimisbrunnr") + .HasColumnType("tinyint(1)"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + + b.Property("WorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HackAndSlashSweeps"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("GachaCount") + .HasColumnType("int"); + + b.Property("HasStageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffId") + .HasColumnType("int"); + + b.Property("Cleared") + .HasColumnType("tinyint(1)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("StageId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("HasWithRandomBuffs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("EquipmentItemId") + .HasColumnType("longtext"); + + b.Property("EquipmentLevel") + .HasColumnType("int"); + + b.Property("GainedCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("MaterialItemId") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancementFails"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Exp") + .HasColumnType("bigint"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("MaterialId") + .HasColumnType("longtext"); + + b.Property("MaterialIdsCount") + .HasColumnType("int"); + + b.Property("SheetId") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ItemEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("ArenaRound") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("ChampionshipId") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("JoinArenas"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("MigrationAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("MigrationStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("StakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("MigrateMonsterCollections"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntSoulStone") + .HasColumnType("decimal(65,30)"); + + b.Property("ChangedLevel") + .HasColumnType("int"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("OutputPetLevel") + .HasColumnType("int"); + + b.Property("PetId") + .HasColumnType("int"); + + b.Property("PreviousPetLevel") + .HasColumnType("int"); + + b.Property("TargetLevel") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("PetEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RaiderModel", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("Address") + .IsRequired() + .HasColumnType("varchar(255)"); + + b.Property("AvatarName") + .IsRequired() + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("CreatedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("PurchaseCount") + .HasColumnType("int"); + + b.Property("RaidId") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.Property("UpdatedAt") + .ValueGeneratedOnAddOrUpdate() + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("RaidId", "Address") + .IsUnique(); + + b.ToTable("Raiders"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("HourglassCount") + .HasColumnType("int"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RapidCombinations"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("ReplacedMaterialCount") + .HasColumnType("int"); + + b.Property("ReplacedMaterialId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("ReplaceCombinationEquipmentMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RequestPledgeModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("PledgeAgentAddress") + .HasColumnType("longtext"); + + b.Property("RefillMead") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxSigner") + .HasColumnType("longtext"); + + b.HasKey("TxId"); + + b.ToTable("RequestPledges"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("BurntRune") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("OutputRuneLevel") + .HasColumnType("int"); + + b.Property("PreviousRuneLevel") + .HasColumnType("int"); + + b.Property("RuneId") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TryCount") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("RuneEnhancements"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("varchar(255)"); + + b.Property("TickerType") + .HasColumnType("varchar(255)"); + + b.Property("AcquiredRune") + .HasColumnType("decimal(65,30)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id", "ActionType", "TickerType"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.HasIndex("Id", "ActionType", "TickerType") + .IsUnique(); + + b.ToTable("RunesAcquired"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopConsumableModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopCostumeModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopEquipmentModel", b => + { + b.Property("ItemId") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("ItemId"); + + b.ToTable("ShopEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryConsumableModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryCostumeModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryEquipmentModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryFungibleAssetValueModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("Quantity") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("Ticker") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryFungibleAssetValues"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopHistoryMaterialModel", b => + { + b.Property("OrderId") + .HasColumnType("varchar(255)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuyerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("OrderId"); + + b.ToTable("ShopHistoryMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ShopMaterialModel", b => + { + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CombatPoint") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemCount") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("OrderId") + .HasColumnType("longtext"); + + b.Property("Price") + .HasColumnType("decimal(65,30)"); + + b.Property("SellExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellStartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("SellerAgentAddress") + .HasColumnType("longtext"); + + b.Property("SellerAvatarAddress") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.ToTable("ShopMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StageRankingModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("ArmorId") + .HasColumnType("int"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("AvatarLevel") + .HasColumnType("int"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ClearedStageId") + .HasColumnType("int"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("Name") + .HasColumnType("longtext"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TitleId") + .HasColumnType("int"); + + b.ToTable("StageRanking"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("NewAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("NewStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PrevStakeStartBlockIndex") + .HasColumnType("bigint"); + + b.Property("PreviousAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("RemainingNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("Stakings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransactionModel", b => + { + b.Property("TxId") + .HasColumnType("varchar(255)"); + + b.Property("ActionType") + .HasColumnType("longtext"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("datetime(6)"); + + b.Property("Nonce") + .HasColumnType("bigint"); + + b.Property("PublicKey") + .HasColumnType("longtext"); + + b.Property("Signer") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UpdatedAddressesCount") + .HasColumnType("int"); + + b.HasKey("TxId"); + + b.ToTable("Transactions"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.TransferAssetModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("Amount") + .HasColumnType("decimal(65,30)"); + + b.Property("BlockHash") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("Recipient") + .HasColumnType("longtext"); + + b.Property("Sender") + .HasColumnType("longtext"); + + b.Property("TickerType") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TxId") + .HasColumnType("longtext"); + + b.HasKey("Id"); + + b.ToTable("TransferAssets"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockEquipmentRecipeId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockEquipmentRecipes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntNCG") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("SlotIndex") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockRuneSlots"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.Property("Id") + .HasColumnType("varchar(255)"); + + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BurntCrystal") + .HasColumnType("decimal(65,30)"); + + b.Property("Date") + .HasColumnType("date"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("UnlockWorldId") + .HasColumnType("int"); + + b.HasKey("Id"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UnlockWorlds"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserConsumablesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCostumesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCrystalsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CrystalBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserCrystals"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserEquipmentsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.ToTable("UserEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMaterialsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMonsterCollectionsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("MonsterCollectionAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("ReceivedBlockIndex") + .HasColumnType("bigint"); + + b.Property("RewardLevel") + .HasColumnType("bigint"); + + b.Property("StartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserMonsterCollections"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserNCGsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("NCGBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserNCGs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserRunesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RuneBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("Ticker") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserRunes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserStakingsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CancellableBlockIndex") + .HasColumnType("bigint"); + + b.Property("ReceivedBlockIndex") + .HasColumnType("bigint"); + + b.Property("StakeAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("StartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserStakings"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossRankingModel", b => + { + b.Property("Address") + .HasColumnType("longtext"); + + b.Property("AvatarName") + .HasColumnType("longtext"); + + b.Property("Cp") + .HasColumnType("int"); + + b.Property("HighScore") + .HasColumnType("int"); + + b.Property("IconId") + .HasColumnType("int"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("Ranking") + .HasColumnType("int"); + + b.Property("TotalScore") + .HasColumnType("int"); + + b.ToTable("WorldBossRankings", null, t => t.ExcludeFromMigrations()); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossSeasonMigrationModel", b => + { + b.Property("RaidId") + .ValueGeneratedOnAdd() + .HasColumnType("int"); + + b.Property("MigratedAt") + .ValueGeneratedOnAdd() + .HasColumnType("datetime(6)"); + + b.HasKey("RaidId"); + + b.HasIndex("RaidId") + .IsUnique(); + + b.ToTable("WorldBossSeasonMigrationModels"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AuraSummonModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.AvatarModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.BattleGrandFinaleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ClaimStakeRewardModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationConsumableModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CombinationEquipmentModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventConsumableItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventDungeonBattleModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EventMaterialItemCraftsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.GrindingModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HackAndSlashSweepModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.HasWithRandomBuffModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementFailModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ItemEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.JoinArenaModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.MigrateMonsterCollectionModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.PetEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RapidCombinationModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.ReplaceCombinationEquipmentMaterialModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RuneEnhancementModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.RunesAcquiredModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.StakeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockEquipmentRecipeModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockRuneSlotModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UnlockWorldModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserConsumablesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCostumesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCrystalsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMaterialsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMonsterCollectionsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserNCGsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserRunesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserStakingsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); +#pragma warning restore 612, 618 + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.cs b/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.cs new file mode 100644 index 00000000..d519cda9 --- /dev/null +++ b/NineChronicles.DataProvider.Executable/Migrations/20231106114947_AddUserDataTables.cs @@ -0,0 +1,774 @@ +using System; +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace NineChronicles.DataProvider.Executable.Migrations +{ + public partial class AddUserDataTables : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "CraftRankingsOutput"); + + migrationBuilder.DropPrimaryKey( + name: "PK_CraftRankings", + table: "CraftRankings"); + + migrationBuilder.AddColumn( + name: "Date", + table: "UnlockWorlds", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "UnlockEquipmentRecipes", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "Stakings", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "ReplaceCombinationEquipmentMaterials", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "MigrateMonsterCollections", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "JoinArenas", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "ItemEnhancements", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "TimeStamp", + table: "ItemEnhancements", + type: "datetime(6)", + nullable: false, + defaultValue: new DateTimeOffset(new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0))); + + migrationBuilder.AddColumn( + name: "Date", + table: "ItemEnhancementFails", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "HasWithRandomBuffs", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "HasRandomBuffs", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "HackAndSlashSweeps", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "HackAndSlashes", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Timestamp", + table: "HackAndSlashes", + type: "datetime(6)", + nullable: false, + defaultValue: new DateTimeOffset(new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0))); + + migrationBuilder.AddColumn( + name: "Date", + table: "Grindings", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "EventDungeonBattles", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "EventConsumableItemCrafts", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "TimeStamp", + table: "Equipments", + type: "datetime(6)", + nullable: false, + defaultValue: new DateTimeOffset(new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0))); + + migrationBuilder.AlterColumn( + name: "AvatarAddress", + table: "CraftRankings", + type: "longtext", + nullable: true, + oldClrType: typeof(string), + oldType: "varchar(255)") + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AddColumn( + name: "ArmorId", + table: "CraftRankings", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "AvatarLevel", + table: "CraftRankings", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "Cp", + table: "CraftRankings", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "Name", + table: "CraftRankings", + type: "longtext", + nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AddColumn( + name: "TitleId", + table: "CraftRankings", + type: "int", + nullable: true); + + migrationBuilder.AddColumn( + name: "Date", + table: "CombinationEquipments", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "TimeStamp", + table: "CombinationEquipments", + type: "datetime(6)", + nullable: false, + defaultValue: new DateTimeOffset(new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0))); + + migrationBuilder.AddColumn( + name: "Date", + table: "CombinationConsumables", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "TimeStamp", + table: "CombinationConsumables", + type: "datetime(6)", + nullable: false, + defaultValue: new DateTimeOffset(new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), new TimeSpan(0, 0, 0, 0, 0))); + + migrationBuilder.AddColumn( + name: "Date", + table: "ClaimStakeRewards", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "Blocks", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.AddColumn( + name: "Date", + table: "BattleArenas", + type: "date", + nullable: false, + defaultValue: new DateOnly(1, 1, 1)); + + migrationBuilder.CreateTable( + name: "UserConsumables", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "int", nullable: true), + BuffSkillCount = table.Column(type: "int", nullable: true), + ElementalType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Grade = table.Column(type: "int", nullable: true), + SkillsCount = table.Column(type: "int", nullable: true), + RequiredBlockIndex = table.Column(type: "bigint", nullable: true), + NonFungibleId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TradableId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + MainStat = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserConsumables_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + table.ForeignKey( + name: "FK_UserConsumables_Avatars_AvatarAddress", + column: x => x.AvatarAddress, + principalTable: "Avatars", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserCostumes", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "int", nullable: true), + ElementalType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Grade = table.Column(type: "int", nullable: true), + Equipped = table.Column(type: "tinyint(1)", nullable: true), + SpineResourcePath = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + RequiredBlockIndex = table.Column(type: "bigint", nullable: true), + NonFungibleId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TradableId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserCostumes_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + table.ForeignKey( + name: "FK_UserCostumes_Avatars_AvatarAddress", + column: x => x.AvatarAddress, + principalTable: "Avatars", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserCrystals", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + CrystalBalance = table.Column(type: "decimal(65,30)", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserCrystals_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserEquipments", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Id = table.Column(type: "int", nullable: true), + BuffSkillCount = table.Column(type: "int", nullable: true), + ElementalType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Grade = table.Column(type: "int", nullable: true), + Level = table.Column(type: "int", nullable: true), + SetId = table.Column(type: "int", nullable: true), + SkillsCount = table.Column(type: "int", nullable: true), + SpineResourcePath = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + RequiredBlockIndex = table.Column(type: "bigint", nullable: true), + NonFungibleId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TradableId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + UniqueStatType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserMaterials", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + ItemId = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ItemSubType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Count = table.Column(type: "int", nullable: true), + Id = table.Column(type: "int", nullable: true), + ElementalType = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Grade = table.Column(type: "int", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserMaterials_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + table.ForeignKey( + name: "FK_UserMaterials_Avatars_AvatarAddress", + column: x => x.AvatarAddress, + principalTable: "Avatars", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserMonsterCollections", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + MonsterCollectionAmount = table.Column(type: "decimal(65,30)", nullable: true), + Level = table.Column(type: "int", nullable: true), + RewardLevel = table.Column(type: "bigint", nullable: true), + StartedBlockIndex = table.Column(type: "bigint", nullable: true), + ReceivedBlockIndex = table.Column(type: "bigint", nullable: true), + ExpiredBlockIndex = table.Column(type: "bigint", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserMonsterCollections_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserNCGs", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + NCGBalance = table.Column(type: "decimal(65,30)", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserNCGs_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserRunes", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Ticker = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + RuneBalance = table.Column(type: "decimal(65,30)", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserRunes_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + table.ForeignKey( + name: "FK_UserRunes_Avatars_AvatarAddress", + column: x => x.AvatarAddress, + principalTable: "Avatars", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateTable( + name: "UserStakings", + columns: table => new + { + BlockIndex = table.Column(type: "bigint", nullable: true), + AgentAddress = table.Column(type: "varchar(255)", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + StakeAmount = table.Column(type: "decimal(65,30)", nullable: true), + StartedBlockIndex = table.Column(type: "bigint", nullable: true), + ReceivedBlockIndex = table.Column(type: "bigint", nullable: true), + CancellableBlockIndex = table.Column(type: "bigint", nullable: true), + TimeStamp = table.Column(type: "datetime(6)", nullable: true) + }, + constraints: table => + { + table.ForeignKey( + name: "FK_UserStakings_Agents_AgentAddress", + column: x => x.AgentAddress, + principalTable: "Agents", + principalColumn: "Address"); + }) + .Annotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.CreateIndex( + name: "IX_UserConsumables_AgentAddress", + table: "UserConsumables", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserConsumables_AvatarAddress", + table: "UserConsumables", + column: "AvatarAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserCostumes_AgentAddress", + table: "UserCostumes", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserCostumes_AvatarAddress", + table: "UserCostumes", + column: "AvatarAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserCrystals_AgentAddress", + table: "UserCrystals", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserMaterials_AgentAddress", + table: "UserMaterials", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserMaterials_AvatarAddress", + table: "UserMaterials", + column: "AvatarAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserMonsterCollections_AgentAddress", + table: "UserMonsterCollections", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserNCGs_AgentAddress", + table: "UserNCGs", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserRunes_AgentAddress", + table: "UserRunes", + column: "AgentAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserRunes_AvatarAddress", + table: "UserRunes", + column: "AvatarAddress"); + + migrationBuilder.CreateIndex( + name: "IX_UserStakings_AgentAddress", + table: "UserStakings", + column: "AgentAddress"); + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "UserConsumables"); + + migrationBuilder.DropTable( + name: "UserCostumes"); + + migrationBuilder.DropTable( + name: "UserCrystals"); + + migrationBuilder.DropTable( + name: "UserEquipments"); + + migrationBuilder.DropTable( + name: "UserMaterials"); + + migrationBuilder.DropTable( + name: "UserMonsterCollections"); + + migrationBuilder.DropTable( + name: "UserNCGs"); + + migrationBuilder.DropTable( + name: "UserRunes"); + + migrationBuilder.DropTable( + name: "UserStakings"); + + migrationBuilder.DropColumn( + name: "Date", + table: "UnlockWorlds"); + + migrationBuilder.DropColumn( + name: "Date", + table: "UnlockEquipmentRecipes"); + + migrationBuilder.DropColumn( + name: "Date", + table: "Stakings"); + + migrationBuilder.DropColumn( + name: "Date", + table: "ReplaceCombinationEquipmentMaterials"); + + migrationBuilder.DropColumn( + name: "Date", + table: "MigrateMonsterCollections"); + + migrationBuilder.DropColumn( + name: "Date", + table: "JoinArenas"); + + migrationBuilder.DropColumn( + name: "Date", + table: "ItemEnhancements"); + + migrationBuilder.DropColumn( + name: "TimeStamp", + table: "ItemEnhancements"); + + migrationBuilder.DropColumn( + name: "Date", + table: "ItemEnhancementFails"); + + migrationBuilder.DropColumn( + name: "Date", + table: "HasWithRandomBuffs"); + + migrationBuilder.DropColumn( + name: "Date", + table: "HasRandomBuffs"); + + migrationBuilder.DropColumn( + name: "Date", + table: "HackAndSlashSweeps"); + + migrationBuilder.DropColumn( + name: "Date", + table: "HackAndSlashes"); + + migrationBuilder.DropColumn( + name: "Timestamp", + table: "HackAndSlashes"); + + migrationBuilder.DropColumn( + name: "Date", + table: "Grindings"); + + migrationBuilder.DropColumn( + name: "Date", + table: "EventDungeonBattles"); + + migrationBuilder.DropColumn( + name: "Date", + table: "EventConsumableItemCrafts"); + + migrationBuilder.DropColumn( + name: "TimeStamp", + table: "Equipments"); + + migrationBuilder.DropColumn( + name: "ArmorId", + table: "CraftRankings"); + + migrationBuilder.DropColumn( + name: "AvatarLevel", + table: "CraftRankings"); + + migrationBuilder.DropColumn( + name: "Cp", + table: "CraftRankings"); + + migrationBuilder.DropColumn( + name: "Name", + table: "CraftRankings"); + + migrationBuilder.DropColumn( + name: "TitleId", + table: "CraftRankings"); + + migrationBuilder.DropColumn( + name: "Date", + table: "CombinationEquipments"); + + migrationBuilder.DropColumn( + name: "TimeStamp", + table: "CombinationEquipments"); + + migrationBuilder.DropColumn( + name: "Date", + table: "CombinationConsumables"); + + migrationBuilder.DropColumn( + name: "TimeStamp", + table: "CombinationConsumables"); + + migrationBuilder.DropColumn( + name: "Date", + table: "ClaimStakeRewards"); + + migrationBuilder.DropColumn( + name: "Date", + table: "Blocks"); + + migrationBuilder.DropColumn( + name: "Date", + table: "BattleArenas"); + + migrationBuilder.UpdateData( + table: "CraftRankings", + keyColumn: "AvatarAddress", + keyValue: null, + column: "AvatarAddress", + value: string.Empty); + + migrationBuilder.AlterColumn( + name: "AvatarAddress", + table: "CraftRankings", + type: "varchar(255)", + nullable: false, + oldClrType: typeof(string), + oldType: "longtext", + oldNullable: true) + .Annotation("MySql:CharSet", "utf8mb4") + .OldAnnotation("MySql:CharSet", "utf8mb4"); + + migrationBuilder.AddPrimaryKey( + name: "PK_CraftRankings", + table: "CraftRankings", + column: "AvatarAddress"); + + migrationBuilder.CreateTable( + name: "CraftRankingsOutput", + columns: table => new + { + AgentAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + ArmorId = table.Column(type: "int", nullable: true), + AvatarAddress = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + AvatarLevel = table.Column(type: "int", nullable: true), + BlockIndex = table.Column(type: "bigint", nullable: false), + Cp = table.Column(type: "int", nullable: true), + CraftCount = table.Column(type: "int", nullable: false), + Name = table.Column(type: "longtext", nullable: true) + .Annotation("MySql:CharSet", "utf8mb4"), + Ranking = table.Column(type: "int", nullable: false), + TitleId = table.Column(type: "int", nullable: true) + }, + constraints: table => + { + }) + .Annotation("MySql:CharSet", "utf8mb4"); + } + } +} diff --git a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs index 3a8bdba0..85b1accc 100644 --- a/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs +++ b/NineChronicles.DataProvider.Executable/Migrations/NineChroniclesContextModelSnapshot.cs @@ -178,6 +178,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("ChampionshipId") .HasColumnType("int"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EnemyAvatarAddress") .HasColumnType("longtext"); @@ -340,6 +343,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("Hash") .HasColumnType("varchar(255)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("Difficulty") .HasColumnType("bigint"); @@ -404,6 +410,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("ClaimStakeStartBlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("HourGlassCount") .HasColumnType("int"); @@ -431,12 +440,18 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("RecipeId") .HasColumnType("int"); b.Property("SlotIndex") .HasColumnType("int"); + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + b.HasKey("Id"); b.HasIndex("AgentAddress"); @@ -460,6 +475,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("RecipeId") .HasColumnType("int"); @@ -469,6 +487,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("SubRecipeId") .HasColumnType("int"); + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + b.HasKey("Id"); b.HasIndex("AgentAddress"); @@ -478,29 +499,7 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.ToTable("CombinationEquipments"); }); - modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingInputModel", b => - { - b.Property("AvatarAddress") - .HasColumnType("varchar(255)"); - - b.Property("AgentAddress") - .HasColumnType("longtext"); - - b.Property("BlockIndex") - .HasColumnType("bigint"); - - b.Property("CraftCount") - .HasColumnType("int"); - - b.Property("Ranking") - .HasColumnType("int"); - - b.HasKey("AvatarAddress"); - - b.ToTable("CraftRankings"); - }); - - modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingOutputModel", b => + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.CraftRankingModel", b => { b.Property("AgentAddress") .HasColumnType("longtext"); @@ -532,7 +531,7 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("TitleId") .HasColumnType("int"); - b.ToTable("CraftRankingsOutput"); + b.ToTable("CraftRankings"); }); modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.EquipmentModel", b => @@ -558,6 +557,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("Level") .HasColumnType("int"); + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + b.HasKey("ItemId"); b.ToTable("Equipments"); @@ -823,6 +825,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EventConsumableItemRecipeId") .HasColumnType("int"); @@ -903,6 +908,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("CostumesCount") .HasColumnType("int"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EquipmentsCount") .HasColumnType("int"); @@ -1119,6 +1127,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("Crystal") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EquipmentId") .HasColumnType("int"); @@ -1157,12 +1168,18 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("Cleared") .HasColumnType("tinyint(1)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("Mimisbrunnr") .HasColumnType("tinyint(1)"); b.Property("StageId") .HasColumnType("int"); + b.Property("Timestamp") + .HasColumnType("datetime(6)"); + b.HasKey("Id"); b.HasIndex("AgentAddress"); @@ -1198,6 +1215,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("CostumesCount") .HasColumnType("int"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EquipmentsCount") .HasColumnType("int"); @@ -1239,6 +1259,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntCrystal") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("GachaCount") .HasColumnType("int"); @@ -1277,6 +1300,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("Cleared") .HasColumnType("tinyint(1)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("StageId") .HasColumnType("int"); @@ -1309,6 +1335,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntNCG") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("EquipmentItemId") .HasColumnType("longtext"); @@ -1353,6 +1382,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntNCG") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("Exp") .HasColumnType("bigint"); @@ -1374,6 +1406,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("SlotIndex") .HasColumnType("int"); + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + b.HasKey("Id"); b.HasIndex("AgentAddress"); @@ -1409,6 +1444,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("ChampionshipId") .HasColumnType("int"); + b.Property("Date") + .HasColumnType("date"); + b.Property("TimeStamp") .HasColumnType("datetime(6)"); @@ -1429,6 +1467,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("MigrationAmount") .HasColumnType("decimal(65,30)"); @@ -1599,6 +1640,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntCrystal") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("ReplacedMaterialCount") .HasColumnType("int"); @@ -2365,6 +2409,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BlockIndex") .HasColumnType("bigint"); + b.Property("Date") + .HasColumnType("date"); + b.Property("NewAmount") .HasColumnType("decimal(65,30)"); @@ -2479,6 +2526,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntCrystal") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("TimeStamp") .HasColumnType("datetime(6)"); @@ -2546,6 +2596,9 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Property("BurntCrystal") .HasColumnType("decimal(65,30)"); + b.Property("Date") + .HasColumnType("date"); + b.Property("TimeStamp") .HasColumnType("datetime(6)"); @@ -2561,6 +2614,348 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.ToTable("UnlockWorlds"); }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserConsumablesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("MainStat") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserConsumables"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCostumesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Equipped") + .HasColumnType("tinyint(1)"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserCostumes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCrystalsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CrystalBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserCrystals"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserEquipmentsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("longtext"); + + b.Property("AvatarAddress") + .HasColumnType("longtext"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("BuffSkillCount") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("NonFungibleId") + .HasColumnType("longtext"); + + b.Property("RequiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("SetId") + .HasColumnType("int"); + + b.Property("SkillsCount") + .HasColumnType("int"); + + b.Property("SpineResourcePath") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.Property("TradableId") + .HasColumnType("longtext"); + + b.Property("UniqueStatType") + .HasColumnType("longtext"); + + b.ToTable("UserEquipments"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMaterialsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("Count") + .HasColumnType("int"); + + b.Property("ElementalType") + .HasColumnType("longtext"); + + b.Property("Grade") + .HasColumnType("int"); + + b.Property("Id") + .HasColumnType("int"); + + b.Property("ItemId") + .HasColumnType("longtext"); + + b.Property("ItemSubType") + .HasColumnType("longtext"); + + b.Property("ItemType") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserMaterials"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMonsterCollectionsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("ExpiredBlockIndex") + .HasColumnType("bigint"); + + b.Property("Level") + .HasColumnType("int"); + + b.Property("MonsterCollectionAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("ReceivedBlockIndex") + .HasColumnType("bigint"); + + b.Property("RewardLevel") + .HasColumnType("bigint"); + + b.Property("StartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserMonsterCollections"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserNCGsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("NCGBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserNCGs"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserRunesModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("AvatarAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("RuneBalance") + .HasColumnType("decimal(65,30)"); + + b.Property("Ticker") + .HasColumnType("longtext"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.HasIndex("AvatarAddress"); + + b.ToTable("UserRunes"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserStakingsModel", b => + { + b.Property("AgentAddress") + .HasColumnType("varchar(255)"); + + b.Property("BlockIndex") + .HasColumnType("bigint"); + + b.Property("CancellableBlockIndex") + .HasColumnType("bigint"); + + b.Property("ReceivedBlockIndex") + .HasColumnType("bigint"); + + b.Property("StakeAmount") + .HasColumnType("decimal(65,30)"); + + b.Property("StartedBlockIndex") + .HasColumnType("bigint"); + + b.Property("TimeStamp") + .HasColumnType("datetime(6)"); + + b.HasIndex("AgentAddress"); + + b.ToTable("UserStakings"); + }); + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.WorldBossRankingModel", b => { b.Property("Address") @@ -3026,6 +3421,102 @@ protected override void BuildModel(ModelBuilder modelBuilder) b.Navigation("Avatar"); }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserConsumablesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCostumesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserCrystalsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMaterialsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserMonsterCollectionsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserNCGsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserRunesModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.HasOne("NineChronicles.DataProvider.Store.Models.AvatarModel", "Avatar") + .WithMany() + .HasForeignKey("AvatarAddress"); + + b.Navigation("Agent"); + + b.Navigation("Avatar"); + }); + + modelBuilder.Entity("NineChronicles.DataProvider.Store.Models.UserStakingsModel", b => + { + b.HasOne("NineChronicles.DataProvider.Store.Models.AgentModel", "Agent") + .WithMany() + .HasForeignKey("AgentAddress"); + + b.Navigation("Agent"); + }); #pragma warning restore 612, 618 } } From 9c0644b796f77c01b9c8e7beb8b5bfb15fcadcca Mon Sep 17 00:00:00 2001 From: Submodule Updater Date: Tue, 7 Nov 2023 04:46:44 +0000 Subject: [PATCH 13/13] Update NineChronicles.Headless submodule to planetarium/NineChronicles.Headless@f43535afbb2cb5c2f2258ed6f4e1d0ab49d670e8 This commit was automatically generated by Submodule Updater. --- NineChronicles.Headless | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NineChronicles.Headless b/NineChronicles.Headless index ba982836..f43535af 160000 --- a/NineChronicles.Headless +++ b/NineChronicles.Headless @@ -1 +1 @@ -Subproject commit ba9828361d22625a0b47c706c7cdf4a3b57b811a +Subproject commit f43535afbb2cb5c2f2258ed6f4e1d0ab49d670e8