source: trunk/services/templates/versions_diff.ihtml @ 457

Last change on this file since 457 was 457, checked in by anonymous, 10 years ago

Removed use of requireAccessClearance(). Adjusted sequence of sslOn() and requireLogin(). Added ACL::requireAllow() method. Added arguments to SortOrder::set(). Changed behavior of Validator::validateStrDate(). Added use of Validator::validateStrDate() to module maker templates.

File size: 1.1 KB
Line 
1<div class="commandbox">
2<?php if (!getFormData('current', false)) { ?>
3    <span class="sc-nowrap commanditem"><a href="<?php echo $app->oHREF($_SERVER['PHP_SELF'] . '?op=restore', array('version_id', 'version_title')); ?>"><?php echo _("Restore this saved version"); ?></a></span>
4<?php } else { ?>
5    <span class="sc-nowrap commanditem">&nbsp;</span>
6<?php } ?>
7</div>
8
9<?php if (is_array($data) && !empty($data) && is_array($current) && !empty($current)) { ?>
10<table class="list">
11    <tr>
12        <th class="sc-padleft"><?php echo _("Field"); ?></th>
13        <th class="sc-padleft"><?php echo _("Saved version"); ?></th>
14        <th class="sc-padleft"><?php echo _("Current record"); ?></th>
15    </tr>
16<?php
17foreach ($current as $k=>$v_c) {
18    $v_d = isset($data[$k]) ? $data[$k] : '<span style="color: #e00;">Unavailable</span>';
19    $style = $v_d != $v_c ? ' style="font-weight: bold;"' : '';
20    ?>
21    <tr>
22        <td class="sc-padleft sc-nowrap"<?php echo $style; ?>><label><?php echo $k; ?></label></td>
23        <td class="sc-padleft"><?php echo $v_d; ?></td>
24        <td class="sc-padleft"><?php echo $v_c; ?></td>
25    </tr>
26<?php } ?>
27</table>
28<?php } ?>
Note: See TracBrowser for help on using the repository browser.