1 | <?php |
||
19 | class TestimonialsController extends AuthorizedController |
||
20 | { |
||
21 | /** |
||
22 | * {@inheritdoc} |
||
23 | */ |
||
24 | protected $resource = Testimonial::class; |
||
25 | |||
26 | /** |
||
27 | * List all testimonials. |
||
28 | * |
||
29 | * @param \Cortex\Testimonials\DataTables\Managerarea\TestimonialsDataTable $testimonialsDataTable |
||
30 | * |
||
31 | * @return \Illuminate\Http\JsonResponse|\Illuminate\View\View |
||
32 | */ |
||
33 | public function index(TestimonialsDataTable $testimonialsDataTable) |
||
39 | |||
40 | /** |
||
41 | * List testimonial logs. |
||
42 | * |
||
43 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
44 | * @param \Cortex\Foundation\DataTables\LogsDataTable $logsDataTable |
||
45 | * |
||
46 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
47 | */ |
||
48 | public function logs(Testimonial $testimonial, LogsDataTable $logsDataTable) |
||
56 | |||
57 | /** |
||
58 | * Import testimonials. |
||
59 | * |
||
60 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
61 | * @param \Cortex\Foundation\DataTables\ImportRecordsDataTable $importRecordsDataTable |
||
62 | * |
||
63 | * @return \Illuminate\View\View |
||
64 | */ |
||
65 | public function import(Testimonial $testimonial, ImportRecordsDataTable $importRecordsDataTable) |
||
74 | |||
75 | /** |
||
76 | * Stash testimonials. |
||
77 | * |
||
78 | * @param \Cortex\Foundation\Http\Requests\ImportFormRequest $request |
||
79 | * @param \Cortex\Foundation\Importers\DefaultImporter $importer |
||
80 | * |
||
81 | * @return void |
||
82 | */ |
||
83 | public function stash(ImportFormRequest $request, DefaultImporter $importer) |
||
90 | |||
91 | /** |
||
92 | * Hoard testimonials. |
||
93 | * |
||
94 | * @param \Cortex\Foundation\Http\Requests\ImportFormRequest $request |
||
95 | * |
||
96 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
97 | */ |
||
98 | public function hoard(ImportFormRequest $request) |
||
121 | |||
122 | /** |
||
123 | * List testimonial import logs. |
||
124 | * |
||
125 | * @param \Cortex\Foundation\DataTables\ImportLogsDataTable $importLogsDatatable |
||
126 | * |
||
127 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
128 | */ |
||
129 | public function importLogs(ImportLogsDataTable $importLogsDatatable) |
||
137 | |||
138 | /** |
||
139 | * Create new testimonial. |
||
140 | * |
||
141 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
142 | * |
||
143 | * @return \Illuminate\View\View |
||
144 | */ |
||
145 | public function create(Testimonial $testimonial) |
||
149 | |||
150 | /** |
||
151 | * Edit given testimonial. |
||
152 | * |
||
153 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
154 | * |
||
155 | * @return \Illuminate\View\View |
||
156 | */ |
||
157 | public function edit(Testimonial $testimonial) |
||
161 | |||
162 | /** |
||
163 | * Show testimonial create/edit form. |
||
164 | * |
||
165 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
166 | * |
||
167 | * @return \Illuminate\View\View |
||
168 | */ |
||
169 | protected function form(Testimonial $testimonial) |
||
173 | |||
174 | /** |
||
175 | * Store new testimonial. |
||
176 | * |
||
177 | * @param \Cortex\Testimonials\Http\Requests\Managerarea\TestimonialFormRequest $request |
||
178 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
179 | * |
||
180 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
181 | */ |
||
182 | public function store(TestimonialFormRequest $request, Testimonial $testimonial) |
||
186 | |||
187 | /** |
||
188 | * Update given testimonial. |
||
189 | * |
||
190 | * @param \Cortex\Testimonials\Http\Requests\Managerarea\TestimonialFormRequest $request |
||
191 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
192 | * |
||
193 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
194 | */ |
||
195 | public function update(TestimonialFormRequest $request, Testimonial $testimonial) |
||
199 | |||
200 | /** |
||
201 | * Process stored/updated testimonial. |
||
202 | * |
||
203 | * @param \Illuminate\Foundation\Http\FormRequest $request |
||
204 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
205 | * |
||
206 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
207 | */ |
||
208 | protected function process(FormRequest $request, Testimonial $testimonial) |
||
221 | |||
222 | /** |
||
223 | * Destroy given testimonial. |
||
224 | * |
||
225 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
226 | * |
||
227 | * @throws \Exception |
||
228 | * |
||
229 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
230 | */ |
||
231 | public function destroy(Testimonial $testimonial) |
||
240 | } |
||
241 |
Very long variable names usually make code harder to read. It is therefore recommended not to make variable names too verbose.