[open-ils-commits] [GIT] Evergreen ILS branch master updated. d87ad5f21e23f5e28fe7b970baad090d2b59eb63

Evergreen Git git at git.evergreen-ils.org
Sun Sep 1 09:49:17 EDT 2019


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Evergreen ILS".

The branch, master has been updated
       via  d87ad5f21e23f5e28fe7b970baad090d2b59eb63 (commit)
      from  001edcb20b3b408e9df9f901169749e5585b8b26 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit d87ad5f21e23f5e28fe7b970baad090d2b59eb63
Author: Remington Steed <rjs7 at calvin.edu>
Date:   Wed Apr 24 14:01:39 2019 -0400

    LP#1721036: Add url to item tags (DB, IDL, and OPAC link)
    
    This commit adds a new field to the asset.copy_tag database table, adds
    it to the IDL, and includes it as a link in the OPAC when present.
    
    Signed-off-by: Remington Steed <rjs7 at calvin.edu>
    Signed-off-by: Kyle Huckins <khuckins at catalyte.io>
    Signed-off-by: Chris Sharp <csharp at georgialibraries.org>

diff --git a/Open-ILS/examples/fm_IDL.xml b/Open-ILS/examples/fm_IDL.xml
index 0a14cb5f14..544488e3f1 100644
--- a/Open-ILS/examples/fm_IDL.xml
+++ b/Open-ILS/examples/fm_IDL.xml
@@ -12706,6 +12706,7 @@ SELECT  usr,
 			<field reporter:label="Staff Note" name="staff_note" reporter:datatype="text"/>
 			<field reporter:label="Is OPAC Visible?" name="pub" reporter:datatype="bool"/>
 			<field reporter:label="Owner" name="owner" reporter:datatype="org_unit" oils_obj:required="true"/>
+			<field reporter:label="URL" name="url" reporter:datatype="text"/>
 		</fields>
 		<links>
 			<link field="tag_type" reltype="has_a" key="code" map="" class="cctt"/>
diff --git a/Open-ILS/src/sql/Pg/040.schema.asset.sql b/Open-ILS/src/sql/Pg/040.schema.asset.sql
index 9beed1d751..198632a617 100644
--- a/Open-ILS/src/sql/Pg/040.schema.asset.sql
+++ b/Open-ILS/src/sql/Pg/040.schema.asset.sql
@@ -967,7 +967,8 @@ CREATE TABLE asset.copy_tag (
     index_vector    tsvector NOT NULL,
     staff_note      TEXT,
     pub             BOOLEAN DEFAULT TRUE,
-    owner           INTEGER NOT NULL REFERENCES actor.org_unit (id)
+    owner           INTEGER NOT NULL REFERENCES actor.org_unit (id),
+    url             TEXT
 );
 
 CREATE INDEX asset_copy_tag_label_idx
diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.asset.copy_tag.url.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.asset.copy_tag.url.sql
new file mode 100644
index 0000000000..b7b26ceb09
--- /dev/null
+++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.asset.copy_tag.url.sql
@@ -0,0 +1,8 @@
+BEGIN;
+
+--INSERT INTO config.upgrade_log (version, applied_to) VALUES ('XXXX', :eg_version);
+
+ALTER TABLE asset.copy_tag
+          ADD COLUMN url TEXT;
+
+COMMIT;
diff --git a/Open-ILS/src/templates/opac/parts/record/copy_table.tt2 b/Open-ILS/src/templates/opac/parts/record/copy_table.tt2
index 1e0456cf83..1c7a2de0dd 100644
--- a/Open-ILS/src/templates/opac/parts/record/copy_table.tt2
+++ b/Open-ILS/src/templates/opac/parts/record/copy_table.tt2
@@ -236,7 +236,15 @@ END; # FOREACH bib
                 <tr class="copy_tag_row">
                     <td> </td>
                     <td class="copy_tag" colspan="4">
-                        <span class="copy_tag_value">[% tag.value | html %]</span>
+                        <span class="copy_tag_value">
+                            [% IF tag.url %]
+                            <a href="[% tag.url | html %]">
+                            [% END %]
+                                [% tag.value | html %]
+                            [% IF tag.url %]
+                            </a>
+                            [% END %]
+                        </span>
                     </td>
                 <tr>
             [% END %]

-----------------------------------------------------------------------

Summary of changes:
 Open-ILS/examples/fm_IDL.xml                                   |  1 +
 Open-ILS/src/sql/Pg/040.schema.asset.sql                       |  3 ++-
 Open-ILS/src/sql/Pg/upgrade/XXXX.schema.asset.copy_tag.url.sql |  8 ++++++++
 Open-ILS/src/templates/opac/parts/record/copy_table.tt2        | 10 +++++++++-
 4 files changed, 20 insertions(+), 2 deletions(-)
 create mode 100644 Open-ILS/src/sql/Pg/upgrade/XXXX.schema.asset.copy_tag.url.sql


hooks/post-receive
-- 
Evergreen ILS


More information about the open-ils-commits mailing list