| 12345678910111213141516171819202122232425262728293031323334 |
- <?php
- namespace App\Services\Sharing;
- final class ShareDefaults
- {
- public const TIMEZONE = 'Asia/Shanghai';
- public static function categories(): array
- {
- return ['third:1' => '真人', 'third:2' => '电子', 'third:3' => '彩票',
- 'third:4' => '体育', 'third:5' => '电竞', 'third:6' => '捕鱼',
- 'third:7' => '棋牌', 'self:sport' => 'F1体育', 'self:lottery' => 'F1彩票'];
- }
- /** 返佣与代理合营分成使用的 8 类(暂无三方彩票;以后接入时按 third:3 标识加回)。 */
- public static function commissionCategories(): array
- {
- $categories = self::categories();
- unset($categories['third:3']);
- return $categories;
- }
- public static function rules(): array
- {
- $rows = [];
- foreach ([[0,100,'0.10'],[1,20000,'0.20'],[1,50000,'0.25'],[2,100000,'0.30'],
- [2,200000,'0.35'],[3,300000,'0.40'],[3,500000,'0.45'],[3,600000,'0.50'],
- [5,900000,'0.55'],[5,1100000,'0.60'],[5,1500000,'0.65'],[5,1700000,'0.70']] as [$people,$amount,$rate]) {
- $rows[] = ['min_valid_members' => $people, 'min_performance' => (string)$amount, 'rate' => $rate];
- }
- return array_fill_keys(array_keys(self::commissionCategories()), $rows);
- }
- }
|