23 lines
464 B
PHP
23 lines
464 B
PHP
<?php
|
|
|
|
namespace Garradin;
|
|
|
|
use Garradin\Plugin\Materiels\Equipment;
|
|
use Garradin\Plugin\Materiels\Entry;
|
|
|
|
require_once __DIR__ . '/../_inc.php';
|
|
|
|
$eqmt = new Equipment;
|
|
$entry = new Entry;
|
|
|
|
$entries = $entry->listAll();
|
|
|
|
foreach ($entries as $key => $value) {
|
|
$entry_eqmt = $eqmt->get($value->equipment_id);
|
|
$entries[$key]->equipment = $entry_eqmt->designation;
|
|
}
|
|
|
|
$tpl->assign(compact('entries'));
|
|
|
|
$tpl->display(PLUGIN_ROOT . '/templates/entrees/index.tpl');
|