|
@@ 72-74 (lines=3) @@
|
| 69 |
|
{ |
| 70 |
|
// find feedback post by id |
| 71 |
|
$record = FeedbackPost::find($id); |
| 72 |
|
if ($record === null || $record === false) { |
| 73 |
|
throw new NotFoundException(__('The feedback message is not founded')); |
| 74 |
|
} |
| 75 |
|
|
| 76 |
|
// initialize model with answer add if thread is not closed |
| 77 |
|
$model = null; |
|
@@ 124-126 (lines=3) @@
|
| 121 |
|
} |
| 122 |
|
|
| 123 |
|
// try what we got |
| 124 |
|
if ($record === null || $record === false) { |
| 125 |
|
throw new NotFoundException(__('Feedback item is not founded')); |
| 126 |
|
} |
| 127 |
|
|
| 128 |
|
// initialize model |
| 129 |
|
$model = new FormUpdate($record); |
|
@@ 157-159 (lines=3) @@
|
| 154 |
|
{ |
| 155 |
|
// try to find record |
| 156 |
|
$record = FeedbackPost::find($id); |
| 157 |
|
if ($record === null || $record === false) { |
| 158 |
|
throw new NotFoundException(__('Feedback request with id %id% is not found', ['id' => $id])); |
| 159 |
|
} |
| 160 |
|
|
| 161 |
|
// switch operation direction to what we must change |
| 162 |
|
switch ($direction) { |
|
@@ 212-214 (lines=3) @@
|
| 209 |
|
} |
| 210 |
|
|
| 211 |
|
// check if we get the row |
| 212 |
|
if ($record === null || $record === false) { |
| 213 |
|
throw new NotFoundException(__('Feedback item is not founded')); |
| 214 |
|
} |
| 215 |
|
|
| 216 |
|
// if delete is submited |
| 217 |
|
if ($this->request->request->get('deleteFeedback')) { |