芝麻web文件管理V1.00
编辑当前文件:/home/forge/stage.sksb.smartcon-survey.com/app/Livewire/TopicsTable.php
selected) > 0) { Topic::destroy($this->selected); } } public function render() { $this->disableDelete = count($this->selected) === 0; return view('livewire.topics-table', [ 'topics' => Topic::search($this->search) ->orderBy('created_at', 'desc') ->simplePaginate($this->paginationLimit), ]); } public function toggleAllCheckboxes($checkboxStatus) { if (count($this->selected) > 0 || $checkboxStatus === false) { $this->selected = []; } else { $topics = Topic::search($this->search) ->orderBy('created_at', 'desc') ->simplePaginate($this->paginationLimit); foreach ($topics as $topic) { array_push($this->selected, $topic->id); } } } public function pageLimit($limit) { $this->paginationLimit = $limit; } }