|
@@ -12,7 +12,6 @@ namespace CardCollector.Resources
|
|
|
/* В данном классе содержатся все клавиатуры, используемые в проекте */
|
|
|
public static class Keyboard
|
|
|
{
|
|
|
-
|
|
|
/* Клавиатура, отображаемая с первым сообщением пользователя */
|
|
|
public static readonly ReplyKeyboardMarkup Menu = new(new[]
|
|
|
{
|
|
@@ -27,6 +26,18 @@ namespace CardCollector.Resources
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
+ public static InlineKeyboardMarkup StopKeyboard = new(new[]
|
|
|
+ {
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.stop_bot, Command.stop_bot)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)}
|
|
|
+ });
|
|
|
+
|
|
|
+ public static InlineKeyboardMarkup ShowStickers = new(new[]
|
|
|
+ {
|
|
|
+ new[] {InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_stickers)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)}
|
|
|
+ });
|
|
|
+
|
|
|
public static InlineKeyboardMarkup BuyCoinsKeyboard(bool confirmButton = false)
|
|
|
{
|
|
|
var keyboard = new List<InlineKeyboardButton[]>
|
|
@@ -38,8 +49,12 @@ namespace CardCollector.Resources
|
|
|
InlineKeyboardButton.WithCallbackData($"900{Text.coin}", $"{Command.set_exchange_sum}=90")
|
|
|
}
|
|
|
};
|
|
|
- if (confirmButton) keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.confirm_exchange,
|
|
|
- Command.confirm_exchange)});
|
|
|
+ if (confirmButton)
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.confirm_exchange,
|
|
|
+ Command.confirm_exchange)
|
|
|
+ });
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
@@ -61,44 +76,54 @@ namespace CardCollector.Resources
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
- public static InlineKeyboardMarkup Settings = new(new[]
|
|
|
+ public static InlineKeyboardMarkup Settings(PrivilegeLevel privilegeLevel)
|
|
|
{
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.alerts, Command.alerts)},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
- });
|
|
|
+ var keyboard = new List<InlineKeyboardButton[]>
|
|
|
+ {
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.alerts, Command.alerts)},
|
|
|
+ };
|
|
|
+ if (privilegeLevel > PrivilegeLevel.Vip)
|
|
|
+ keyboard.Add(
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.control_panel, Command.control_panel)});
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
+ return new InlineKeyboardMarkup(keyboard);
|
|
|
+ }
|
|
|
|
|
|
public static InlineKeyboardMarkup MyPacks = new(new[]
|
|
|
{
|
|
|
InlineKeyboardButton.WithCallbackData(Text.open_packs, Command.my_packs)
|
|
|
});
|
|
|
-
|
|
|
+
|
|
|
public static InlineKeyboardMarkup Alerts(UserSettings settings)
|
|
|
{
|
|
|
var keyboard = new List<InlineKeyboardButton[]>
|
|
|
{
|
|
|
- new[] {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.daily_tasks} {(settings[UserSettingsEnum.DailyTasks] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.DailyTasks}"),
|
|
|
+ $"{Text.daily_tasks} {(settings[UserSettingsEnum.DailyTasks] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.DailyTasks}"),
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.sticker_effects} {(settings[UserSettingsEnum.StickerEffects] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.StickerEffects}")
|
|
|
+ $"{Text.sticker_effects} {(settings[UserSettingsEnum.StickerEffects] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.StickerEffects}")
|
|
|
},
|
|
|
- new[] {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.exp_gain} {(settings[UserSettingsEnum.ExpGain] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.ExpGain}"),
|
|
|
+ $"{Text.exp_gain} {(settings[UserSettingsEnum.ExpGain] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.ExpGain}"),
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.daily_task_progress} {(settings[UserSettingsEnum.DailyTaskProgress] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.DailyTaskProgress}")
|
|
|
+ $"{Text.daily_task_progress} {(settings[UserSettingsEnum.DailyTaskProgress] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.DailyTaskProgress}")
|
|
|
},
|
|
|
- new[] {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.piggy_bank_capacity} {(settings[UserSettingsEnum.PiggyBankCapacity] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.PiggyBankCapacity}"),
|
|
|
+ $"{Text.piggy_bank_capacity} {(settings[UserSettingsEnum.PiggyBankCapacity] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.PiggyBankCapacity}"),
|
|
|
InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.daily_exp_top} {(settings[UserSettingsEnum.DailyExpTop] ? Text.alert_on : Text.alert_off)}",
|
|
|
- $"{Command.alerts}={(int)UserSettingsEnum.DailyExpTop}")
|
|
|
+ $"{Text.daily_exp_top} {(settings[UserSettingsEnum.DailyExpTop] ? Text.alert_on : Text.alert_off)}",
|
|
|
+ $"{Command.alerts}={(int) UserSettingsEnum.DailyExpTop}")
|
|
|
},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
};
|
|
@@ -122,25 +147,43 @@ namespace CardCollector.Resources
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.tier, Command.tier)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.emoji, Command.emoji)}
|
|
|
};
|
|
|
- if (state != UserState.CollectionMenu) keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.price, Command.select_price)});
|
|
|
+ if (state != UserState.CollectionMenu)
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.price, Command.select_price)});
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.sort, Command.sort)});
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_stickers)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
+
|
|
|
/* Клавиатура меню сортировки */
|
|
|
public static readonly InlineKeyboardMarkup SortOptions = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.no, $"{Command.set}={Command.sort}={SortingTypes.None}")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(SortingTypes.ByTierIncrease, $"{Command.set}={Command.sort}={SortingTypes.ByTierIncrease}")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(SortingTypes.ByTierDecrease, $"{Command.set}={Command.sort}={SortingTypes.ByTierDecrease}")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(SortingTypes.ByAuthor, $"{Command.set}={Command.sort}={SortingTypes.ByAuthor}")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(SortingTypes.ByTitle, $"{Command.set}={Command.sort}={SortingTypes.ByTitle}")},
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(SortingTypes.ByTierIncrease,
|
|
|
+ $"{Command.set}={Command.sort}={SortingTypes.ByTierIncrease}")
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(SortingTypes.ByTierDecrease,
|
|
|
+ $"{Command.set}={Command.sort}={SortingTypes.ByTierDecrease}")
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(SortingTypes.ByAuthor,
|
|
|
+ $"{Command.set}={Command.sort}={SortingTypes.ByAuthor}")
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(SortingTypes.ByTitle,
|
|
|
+ $"{Command.set}={Command.sort}={SortingTypes.ByTitle}")
|
|
|
+ },
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
/* Клавиатура меню выбора тира */
|
|
|
- public static readonly InlineKeyboardMarkup TierOptions = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup TierOptions = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.all, $"{Command.set}={Command.tier}=-1")},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData("1", $"{Command.set}={Command.tier}=1")},
|
|
@@ -151,21 +194,21 @@ namespace CardCollector.Resources
|
|
|
});
|
|
|
|
|
|
/* Клавиатура меню ввода эмоджи */
|
|
|
- public static readonly InlineKeyboardMarkup EmojiOptions = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup EmojiOptions = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.all, $"{Command.set}={Command.emoji}=")},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
/* Клавиатура с одной кнопкой отмены */
|
|
|
- public static readonly InlineKeyboardMarkup BackKeyboard = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup BackKeyboard = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
|
|
|
/* Клавиатура с одной кнопкой отмены */
|
|
|
- public static readonly InlineKeyboardMarkup StickerInfoKeyboard = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup StickerInfoKeyboard = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_stickers)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
@@ -176,57 +219,80 @@ namespace CardCollector.Resources
|
|
|
{
|
|
|
return new InlineKeyboardMarkup(new[]
|
|
|
{
|
|
|
- new[] {InlineKeyboardButton.WithPayment($"{Text.buy} {count}{Text.gem} {Text.per} ₽{count * 69 / 100}")},
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithPayment($"{Text.buy} {count}{Text.gem} {Text.per} ₽{count * 69 / 100}")
|
|
|
+ },
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
}
|
|
|
|
|
|
/* Клавиатура с отменой и выставлением */
|
|
|
- public static readonly InlineKeyboardMarkup AuctionPutCancelKeyboard = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup AuctionPutCancelKeyboard = new(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.sell_on_auction, Command.confirm_selling)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
/* Клавиатура меню выбора цен */
|
|
|
- public static readonly InlineKeyboardMarkup CoinsPriceOptions = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup CoinsPriceOptions = new(new[]
|
|
|
{
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 0", $"{Command.set}={Command.price_coins_from}=0"),
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 100", $"{Command.set}={Command.price_coins_to}=100"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 0",
|
|
|
+ $"{Command.set}={Command.price_coins_from}=0"),
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 100",
|
|
|
+ $"{Command.set}={Command.price_coins_to}=100"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 100", $"{Command.set}={Command.price_coins_from}=100"),
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 500", $"{Command.set}={Command.price_coins_to}=500"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 100",
|
|
|
+ $"{Command.set}={Command.price_coins_from}=100"),
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 500",
|
|
|
+ $"{Command.set}={Command.price_coins_to}=500"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 500", $"{Command.set}={Command.price_coins_from}=500"),
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 1000", $"{Command.set}={Command.price_coins_to}=1000"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 500",
|
|
|
+ $"{Command.set}={Command.price_coins_from}=500"),
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.to} 1000",
|
|
|
+ $"{Command.set}={Command.price_coins_to}=1000"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 1000", $"{Command.set}={Command.price_coins_from}=1000"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💰 {Text.from} 1000",
|
|
|
+ $"{Command.set}={Command.price_coins_from}=1000"),
|
|
|
InlineKeyboardButton.WithCallbackData($"💰 {Text.to} ∞", $"{Command.set}={Command.price_coins_to}=0"),
|
|
|
},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
|
|
|
/* Клавиатура меню выбора цен */
|
|
|
- public static readonly InlineKeyboardMarkup GemsPriceOptions = new (new[]
|
|
|
+ public static readonly InlineKeyboardMarkup GemsPriceOptions = new(new[]
|
|
|
{
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 0", $"{Command.set}={Command.price_gems_from}=0"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 0",
|
|
|
+ $"{Command.set}={Command.price_gems_from}=0"),
|
|
|
InlineKeyboardButton.WithCallbackData($"💎 {Text.to} 10", $"{Command.set}={Command.price_gems_to}=10"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 10", $"{Command.set}={Command.price_gems_from}=10"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 10",
|
|
|
+ $"{Command.set}={Command.price_gems_from}=10"),
|
|
|
InlineKeyboardButton.WithCallbackData($"💎 {Text.to} 50", $"{Command.set}={Command.price_gems_to}=50"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 50", $"{Command.set}={Command.price_gems_from}=50"),
|
|
|
- InlineKeyboardButton.WithCallbackData($"💎 {Text.to} 100", $"{Command.set}={Command.price_gems_to}=100"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 50",
|
|
|
+ $"{Command.set}={Command.price_gems_from}=50"),
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💎 {Text.to} 100",
|
|
|
+ $"{Command.set}={Command.price_gems_to}=100"),
|
|
|
},
|
|
|
- new[] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 100", $"{Command.set}={Command.price_gems_from}=100"),
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"💎 {Text.from} 100",
|
|
|
+ $"{Command.set}={Command.price_gems_from}=100"),
|
|
|
InlineKeyboardButton.WithCallbackData($"💎 {Text.to} ∞", $"{Command.set}={Command.price_gems_to}=0"),
|
|
|
},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
@@ -234,20 +300,26 @@ namespace CardCollector.Resources
|
|
|
|
|
|
public static InlineKeyboardMarkup GetAuthorsKeyboard(List<string> list, InlineKeyboardButton[] pagePanel)
|
|
|
{
|
|
|
- var keyboardList = new List<InlineKeyboardButton[]> {
|
|
|
+ var keyboardList = new List<InlineKeyboardButton[]>
|
|
|
+ {
|
|
|
/* Добавляем в список кнопку "Все" */
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.all, $"{Command.set}={Command.authors_menu}=")}
|
|
|
};
|
|
|
foreach (var (author, i) in list.WithIndex())
|
|
|
{
|
|
|
- if (i % 2 == 0) keyboardList.Add(new [] {
|
|
|
- InlineKeyboardButton.WithCallbackData(author, $"{Command.set}={Command.authors_menu}={author}")
|
|
|
- });
|
|
|
- else keyboardList[keyboardList.Count - 1] = new [] {
|
|
|
- keyboardList[keyboardList.Count - 1][0],
|
|
|
- InlineKeyboardButton.WithCallbackData(author, $"{Command.set}={Command.authors_menu}={author}")
|
|
|
- };
|
|
|
+ if (i % 2 == 0)
|
|
|
+ keyboardList.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(author, $"{Command.set}={Command.authors_menu}={author}")
|
|
|
+ });
|
|
|
+ else
|
|
|
+ keyboardList[keyboardList.Count - 1] = new[]
|
|
|
+ {
|
|
|
+ keyboardList[keyboardList.Count - 1][0],
|
|
|
+ InlineKeyboardButton.WithCallbackData(author, $"{Command.set}={Command.authors_menu}={author}")
|
|
|
+ };
|
|
|
}
|
|
|
+
|
|
|
keyboardList.Add(pagePanel);
|
|
|
return new InlineKeyboardMarkup(keyboardList);
|
|
|
}
|
|
@@ -255,47 +327,61 @@ namespace CardCollector.Resources
|
|
|
public static InlineKeyboardButton[] GetPagePanel(int page, int totalCount, string callback)
|
|
|
{
|
|
|
var arrows = new List<InlineKeyboardButton>();
|
|
|
- if (page > 1) arrows.Add(InlineKeyboardButton
|
|
|
- .WithCallbackData(Text.previous, $"{callback}={page - 1}"));
|
|
|
+ if (page > 1)
|
|
|
+ arrows.Add(InlineKeyboardButton
|
|
|
+ .WithCallbackData(Text.previous, $"{callback}={page - 1}"));
|
|
|
arrows.Add(InlineKeyboardButton.WithCallbackData(Text.back, Command.back));
|
|
|
- if (totalCount > page * 10) arrows.Add(InlineKeyboardButton
|
|
|
- .WithCallbackData(Text.next, $"{callback}={page + 1}"));
|
|
|
+ if (totalCount > page * 10)
|
|
|
+ arrows.Add(InlineKeyboardButton
|
|
|
+ .WithCallbackData(Text.next, $"{callback}={page + 1}"));
|
|
|
return arrows.ToArray();
|
|
|
}
|
|
|
|
|
|
- public static InlineKeyboardMarkup GetShopPacksKeyboard(List<PackEntity> infoList, InlineKeyboardButton[] pagePanel)
|
|
|
+ public static InlineKeyboardMarkup GetPacksKeyboard(List<PackEntity> infoList, string command,
|
|
|
+ InlineKeyboardButton[] pagePanel)
|
|
|
{
|
|
|
var keyboardList = new List<InlineKeyboardButton[]>();
|
|
|
foreach (var (item, i) in infoList.WithIndex())
|
|
|
{
|
|
|
- if (i % 2 == 0) keyboardList.Add(new [] {
|
|
|
- InlineKeyboardButton.WithCallbackData(item.Author, $"{Command.select_shop_pack}={item.Id}")
|
|
|
- });
|
|
|
- else keyboardList[keyboardList.Count - 1] = new [] {
|
|
|
- keyboardList[keyboardList.Count - 1][0],
|
|
|
- InlineKeyboardButton.WithCallbackData(item.Author, $"{Command.select_shop_pack}={item.Id}")
|
|
|
- };
|
|
|
+ if (i % 2 == 0)
|
|
|
+ keyboardList.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(item.Author, $"{command}={item.Id}")
|
|
|
+ });
|
|
|
+ else
|
|
|
+ keyboardList[keyboardList.Count - 1] = new[]
|
|
|
+ {
|
|
|
+ keyboardList[keyboardList.Count - 1][0],
|
|
|
+ InlineKeyboardButton.WithCallbackData(item.Author, $"{command}={item.Id}")
|
|
|
+ };
|
|
|
}
|
|
|
+
|
|
|
keyboardList.Add(pagePanel);
|
|
|
return new InlineKeyboardMarkup(keyboardList);
|
|
|
}
|
|
|
|
|
|
- public static async Task<InlineKeyboardMarkup> GetUserPacksKeyboard(List<UserPacks> infoList, InlineKeyboardButton[] pagePanel)
|
|
|
+ public static async Task<InlineKeyboardMarkup> GetUserPacksKeyboard(List<UserPacks> infoList,
|
|
|
+ InlineKeyboardButton[] pagePanel)
|
|
|
{
|
|
|
var keyboardList = new List<InlineKeyboardButton[]>();
|
|
|
foreach (var (item, i) in infoList.WithIndex())
|
|
|
{
|
|
|
var author = await PacksDao.GetById(item.PackId);
|
|
|
- if (i % 2 == 0) keyboardList.Add(new [] {
|
|
|
- InlineKeyboardButton.WithCallbackData($"{author.Author} ({item.Count}{Text.items})",
|
|
|
- $"{Command.open_pack}={item.PackId}")
|
|
|
- });
|
|
|
- else keyboardList[keyboardList.Count - 1] = new [] {
|
|
|
- keyboardList[keyboardList.Count - 1][0],
|
|
|
- InlineKeyboardButton.WithCallbackData($"{author.Author} ({item.Count}{Text.items})",
|
|
|
- $"{Command.open_pack}={item.PackId}")
|
|
|
- };
|
|
|
+ if (i % 2 == 0)
|
|
|
+ keyboardList.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{author.Author} ({item.Count}{Text.items})",
|
|
|
+ $"{Command.open_pack}={item.PackId}")
|
|
|
+ });
|
|
|
+ else
|
|
|
+ keyboardList[keyboardList.Count - 1] = new[]
|
|
|
+ {
|
|
|
+ keyboardList[keyboardList.Count - 1][0],
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{author.Author} ({item.Count}{Text.items})",
|
|
|
+ $"{Command.open_pack}={item.PackId}")
|
|
|
+ };
|
|
|
}
|
|
|
+
|
|
|
keyboardList.Add(pagePanel);
|
|
|
return new InlineKeyboardMarkup(keyboardList);
|
|
|
}
|
|
@@ -307,21 +393,27 @@ namespace CardCollector.Resources
|
|
|
var keyboard = new List<InlineKeyboardButton[]>
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithSwitchInlineQuery(Text.send_sticker, sticker.Title)},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData($"{Text.sell_on_auction} ({count})", Command.sell_on_auction)},
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{Text.sell_on_auction} ({count})", Command.sell_on_auction)
|
|
|
+ },
|
|
|
new[]
|
|
|
{
|
|
|
InlineKeyboardButton.WithCallbackData(Text.minus, $"{Command.count}={Text.minus}"),
|
|
|
InlineKeyboardButton.WithCallbackData(Text.plus, $"{Command.count}={Text.plus}"),
|
|
|
}
|
|
|
};
|
|
|
- if (sticker.Tier != 4) keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData($"{Text.combine} ({count})", Command.combine)});
|
|
|
+ if (sticker.Tier != 4)
|
|
|
+ keyboard.Add(
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData($"{Text.combine} ({count})", Command.combine)});
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
public static InlineKeyboardMarkup GetAuctionStickerKeyboard()
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new[] {
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
+ {
|
|
|
new[] {InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_traders)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
@@ -329,17 +421,23 @@ namespace CardCollector.Resources
|
|
|
|
|
|
public static InlineKeyboardMarkup GetAuctionProductKeyboard(AuctionModule module, double discount, bool owner)
|
|
|
{
|
|
|
- var price = (int)(module.Price * module.Count * discount);
|
|
|
+ var price = (int) (module.Price * module.Count * discount);
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
if (owner)
|
|
|
- keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.return_from_auction,
|
|
|
- Command.return_from_auction)});
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.return_from_auction,
|
|
|
+ Command.return_from_auction)
|
|
|
+ });
|
|
|
else
|
|
|
{
|
|
|
- keyboard.AddRange(new []
|
|
|
+ keyboard.AddRange(new[]
|
|
|
{
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData($"{Text.buy} ({module.Count}) {price}{Text.gem}",
|
|
|
- Command.confirm_buying)},
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{Text.buy} ({module.Count}) {price}{Text.gem}",
|
|
|
+ Command.confirm_buying)
|
|
|
+ },
|
|
|
new[]
|
|
|
{
|
|
|
InlineKeyboardButton.WithCallbackData(Text.minus, $"{Command.count}={Text.minus}"),
|
|
@@ -347,13 +445,15 @@ namespace CardCollector.Resources
|
|
|
},
|
|
|
});
|
|
|
}
|
|
|
+
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
public static InlineKeyboardMarkup GetStickerKeyboard(StickerEntity stickerInfo)
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new[] {
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
+ {
|
|
|
new[] {InlineKeyboardButton.WithSwitchInlineQuery(Text.send_sticker, stickerInfo.Title)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
@@ -361,7 +461,8 @@ namespace CardCollector.Resources
|
|
|
|
|
|
public static InlineKeyboardMarkup GetConfirmationKeyboard(string command)
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new[] {
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
+ {
|
|
|
new[]
|
|
|
{
|
|
|
InlineKeyboardButton.WithCallbackData(Text.no, Command.back),
|
|
@@ -383,7 +484,8 @@ namespace CardCollector.Resources
|
|
|
|
|
|
public static InlineKeyboardMarkup GetCombineStickerKeyboard(CombineModule module)
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new[] {
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
+ {
|
|
|
new[] {InlineKeyboardButton.WithCallbackData($"{Text.add} ({module.Count})", Command.combine)},
|
|
|
new[]
|
|
|
{
|
|
@@ -400,42 +502,57 @@ namespace CardCollector.Resources
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
foreach (var (sticker, _) in module.CombineList)
|
|
|
{
|
|
|
- keyboard.Add(new []{InlineKeyboardButton.WithCallbackData($"{Text.delete} {Text.sticker} {keyboard.Count + 1}",
|
|
|
- $"{Command.delete_combine}={sticker.Md5Hash}")});
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{Text.delete} {Text.sticker} {keyboard.Count + 1}",
|
|
|
+ $"{Command.delete_combine}={sticker.Md5Hash}")
|
|
|
+ });
|
|
|
}
|
|
|
+
|
|
|
if (module.CombineCount == Constants.COMBINE_COUNT)
|
|
|
- keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{Text.combine} {module.CalculateCombinePrice()}{Text.coin}", Command.combine_stickers)});
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(
|
|
|
+ $"{Text.combine} {module.CalculateCombinePrice()}{Text.coin}", Command.combine_stickers)
|
|
|
+ });
|
|
|
else keyboard.Add(new[] {InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.add_sticker)});
|
|
|
keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
/* Клавиатура, отображаемая вместе с сообщением профиля */
|
|
|
- public static InlineKeyboardMarkup GetProfileKeyboard(PrivilegeLevel level, int packsCount, int income = 0)
|
|
|
+ public static InlineKeyboardMarkup GetProfileKeyboard(int packsCount, int income = 0)
|
|
|
{
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
if (income > 0)
|
|
|
- keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData($"{Text.collect} {income}{Text.coin}",
|
|
|
- Command.collect_income)});
|
|
|
- keyboard.AddRange(new []
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{Text.collect} {income}{Text.coin}",
|
|
|
+ Command.collect_income)
|
|
|
+ });
|
|
|
+ keyboard.AddRange(new[]
|
|
|
{
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.daily_tasks, Command.daily_tasks)},
|
|
|
- new[] {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
InlineKeyboardButton.WithCallbackData(Text.settings, Command.settings),
|
|
|
InlineKeyboardButton.WithCallbackData($"{Text.my_packs} {(packsCount > 0 ? Text.gift : "")}",
|
|
|
Command.my_packs)
|
|
|
- }
|
|
|
+ },
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
- if (level > PrivilegeLevel.Vip) keyboard.Add(
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.control_panel, Command.control_panel)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
public static InlineKeyboardMarkup ShopKeyboard(bool haveOffers)
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new[] {
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.special_offers + (haveOffers ? Text.gift : ""), Command.special_offers)},
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
+ {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.special_offers + (haveOffers ? Text.gift : ""),
|
|
|
+ Command.special_offers)
|
|
|
+ },
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.buy_pack, Command.buy_pack)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.buy_coins, Command.buy_coins)},
|
|
|
new[] {InlineKeyboardButton.WithCallbackData(Text.buy_gems, Command.buy_gems)},
|
|
@@ -447,46 +564,57 @@ namespace CardCollector.Resources
|
|
|
{
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
foreach (var offer in specialOffers)
|
|
|
- keyboard.Add(new []{InlineKeyboardButton.WithCallbackData(offer.Title,
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(offer.Title,
|
|
|
$"{Command.select_offer}={offer.Id}")
|
|
|
});
|
|
|
- keyboard.Add(new []{InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
- public static InlineKeyboardMarkup ShopPacksKeyboard = new( new[]
|
|
|
- {
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.buy_random, $"{Command.select_shop_pack}=1")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.buy_author, $"{Command.buy_author_pack_menu}=1")},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.info, Command.pack_info)},
|
|
|
- new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
- });
|
|
|
+ public static InlineKeyboardMarkup ShopPacksKeyboard = new(new[]
|
|
|
+ {
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.buy_random, $"{Command.select_shop_pack}=1")},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.buy_author, $"{Command.buy_author_pack_menu}=1")},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.info, Command.pack_info)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
+ });
|
|
|
|
|
|
public static InlineKeyboardMarkup OfferKeyboard(ShopModule module)
|
|
|
{
|
|
|
- var resultPriceCoins = module.SelectedPosition?.ResultPriceCoins
|
|
|
- ?? module.SelectedPack?.PriceCoins * module.Count ?? -1;
|
|
|
- var resultPriceGems = module.SelectedPosition?.ResultPriceGems
|
|
|
- ?? module.SelectedPack?.PriceGems * module.Count ?? -1;
|
|
|
+ var resultPriceCoins = module.SelectedPosition?.ResultPriceCoins
|
|
|
+ ?? module.SelectedPack?.PriceCoins * module.Count ?? -1;
|
|
|
+ var resultPriceGems = module.SelectedPosition?.ResultPriceGems
|
|
|
+ ?? module.SelectedPack?.PriceGems * module.Count ?? -1;
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
if (resultPriceCoins >= 0)
|
|
|
- keyboard.Add(new [] {InlineKeyboardButton.WithCallbackData(
|
|
|
- $"{resultPriceCoins}{Text.coin}", $"{Command.buy_shop_item}=coins")
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(
|
|
|
+ $"{resultPriceCoins}{Text.coin}", $"{Command.buy_shop_item}=coins")
|
|
|
});
|
|
|
if (resultPriceGems >= 0)
|
|
|
- if (keyboard.Count > 0) keyboard[0] = new [] {
|
|
|
- keyboard[0][0],
|
|
|
- InlineKeyboardButton.WithCallbackData($"{resultPriceGems}{Text.gem}",
|
|
|
- $"{Command.buy_shop_item}=gems")
|
|
|
- };
|
|
|
- else keyboard.Add(new [] {InlineKeyboardButton.WithCallbackData($"{resultPriceGems}{Text.gem}",
|
|
|
- $"{Command.buy_shop_item}=gems")
|
|
|
+ if (keyboard.Count > 0)
|
|
|
+ keyboard[0] = new[]
|
|
|
+ {
|
|
|
+ keyboard[0][0],
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{resultPriceGems}{Text.gem}",
|
|
|
+ $"{Command.buy_shop_item}=gems")
|
|
|
+ };
|
|
|
+ else
|
|
|
+ keyboard.Add(new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData($"{resultPriceGems}{Text.gem}",
|
|
|
+ $"{Command.buy_shop_item}=gems")
|
|
|
+ });
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.info, Command.show_offer_info)});
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
+ if (module.SelectedPack is { } a && a.Id != 1)
|
|
|
+ keyboard.Insert(0, new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_stickers)
|
|
|
});
|
|
|
- keyboard.Add(new [] {InlineKeyboardButton.WithCallbackData(Text.info, Command.show_offer_info)});
|
|
|
- keyboard.Add(new []{InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
- if (module.SelectedPack is { } a && a.Id != 1) keyboard.Insert(0, new [] {
|
|
|
- InlineKeyboardButton.WithSwitchInlineQueryCurrentChat(Text.show_stickers)
|
|
|
- });
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
@@ -499,8 +627,8 @@ namespace CardCollector.Resources
|
|
|
{
|
|
|
return new InlineKeyboardMarkup(new[]
|
|
|
{
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(buttonText, callbackData)},
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(buttonText, callbackData)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
}
|
|
|
|
|
@@ -508,9 +636,9 @@ namespace CardCollector.Resources
|
|
|
{
|
|
|
return new InlineKeyboardMarkup(new[]
|
|
|
{
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(Text.buy_more, callbackData)},
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(Text.open_packs, Command.my_packs)},
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.buy_more, callbackData)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.open_packs, Command.my_packs)},
|
|
|
+ new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)},
|
|
|
});
|
|
|
}
|
|
|
|
|
@@ -518,21 +646,44 @@ namespace CardCollector.Resources
|
|
|
{
|
|
|
var keyboard = new List<InlineKeyboardButton[]>();
|
|
|
if (level >= PrivilegeLevel.Programmer)
|
|
|
- keyboard.AddRange(new []
|
|
|
+ keyboard.AddRange(new[]
|
|
|
{
|
|
|
- new []{InlineKeyboardButton.WithCallbackData(Text.logs_menu, $"{Command.logs_menu}={DateTime.Today}")}
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.logs_menu, $"{Command.logs_menu}={DateTime.Today}")
|
|
|
+ }
|
|
|
});
|
|
|
- keyboard.Add(new []{InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
+ if (level == PrivilegeLevel.Programmer)
|
|
|
+ keyboard.AddRange(new[]
|
|
|
+ {
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.stop_bot, Command.stop_bot)
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.upload_stickerpack, Command.upload_stickerpack)
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.show_sample, Command.show_sample)
|
|
|
+ },
|
|
|
+ new[]
|
|
|
+ {
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.add_for_sale_sticker, $"{Command.add_for_sale_sticker}=1")
|
|
|
+ },
|
|
|
+ });
|
|
|
+ keyboard.Add(new[] {InlineKeyboardButton.WithCallbackData(Text.back, Command.back)});
|
|
|
return new InlineKeyboardMarkup(keyboard);
|
|
|
}
|
|
|
|
|
|
public static InlineKeyboardMarkup LogsMenu(DateTime date)
|
|
|
{
|
|
|
- return new InlineKeyboardMarkup(new []
|
|
|
+ return new InlineKeyboardMarkup(new[]
|
|
|
{
|
|
|
- InlineKeyboardButton.WithCallbackData(Text.arrow_left, $"{Command.logs_menu}={date.AddDays(1)}"),
|
|
|
- InlineKeyboardButton.WithCallbackData(Text.back, Command.back),
|
|
|
- InlineKeyboardButton.WithCallbackData(Text.arrow_right, $"{Command.logs_menu}={date.AddDays(-1)}"),
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.arrow_left, $"{Command.logs_menu}={date.AddDays(1)}"),
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.back, Command.back),
|
|
|
+ InlineKeyboardButton.WithCallbackData(Text.arrow_right, $"{Command.logs_menu}={date.AddDays(-1)}"),
|
|
|
});
|
|
|
}
|
|
|
}
|