diff --git a/app/templates/ApiUsers/columns.inc b/app/templates/ApiUsers/columns.inc index 7b7585165..f38cd7c1c 100644 --- a/app/templates/ApiUsers/columns.inc +++ b/app/templates/ApiUsers/columns.inc @@ -27,7 +27,7 @@ // Output advisory banner when co=1 if($vv_cur_co->id == 1) { - $indexBanners = [ + $banners = [ __d('information','api.cmp') ]; } diff --git a/app/templates/ApiUsers/fields.inc b/app/templates/ApiUsers/fields.inc index 1e23c9b87..cddb22c1b 100644 --- a/app/templates/ApiUsers/fields.inc +++ b/app/templates/ApiUsers/fields.inc @@ -28,7 +28,7 @@ // This view does not support read-only if($vv_action == 'add' || $vv_action == 'edit') { if($vv_cur_co->id == 1) { - print $this->element('banner', ['info' => __d('information', 'api.cmp')]); + print $this->element('notify/banner', ['info' => __d('information', 'api.cmp')]); } // AR-ApiUser-3 For namespacing purposes, API Users are named with a prefix consisting of the string "co_#.". diff --git a/app/templates/Cos/select.php b/app/templates/Cos/select.php index b18e1833b..96df06e13 100644 --- a/app/templates/Cos/select.php +++ b/app/templates/Cos/select.php @@ -34,6 +34,8 @@ +element('flash') // Flash messages ?> + element('notify/alert', ['message' => __d('information','cos.none')]) ?> diff --git a/app/templates/Dashboards/configuration.php b/app/templates/Dashboards/configuration.php index 1016a428e..368b41b47 100644 --- a/app/templates/Dashboards/configuration.php +++ b/app/templates/Dashboards/configuration.php @@ -35,6 +35,8 @@ +element('flash') // Flash messages ?> +

diff --git a/app/templates/Dashboards/search.php b/app/templates/Dashboards/search.php index e39f29d6b..fdb036d45 100644 --- a/app/templates/Dashboards/search.php +++ b/app/templates/Dashboards/search.php @@ -53,22 +53,7 @@ - -
- Flash->render() ?> - - - - element('notify/alert', ['message' => $b]) ?> - - - - - - element('notify/alert', ['message' => $b]) ?> - - -
+element('flash') // Flash messages ?>
diff --git a/app/templates/EnrollmentFlows/start.php b/app/templates/EnrollmentFlows/start.php index d0a293c81..7dd28ede7 100644 --- a/app/templates/EnrollmentFlows/start.php +++ b/app/templates/EnrollmentFlows/start.php @@ -35,6 +35,8 @@
+element('flash') // Flash messages ?> + set('vv_fields_inc', 'start.inc'); diff --git a/app/templates/ExternalIdentities/relink.php b/app/templates/ExternalIdentities/relink.php index 2ca6c2c6b..ea7d1ae42 100644 --- a/app/templates/ExternalIdentities/relink.php +++ b/app/templates/ExternalIdentities/relink.php @@ -34,6 +34,8 @@ +element('flash') // Flash messages ?> + Form->create(null, [ 'id' => 'ei-relink-form', diff --git a/app/templates/ExternalIdentitySources/retrieve.php b/app/templates/ExternalIdentitySources/retrieve.php index b87b22b12..19270cda0 100644 --- a/app/templates/ExternalIdentitySources/retrieve.php +++ b/app/templates/ExternalIdentitySources/retrieve.php @@ -156,6 +156,9 @@ } ?> element('notify/alert', ['message' => $noticeText,'type' => 'information']) ?> + +element('flash') // Flash messages ?> +

