Skip to content

Instantly share code, notes, and snippets.

View sashabeep's full-sized avatar

Sasha Beep sashabeep

View GitHub Profile
@sashabeep
sashabeep / evoshop.module.php
Last active October 20, 2017 09:27
Evoshop view orders module
if(IN_MANAGER_MODE!='true' && !$modx->hasPermission('exec_module')) die('<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the MODX Content Manager instead of accessing this file directly.');
$moduleurl = 'index.php?a=112&id='.$_GET['id'].'&';
$txt = $modx->runSnippet('DocLister', array( 'controller' => 'onetable',
'table' => 'evoshop_orders',
'idField' => 'id',
'tpl' => '@CODE:<tr><td>[+id+]</td><td>[+orderdata+]</td><td><b>[+price+]</b></td><td>[+date+]</td><td>[+email+]</td><td>[+phone+]</td><td align="center"><a href="'.$moduleurl.'action=remove&amp;eid=[+id+]"><i class="fa fa-trash-o"></i></a></td></tr>',
'orderBy'=>'id ASC',
'selectFields'=>'id,price,date,email,phone,content',