상첨 처리 추가
This commit is contained in:
parent
92b0e9d212
commit
4b77dea709
|
|
@ -3,6 +3,7 @@ using Newtonsoft.Json;
|
|||
using Server.SQL;
|
||||
using Server.Manager;
|
||||
using NLog;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace Server.Service
|
||||
{
|
||||
|
|
@ -15,6 +16,7 @@ namespace Server.Service
|
|||
{
|
||||
Statics.userSQL.SaveChanges();
|
||||
Statics.resetShopItemSQL.SaveChanges();
|
||||
Statics.shopItemSQL.SaveChanges();
|
||||
item.box.SaveSQL();
|
||||
}
|
||||
|
||||
|
|
@ -26,7 +28,7 @@ namespace Server.Service
|
|||
long reward;
|
||||
long id;
|
||||
ResetShopItem resetShopItem = null;
|
||||
if (req.reset_id == 0)
|
||||
if (req.reset_id == -1)
|
||||
{
|
||||
ShopItemData shopItemData = Statics.shopItemExcel.getShopItemData(req.shopItemIndex);
|
||||
buy_type = shopItemData.buy_type;
|
||||
|
|
@ -69,11 +71,12 @@ namespace Server.Service
|
|||
if (reward != 0)
|
||||
{
|
||||
item.addReward(reward);
|
||||
ShopItem shopItem = new ShopItem();
|
||||
if(resetShopItem == null)
|
||||
{
|
||||
ShopItem shopItem = new ShopItem();
|
||||
shopItem.user_id = user.id;
|
||||
shopItem.shop_item_data_id = id;
|
||||
shopItem.buy_date = DateTime.UtcNow;
|
||||
Statics.shopItemSQL.Insert(shopItem);
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in New Issue