Revize 979
Přidáno uživatelem Michal Kliment před více než 13 roky(ů)
freenetis/branches/testing/application/models/device.php | ||
---|---|---|
(
|
||
SELECT * FROM
|
||
(
|
||
SELECT d.id, d.name, IFNULL(t.translated_term,e.value) AS type, i.mac, IFNULL(ip1.ip_address,ip2.ip_address) AS ip_address FROM devices d
|
||
SELECT d.id, d.name, d.buy_date, IFNULL(t.translated_term,e.value) AS type, i.mac, IFNULL(ip1.ip_address,ip2.ip_address) AS ip_address FROM devices d
|
||
LEFT JOIN enum_types e ON d.type = e.id
|
||
LEFT JOIN translations t ON e.value LIKE t.original_term AND t.lang = '". Config::get('lang') ."'
|
||
LEFT JOIN ifaces i ON d.id = i.device_id
|
freenetis/branches/testing/application/controllers/devices.php | ||
---|---|---|
$arr_devices[$device->id] = array(
|
||
'type' => $device->type,
|
||
'name' => $device->name,
|
||
'buy_date' => $device->buy_date,
|
||
'grids' => array()
|
||
);
|
||
|
freenetis/branches/testing/application/views/devices_show.php | ||
---|---|---|
<th><?php echo url_lang::lang('texts.Monthly payment rate') ?></th>
|
||
<td><?php echo $device->payment_rate ?></td>
|
||
</tr>
|
||
<?php }
|
||
if ($device->buy_date != '' && $device->buy_date != '1970-01-01') { ?>
|
||
<tr>
|
||
<th><?php echo url_lang::lang('texts.Buy date') ?></th>
|
||
<td><?php echo $device->buy_date ?></td>
|
Také k dispozici: Unified diff
Implementace http://vyuka.slfree.net/mod/forum/discuss.php?d=1677 - vyuziti jiz existujici datumu koupe zarizeni pro interni potreby.