1234567891011121314151617181920212223242526272829303132 |
- <?php
- namespace App\Admin\Actions\Games;
- use App\Models\UserInfoModel;
- use Dcat\Admin\Admin;
- use Dcat\Admin\Grid\RowAction;
- use Dcat\Admin\Widgets\Modal;
- use Dcat\Admin\Widgets\Table;
- class GameScores extends RowAction
- {
- protected $title;
- protected $type;
- public function href(): string
- {
- if($this->type=='game'){
- return "/admin/game_user_scores?game_id=".$this->getKey();
- }else{
- return "/admin/game_user_scores?user_id=".$this->getKey();
- }
- }
- public function __construct(string $type = 'game')
- {
- $this->type = $type;
- $this->title = '<i class="feather icon-aperture"></i> '.trans('games.fields.game_record');
- }
- }
|