diff --git a/app/templates/ExternalIdentitySources/search.php b/app/templates/ExternalIdentitySources/search.php index fb943f460..61f5d2e01 100644 --- a/app/templates/ExternalIdentitySources/search.php +++ b/app/templates/ExternalIdentitySources/search.php @@ -41,6 +41,8 @@
+element('flash') // Flash messages ?> + element('notify/alert', [ 'message' => __d('information', 'ExternalIdentitySources.search.attrs.none'), diff --git a/app/templates/HistoryRecords/columns.inc b/app/templates/HistoryRecords/columns.inc index 252bb9af5..f244c2117 100644 --- a/app/templates/HistoryRecords/columns.inc +++ b/app/templates/HistoryRecords/columns.inc @@ -25,7 +25,7 @@ * @license Apache License, Version 2.0 (http://www.apache.org/licenses/LICENSE-2.0) */ -$indexBanners = [ +$banners = [ // CFM-76 info message pending eventual "virtual" view consolidating all History Record types __d('information', 'HistoryRecords.xref') ]; diff --git a/app/templates/MostlyStaticPages/display.php b/app/templates/MostlyStaticPages/display.php index e4d20f54a..f01c74bdc 100644 --- a/app/templates/MostlyStaticPages/display.php +++ b/app/templates/MostlyStaticPages/display.php @@ -34,22 +34,7 @@ - -
- Flash->render() ?> - - - - Alert->alert($b, 'warning') ?> - - - - - - Alert->alert($b, 'warning') ?> - - -
+element('flash') // Flash messages ?>
diff --git a/app/templates/Petitions/resume.php b/app/templates/Petitions/resume.php index 65e0b09be..9c4f9557c 100644 --- a/app/templates/Petitions/resume.php +++ b/app/templates/Petitions/resume.php @@ -71,22 +71,7 @@
- -
- Flash->render() ?> - - - - Alert->alert($b, 'warning') ?> - - - - - - Alert->alert($b, 'warning') ?> - - -
+element('flash') // Flash messages ?>
diff --git a/app/templates/ProvisioningTargets/status.php b/app/templates/ProvisioningTargets/status.php index b22ac3d26..201daa1ff 100644 --- a/app/templates/ProvisioningTargets/status.php +++ b/app/templates/ProvisioningTargets/status.php @@ -34,22 +34,7 @@
- -
- Flash->render() ?> - - - - element('notify/alert', ['message' => $b]) ?> - - - - - - element('notify/alert', ['message' => $b]) ?> - - -
+element('flash') // Flash messages ?>
diff --git a/app/templates/Standard/add-edit-view.php b/app/templates/Standard/add-edit-view.php index a4dceac6c..7e157cf9b 100644 --- a/app/templates/Standard/add-edit-view.php +++ b/app/templates/Standard/add-edit-view.php @@ -56,15 +56,6 @@ $linkFilter = [$vv_primary_link => $this->request->getQuery($vv_primary_link)]; } -// $flashArgs pass banner messages to the flash element container -$flashArgs = []; -if(!empty($banners)) { - // XXX this doesn't work yet because we don't include fields.inc until later - // either create a second file to include earlier, or use a function to emit - // the fields (which would be more consistent with how Views render...) - $flashArgs['vv_banners'] = $banners; -} - // Subnavigation $hasSubnav = false; if(file_exists(ROOT . DS . 'templates' . DS . 'Standard/subnavigation.inc')) { @@ -72,8 +63,8 @@ $hasSubnav = $this->get('hasSupertitle'); } -// When under a subnavigation we do not want a title with Edit or Add or View followed by a number -// We might find ourselved in that situation since we calculate the title for the breadcrumbs and +// When under subnavigation we do not want a title with Edit or Add or View followed by a number. +// We might find ourselves in that situation since we calculate the title for the breadcrumbs and // this simple description is not wrong. It is just not appropriate for the subnavigation title $title = $vv_title; $re = '/^(Add|Edit|View)\s([a-zA-Z]+?)\s[0-9]+/m'; @@ -186,7 +177,7 @@ - element('flash', $flashArgs) ?> + element('flash') ?>
- element('flash', $flashArgs); - ?> + element('flash') // Flash messages ?>