Conditions | 4 |
Paths | 3 |
Total Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
25 | public function index() |
||
26 | { |
||
27 | if (Permission::check('ADMIN')) { |
||
28 | $object = $_REQUEST['class']::get()->byID(intval($_REQUEST['id'])); |
||
29 | if ($object && $object->hasMethod('updatePrices')) { |
||
30 | $object->updatePrices(Convert::raw2sql($_REQUEST['From']), explode(',', Convert::raw2sql($_REQUEST['To']))); |
||
31 | echo '<p>All prices updated from <strong>'.$_REQUEST['From'].'</strong> to <strong>'.$_REQUEST['To'].'</strong></p>'; |
||
32 | return; |
||
33 | } |
||
34 | } else { |
||
35 | echo "please log in as admin first"; |
||
36 | } |
||
37 | } |
||
38 | |||
45 |