Skip to content

Commit

Permalink
Move custom craft field into Update function
Browse files Browse the repository at this point in the history
  • Loading branch information
U-lis committed Sep 5, 2024
1 parent 879e3b7 commit 09be416
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
3 changes: 3 additions & 0 deletions MarketService/Models/ItemProductModel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ public void Update(ITradableItem tradableItem, FungibleAssetValue price, Costume
{
SetId = equipment.SetId;
Level = equipment.level;
IconId = equipment.IconId;
ByCustomCraft = equipment.ByCustomCraft;
HasRandomOnlyIcon = equipment.HasRandomOnlyIcon;
OptionCountFromCombination = equipment.optionCountFromCombination;
var skillModels = new List<SkillModel>();
skillModels.AddRange(equipment.Skills.Select(s => new SkillModel
Expand Down
7 changes: 0 additions & 7 deletions MarketService/RpcClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -514,13 +514,6 @@ public async Task InsertProducts(List<Product> products, CostumeStatSheet costum
Exist = true,
};

if (item is Equipment equipment)
{
itemProductModel.IconId = equipment.IconId;
itemProductModel.ByCustomCraft = equipment.ByCustomCraft;
itemProductModel.HasRandomOnlyIcon = equipment.HasRandomOnlyIcon;
}

itemProductModel.Update(itemProduct.TradableItem, itemProduct.Price, costumeStatSheet,
crystalEquipmentGrindingSheet, crystalMonsterCollectionMultiplierSheet);
productBag.Add(itemProductModel);
Expand Down

0 comments on commit 09be416

Please sign in to comment.