1 | <?php |
||
17 | class TestimonialsController extends AuthorizedController |
||
18 | { |
||
19 | /** |
||
20 | * {@inheritdoc} |
||
21 | */ |
||
22 | protected $resource = Testimonial::class; |
||
23 | |||
24 | /** |
||
25 | * List all testimonials. |
||
26 | * |
||
27 | * @param \Cortex\Testimonials\DataTables\Managerarea\TestimonialsDataTable $testimonialsDataTable |
||
28 | * |
||
29 | * @return \Illuminate\Http\JsonResponse|\Illuminate\View\View |
||
30 | */ |
||
31 | public function index(TestimonialsDataTable $testimonialsDataTable) |
||
38 | |||
39 | /** |
||
40 | * List testimonial logs. |
||
41 | * |
||
42 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
43 | * @param \Cortex\Foundation\DataTables\LogsDataTable $logsDataTable |
||
44 | * |
||
45 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
46 | */ |
||
47 | public function logs(Testimonial $testimonial, LogsDataTable $logsDataTable) |
||
56 | |||
57 | /** |
||
58 | * Import testimonials. |
||
59 | * |
||
60 | * @return \Illuminate\View\View |
||
61 | */ |
||
62 | public function import() |
||
71 | |||
72 | /** |
||
73 | * Hoard testimonials. |
||
74 | * |
||
75 | * @param \Cortex\Foundation\Http\Requests\ImportFormRequest $request |
||
76 | * @param \Cortex\Foundation\Importers\DefaultImporter $importer |
||
77 | * |
||
78 | * @return void |
||
79 | */ |
||
80 | public function hoard(ImportFormRequest $request, DefaultImporter $importer) |
||
87 | |||
88 | /** |
||
89 | * List testimonial import logs. |
||
90 | * |
||
91 | * @param \Cortex\Foundation\DataTables\ImportLogsDataTable $importLogsDatatable |
||
92 | * |
||
93 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
94 | */ |
||
95 | public function importLogs(ImportLogsDataTable $importLogsDatatable) |
||
104 | |||
105 | /** |
||
106 | * Create new testimonial. |
||
107 | * |
||
108 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
109 | * |
||
110 | * @return \Illuminate\View\View |
||
111 | */ |
||
112 | public function create(Testimonial $testimonial) |
||
116 | |||
117 | /** |
||
118 | * Edit given testimonial. |
||
119 | * |
||
120 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
121 | * |
||
122 | * @return \Illuminate\View\View |
||
123 | */ |
||
124 | public function edit(Testimonial $testimonial) |
||
128 | |||
129 | /** |
||
130 | * Show testimonial create/edit form. |
||
131 | * |
||
132 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
133 | * |
||
134 | * @return \Illuminate\View\View |
||
135 | */ |
||
136 | protected function form(Testimonial $testimonial) |
||
140 | |||
141 | /** |
||
142 | * Store new testimonial. |
||
143 | * |
||
144 | * @param \Cortex\Testimonials\Http\Requests\Managerarea\TestimonialFormRequest $request |
||
145 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
146 | * |
||
147 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
148 | */ |
||
149 | public function store(TestimonialFormRequest $request, Testimonial $testimonial) |
||
153 | |||
154 | /** |
||
155 | * Update given testimonial. |
||
156 | * |
||
157 | * @param \Cortex\Testimonials\Http\Requests\Managerarea\TestimonialFormRequest $request |
||
158 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
159 | * |
||
160 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
161 | */ |
||
162 | public function update(TestimonialFormRequest $request, Testimonial $testimonial) |
||
166 | |||
167 | /** |
||
168 | * Process stored/updated testimonial. |
||
169 | * |
||
170 | * @param \Illuminate\Foundation\Http\FormRequest $request |
||
171 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
172 | * |
||
173 | * @return \Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse |
||
174 | */ |
||
175 | protected function process(FormRequest $request, Testimonial $testimonial) |
||
188 | |||
189 | /** |
||
190 | * Destroy given testimonial. |
||
191 | * |
||
192 | * @param \Cortex\Testimonials\Models\Testimonial $testimonial |
||
193 | * |
||
194 | * @return \Illuminate\Http\Response |
||
195 | */ |
||
196 | public function destroy(Testimonial $testimonial) |
||
205 | } |
||
206 |
Very long variable names usually make code harder to read. It is therefore recommended not to make variable names too verbose.