summaryrefslogtreecommitdiffstats
path: root/src/usr/local/www/firewall_rules_edit.php
diff options
context:
space:
mode:
authorPhil Davis <phil@jankaritech.com>2017-05-19 13:40:27 +0545
committerjim-p <jimp@pfsense.org>2017-06-21 09:52:53 -0400
commit1ea6736f8fe2d641eecbbc9977bd28f97236b213 (patch)
tree8513a8ff74430bd317ce22d119e6637a0073ac5f /src/usr/local/www/firewall_rules_edit.php
parentf4f220a796c0e529bd99f969b9f204d37ad79a97 (diff)
downloadpfsense-1ea6736f8fe2d641eecbbc9977bd28f97236b213.zip
pfsense-1ea6736f8fe2d641eecbbc9977bd28f97236b213.tar.gz
Make consistent rule information section
(cherry picked from commit f0dc8b688c2b7d973bc18769579ee8cc6d3d2dad) (cherry picked from commit 4c4504b1e785396d92be853072a9c557c55b3c4a)
Diffstat (limited to 'src/usr/local/www/firewall_rules_edit.php')
-rw-r--r--src/usr/local/www/firewall_rules_edit.php24
1 files changed, 2 insertions, 22 deletions
diff --git a/src/usr/local/www/firewall_rules_edit.php b/src/usr/local/www/firewall_rules_edit.php
index 2ccf127..7727082 100644
--- a/src/usr/local/www/firewall_rules_edit.php
+++ b/src/usr/local/www/firewall_rules_edit.php
@@ -1768,30 +1768,10 @@ $section->add($group)->setHelp('Choose the Acknowledge Queue only if there is a
'selected Queue.'
);
-$has_created_time = (isset($a_filter[$id]['created']) && is_array($a_filter[$id]['created']));
-$has_updated_time = (isset($a_filter[$id]['updated']) && is_array($a_filter[$id]['updated']));
-
-
-if ($has_created_time || $has_updated_time) {
- $form->add($section);
- $section = new Form_Section('Rule Information');
-
- if ($has_created_time) {
- $section->addInput(new Form_StaticText(
- 'Created',
- date('n/j/y H:i:s', $a_filter[$id]['created']['time']) . gettext(' by ') .'<b>'. $a_filter[$id]['created']['username'] .'</b>'
- ));
- }
+$form->add($section);
- if ($has_updated_time) {
- $section->addInput(new Form_StaticText(
- 'Updated',
- date('n/j/y H:i:s', $a_filter[$id]['updated']['time']) . gettext(' by ') .'<b>'. $a_filter[$id]['updated']['username'] .'</b>'
- ));
- }
-}
+gen_created_updated_fields($form, $a_filter[$id]['created'], $a_filter[$id]['updated']);
-$form->add($section);
echo $form;
?>
OpenPOWER on IntegriCloud