mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-29 00:39:55 +00:00
Added support for credits in messages for starting and ending giveaways.
This commit is contained in:
@@ -471,8 +471,8 @@ GiveawayStart ComputeGiveawayStartData(
|
||||
auto result = GiveawayStart{
|
||||
.untilDate = data.vuntil_date().v,
|
||||
.quantity = data.vquantity().v,
|
||||
.months = data.vmonths().value_or_empty(),AssertIsDebug()
|
||||
//.stars = data.vstars().value_or_empty(),
|
||||
.months = data.vmonths().value_or_empty(),
|
||||
.credits = data.vstars().value_or_empty(),
|
||||
.all = !data.is_only_new_subscribers(),
|
||||
};
|
||||
result.channels.reserve(data.vchannels().v.size());
|
||||
@@ -503,8 +503,8 @@ GiveawayResults ComputeGiveawayResultsData(
|
||||
.additionalPeersCount = additional.value_or_empty(),
|
||||
.winnersCount = data.vwinners_count().v,
|
||||
.unclaimedCount = data.vunclaimed_count().v,
|
||||
.months = data.vmonths().value_or_empty(), AssertIsDebug()
|
||||
//.stars = data.vstars().value_or_empty(),
|
||||
.months = data.vmonths().value_or_empty(),
|
||||
.credits = data.vstars().value_or_empty(),
|
||||
.refunded = data.is_refunded(),
|
||||
.all = !data.is_only_new_subscribers(),
|
||||
};
|
||||
|
||||
@@ -108,6 +108,7 @@ struct GiveawayStart {
|
||||
TimeId untilDate = 0;
|
||||
int quantity = 0;
|
||||
int months = 0;
|
||||
uint64 credits = 0;
|
||||
bool all = false;
|
||||
};
|
||||
|
||||
@@ -121,6 +122,7 @@ struct GiveawayResults {
|
||||
int winnersCount = 0;
|
||||
int unclaimedCount = 0;
|
||||
int months = 0;
|
||||
uint64 credits = 0;
|
||||
bool refunded = false;
|
||||
bool all = false;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user