|
|
@@ -359,6 +359,11 @@ class BetService extends BaseService
|
|
|
// 期数验证
|
|
|
$issueInfo = IssueService::model()::where('status', IssueService::model()::STATUS_BETTING)->orderBy('id', 'desc')->first();
|
|
|
if ($issueInfo) {
|
|
|
+ $betFakeRandAmount = Config::where('field', 'bet_fake_rand_amount')->first()->val;
|
|
|
+ $betFakeRandAmount = explode(',', $betFakeRandAmount);
|
|
|
+ $betMini = $betFakeRandAmount[0]??10;
|
|
|
+ $betMax = $betFakeRandAmount[1]??10000;
|
|
|
+
|
|
|
$now_date = date('Y-m-d H:i:s',time() + 30); // 提前30秒
|
|
|
if($issueInfo['end_time'] > $now_date){
|
|
|
$fake_bet_list = Cache::get('fake_bet_' . $issueInfo->issue_no, []);
|
|
|
@@ -368,12 +373,12 @@ class BetService extends BaseService
|
|
|
$randKey = array_rand($gameplayRuleList, 1);
|
|
|
$gameplayRuleInfo = $gameplayRuleList[$randKey] ?? [];
|
|
|
if ($gameplayRuleInfo) {
|
|
|
-
|
|
|
+ $amount = rand($betMini, $betMax);
|
|
|
|
|
|
$item = [];
|
|
|
$item['keywords'] = $gameplayRuleInfo['keywords'];
|
|
|
$item['odds'] = $gameplayRuleInfo['odds'];
|
|
|
- $item['amount'] = rand(10, 10000);
|
|
|
+ $item['amount'] = $amount;
|
|
|
$item['first_name'] = self::generateRandomString(6);
|
|
|
$item['member_id'] = self::generateRandomNumber(10);
|
|
|
$item['profit'] = 0;
|