filter finised
This commit is contained in:
1 parent
ff43f231f0
commit
f684d61a61
15 files changed
+376
-136
No files matched your search
@@ -16,12 +16,6 @@ class BettypeToggle extends Component
|
||||
'refreshBettypeMenu' => '$refresh',
|
||||
];
|
||||
|
||||
protected $filter_star = false;
|
||||
|
||||
protected $filter_note = false;
|
||||
|
||||
protected $filter_notify = false;
|
||||
|
||||
public function boot()
|
||||
{
|
||||
$this->bettype_toggles = [];
|
||||
@@ -39,6 +33,12 @@ class BettypeToggle extends Component
|
||||
'is_active' => $set->is_active,
|
||||
];
|
||||
}
|
||||
|
||||
// $filters = $livewire->getTable()->getFilters();
|
||||
// $filters = [$filters];
|
||||
// foreach ($filters as $value) {
|
||||
// dd($value['events']->getState());
|
||||
// }
|
||||
}
|
||||
|
||||
public function render()
|
||||
@@ -54,20 +54,17 @@ class BettypeToggle extends Component
|
||||
|
||||
public function toggleStar()
|
||||
{
|
||||
$this->filter_star = ! $this->filter_star;
|
||||
$this->dispatch('filterStarFilter', ['filter', $this->filter_star]);
|
||||
$this->dispatch('filterStarFilter');
|
||||
}
|
||||
|
||||
public function toggleNote()
|
||||
{
|
||||
User::where('id', auth()->user()->id)->update(['filter_notes' => DB::raw('!filter_notes')]);
|
||||
$this->dispatch('filterNotificationFilter');
|
||||
$this->dispatch('filterNoteFilter');
|
||||
}
|
||||
|
||||
public function toggleNotification()
|
||||
{
|
||||
User::where('id', auth()->user()->id)->update(['filter_notification' => DB::raw('!filter_notification')]);
|
||||
$this->dispatch('filterStarFilter');
|
||||
$this->dispatch('filterNotificationFilter');
|
||||
}
|
||||
|
||||
public function toggleShowPartner()
|
||||
|
||||
@@ -17,6 +17,10 @@ class SportSwitcher extends Component
|
||||
|
||||
public $iconcolor = '';
|
||||
|
||||
protected $listeners = [
|
||||
'refreshSportSwitcher' => '$refresh',
|
||||
];
|
||||
|
||||
public function mount()
|
||||
{
|
||||
$cps = Client::where('id', auth()->user()->client_id)->pluck('sport')->first();
|
||||
@@ -35,9 +39,15 @@ class SportSwitcher extends Component
|
||||
{
|
||||
User::where('id', auth()->user()->id)->update(['sport_id' => $this->sport_id]);
|
||||
|
||||
$this->dispatch('clear_filters');
|
||||
$this->sporticon = Sport::where('id', $this->sport_id)->pluck('icon')->first();
|
||||
|
||||
$this->js('window.location.reload()');
|
||||
$this->iconcolor = Sport::where('id', $this->sport_id)->pluck('color')->first();
|
||||
|
||||
// $this->js('window.location.reload()');
|
||||
|
||||
$this->dispatch('filterClearFilter');
|
||||
|
||||
$this->dispatch('refreshSportSwitcher');
|
||||
}
|
||||
|
||||
public function render()
|
||||
|
||||
Reference in new issue
Block a user