show patron alert_message in summary panel
authorphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 3 Feb 2006 16:12:52 +0000 (16:12 +0000)
committerphasefx <phasefx@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 3 Feb 2006 16:12:52 +0000 (16:12 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@2950 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/xul/staff_client/server/patron/summary.js
Open-ILS/xul/staff_client/server/patron/summary_overlay.xul

index 15943ee..77add77 100644 (file)
@@ -30,6 +30,25 @@ patron.summary.prototype = {
                                                ['command'],
                                                function() { alert('Not Yet Implemented'); }
                                        ],
+                                       'patron_alert' : [
+                                               ['render'],
+                                               function(e) {
+                                                       return function() {
+                                                               JSAN.use('util.widgets');
+                                                               util.widgets.remove_children( e );
+                                                               if (obj.patron.alert_message()) {
+                                                                       e.appendChild(
+                                                                               document.createTextNode(
+                                                                                       obj.patron.alert_message()
+                                                                               )
+                                                                       );
+                                                                       e.parentNode.hidden = false;
+                                                               } else {
+                                                                       e.parentNode.hidden = true;
+                                                               }
+                                                       };
+                                               }
+                                       ],
                                        'patron_name' : [
                                                ['render'],
                                                function(e) {
index e6556cb..ee27dd7 100644 (file)
 </box>
 
 <vbox id="patron_info_sidebar" flex="1">
+       <groupbox id="PatronSummaryAlert_groupbox" flex="0" hidden="true">
+               <caption id="psagbc" label="Alert" class="shrinkable_groupbox"/>
+               <description id="patron_alert"/>
+       </groupbox>
        <groupbox id="PatronSummaryStatus_groupbox" flex="0"/>
        <groupbox id="PatronSummarySurvey_groupbox" flex="0">
                <caption id="pdsgbc" label="Surveys" class="shrinkable_groupbox"/>