[open-ils-commits] r15660 - in trunk/Open-ILS/web: css/skin/default js/ui/default/acq/common templates/default/acq/common (senator)

svn at svn.open-ils.org svn at svn.open-ils.org
Tue Mar 2 14:42:31 EST 2010


Author: senator
Date: 2010-03-02 14:42:26 -0500 (Tue, 02 Mar 2010)
New Revision: 15660

Modified:
   trunk/Open-ILS/web/css/skin/default/acq.css
   trunk/Open-ILS/web/js/ui/default/acq/common/li_table.js
   trunk/Open-ILS/web/templates/default/acq/common/li_table.tt2
Log:
Acq: Indicate presence of alerts among notes in lineitem table interface

Italicize the notes link and mark it with a red flag character when the notes
associated with a given lineitem have alert texts linked to them.


Modified: trunk/Open-ILS/web/css/skin/default/acq.css
===================================================================
--- trunk/Open-ILS/web/css/skin/default/acq.css	2010-03-02 19:36:00 UTC (rev 15659)
+++ trunk/Open-ILS/web/css/skin/default/acq.css	2010-03-02 19:42:26 UTC (rev 15660)
@@ -143,6 +143,7 @@
 #acq-lit-alert-value { height: 5em; width: 20em; }
 .acq-lit-note-row { margin: 6px 0; }
 span[name="alert_code"] {color: #c00;padding-right: 1em;font-weight: bold;}
+span[name="notes_alert_flag"] {color: #c00;font-weight: bold;font-size: 110%;margin: 0 7px;}
 
 .acq-lit-li-menu-bar {width:99%; text-align:left; border:1px solid #aaa; margin:5px 0px 10px 0px;}
 .acq-lit-li-menu-left {text-align:left; width:300px;}

Modified: trunk/Open-ILS/web/js/ui/default/acq/common/li_table.js
===================================================================
--- trunk/Open-ILS/web/js/ui/default/acq/common/li_table.js	2010-03-02 19:36:00 UTC (rev 15659)
+++ trunk/Open-ILS/web/js/ui/default/acq/common/li_table.js	2010-03-02 19:42:26 UTC (rev 15660)
@@ -271,6 +271,16 @@
     this.updateLiNotesCount = function(li, row) {
         if (typeof(row) == "undefined")
             row = dojo.query('tr[li="' + li.id() + '"]', "acq-lit-tbody")[0];
+
+        var has_notes = (li.lineitem_notes().filter(
+                function(o) { return Boolean (o.alert_text()); }
+            ).length > 0);
+
+        /* U+2691 is the code point for a filled-in flag character */
+        nodeByName("notes_alert_flag", row).innerHTML =
+             has_notes ? "⚑" : "";
+        nodeByName("noteslink", row).style.fontStyle =
+            has_notes ? "italic" : "normal";
         nodeByName("notes_count", row).innerHTML = li.lineitem_notes().length;
     };
 

Modified: trunk/Open-ILS/web/templates/default/acq/common/li_table.tt2
===================================================================
--- trunk/Open-ILS/web/templates/default/acq/common/li_table.tt2	2010-03-02 19:36:00 UTC (rev 15659)
+++ trunk/Open-ILS/web/templates/default/acq/common/li_table.tt2	2010-03-02 19:42:26 UTC (rev 15660)
@@ -96,8 +96,7 @@
                     </td>
                     <td><a name='copieslink' href='javascript:void(0);'>Copies(<span name='count'>0</span>)</a></td>
                     <td>
-                        <a name='noteslink' href='javascript:void(0);' 
-                            style='margin-right:15px;'>Notes(<span name='notes_count'>0</span>)</a>
+                        <a name='noteslink' href='javascript:void(0);'>Notes(<span name='notes_count'>0</span>)</a><span name="notes_alert_flag"></span>
                     </td>
                     <td><span name='li_state'></span></td>
                     <td><input type='text' size='8' name='price'/></td>



More information about the open-ils-commits mailing list