From 9a71f1cad36d91d1efe1919a5368569299542138 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=ED=8C=90=EB=8F=8C?= Date: Wed, 20 Mar 2024 22:14:19 +0900 Subject: [PATCH] =?UTF-8?q?shop=20=EC=B2=98=EB=A6=AC=20=EC=9E=91=EC=97=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Server/Git/AbstractGit.cs | 26 ++++++-------------------- Server/Git/XlsxToJson.cs | 1 + Server/SQL/ResetShopItemData.cs | 1 + Server/Service/BuyShopItem.cs | 1 + 4 files changed, 9 insertions(+), 20 deletions(-) diff --git a/Server/Git/AbstractGit.cs b/Server/Git/AbstractGit.cs index e17ee6d..3a34ed4 100644 --- a/Server/Git/AbstractGit.cs +++ b/Server/Git/AbstractGit.cs @@ -169,37 +169,23 @@ namespace Server.Git { int index = -1; index = sheets.FindIndex(n => n.name == Statics.equipmentExcel.sheetName); - if(index != 0) - { + if(index != -1) Statics.equipmentExcel.init(sheets[index]); - } index = sheets.FindIndex(n => n.name == Statics.randomRewardExcel.sheetName); - if (index != 0) - { + if (index != -1) Statics.randomRewardExcel.init(sheets[index]); - } index = sheets.FindIndex(n => n.name == Statics.rewardExcel.sheetName); - if (index != 0) - { + if (index != -1) Statics.rewardExcel.init(sheets[index]); - } index = sheets.FindIndex(n => n.name == Statics.shopItemExcel.sheetName); - if (index != 0) - { + if (index != -1) Statics.shopItemExcel.init(sheets[index]); - } index = sheets.FindIndex(n => n.name == Statics.consumableItemExcel.sheetName); - if (index != 0) - { + if (index != -1) Statics.consumableItemExcel.init(sheets[index]); - } - index = sheets.FindIndex(n => n.name == Statics.resetShopItemExcel.sheetName); - if (index != 0) - { + if (index != -1) Statics.resetShopItemExcel.init(sheets[index]); - } - } } } diff --git a/Server/Git/XlsxToJson.cs b/Server/Git/XlsxToJson.cs index 22cf70d..8220855 100644 --- a/Server/Git/XlsxToJson.cs +++ b/Server/Git/XlsxToJson.cs @@ -18,6 +18,7 @@ namespace Server.Git ExcelManager em = new ExcelManager(fileList[n]); if (em.Play()) { + //나의 sheet가 아니라 em에 들어있는 시트만으로 처리되도록 해야함. sheets = em.sheets; for (int m = 0; m < sheets.Count; m++) { diff --git a/Server/SQL/ResetShopItemData.cs b/Server/SQL/ResetShopItemData.cs index 044d3f2..afbe222 100644 --- a/Server/SQL/ResetShopItemData.cs +++ b/Server/SQL/ResetShopItemData.cs @@ -33,6 +33,7 @@ namespace Server.SQL public void init(Sheet data) { this.resetShopItemData = new Dictionary(); + Console.WriteLine($"----------------------------{sheetName}----------------------------"); foreach (var item in data.dicViewer) { ResetShopItemData resetShopItemData = new ResetShopItemData(); diff --git a/Server/Service/BuyShopItem.cs b/Server/Service/BuyShopItem.cs index 5a21741..9635805 100644 --- a/Server/Service/BuyShopItem.cs +++ b/Server/Service/BuyShopItem.cs @@ -79,6 +79,7 @@ namespace Server.Service { public string uuid; public long shopItemIndex; + public long reset_id; public override bool IsReceivedAllField() { if (uuid == "" || shopItemIndex == 0)