LP#1234927: Pluralizing link names to follow convention.
[working/Evergreen.git] / Open-ILS / examples / fm_IDL.xml
index 1c92c2e..40fd709 100644 (file)
@@ -19,6 +19,56 @@ You should have received a copy of the GNU General Public License
 along with this program; if not, write to the Free Software
 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
 
+############################
+          TEMPLATE
+############################
+
+    <class
+        id=""
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper=""
+        oils_persist:tablename=""
+        reporter:label=""
+        oils_persist:field_safe=""
+        oils_persist:virtual=""
+        oils_persist:readonly=""
+        reporter:core=""
+    >
+
+        <oils_persist:source_definition><![CDATA[
+            SELECT * FROM foo
+        ]]></oils_persist:source_definition>
+
+        <fields oils_persist:primary="" oils_persist:sequence="">
+            <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="" name="" reporter:datatype="org_unit"/>
+            <field reporter:label="" name="" reporter:datatype="text"/>
+            <field reporter:label="" name="" reporter:datatype="link"/>
+            <field reporter:label="" name="" reporter:datatype="timestamp"/>
+            <field reporter:label="" name="" reporter:datatype="money"/>
+            <field reporter:label="" name="" reporter:datatype="bool"/>
+            <field reporter:label="" name="" reporter:datatype="int" oils_obj:required="true"/>
+            <field reporter:label="" name="" reporter:datatype="int" oils_persist:virtual="true"/>
+        </fields>
+
+        <links>
+            <link field="" reltype="has_a" key="" map="" class=""/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="" gloabl_required="true"/>
+                <retrieve/>
+                <update permission="" context_field=""/>
+                <delete permission="">
+                    <context link="" field=""/>
+                </delete>
+            </actions>
+        </permacrud>
+
+    </class>
+
+
 -->
 
 <IDL xmlns="http://opensrf.org/spec/IDL/base/v1" xmlns:idl="http://opensrf.org/spec/IDL/base/v1" xmlns:oils_persist="http://open-ils.org/spec/opensrf/IDL/persistence/v1" xmlns:oils_obj="http://open-ils.org/spec/opensrf/IDL/objects/v1" xmlns:reporter="http://open-ils.org/spec/opensrf/IDL/reporter/v1" xmlns:permacrud="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
@@ -166,22 +216,54 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
        <class id="vibtf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::import_bib_trash_fields" oils_persist:tablename="vandelay.import_bib_trash_fields" reporter:label="Import/Overlay Fields for Removal">
                <fields oils_persist:primary="id" oils_persist:sequence="vandelay.import_bib_trash_fields_id_seq">
                        <field reporter:label="Field ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
+                       <field reporter:label="Group" name="grp" reporter:datatype="link"/>
                        <field reporter:label="Field" name="field" reporter:datatype="text"/>
                </fields>
                <links>
+                       <link field="grp" reltype="has_a" key="id" map="" class="vibtg"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="CREATE_IMPORT_TRASH_FIELD">
+                    <context link="grp" field="owner"/>
+                </create>
+                               <retrieve/>
+                               <update permission="UPDATE_IMPORT_TRASH_FIELD">
+                    <context link="grp" field="owner"/>
+                </update>
+                               <delete permission="DELETE_IMPORT_TRASH_FIELD">
+                    <context link="grp" field="owner"/>
+                </delete>
+                       </actions>
+               </permacrud>
+       </class>
+
+       <class  id="vibtg" 
+            controller="open-ils.cstore open-ils.pcrud" 
+            oils_obj:fieldmapper="vandelay::import_bib_trash_group" 
+            oils_persist:tablename="vandelay.import_bib_trash_group" 
+            reporter:label="Import/Overlay Field Groups for Removal">
+               <fields oils_persist:primary="id" 
+                oils_persist:sequence="vandelay.import_bib_trash_group_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id" reporter:selector="name"/>
+                       <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
+                       <field reporter:label="Label" name="label" reporter:datatype="text"/>
+                       <field reporter:label="Always Apply" name="always_apply" reporter:datatype="bool"/>
+               </fields>
+               <links>
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
                                <create permission="CREATE_IMPORT_TRASH_FIELD" context_field="owner"/>
-                               <retrieve permission="CREATE_IMPORT_TRASH_FIELD UPDATE_IMPORT_TRASH_FIELD DELETE_IMPORT_TRASH_FIELD" context_field="owner"/>
+                               <retrieve/>
                                <update permission="UPDATE_IMPORT_TRASH_FIELD" context_field="owner"/>
                                <delete permission="DELETE_IMPORT_TRASH_FIELD" context_field="owner"/>
                        </actions>
                </permacrud>
        </class>
 
+
        <class id="vii" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::import_item" oils_persist:tablename="vandelay.import_item" reporter:label="Import Item">
                <fields oils_persist:primary="id" oils_persist:sequence="vandelay.import_item_id_seq">
                        <field reporter:label="Import Item ID" name="id" reporter:datatype="id"/>
@@ -210,6 +292,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Public Note" name="pub_note" reporter:datatype="text"/>
                        <field reporter:label="Private Note" name="priv_note" reporter:datatype="text"/>
                        <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
+                       <field reporter:label="Overlay Match ID" name="internal_id" reporter:datatype="int"/>
                </fields>
                <links>
                        <link field="import_error" reltype="has_a" key="code" map="" class="vie"/>
@@ -261,6 +344,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Private Note" name="priv_note" reporter:datatype="text"/>
                        <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="text"/>
                        <field reporter:label="Copy Number" name="copy_number" reporter:datatype="text"/>
+                       <field reporter:label="Overlay Match ID" name="internal_id" reporter:datatype="text"/>
                </fields>
                <links>
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
@@ -284,11 +368,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Type" name="queue_type" reporter:datatype="text"/>
                        <field reporter:label="Match Set" name="match_set" reporter:datatype="link"/>
                        <field reporter:label="Item Import Attribute Definition" name="item_attr_def" reporter:datatype="link"/>
+                       <field reporter:label="Match Bucket" name="match_bucket" reporter:datatype="link"/>
                </fields>
                <links>
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="item_attr_def" reltype="has_a" key="id" map="" class="viiad"/>
                        <link field="match_set" reltype="has_a" key="id" map="" class="vms"/>
+                       <link field="match_bucket" reltype="has_a" key="id" map="" class="cbreb"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
@@ -518,8 +604,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Quality" name="quality" reporter:datatype="int"/>
                </fields>
                <links>
-                       <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
-                       <link field="eg_record" reltype="has_a" key="id" map="" class="bre"/>
+                       <link field="queued_record" reltype="has_a" key="id" map="" class="vqar"/>
+                       <link field="eg_record" reltype="has_a" key="id" map="" class="are"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
@@ -544,7 +630,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
                                <create permission="ADMIN_IMPORT_MATCH_SET" context_field="owner"/>
-                               <retrieve permission="ADMIN_IMPORT_MATCH_SET" context_field="owner"/>
+                               <retrieve permission="ADMIN_IMPORT_MATCH_SET VIEW_IMPORT_MATCH_SET" context_field="owner"/>
                                <update permission="ADMIN_IMPORT_MATCH_SET" context_field="owner"/>
                                <delete permission="ADMIN_IMPORT_MATCH_SET" context_field="owner"/>
                        </actions>
@@ -575,7 +661,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                                <create permission="ADMIN_IMPORT_MATCH_SET">
                     <context link="match_set" field="owner"/>
                                </create>
-                               <retrieve permission="ADMIN_IMPORT_MATCH_SET">
+                               <retrieve permission="ADMIN_IMPORT_MATCH_SET VIEW_IMPORT_MATCH_SET">
                     <context link="match_set" field="owner"/>
                                </retrieve>
                                <update permission="ADMIN_IMPORT_MATCH_SET">
@@ -698,8 +784,10 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Name" name="name" reporter:datatype="id" reporter:selector="label"  oils_obj:required="true"/>
                        <field reporter:label="Label" name="label" reporter:datatype="text"  oils_obj:required="true"/>
                        <field reporter:label="Description" name="description" reporter:datatype="text" />
+                       <field reporter:label="Multi-valued?" name="multi" reporter:datatype="bool"/>
                        <field reporter:label="Filter?" name="filter" reporter:datatype="bool"/>
                        <field reporter:label="Sorter?" name="sorter" reporter:datatype="bool"/>
+                       <field reporter:label="Composite attribute?" name="composite" reporter:datatype="bool"/>
                        <field reporter:label="MARC Tag" name="tag" reporter:datatype="text"/>
                        <field reporter:label="MARC Subfields" name="sf_list" reporter:datatype="text"/>
                        <field reporter:label="Joiner" name="joiner" reporter:datatype="text"/>
@@ -744,7 +832,92 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
         </permacrud>
        </class>
 
-       <class id="mra" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::record_attr" oils_persist:tablename="metabib.record_attr" reporter:label="SVF Record Attribute" oils_persist:field_safe="true">
+       <class id="ccraed" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::composite_attr_entry_definition" oils_persist:tablename="config.composite_attr_entry_definition" reporter:label="Composite Attribute Definitions" oils_persist:field_safe="true">
+               <fields oils_persist:primary="coded_value">
+                       <field reporter:label="Coded Value" name="coded_value" reporter:datatype="id" oils_obj:required="true"/>
+                       <field reporter:label="Defintion" name="definition" reporter:datatype="text"  oils_obj:required="true"/>
+               </fields>
+               <links>
+                       <link field="coded_value" reltype="has_a" key="id" map="" class="ccvm"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_CODED_VALUE" global_required="true"/>
+                <retrieve/>
+                <update permission="ADMIN_CODED_VALUE" global_required="true"/>
+                <delete permission="ADMIN_CODED_VALUE" global_required="true"/>
+            </actions>
+        </permacrud>
+       </class>
+
+       <class id="murav" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::uncontrolled_record_attr_value" oils_persist:tablename="metabib.uncontrolled_record_attr_value" reporter:label="Uncontrolled Record Attribute Values" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="metabib.uncontrolled_record_attr_value_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id" oils_obj:required="true"/>
+                       <field reporter:label="Attribute" name="attr" reporter:datatype="text"  oils_obj:required="true"/>
+                       <field reporter:label="Value" name="value" reporter:datatype="text"  oils_obj:required="true"/>
+               </fields>
+               <links>
+                       <link field="attr" reltype="has_a" key="name" map="" class="crad"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve/>
+            </actions>
+        </permacrud>
+       </class>
+
+
+       <class id="mrs" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::record_sorter" oils_persist:tablename="metabib.record_sorter" reporter:label="Record Sort Values" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="metabib.record_sorter_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id" oils_obj:required="true"/>
+                       <field reporter:label="Bib Record ID" name="source" reporter:datatype="int" oils_obj:required="true"/>
+                       <field reporter:label="Attribute" name="attr" reporter:datatype="text"  oils_obj:required="true"/>
+                       <field reporter:label="Value" name="value" reporter:datatype="text"  oils_obj:required="true"/>
+               </fields>
+               <links>
+                       <link field="source" reltype="has_a" key="id" map="" class="bre"/>
+                       <link field="attr" reltype="has_a" key="name" map="" class="crad"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve/>
+            </actions>
+        </permacrud>
+       </class>
+
+
+       <class id="mravl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::record_attr_vector_list" oils_persist:tablename="metabib.record_attr_vector_list" reporter:label="MVF Record Attribute Vectors" oils_persist:field_safe="true">
+               <fields oils_persist:primary="source">
+                       <field reporter:label="Record ID" name="source" reporter:datatype="id" oils_obj:required="true"/>
+                       <field reporter:label="Vector" name="vlist" reporter:datatype="text"  oils_obj:required="true"/> <!-- Actually an int[], but this is the best we can do in fm_IDL.xml -->
+               </fields>
+               <links>
+                       <link field="source" reltype="has_a" key="id" map="" class="bre"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve/>
+            </actions>
+        </permacrud>
+       </class>
+
+       <class id="mraf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::record_attr_flat" oils_persist:tablename="metabib.record_attr_flat" reporter:label="MVF Record Attribute Flat List" oils_persist:field_safe="true">
+               <fields>
+                       <field reporter:label="Record ID" name="id" reporter:datatype="id" oils_obj:required="true"/>
+                       <field reporter:label="Attribute" name="attr" reporter:datatype="text"  oils_obj:required="true"/>
+                       <field reporter:label="Value" name="value" reporter:datatype="text"  oils_obj:required="true"/>
+               </fields>
+               <links>
+                       <link field="source" reltype="has_a" key="id" map="" class="bre"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve/>
+            </actions>
+        </permacrud>
+       </class>
+
+       <class id="mra" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::record_attr" oils_persist:tablename="metabib.record_attr" reporter:label="SVF Record Attribute" oils_persist:field_safe="true" oils_persist:readonly="true">
                <fields oils_persist:primary="id">
                        <field reporter:label="Record ID" name="id" reporter:datatype="id" oils_obj:required="true"/>
                        <field reporter:label="Attributes" name="attrs" reporter:datatype="text"  oils_obj:required="true"/>
@@ -783,14 +956,19 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
 
        <class id="ccvm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::coded_value_map" oils_persist:tablename="config.coded_value_map" reporter:label="SVF Record Attribute Coded Value Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="config.coded_value_map_id_seq">
-                       <field reporter:label="ID" name="id" reporter:datatype="id"  oils_obj:required="true"/>
+                       <field reporter:label="ID" name="id" reporter:datatype="id"  oils_obj:required="true" reporter:selector="value"/>
                        <field reporter:label="SVF Attribute" name="ctype" reporter:datatype="link"  oils_obj:required="true"/>
                        <field reporter:label="Code" name="code" reporter:datatype="text"  oils_obj:required="true"/>
-                       <field reporter:label="Value" name="value" reporter:datatype="text"  oils_obj:required="true"/>
-                       <field reporter:label="Description" name="description" reporter:datatype="text"/>
+                       <field reporter:label="Value" name="value" reporter:datatype="text"  oils_obj:required="true" oils_persist:i18n="true"/>
+                       <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
+                       <field reporter:label="Search Label" name="search_label" reporter:datatype="text" oils_persist:i18n="true"/>
+            <field reporter:label="Is Simple Selector" name="is_simple" reporter:datatype="bool"/>
+            <field reporter:label="Composite Definition" name="composite_def" oils_persist:virtual="true" reporter:datatype="link"/>
                </fields>
                <links>
                        <link field="ctype" reltype="has_a" key="name" map="" class="crad"/>
+                       <link field="composite_def" reltype="might_have" key="coded_value" map="" class="ccraed"/>
                </links>
         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
             <actions>
@@ -854,9 +1032,9 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
         </permacrud>
     </class>
 
-    <class id="cza" controller="open-ils.cstore" oils_obj:fieldmapper="config::z3950_attr" oils_persist:tablename="config.z3950_attr" reporter:label="Z39.50 Attribute">
+    <class id="cza" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::z3950_attr" oils_persist:tablename="config.z3950_attr" reporter:label="Z39.50 Attribute">
         <fields oils_persist:primary="id" oils_persist:sequence="config.z3950_attr_id_seq">
-            <field reporter:label="Z39.50 Attribute ID" name="id" reporter:datatype="id"/>
+            <field reporter:label="Z39.50 Attribute ID" name="id" reporter:datatype="id" reporter:selector="label"/>
             <field reporter:label="Z39.50 Source" name="source" reporter:datatype="link"/>
             <field reporter:label="Name" name="name" reporter:datatype="text"/>
             <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
@@ -867,8 +1045,44 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
         <links>
             <link field="source" reltype="has_a" key="name" map="" class="czs"/>
         </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+                <retrieve/>
+                <update permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+                <delete permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+            </actions>
+        </permacrud>
+    </class>
+
+    <class id="czifm" controller="open-ils.cstore open-ils.pcrud" 
+                       oils_obj:fieldmapper="config::z3950_index_field_map" 
+                       oils_persist:tablename="config.z3950_index_field_map" 
+                       reporter:label="Z39.50 Index Field Map">
+        <fields oils_persist:primary="id" oils_persist:sequence="config.z3950_index_field_map_id_seq">
+            <field reporter:label="Map ID" name="id" reporter:datatype="id"/>
+            <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
+            <field reporter:label="Metabib Field" name="metabib_field" reporter:datatype="link"/>
+            <field reporter:label="Record Attribute" name="record_attr" reporter:datatype="link"/>
+            <field reporter:label="Z39.50 Attribute" name="z3950_attr"  reporter:datatype="link"/>
+            <field reporter:label="Z39.50 Attribute Type" name="z3950_attr_type" reporter:datatype="text"/>
+        </fields>
+        <links>
+            <link field="metabib_field" reltype="has_a" key="id" map="" class="cmf"/>
+            <link field="record_attr" reltype="has_a" key="name" map="" class="crad"/>
+            <link field="z3950_attr" reltype="has_a" key="id" map="" class="cza"/>
+        </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+                <retrieve/>
+                <update permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+                <delete permission="ADMIN_Z3950_SOURCE" global_required="true"/>
+            </actions>
+        </permacrud>
     </class>
 
+
        <class id="ateo" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::event_output" oils_persist:tablename="action_trigger.event_output" reporter:label="Event Output">
                <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.event_output_id_seq">
                        <field reporter:label="Output ID" name="id" reporter:datatype="id"/>
@@ -1013,6 +1227,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Granularity" name="granularity"  reporter:datatype="text"/>
                        <field reporter:label="Opt-In User Field" name="usr_field"  reporter:datatype="text"/>
                        <field reporter:label="Opt-In Setting Type" name="opt_in_setting"  reporter:datatype="link"/>
+                       <field reporter:label="Event Repeatability Delay" name="repeat_delay"  reporter:datatype="interval"/>
                        <field reporter:label="Environment Entries" name="env" oils_persist:virtual="true"  reporter:datatype="link"/>
                        <field reporter:label="Parameters" name="params" oils_persist:virtual="true"  reporter:datatype="link"/>
                </fields>
@@ -1090,17 +1305,102 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                </permacrud>
        </class>
 
-       <class id="aws" controller="open-ils.cstore" oils_obj:fieldmapper="actor::workstation" oils_persist:tablename="actor.workstation" reporter:label="Workstation">
+       <class id="atul" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::user_log" reporter:label="Action Trigger User Log" oils_persist:readonly="true">
+               <oils_persist:source_definition><![CDATA[
+               SELECT  atevdef.hook,
+                       atevdef.name,
+                       atevdef.reactor,
+                       atev.id,
+                       atev.event_def,
+                       atev.add_time,
+                       atev.run_time,
+                       atev.start_time,
+                       atev.update_time,
+                       atev.complete_time,
+                       atev.update_process,
+                       atev.state,
+                       atev.user_data,
+                       atev.template_output,
+                       atev.error_output,
+                       atev.async_output,
+                       targ_circ.id AS target_circ,
+                       targ_ahr.id AS target_hold,
+                       COALESCE(
+                               targ_circ.circ_lib,
+                               targ_ahr.pickup_lib
+                       ) AS perm_lib
+               FROM action_trigger.event atev
+               JOIN action_trigger.event_definition atevdef ON
+                       (atevdef.id = atev.event_def)
+               JOIN action_trigger.hook ath ON
+                       (ath.key = atevdef.hook)
+               LEFT JOIN action.circulation targ_circ ON
+                       (ath.core_type = 'circ' AND targ_circ.id = atev.target)
+               LEFT JOIN action.hold_request targ_ahr ON
+                       (ath.core_type = 'ahr' AND targ_ahr.id = atev.target)
+               WHERE atev.add_time > NOW() - (SELECT MAX(value) FROM (
+                       SELECT value::INTERVAL FROM actor.org_unit_ancestor_setting(
+                               'circ.staff.max_visible_event_age',
+                               COALESCE(targ_circ.circ_lib, targ_ahr.pickup_lib)
+                       ) UNION
+                       SELECT '1000 YEARS'::INTERVAL AS value
+               ) ous)
+               ]]></oils_persist:source_definition>
+               <fields oils_persist:primary="id">
+                       <field reporter:label="Hook" name="hook" reporter:datatype="link" />
+                       <field reporter:label="Name" name="name" reporter:datatype="text" />
+                       <field reporter:label="Reactor" name="reactor" reporter:datatype="text" />
+                       <field reporter:label="Event ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="Event Definition ID" name="event_def" reporter:datatype="int" />
+                       <field reporter:label="Event Add Time" name="add_time" reporter:datatype="timestamp" />
+                       <field reporter:label="Event Run Time" name="run_time" reporter:datatype="timestamp" />
+                       <field reporter:label="Event Start Time" name="start_time" reporter:datatype="timestamp" />
+                       <field reporter:label="Event Update Time" name="update_time" reporter:datatype="timestamp" />
+                       <field reporter:label="Event Complete Time" name="complete_time" reporter:datatype="timestamp" />
+                       <field reporter:label="Event Update PID" name="update_process" reporter:datatype="int" />
+                       <field reporter:label="Event State" name="state" reporter:datatype="text" />
+                       <field reporter:label="Event User Data" name="user_data" reporter:datatype="text" />
+                       <field reporter:label="Event Template Output" name="template_output" reporter:datatype="link" />
+                       <field reporter:label="Event Error Output" name="error_output" reporter:datatype="link" />
+                       <field reporter:label="Event Async Output" name="async_output" reporter:datatype="link" />
+                       <field reporter:label="Target Circulation" name="target_circ" reporter:datatype="link" />
+                       <field reporter:label="Target Hold" name="target_hold" reporter:datatype="link" />
+                       <field reporter:label="Permission Context" name="perm_lib" reporter:datatype="org_unit" />
+               </fields>
+               <links>
+                       <link field="hook" reltype="has_a" key="key" map="" class="ath" />
+                       <link field="template_output" reltype="has_a" key="id" map="" class="ateo" />
+                       <link field="error_output" reltype="has_a" key="id" map="" class="ateo" />
+                       <link field="async_output" reltype="has_a" key="id" map="" class="ateo" />
+                       <link field="target_circ" reltype="has_a" key="id" map="" class="circ" />
+                       <link field="target_hold" reltype="has_a" key="id" map="" class="ahr" />
+                       <link field="perm_lib" reltype="has_a" key="id" map="" class="aou" />
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_TRIGGER_EVENT" context_field="perm_lib" />
+                       </actions>
+               </permacrud>
+       </class>
+
+       <class id="aws" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::workstation" oils_persist:tablename="actor.workstation" reporter:label="Workstation">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.workstation_id_seq">
                        <field reporter:label="Workstation ID" name="id" reporter:datatype="id"/>
                        <field reporter:label="Workstation Name" name="name" reporter:datatype="text"/>
                        <field reporter:label="Owning Library" name="owning_lib"  reporter:datatype="org_unit"/>
+                       <field reporter:label="Toolbars" name="toolbars" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Circulations" name="circulations" oils_persist:virtual="true" reporter:datatype="link"/>
                </fields>
                <links>
                        <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="toolbars" reltype="has_many" key="ws" map="" class="atb"/>
                        <link field="circulations" reltype="has_many" key="workstation" map="" class="circ"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="STAFF_LOGIN" context_field="owning_lib" />
+                       </actions>
+               </permacrud>
        </class>
 
        <class id="ccm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_modifier" oils_persist:tablename="config.circ_modifier" reporter:label="Circulation Modifier">
@@ -1294,7 +1594,9 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Circulation Modifier" name="circ_modifier" oils_persist:primitive="string" reporter:datatype="float"/>
             <field reporter:label="MARC Type" name="marc_type" oils_persist:primitive="string" reporter:datatype="float"/>
             <field reporter:label="MARC Form" name="marc_form" oils_persist:primitive="string" reporter:datatype="float"/>
+            <field reporter:label="MARC Bib Level" name="marc_bib_level" oils_persist:primitive="string" reporter:datatype="float"/>
             <field reporter:label="Videorecording Format" name="marc_vr_format" oils_persist:primitive="string" reporter:datatype="float"/>
+            <field reporter:label="Juvenile?" name="juvenile_flag" oils_persist:primitive="string" reporter:datatype="float"/>
             <field reporter:label="Reference?" name="ref_flag" reporter:datatype="float"/>
             <field reporter:label="Item Age &lt;" name="item_age" reporter:datatype="float"/>
         </fields>
@@ -1313,16 +1615,20 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
         <fields oils_persist:primary="id" oils_persist:sequence="config.circ_matrix_weights_id_seq">
             <field reporter:label="Circ Weights ID" name="id" reporter:datatype="id" reporter:selector="name"/>
             <field reporter:label="Name" name="name" reporter:datatype="text"/>
+            <field reporter:label="Renewal?" name="is_renewal" reporter:datatype="float"/>
             <field reporter:label="Org Unit" name="org_unit" reporter:datatype="float"/>
             <field reporter:label="Copy Circ Lib" name="copy_circ_lib" reporter:datatype="float"/>
             <field reporter:label="Copy Owning Lib" name="copy_owning_lib" reporter:datatype="float"/>
             <field reporter:label="User Home Lib" name="user_home_ou" reporter:datatype="float"/>
             <field reporter:label="Permission Group" name="grp" reporter:datatype="float"/>
             <field reporter:label="Circulation Modifier" name="circ_modifier" reporter:datatype="float"/>
+            <field reporter:label="Copy Location" name="copy_location" reporter:datatype="float"/>
             <field reporter:label="MARC Type" name="marc_type" reporter:datatype="float"/>
             <field reporter:label="MARC Form" name="marc_form" reporter:datatype="float"/>
+            <field reporter:label="MARC Bib Level" name="marc_bib_level" reporter:datatype="float"/>
             <field reporter:label="Videorecording Format" name="marc_vr_format" reporter:datatype="float"/>
             <field reporter:label="Reference?" name="ref_flag" reporter:datatype="float"/>
+            <field reporter:label="Juvenile?" name="juvenile_flag" reporter:datatype="float"/>
             <field reporter:label="User Age: Lower Bound" name="usr_age_lower_bound" reporter:datatype="float"/>
             <field reporter:label="User Age: Upper Bound" name="usr_age_upper_bound" reporter:datatype="float"/>
             <field reporter:label="Item Age &lt;" name="item_age" reporter:datatype="float"/>
@@ -1424,6 +1730,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="User Home Lib" name="user_home_ou" reporter:datatype="org_unit"/>
                        <field reporter:label="Permission Group" name="grp" reporter:datatype="link" oils_obj:required="true"/>
                        <field reporter:label="Circulation Modifier" name="circ_modifier" oils_persist:primitive="string" reporter:datatype="link"/>
+                       <field reporter:label="Copy Location" name="copy_location" reporter:datatype="link"/>
                        <field reporter:label="MARC Type" name="marc_type" oils_persist:primitive="string" reporter:datatype="link"/>
                        <field reporter:label="MARC Form" name="marc_form" oils_persist:primitive="string" reporter:datatype="link"/>
                        <field reporter:label="MARC Bib Level" name="marc_bib_level" oils_persist:primitive="string" reporter:datatype="link"/>
@@ -1451,6 +1758,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="user_home_ou" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
                        <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
+                       <link field="copy_location" reltype="has_a" key="id" map="" class="acpl"/>
                        <link field="marc_type" reltype="has_a" key="code" map="" class="citm"/>
                        <link field="marc_form" reltype="has_a" key="code" map="" class="cifm"/>
                        <link field="marc_bib_level" reltype="has_a" key="code" map="" class="cblvl"/>
@@ -1563,6 +1871,31 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             </actions>
         </permacrud>
     </class>
+    <class id="cclsacpl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_limit_set_copy_loc_map" oils_persist:tablename="config.circ_limit_set_copy_loc_map" reporter:label="Circulation Limit Set Copy Location Map">
+        <fields oils_persist:primary="id" oils_persist:sequence="config.circ_limit_set_copy_loc_map_id_seq">
+            <field reporter:label="ID" name="id" reporter:datatype="id"/>
+            <field reporter:label="Limit Set" name="limit_set" reporter:datatype="link"/>
+            <field reporter:label="Copy Location" name="copy_loc" reporter:datatype="link"/>
+        </fields>
+        <links>
+            <link field="limit_set" reltype="has_a" key="id" map="" class="ccls"/>
+            <link field="copy_loc" reltype="has_a" key="id" map="" class="acpl"/>
+        </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
+                    <context link="limit_set" field="owning_lib"/>
+                </create>
+                <retrieve/>
+                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
+                    <context link="limit_set" field="owning_lib"/>
+                </update>
+                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
+                    <context link="limit_set" field="owning_lib"/>
+                </delete>
+            </actions>
+        </permacrud>
+    </class>
 
     <class id="cclsgm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_limit_set_group_map" oils_persist:tablename="config.circ_limit_set_group_map" reporter:label="Circulation Limit Set Group Map">
         <fields oils_persist:primary="id" oils_persist:sequence="config.circ_limit_set_group_map_id_seq">
@@ -1635,7 +1968,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             </actions>
         </permacrud>
        </class>
-       <class id="mbts" controller="open-ils.cstore" oils_obj:fieldmapper="money::billable_transaction_summary" oils_persist:tablename="money.materialized_billable_xact_summary" reporter:label="Billable Transaction Summary" oils_persist:readonly="true">
+       <class id="mbts" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::billable_transaction_summary" oils_persist:tablename="money.materialized_billable_xact_summary" reporter:label="Billable Transaction Summary" oils_persist:readonly="true">
                <fields oils_persist:primary="id" oils_persist:sequence="">
                        <field reporter:label="Balance Owed" name="balance_owed" reporter:datatype="money"/>
                        <field reporter:label="Transaction ID" name="id" reporter:datatype="id"/>
@@ -1655,6 +1988,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="usr" reltype="has_a" key="id" map="" class="au"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_USER_TRANSACTIONS">
+                                       <context link="usr" field="home_ou" />
+                               </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="mbtslv" controller="open-ils.cstore" oils_obj:fieldmapper="money::billable_transaction_summary_location_view" oils_persist:tablename="money.billable_xact_summary_location_view" reporter:label="Billable Transaction Summary with Billing Location" oils_persist:readonly="true" reporter:core="true">
                <fields oils_persist:primary="id" oils_persist:sequence="">
@@ -1679,7 +2019,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
                </links>
        </class>
-       <class id="aun" controller="open-ils.cstore" oils_obj:fieldmapper="actor::usr_note" oils_persist:tablename="actor.usr_note" reporter:label="User Note">
+       <class id="aun" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::usr_note" oils_persist:tablename="actor.usr_note" reporter:label="User Note">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_note_id_seq">
                        <field reporter:label="Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
                        <field reporter:label="Creating Staff" name="creator" reporter:datatype="link"/>
@@ -1693,6 +2033,23 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="usr" reltype="has_a" key="id" map="" class="au"/>
                        <link field="creator" reltype="has_a" key="id" map="" class="au"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="UPDATE_USER" context_field="owner">
+                    <context link="usr" field="home_ou"/>
+                </create>
+                               <!-- note: public notes are still accessible via API -->
+                <retrieve permission="UPDATE_USER">
+                    <context link="usr" field="home_ou"/>
+                               </retrieve>
+                <update permission="UPDATE_USER">
+                    <context link="usr" field="home_ou"/>
+                               </update>
+                <delete permission="UPDATE_USER">
+                    <context link="usr" field="home_ou"/>
+                               </delete>
+            </actions>
+        </permacrud>
        </class>
        <class id="aupr" controller="open-ils.cstore" oils_obj:fieldmapper="actor::usr_password_reset" oils_persist:tablename="actor.usr_password_reset" reporter:label="User password reset requests">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_password_reset_id_seq">
@@ -1878,13 +2235,16 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Control Set" name="control_set" reporter:datatype="link"/>
                        <field reporter:label="Tag" name="tag" reporter:datatype="text" oils_obj:required="true" oils_obj:validate="^.{3}$"/>
                        <field reporter:label="Subfield List" name="sf_list" reporter:datatype="text" />
+                       <field reporter:label="Subfield List for Display" name="display_sf_list" reporter:datatype="text" />
                        <field reporter:label="Non-filing Indicator" name="nfi" reporter:datatype="text" />
                        <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true" oils_obj:required="true" />
                        <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
+                       <field reporter:label="Linking Subfield" name="linking_subfield" reporter:datatype="text" />
                        <field reporter:label="Subordinate Entries" name="sub_entries" reporter:datatype="link" oils_persist:virtual="true"/>
                        <field reporter:label="Controlled Bib Fields" name="bib_fields" reporter:datatype="link" oils_persist:virtual="true"/>
                        <field reporter:label="Thesauri" name="thesauri" reporter:datatype="link" oils_persist:virtual="true"/>
                        <field reporter:label="Browse Axis Maps" name="axis_maps" reporter:datatype="link" oils_persist:virtual="true"/>
+                       <field reporter:label="Joiner" name="joiner" reporter:datatype="text" />
                </fields>
                <links>
                        <link field="axis_maps" reltype="has_many" key="field" map="" class="abaafm"/>
@@ -1923,6 +2283,26 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                </permacrud>
        </class>
 
+       <class id="acsbfmfm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::control_set_bib_field_metabib_field_map" oils_persist:tablename="authority.control_set_bib_field_metabib_field_map" reporter:label="Authority Control Set Bib Field to Metabib Field Map" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="authority.control_set_bib_field_metabib_field_map_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id" reporter:selector="name"/>
+                       <field reporter:label="Bib Field" name="bib_field" reporter:datatype="link"/>
+                       <field reporter:label="Metabib Field" name="metabib_field" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="bib_field" reltype="has_a" key="id" map="" class="acsbf"/>
+                       <link field="metabib_field" reltype="has_a" key="id" map="" class="cmf"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="CREATE_AUTHORITY_CONTROL_SET" global_required="true"/>
+                               <retrieve/>
+                               <update permission="UPDATE_AUTHORITY_CONTROL_SET" global_required="true"/>
+                               <delete permission="UPDATE_AUTHORITY_CONTROL_SET" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
+
        <class id="at" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::thesaurus" oils_persist:tablename="authority.thesaurus" reporter:label="Authority Thesaurus" oils_persist:field_safe="true">
                <fields oils_persist:primary="code">
                        <field reporter:label="Thesaurus Code" name="code" reporter:datatype="id" reporter:selector="name"/>
@@ -2001,6 +2381,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="source" />
                        <field reporter:label="Control Set" name="control_set" reporter:datatype="link"/>
                        <field reporter:label="Owner" name="owner"  reporter:datatype="org_unit"/>
+                       <field name="heading" />
+                       <field name="simple_heading" />
                        <field name="fixed_fields" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field name="bib_links" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -2047,6 +2429,18 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="authority" reltype="has_a" key="id" map="" class="are"/>
                </links>
        </class>
+       <class id="ash" controller="open-ils.cstore" oils_obj:fieldmapper="authority::simple_heading" oils_persist:tablename="authority.simple_heading" reporter:label="Authority Simple Heading">
+               <fields oils_persist:primary="id" oils_persist:sequence="authority.simple_heading_id_seq">
+                       <field name="id" reporter:datatype="id" />
+                       <field name="record" reporter:datatype="link" />
+                       <field name="atag" reporter:datatype="link" />
+                       <field name="value" reporter:datatype="text" />
+               </fields>
+               <links>
+                       <link field="record" reltype="has_a" key="id" map="" class="are"/>
+                       <link field="atag" reltype="has_a" key="id" map="" class="acsaf"/>
+               </links>
+       </class>
        <class id="clm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::language_map" oils_persist:tablename="config.language_map" reporter:label="Language Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="code" oils_persist:sequence="">
                        <field reporter:label="Language Code" name="code" reporter:selector="value" reporter:datatype="text"/>
@@ -2062,7 +2456,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             </actions>
         </permacrud>
        </class>
-       <class id="mccp" controller="open-ils.cstore" oils_obj:fieldmapper="money::credit_card_payment" oils_persist:tablename="money.credit_card_payment" reporter:label="Credit Card Payment">
+       <class id="mccp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::credit_card_payment" oils_persist:tablename="money.credit_card_payment" reporter:label="Credit Card Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field name="accepting_usr" />
                        <field name="amount" reporter:datatype="money" />
@@ -2090,6 +2484,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="cxt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::xml_transform" oils_persist:tablename="config.xml_transform" reporter:label="XML/XSLT Transform Definition">
                <fields oils_persist:primary="name">
@@ -2135,6 +2536,11 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field reporter:label="Buoyant?" name="buoyant" reporter:datatype="bool" />
                        <field reporter:label="Restrict?" name="restrict" reporter:datatype="bool" />
+                       <field reporter:label="Combined?" name="combined" reporter:datatype="bool" />
+                       <field reporter:label="A Weight" name="a_weight" reporter:datatype="float" />
+                       <field reporter:label="B Weight" name="b_weight" reporter:datatype="float" />
+                       <field reporter:label="C Weight" name="c_weight" reporter:datatype="float" />
+                       <field reporter:label="D Weight" name="d_weight" reporter:datatype="float" />
                        <field reporter:label="Fields" name="fields" reporter:datatype="link" oils_persist:virtual="true"/>
                </fields>
                <links>
@@ -2153,7 +2559,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
        <class id="cmf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_field" oils_persist:tablename="config.metabib_field" reporter:label="Metabib Field" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="config.metabib_field_id_seq">
                        <field reporter:label="Class" name="field_class" reporter:datatype="link"/>
-                       <field reporter:label="ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="ID" name="id" reporter:datatype="id" reporter:selector="label"/>
                        <field reporter:label="Name" name="name" reporter:datatype="text"/>
                        <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field reporter:label="XPath" name="xpath" reporter:datatype="text"/>
@@ -2178,6 +2584,32 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             </actions>
         </permacrud>
        </class>
+       <class id="cbho" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::best_hold_order" oils_persist:tablename="config.best_hold_order" reporter:label="Best-Hold Sort Order">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.best_hold_order_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id" reporter:selector="name" />
+                       <field reporter:label="Name" name="name" reporter:datatype="text"/>
+                       <field reporter:label="Capture Lib to Pickup Lib Proximity" name="pprox" reporter:datatype="int" />
+                       <field reporter:label="Circ Lib to Request Lib Proximity" name="hprox" reporter:datatype="int" />
+                       <field reporter:label="Adjusted Circ Lib to Pickup Lib Proximity" name="aprox" reporter:datatype="int" />
+                       <field reporter:label="Adjusted Capture Location to Pickup Lib Proximity" name="approx" reporter:datatype="int" />
+                       <field reporter:label="Hold Priority" name="priority" reporter:datatype="int" />
+                       <field reporter:label="Hold Cut-in-line State" name="cut" reporter:datatype="int" />
+                       <field reporter:label="Hold Selection Depth" name="depth" reporter:datatype="int" />
+                       <field reporter:label="Copy Has Circulated From Home Lately" name="htime" reporter:datatype="int" />
+                       <field reporter:label="Hold Request Time" name="rtime" reporter:datatype="int" />
+                       <field reporter:label="Copy Has Been Home At All Lately" name="shtime" reporter:datatype="int" />
+               </fields>
+               <links>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_HOLD_CAPTURE_SORT" global_required="true"/>
+                               <retrieve permission="ADMIN_HOLD_CAPTURE_SORT" global_required="true"/>
+                               <update permission="ADMIN_HOLD_CAPTURE_SORT" global_required="true"/>
+                               <delete permission="ADMIN_HOLD_CAPTURE_SORT" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
        <class id="cbfp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::biblio_fingerprint" oils_persist:tablename="config.biblio_fingerprint" reporter:label="Fingerprint Definition">
                <fields oils_persist:primary="id" oils_persist:sequence="config.biblio_fingerprint_id_seq">
                        <field name="id" reporter:datatype="id" />
@@ -2293,7 +2725,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="URI Maps" name="uri_maps" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="URIs" name="uris" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Sort Key" name="label_sortkey" reporter:datatype="text"/>
+                       <field reporter:label="Call Number Sort Key" name="label_sortkey" reporter:datatype="text"/>
                        <field reporter:label="Classification Scheme" name="label_class" reporter:datatype="link"/>
                        <field reporter:label="Prefix" name="prefix" reporter:datatype="link"/>
                        <field reporter:label="Suffix" name="suffix" reporter:datatype="link"/>
@@ -2454,6 +2886,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                 <create permission="CREATE_MARC IMPORT_MARC" global_required="true"/>
                 <retrieve/>
                 <update permission="UPDATE_MARC" global_required="true"/>
+               <!-- WARNING: Deleting records via PCRUD does NOT check that any prerequisite conditions have been handled first. It is your responsibility to check for those conditions before deleting bib records. -->
+                <delete permission="DELETE_RECORD" global_required="true"/>
             </actions>
         </permacrud>
        </class>
@@ -2608,7 +3042,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                </permacrud>
        </class>
 
-       <class id="mobts" controller="open-ils.cstore" oils_obj:fieldmapper="money::open_billable_transaction_summary" oils_persist:tablename="money.open_billable_xact_summary" reporter:label="Open Billable Transaction Summary">
+       <class id="mobts" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::open_billable_transaction_summary" oils_persist:tablename="money.open_billable_xact_summary" reporter:label="Open Billable Transaction Summary">
                <fields oils_persist:primary="id" oils_persist:sequence="">
                        <field name="balance_owed" reporter:datatype="money"/>
                        <field name="id" reporter:datatype="id" />
@@ -2638,8 +3072,15 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="reservation" reltype="might_have" key="id" map="" class="bresv"/>
                        <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_USER_TRANSACTIONS">
+                                       <context link="usr" field="home_ou" />
+                               </retrieve>
+                       </actions>
+               </permacrud>
        </class>
-       <class id="au" controller="open-ils.cstore" oils_obj:fieldmapper="actor::user" oils_persist:tablename="actor.usr" reporter:core="true" reporter:label="ILS User">
+       <class id="au" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::user" oils_persist:tablename="actor.usr" reporter:core="true" reporter:label="ILS User">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_id_seq">
                        <field reporter:label="All Addresses" name="addresses" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="All Library Cards" name="cards" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -2679,13 +3120,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Is Group Lead Account" name="master_account" reporter:datatype="bool"/>
                        <field reporter:label="Internet Access Level" name="net_access_level" reporter:datatype="link"/>
                        <field reporter:label="Other Phone" name="other_phone"  reporter:datatype="text"/>
-                       <field reporter:label="Password" name="passwd"  reporter:datatype="text"/>
+                       <field reporter:label="Password" name="passwd" suppress_controller="open-ils.pcrud open-ils.reporter-store" reporter:datatype="text"/>
                        <field reporter:label="Photo URL" name="photo_url"  reporter:datatype="text"/>
-                       <field reporter:label="Prefix" name="prefix"  reporter:datatype="text"/>
+                       <field reporter:label="Prefix/Title" name="prefix"  reporter:datatype="text"/>
                        <field reporter:label="Main (Profile) Permission Group" name="profile" reporter:datatype="link"/>
                        <field reporter:label="Middle Name" name="second_given_name"  reporter:datatype="text"/>
                        <field reporter:label="Standing (unused)" name="standing" reporter:datatype="link"/>
-                       <field reporter:label="Suffix/Title" name="suffix"  reporter:datatype="text"/>
+                       <field reporter:label="Suffix" name="suffix"  reporter:datatype="text"/>
                        <field reporter:label="Is Super User" name="super_user" reporter:datatype="bool"/>
                        <field reporter:label="Family Linkage or other Group" name="usrgroup" reporter:datatype="int"/>
                        <field reporter:label="OPAC/Staff Client User Name" name="usrname"  reporter:datatype="text"/>
@@ -2720,7 +3161,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="groups" reltype="has_many" key="usr" map="grp" class="pugm"/>
                        <link field="usrgroup" reltype="has_many" key="usrgroup" map="" class="au"/>
                        <link field="checkouts" reltype="has_many" key="usr" map="" class="circ"/>
-                       <link field="hold_requests" reltype="has_many" key="usr" map="" class="circ"/>
+                       <link field="hold_requests" reltype="has_many" key="usr" map="" class="ahr"/>
                        <link field="permissions" reltype="has_many" key="usr" map="perm" class="pupm"/>
                        <link field="settings" reltype="has_many" key="usr" map="" class="aus"/>
                        <link field="billable_transactions" reltype="has_many" key="usr" map="" class="mbt"/>
@@ -2737,6 +3178,11 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="reservations" reltype="has_many" key="usr" map="" class="bresv"/>
                        <link field="usr_activity" reltype="has_many" key="usr" map="" class="auact"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_USER" context_field="home_ou" />
+                       </actions>
+               </permacrud>
        </class>
        <class id="cuat" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::usr_activity_type" oils_persist:tablename="config.usr_activity_type" reporter:label="User Activity Type">
                <fields oils_persist:primary="id" oils_persist:sequence="config.usr_activity_type_id_seq">
@@ -2777,6 +3223,41 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        </actions>
                </permacrud>
        </class>
+       <class id="atb" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::toolbar" oils_persist:tablename="actor.toolbar" reporter:label="Custom Toolbar">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.toolbar_id_seq">
+                       <field name="id" reporter:label="ID" reporter:datatype="id" />
+                       <field name="usr" reporter:label="Owning User" reporter:datatype="link" />
+                       <field name="org" reporter:label="Owning Org Unit" reporter:datatype="link" />
+                       <field name="ws" reporter:label="Owning Workstation" reporter:datatype="link" />
+                       <field name="label" reporter:label="Label" reporter:datatype="text" oils_persist:i18n="true" />
+                       <field name="layout" reporter:label="Layout" reporter:datatype="text" />
+        </fields>
+        <links>
+                       <link field="usr" reltype="might_have" key="id" map="" class="au"/>
+                       <link field="org" reltype="might_have" key="id" map="" class="aou"/>
+                       <link field="ws" reltype="might_have" key="id" map="" class="aws"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="ADMIN_TOOLBAR STAFF_LOGIN" context_field="org">
+                                       <context link="usr" field="home_ou" />
+                                       <context link="ws" field="owning_lib" />
+                               </retrieve>
+                               <create permission="ADMIN_TOOLBAR" context_field="org">
+                                       <context link="usr" field="home_ou" />
+                                       <context link="ws" field="owning_lib" />
+                               </create>
+                               <update permission="ADMIN_TOOLBAR" context_field="org">
+                                       <context link="usr" field="home_ou" />
+                                       <context link="ws" field="owning_lib" />
+                               </update>
+                               <delete permission="ADMIN_TOOLBAR" context_field="org">
+                                       <context link="usr" field="home_ou" />
+                                       <context link="ws" field="owning_lib" />
+                               </delete>
+                       </actions>
+               </permacrud>
+       </class>
        <class id="csg" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::settings_group" oils_persist:tablename="config.settings_group" reporter:label="Settings Group">
                <fields oils_persist:primary="name">
                        <field name="name" reporter:datatype="text"/>
@@ -2795,12 +3276,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
        <class id="cust" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::usr_setting_type" oils_persist:tablename="config.usr_setting_type" reporter:label="User Setting Type">
                <fields oils_persist:primary="name">
                        <field name="name" reporter:label="Name" reporter:datatype="text"/>
-                       <field name="label" reporter:label="Label" reporter:datatype="text"/>
-                       <field name="description" reporter:label="Description" reporter:datatype="text"/>
+                       <field name="label" reporter:label="Label" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field name="description" reporter:label="Description" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field name="datatype" reporter:label="Datatype" reporter:datatype="text"/>
-                       <field name="fm_class" reporter:label="Fielmapper Class" reporter:datatype="text"/>
+                       <field name="fm_class" reporter:label="Fieldmapper Class" reporter:datatype="text"/>
                        <field name="grp" reporter:label="Settings Group" reporter:datatype="link"/>
                        <field name="opac_visible" reporter:label="OPAC/Patron Visible" reporter:datatype="bool"/>
+                       <field name="reg_default" reporter:label="Registration Default" reporter:datatype="text"/>
                </fields>
                <links>
                        <link field="name" reltype="has_many" key="name" map="" class="aus"/>
@@ -2818,8 +3300,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
        <class id="coust" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::org_unit_setting_type" oils_persist:tablename="config.org_unit_setting_type" reporter:label="Organizational Unit Setting Type">
                <fields oils_persist:primary="name">
                        <field name="name" reporter:datatype="text"/>
-                       <field name="label" reporter:datatype="text"/>
-                       <field name="description" reporter:datatype="text"/>
+                       <field name="label" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field name="datatype" reporter:datatype="text"/>
                        <field name="view_perm" reporter:datatype="link"/>
                        <field name="update_perm" reporter:datatype="link"/>
@@ -2914,7 +3396,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
        <class id="cnal" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::net_access_level" oils_persist:tablename="config.net_access_level" reporter:label="Net Access Level">
                <fields oils_persist:primary="id" oils_persist:sequence="config.net_access_level_id_seq">
                        <field name="id" reporter:selector="name" reporter:datatype="id"/>
-                       <field name="name"  reporter:datatype="text"/>
+                       <field name="name"  reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
@@ -2988,9 +3470,20 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="source" reltype="has_a" key="id" map="" class="bre"/>
                </links>
        </class>
-       <class id="mfe" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::field_entry" reporter:label="Combined Field Entry View" oils_persist:readonly="true">
-               <oils_persist:source_definition>
-                       SELECT * FROM metabib.author_field_entry
+       <class id="mbeshm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::browse_entry_simple_heading_map" oils_persist:tablename="metabib.browse_entry_simple_heading_map" reporter:label="Combined Browse Entry Simple Authority Heading Map" oils_persist:readonly="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="metabib.browse_entry_simple_heading_map_id_seq">
+                       <field name="id" reporter:datatype="id" />
+                       <field name="entry" reporter:datatype="link"/>
+                       <field name="simple_heading" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="entry" reltype="has_a" key="id" map="" class="mbe"/>
+                       <link field="simple_heading" reltype="has_a" key="id" map="" class="ash"/>
+               </links>
+       </class>
+       <class id="mfe" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="metabib::field_entry" reporter:label="Combined Field Entry View" oils_persist:readonly="true">
+               <oils_persist:source_definition>
+                       SELECT * FROM metabib.author_field_entry
                                                UNION ALL
                        SELECT * FROM metabib.keyword_field_entry
                                                UNION ALL
@@ -3025,7 +3518,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
                </links>
        </class>
-       <class id="mcp" controller="open-ils.cstore" oils_obj:fieldmapper="money::cash_payment" oils_persist:tablename="money.cash_payment" reporter:label="Cash Payment">
+       <class id="mcp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::cash_payment" oils_persist:tablename="money.cash_payment" reporter:label="Cash Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field name="accepting_usr" reporter:datatype="link"/>
                        <field name="amount" reporter:datatype="money" />
@@ -3044,8 +3537,15 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
-       <class id="mfp" controller="open-ils.cstore" oils_obj:fieldmapper="money::forgive_payment" oils_persist:tablename="money.forgive_payment" reporter:label="Forgive Payment">
+       <class id="mfp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::forgive_payment" oils_persist:tablename="money.forgive_payment" reporter:label="Forgive Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field name="accepting_usr" reporter:datatype="link"/>
                        <field name="amount" reporter:datatype="money" />
@@ -3062,6 +3562,13 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="mrd" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::record_descriptor" oils_persist:tablename="metabib.rec_descriptor" reporter:label="Basic Record Descriptor">
                <fields oils_persist:primary="id" oils_persist:sequence="metabib.rec_descriptor_id_seq">
@@ -3324,8 +3831,8 @@ SELECT  usr,
         ) AS overdue,
 
         SUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'LOST') THEN 1 ELSE 0 END) AS lost,
-        SUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'CLAIMSRETURNED') THEN 1 ELSE 0 END) AS claims_returned,
-        SUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'LONGOVERDUE') THEN 1 ELSE 0 END) AS long_overdue
+        SUM( CASE WHEN stop_fines = 'CLAIMSRETURNED' THEN 1 ELSE 0 END) AS claims_returned,
+        SUM( CASE WHEN stop_fines = 'LONGOVERDUE' THEN 1 ELSE 0 END) AS long_overdue
   FROM  action.circulation
   WHERE checkin_time IS NULL
   GROUP BY 1
@@ -3345,29 +3852,29 @@ SELECT  usr,
        <class id="ocirclist" controller="open-ils.cstore" oils_obj:fieldmapper="action::open_circ_list" reporter:label="Open Circulation List" oils_persist:readonly="true">
         <oils_persist:source_definition>
 SELECT  usr,
-        ARRAY_TO_STRING(ARRAY_ACCUM(
+        STRING_AGG(
             CASE
                 WHEN (
                     ((fine_interval >= '1 day' AND due_date >= 'today') OR (fine_interval &lt; '1 day'  AND due_date > 'now'))
                     AND (stop_fines IS NULL OR stop_fines NOT IN ('LOST','CLAIMSRETURNED','LONGOVERDUE'))
-                ) THEN id
-                ELSE 0
+                ) THEN id::TEXT
+                ELSE '0'
             END
-        ),',') AS out,
+        ,',') AS out,
 
-        ARRAY_TO_STRING(ARRAY_ACCUM(
+        STRING_AGG(
             CASE
                 WHEN (
                     ((fine_interval >= '1 day' AND due_date &lt; 'today') OR (fine_interval &lt; '1 day'  AND due_date &lt; 'now'))
                     AND (stop_fines IS NULL OR stop_fines NOT IN ('LOST','CLAIMSRETURNED','LONGOVERDUE'))
-                ) THEN id
-                ELSE 0
+                ) THEN id::TEXT
+                ELSE '0'
             END
-        ),',') AS overdue,
+        ,',') AS overdue,
 
-        ARRAY_TO_STRING(ARRAY_ACCUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'LOST') THEN id ELSE 0 END),',') AS lost,
-        ARRAY_TO_STRING(ARRAY_ACCUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'CLAIMSRETURNED') THEN id ELSE 0 END),',') AS claims_returned,
-        ARRAY_TO_STRING(ARRAY_ACCUM( CASE WHEN (xact_finish IS NULL AND stop_fines = 'LONGOVERDUE') THEN id ELSE 0 END),',') AS long_overdue
+        STRING_AGG( CASE WHEN (xact_finish IS NULL AND stop_fines = 'LOST') THEN id::TEXT ELSE '0' END,',') AS lost,
+        STRING_AGG( CASE WHEN stop_fines = 'CLAIMSRETURNED' THEN id::TEXT ELSE '0' END,',') AS claims_returned,
+        STRING_AGG( CASE WHEN stop_fines = 'LONGOVERDUE' THEN id::TEXT ELSE '0' END,',') AS long_overdue
   FROM  action.circulation
   WHERE checkin_time IS NULL
   GROUP BY 1
@@ -3384,7 +3891,7 @@ SELECT  usr,
             <link field="usr" reltype="has_a" key="id" map="" class="au"/>
         </links>
        </class>
-       <class id="circ" controller="open-ils.cstore" oils_obj:fieldmapper="action::circulation" oils_persist:tablename="action.circulation" reporter:core="true" reporter:label="Circulation">
+       <class id="circ" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::circulation" oils_persist:tablename="action.circulation" reporter:core="true" reporter:label="Circulation">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
                        <field reporter:label="Check In Library" name="checkin_lib" reporter:datatype="org_unit"/>
                        <field reporter:label="Check In Staff" name="checkin_staff" reporter:datatype="link"/>
@@ -3451,6 +3958,11 @@ SELECT  usr,
                        <link field="aaactsc_entries" reltype="has_many" key="xact" map="" class="aaactsc"/>
                        <link field="aaasc_entries" reltype="has_many" key="xact" map="" class="aaasc"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_CIRCULATIONS" context_field="circ_lib" />
+                       </actions>
+               </permacrud>
        </class>
        <class id="combcirc" controller="open-ils.cstore" oils_obj:fieldmapper="action::all_circulation" oils_persist:tablename="action.all_circulation" reporter:core="true" reporter:label="Combined Aged and Active Circulations" oils_persist:readonly="true">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
@@ -3878,13 +4390,14 @@ SELECT  usr,
                        <field name="hold" reporter:datatype="link"/>
                        <field name="id" reporter:datatype="id" />
                        <field name="target_copy" reporter:datatype="link"/>
+                       <field name="proximity" reporter:datatype="number"/>
                </fields>
                <links>
                        <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
                        <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
                </links>
        </class>
-       <class id="ahn" controller="open-ils.cstore" oils_obj:fieldmapper="action::hold_notification" oils_persist:tablename="action.hold_notification" reporter:label="Hold Notification">
+       <class id="ahn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::hold_notification" oils_persist:tablename="action.hold_notification" reporter:label="Hold Notification">
                <fields oils_persist:primary="id" oils_persist:sequence="action.hold_notification_id_seq">
                        <field reporter:label="Hold" name="hold" reporter:datatype="link"/>
                        <field reporter:label="Notification ID" name="id" reporter:datatype="id" />
@@ -3897,8 +4410,24 @@ SELECT  usr,
                        <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
                        <link field="notify_staff" reltype="has_a" key="id" map="" class="au"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="CREATE_HOLD_NOTIFICATION">
+                                       <context link="hold" jump="usr" field="home_ou" />
+                               </create>
+                <retrieve permission="VIEW_HOLD_NOTIFICATION">
+                                       <context link="hold" jump="usr" field="home_ou" />
+                               </retrieve>
+                <update permission="CREATE_HOLD_NOTIFICATION">
+                                       <context link="hold" jump="usr" field="home_ou" />
+                               </update>
+                <delete permission="CREATE_HOLD_NOTIFICATION">
+                                       <context link="hold" jump="usr" field="home_ou" />
+                               </delete>
+            </actions>
+        </permacrud>
        </class>
-       <class id="acpl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location" oils_persist:tablename="asset.copy_location" reporter:label="Copy/Shelving Location">
+       <class id="acpl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location" oils_persist:tablename="asset.copy_location" reporter:label="Copy/Shelving Location"  oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_location_id_seq">
                        <field reporter:label="Can Circulate?" name="circulate"  reporter:datatype="bool"/>
                        <field reporter:label="Is Holdable?" name="holdable" reporter:datatype="bool"/>
@@ -4125,6 +4654,7 @@ SELECT  usr,
                        <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
                        <field reporter:label="Create Date" name="create_date" reporter:datatype="timestamp"/>
                        <field reporter:label="Public?" name="pub" reporter:datatype="bool"/>
+                       <field reporter:label="Alert?" name="alert" reporter:datatype="bool"/>
                        <field reporter:label="Title" name="title" reporter:datatype="text"/>
                        <field reporter:label="Value" name="value" reporter:datatype="text"/>
                </fields>
@@ -4148,6 +4678,7 @@ SELECT  usr,
                        <field reporter:label="Bind Unit Template" name="bind_unit_template" reporter:datatype="link"/>
                        <field reporter:label="Unit Label Prefix" name="unit_label_prefix" reporter:datatype="text"/>
                        <field reporter:label="Unit Label Suffix" name="unit_label_suffix" reporter:datatype="text"/>
+                       <field reporter:label="Display Grouping" name="display_grouping" reporter:datatype="text"/>
                        <field reporter:label="Streams" name="streams" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Basic Issue Summary" name="basic_summary" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -4185,6 +4716,7 @@ SELECT  usr,
                        <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
                        <field reporter:label="Create Date" name="create_date" reporter:datatype="timestamp"/>
                        <field reporter:label="Public?" name="pub" reporter:datatype="bool"/>
+                       <field reporter:label="Alert?" name="alert" reporter:datatype="bool"/>
                        <field reporter:label="Title" name="title" reporter:datatype="text"/>
                        <field reporter:label="Value" name="value" reporter:datatype="text"/>
                </fields>
@@ -4342,7 +4874,7 @@ SELECT  usr,
                        <field reporter:label="Copy Status" name="status" reporter:datatype="link"/>
                        <field reporter:label="Copy Status Changed Time" name="status_changed_time" reporter:datatype="timestamp"/>
                        <field reporter:label="Is Mint Condition" name="mint_condition" reporter:datatype="bool"/>
-                       <field reporter:label="Is Floating" name="floating" reporter:datatype="bool"/>
+                       <field reporter:label="Floating Group" name="floating" reporter:datatype="link"/>
                        <field reporter:label="Cost" name="cost" reporter:datatype="money"/>
                        <field reporter:label="Sort Key" name="sort_key" reporter:datatype="text"/>
                        <field reporter:label="Summary Contents" name="summary_contents" reporter:datatype="text"/>
@@ -4369,6 +4901,7 @@ SELECT  usr,
                        <link field="circulations" reltype="has_many" key="target_copy" map="" class="circ"/>
                        <link field="total_circ_count" reltype="might_have" key="id" map="" class="erfcc"/>
                        <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
+                       <link field="floating" reltype="has_a" key="id" map="" class="cfg"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
@@ -4431,6 +4964,7 @@ SELECT  usr,
                        <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
                        <field reporter:label="Create Date" name="create_date" reporter:datatype="timestamp"/>
                        <field reporter:label="Public?" name="pub" reporter:datatype="bool"/>
+                       <field reporter:label="Alert?" name="alert" reporter:datatype="bool"/>
                        <field reporter:label="Title" name="title" reporter:datatype="text"/>
                        <field reporter:label="Value" name="value" reporter:datatype="text"/>
                </fields>
@@ -4440,7 +4974,32 @@ SELECT  usr,
                </links>
                <!-- Not available via PCRUD at this time -->
        </class>
-
+       <class id="sasum" controller="open-ils.cstore" oils_obj:fieldmapper="serial::any_summary" oils_persist:tablename="serial.any_summary" reporter:label="All Issues' Summaries" oils_persist:readonly="true">
+               <fields>
+                       <field name="summary_type" reporter:label="Summary Type" reporter:datatype="text" />
+                       <field name="id" reporter:label="Native ID" reporter:datatype="int" /><!-- not datatype="id", because id is not unique in this view -->
+                       <field name="distribution" reporter:label="Distribution" reporter:datatype="link" />
+                       <field name="generated_coverage" reporter:label="Generated Coverage" reporter:datatype="text" />
+                       <field name="show_generated" reporter:label="Show Generated?" reporter:datatype="bool" />
+               </fields>
+               <links>
+                       <link field="distribution" reltype="has_a" key="id" map="" class="sdist"/>
+               </links>
+       </class>
+       <class id="smhc" controller="open-ils.cstore" oils_obj:fieldmapper="serial::materialized_holding_code" oils_persist:tablename="serial.materialized_holding_code" reporter:label="Materialized Holding Code" oils_persist:readonly="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="serial.materialized_holding_code_id_seq">
+                       <field name="id" reporter:label="ID" reporter:datatype="id" />
+                       <field name="issuance" reporter:label="Issuance" reporter:datatype="link" />
+                       <field name="holding_type" reporter:label="Holding Type" reporter:datatype="text" />
+                       <field name="ind1" reporter:label="First Indicator" reporter:datatype="text" />
+                       <field name="ind2" reporter:label="Second Indicator" reporter:datatype="text" />
+                       <field name="subfield" reporter:label="Subfield" reporter:datatype="text" />
+                       <field name="value" reporter:label="Value" reporter:datatype="text" oils_obj:validate="^\w$" />
+               </fields>
+               <links>
+                       <link field="issuance" reltype="has_a" key="id" map="" class="siss"/>
+               </links>
+       </class>
        <class id="sbsum" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::basic_summary" oils_persist:tablename="serial.basic_summary" reporter:label="Basic Issue Summary">
                <fields oils_persist:primary="id" oils_persist:sequence="serial.basic_summary_id_seq">
                        <field reporter:label="ID" name="id" reporter:datatype="id" />
@@ -4619,6 +5178,36 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
+       <class id="aoupa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit_proximity_adjustment" oils_persist:tablename="actor.org_unit_proximity_adjustment" reporter:label="Org Unit Proximity Adjustment">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_proximity_adjustment_id_seq">
+                       <field name="id" reporter:label="ID" reporter:datatype="id" />
+                       <field name="item_circ_lib" reporter:label="Item Circ Lib" reporter:datatype="org_unit"/>
+                       <field name="item_owning_lib" reporter:label="Item Owning Lib" reporter:datatype="org_unit"/>
+                       <field name="hold_pickup_lib" reporter:label="Hold Pickup Lib" reporter:datatype="org_unit"/>
+                       <field name="hold_request_lib" reporter:label="Hold Request Lib" reporter:datatype="org_unit"/>
+                       <field name="copy_location" reporter:label="Copy Location" reporter:datatype="link"/>
+                       <field name="circ_mod" reporter:label="Circ Modifier" reporter:datatype="link"/>
+                       <field name="pos" reporter:label="Position" reporter:datatype="int" />
+                       <field name="absolute_adjustment" reporter:label="Absolute adjustment?" reporter:datatype="bool" />
+                       <field name="prox_adjustment" reporter:label="Proximity Adjustment" reporter:datatype="number" />
+               </fields>
+               <links>
+                       <link field="item_circ_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="item_owning_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="hold_pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="hold_request_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="circ_mod" reltype="has_a" key="code" map="" class="ccm"/>
+                       <link field="copy_location" reltype="has_a" key="id" map="" class="acpl"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_PROXIMITY_ADJUSTMENT" global_required="true"/>
+                <retrieve permission="ADMIN_PROXIMITY_ADJUSTMENT" global_required="true"/>
+                <update permission="ADMIN_PROXIMITY_ADJUSTMENT" global_required="true"/>
+                <delete permission="ADMIN_PROXIMITY_ADJUSTMENT" global_required="true"/>
+            </actions>
+        </permacrud>
+       </class>
        <class id="aoup" controller="open-ils.cstore" oils_obj:fieldmapper="actor::org_unit_proximity" oils_persist:tablename="actor.org_unit_proximity" reporter:label="Org Unit Proximity">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_proximity_id_seq">
                        <field name="id" reporter:datatype="id" />
@@ -4700,8 +5289,70 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
-       <!-- A note: Please update alhr when updating ahr -->
-       <class id="ahr" controller="open-ils.cstore" oils_obj:fieldmapper="action::hold_request" oils_persist:tablename="action.hold_request" reporter:core="true" reporter:label="Hold Request">
+       <class id="asq" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::search_query" oils_persist:tablename="actor.search_query" reporter:label="Search Query" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.search_query_id_seq">
+                       <field name="id" reporter:datatype="id" reporter:selector="label"/>
+                       <field name="label" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field name="query_text" reporter:datatype="text"/>
+               </fields>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve/>
+            </actions>
+        </permacrud>
+       </class>
+
+       <class id="asfg" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::search_filter_group" oils_persist:tablename="actor.search_filter_group" reporter:label="Search Filter Group" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.search_filter_group_id_seq">
+                       <field name="id" reporter:datatype="id" reporter:selector="label"/>
+                       <field name="owner" reporter:datatype="org_unit"/>
+                       <field name="code" reporter:datatype="text"/>
+                       <field name="label" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field name="create_date" reporter:datatype="timestamp"/>
+                       <field name="entries" oils_persist:virtual="true" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="entries" reltype="has_many" key="grp" map="" class="asfge"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_SEARCH_FILTER_GROUP" context_field="owner"/>
+                <retrieve/>
+                <update permission="ADMIN_SEARCH_FILTER_GROUP" context_field="owner"/>
+                <delete permission="ADMIN_SEARCH_FILTER_GROUP" context_field="owner"/>
+            </actions>
+        </permacrud>
+       </class>
+       <class id="asfge" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::search_filter_group_entry" oils_persist:tablename="actor.search_filter_group_entry" reporter:label="Search Filter Group Entry" oils_persist:field_safe="true">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.search_filter_group_entry_id_seq">
+                       <field name="id" reporter:datatype="id"/>
+                       <field name="grp" reporter:datatype="link"/>
+                       <field name="pos" reporter:datatype="int"/>
+                       <field name="query" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="grp" reltype="has_a" key="id" map="" class="asfg"/>
+                       <link field="query" reltype="has_a" key="id" map="" class="asq"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="ADMIN_SEARCH_FILTER_GROUP">
+                    <context link="grp" field="owner"/>
+                </create>
+                <retrieve/>
+                <update permission="ADMIN_SEARCH_FILTER_GROUP">
+                    <context link="grp" field="owner"/>
+                </update>
+                <delete permission="ADMIN_SEARCH_FILTER_GROUP">
+                    <context link="grp" field="owner"/>
+                </delete>
+            </actions>
+        </permacrud>
+       </class>
+
+       <!-- A note: Please update alhr and ahopl when updating ahr -->
+       <class id="ahr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::hold_request" oils_persist:tablename="action.hold_request" reporter:core="true" reporter:label="Hold Request">
                <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_id_seq">
                        <field reporter:label="Status" name="status" oils_persist:virtual="true" />
                        <field reporter:label="Transit" name="transit" oils_persist:virtual="true" />
@@ -4717,7 +5368,155 @@ SELECT  usr,
                        <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
                        <field reporter:label="Notifications Phone Number" name="phone_notify" reporter:datatype="text"/>
                        <field reporter:label="Notifications SMS Number" name="sms_notify" reporter:datatype="text"/>
-                       <field reporter:label="Notifications SMS Carrier" name="sms_carrier" reporter:datatype="text"/>
+                       <field reporter:label="Notifications SMS Carrier" name="sms_carrier" reporter:datatype="link"/>
+                       <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Last Targeting Date/Time" name="prev_check_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Requesting Library" name="request_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Request Date/Time" name="request_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Requesting User" name="requestor" reporter:datatype="link"/>
+                       <field reporter:label="Item Selection Depth" name="selection_depth" />
+                       <field reporter:label="Selection Locus" name="selection_ou" reporter:datatype="org_unit"/>
+                       <field reporter:label="Target Object ID" name="target" reporter:datatype="link"/>
+                       <field reporter:label="Hold User" name="usr" reporter:datatype="link"/>
+                       <field reporter:label="Hold Cancel Date/Time" name="cancel_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Notify Time" name="notify_time" oils_persist:virtual="true" reporter:datatype="timestamp"/>
+                       <field reporter:label="Notify Count" name="notify_count" oils_persist:virtual="true" reporter:datatype="int" />
+                       <field reporter:label="Notifications" name="notifications" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Bib Record link" name="bib_rec" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Eligible Copies" name="eligible_copies" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Currently Frozen" name="frozen" reporter:datatype="bool"/>
+                       <field reporter:label="Thaw Date (if frozen)" name="thaw_date" reporter:datatype="timestamp"/>
+                       <field reporter:label="Shelf Time" name="shelf_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Cancelation cause" name="cancel_cause" reporter:datatype="link" />
+                       <field reporter:label="Cancelation note" name="cancel_note" reporter:datatype="text" />
+                       <field reporter:label="Top of Queue" name="cut_in_line" reporter:datatype="bool" />
+                       <field reporter:label="Is Mint Condition" name="mint_condition" reporter:datatype="bool" />
+                       <field reporter:label="Shelf Expire Time" name="shelf_expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Notes" name="notes" reporter:datatype="link" oils_persist:virtual="true"/>
+                       <field reporter:label="Current Shelf Lib" name="current_shelf_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Behind Desk" name="behind_desk" reporter:datatype="bool"/>
+               </fields>
+               <links>
+                       <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="fulfillment_staff" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="selection_ou" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="requestor" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="current_copy" reltype="has_a" key="id" map="" class="acp"/>
+                       <link field="usr" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="request_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="transit" reltype="might_have" key="hold" map="" class="ahtc"/>
+                       <link field="notifications" reltype="has_many" key="hold" map="" class="ahn"/>
+                       <link field="eligible_copies" reltype="has_many" key="hold" map="target_copy" class="ahcm"/>
+                       <link field="bib_rec" reltype="might_have" key="id" map="" class="rhrr"/>
+                       <link field="cancel_cause" reltype="might_have" key="id" map="" class="ahrcc"/>
+                       <link field="notes" reltype="has_many" key="hold" map="" class="ahrn"/>
+                       <link field="current_shelf_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="sms_carrier" reltype="has_a" key="id" map="" class="csc"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_HOLD" context_field="pickup_lib" />
+                       </actions>
+               </permacrud>
+       </class>
+       <class id="ahopl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::hold_on_pull_list" reporter:label="Hold On Pull List" oils_persist:readonly="true">
+               <oils_persist:source_definition><![CDATA[
+               SELECT
+                       ahr.*,
+                       COALESCE(acplo.position, acpl_ordered.fallback_position) AS
+                               copy_location_order_position,
+                       CASE WHEN au.alias IS NOT NULL THEN
+                               au.alias
+                       ELSE
+                               au.first_given_name
+                       END AS usr_alias_or_first_given_name,
+                       au.first_given_name AS usr_first_given_name,
+                       au.second_given_name AS usr_second_given_name,
+                       au.family_name AS usr_family_name,
+                       au.prefix AS usr_prefix,
+                       au.suffix AS usr_suffix,
+                       au.alias AS usr_alias,
+                       CASE WHEN au.alias IS NOT NULL THEN
+                               au.alias
+                       ELSE
+                               REGEXP_REPLACE(ARRAY_TO_STRING(ARRAY[
+                                       COALESCE(au.family_name, ''),
+                                       COALESCE(au.suffix, ''),
+                                       ', ',
+                                       COALESCE(au.prefix, ''),
+                                       COALESCE(au.first_given_name, ''),
+                                       COALESCE(au.second_given_name, '')
+                               ], ' '), E'\\s+,', ',')
+                       END AS usr_alias_or_display_name,
+                       REGEXP_REPLACE(ARRAY_TO_STRING(ARRAY[
+                               COALESCE(au.family_name, ''),
+                               COALESCE(au.suffix, ''),
+                               ', ',
+                               COALESCE(au.prefix, ''),
+                               COALESCE(au.first_given_name, ''),
+                               COALESCE(au.second_given_name, '')
+                       ], ' '), E'\\s+,', ',') AS usr_display_name,
+                       TRIM(acnp.label || ' ' || acn.label || ' ' || acns.label)
+                               AS call_number_label,
+                       siss.label AS issuance_label,
+                       (ahr.usr <> ahr.requestor) AS is_staff_hold,
+                       ahcm_1.copy_count AS potential_copies
+               FROM action.hold_request ahr
+               JOIN asset.copy acp ON (acp.id = ahr.current_copy)
+               JOIN asset.call_number acn ON (acp.call_number = acn.id)
+               JOIN asset.call_number_prefix acnp ON (acn.prefix = acnp.id)
+               JOIN asset.call_number_suffix acns ON (acn.suffix = acns.id)
+               JOIN actor.usr au ON (au.id = ahr.usr)
+               JOIN (
+                       SELECT *, (ROW_NUMBER() OVER (ORDER BY name) + 1000000) AS fallback_position
+                       FROM asset.copy_location
+               ) acpl_ordered ON (acpl_ordered.id = acp.location)
+               LEFT JOIN actor.usr_standing_penalty ausp 
+                       ON (ahr.usr = ausp.usr AND (ausp.stop_date IS NULL OR ausp.stop_date > NOW()))
+               LEFT JOIN config.standing_penalty csp
+                       ON (
+                               csp.id = ausp.standing_penalty AND 
+                               csp.block_list LIKE '%CAPTURE%' AND (
+                                       (csp.org_depth IS NULL AND ahr.pickup_lib = ausp.org_unit) OR
+                                       (csp.org_depth IS NOT NULL AND ahr.pickup_lib IN (
+                                               SELECT id FROM actor.org_unit_descendants(ausp.org_unit, csp.org_depth))
+                                       )
+                               )
+                       )
+               JOIN (
+                       SELECT COUNT(target_copy) AS copy_count, hold
+                       FROM action.hold_copy_map
+                       GROUP BY 2
+               ) ahcm_1 ON (ahcm_1.hold = ahr.id)
+               LEFT JOIN serial.issuance siss
+                       ON (ahr.hold_type = 'I' AND siss.id = ahr.target)
+               LEFT JOIN asset.copy_location_order acplo
+                       ON (acp.location = acplo.location AND
+                               acp.circ_lib = acplo.org)
+               WHERE
+                       ahr.capture_time IS NULL AND
+                       ahr.cancel_time IS NULL AND
+                       csp.id IS NULL AND
+                       (ahr.expire_time is NULL OR ahr.expire_time > NOW()) AND
+                       acp.status IN (0,7)
+               ]]></oils_persist:source_definition>
+               <fields oils_persist:primary="id">
+                       <field reporter:label="Status" name="status" oils_persist:virtual="true" />
+                       <field reporter:label="Transit" name="transit" oils_persist:virtual="true" />
+                       <field reporter:label="Capture Date/Time" name="capture_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Currently Targeted Copy" name="current_copy" />
+                       <field reporter:label="Notify by Email?" name="email_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Hold Expire Date/Time" name="expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Fulfilling Library" name="fulfillment_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Fulfilling Staff" name="fulfillment_staff" />
+                       <field reporter:label="Fulfillment Date/Time" name="fulfillment_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Hold Type" name="hold_type" reporter:datatype="text"/>
+                       <field reporter:label="Holdable Formats (for M-type hold)" name="holdable_formats" reporter:datatype="text"/>
+                       <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="Notifications Phone Number" name="phone_notify" reporter:datatype="text"/>
+                       <field reporter:label="Notifications SMS Number" name="sms_notify" reporter:datatype="text"/>
+                       <field reporter:label="Notifications SMS Carrier" name="sms_carrier" reporter:datatype="link"/>
                        <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
                        <field reporter:label="Last Targeting Date/Time" name="prev_check_time" reporter:datatype="timestamp"/>
                        <field reporter:label="Requesting Library" name="request_lib" reporter:datatype="org_unit"/>
@@ -4743,6 +5542,21 @@ SELECT  usr,
                        <field reporter:label="Shelf Expire Time" name="shelf_expire_time" reporter:datatype="timestamp"/>
                        <field reporter:label="Notes" name="notes" reporter:datatype="link" oils_persist:virtual="true"/>
                        <field reporter:label="Current Shelf Lib" name="current_shelf_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Copy Location Sort Order" name="copy_location_order_position" reporter:datatype="int" />
+                       <field reporter:label="User First Given Name" name="usr_first_given_name" reporter:datatype="text" />
+                       <field reporter:label="User Second Given Name" name="usr_second_given_name" reporter:datatype="text" />
+                       <field reporter:label="User Family Name" name="usr_family_name" reporter:datatype="text" />
+                       <field reporter:label="User Prefix" name="usr_prefix" reporter:datatype="text" />
+                       <field reporter:label="User Suffix" name="usr_suffix" reporter:datatype="text" />
+                       <field reporter:label="User Alias or First Given Name" name="usr_alias_or_first_given_name" reporter:datatype="text" />
+                       <field reporter:label="User Display Name" name="usr_display_name" reporter:datatype="text" />
+                       <field reporter:label="User Alias or Display Name" name="usr_alias_or_display_name" reporter:datatype="text" />
+                       <field reporter:label="User Alias" name="usr_alias" reporter:datatype="text" />
+                       <field reporter:label="Call Number Label" name="call_number_label" reporter:datatype="text" />
+                       <field reporter:label="Issuance Label" name="issuance_label" reporter:datatype="text" />
+                       <field reporter:label="Is Staff Hold?" name="is_staff_hold" reporter:datatype="bool" />
+                       <field reporter:label="Potential Copies" name="potential_copies" reporter:datatype="int" />
+                       <field reporter:label="Behind Desk" name="behind_desk" reporter:datatype="bool"/>
                </fields>
                <links>
                        <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
@@ -4760,8 +5574,13 @@ SELECT  usr,
                        <link field="cancel_cause" reltype="might_have" key="id" map="" class="ahrcc"/>
                        <link field="notes" reltype="has_many" key="hold" map="" class="ahrn"/>
                        <link field="current_shelf_lib" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="sms_carrier" reltype="might_have" key="code" map="" class="csc"/>
+                       <link field="sms_carrier" reltype="has_a" key="id" map="" class="csc"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_HOLD" context_field="pickup_lib" />
+                       </actions>
+               </permacrud>
        </class>
        <class id="alhr" controller="open-ils.cstore" oils_obj:fieldmapper="action::last_hold_request" reporter:label="Last Captured Hold Request" oils_persist:readonly="true">
                <oils_persist:source_definition>
@@ -4806,6 +5625,7 @@ SELECT  usr,
                        <field reporter:label="Shelf Expire Time" name="shelf_expire_time" reporter:datatype="timestamp"/>
                        <field reporter:label="Notes" name="notes" reporter:datatype="link" oils_persist:virtual="true"/>
                        <field reporter:label="Current Shelf Lib" name="current_shelf_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Behind Desk" name="behind_desk" reporter:datatype="bool"/>
                </fields>
                <links>
                        <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
@@ -4848,6 +5668,124 @@ SELECT  usr,
                        </actions>
                </permacrud>
        </class>
+       <class id="combahr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::all_hold_request" oils_persist:tablename="action.all_hold_request" reporter:core="true" reporter:label="Combined (Active &amp; Aged) Hold Request">
+               <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_id_seq">
+                       <field reporter:label="Status" name="status" oils_persist:virtual="true" />
+                       <field reporter:label="Capture Date/Time" name="capture_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Currently Targeted Copy" name="current_copy" />
+                       <field reporter:label="Notify by Email?" name="email_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Hold Expire Date/Time" name="expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Fulfilling Library" name="fulfillment_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Fulfilling Staff" name="fulfillment_staff" />
+                       <field reporter:label="Fulfillment Date/Time" name="fulfillment_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Hold Type" name="hold_type" reporter:datatype="text"/>
+                       <field reporter:label="Holdable Formats (for M-type hold)" name="holdable_formats" reporter:datatype="text"/>
+                       <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="Notify by Phone?" name="phone_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Notify by SMS?" name="sms_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Last Targeting Date/Time" name="prev_check_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Requesting Library" name="request_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Request Date/Time" name="request_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Patron ZIP" name="usr_post_code" reporter:datatype="text"/>
+                       <field reporter:label="Patron Home Library" name="usr_home_ou" reporter:datatype="link"/>
+                       <field reporter:label="Patron Profile Group" name="usr_profile" reporter:datatype="link"/>
+                       <field reporter:label="Patron Birth Year" name="usr_birth_year" reporter:datatype="int"/>
+                       <field reporter:label="Staff Placed?" name="staff_placed" reporter:datatype="bool"/>
+                       <field reporter:label="Item Selection Depth" name="selection_depth" />
+                       <field reporter:label="Selection Locus" name="selection_ou" reporter:datatype="org_unit"/>
+                       <field reporter:label="Target Object ID" name="target" reporter:datatype="link"/>
+                       <field reporter:label="Hold Cancel Date/Time" name="cancel_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Bib Record link" name="bib_rec" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Currently Frozen" name="frozen" reporter:datatype="bool"/>
+                       <field reporter:label="Thaw Date (if frozen)" name="thaw_date" reporter:datatype="timestamp"/>
+                       <field reporter:label="Shelf Time" name="shelf_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Cancelation cause" name="cancel_cause" reporter:datatype="link" />
+                       <field reporter:label="Cancelation note" name="cancel_note" reporter:datatype="text" />
+                       <field reporter:label="Top of Queue" name="cut_in_line" reporter:datatype="bool" />
+                       <field reporter:label="Is Mint Condition" name="mint_condition" reporter:datatype="bool" />
+                       <field reporter:label="Shelf Expire Time" name="shelf_expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Current Shelf Lib" name="current_shelf_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Behind Desk" name="behind_desk" reporter:datatype="bool"/>
+               </fields>
+               <links>
+                       <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="fulfillment_staff" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="selection_ou" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="current_copy" reltype="has_a" key="id" map="" class="acp"/>
+                       <link field="request_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="usr_home_ou" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="bib_rec" reltype="might_have" key="id" map="" class="rhrr"/>
+                       <link field="cancel_cause" reltype="might_have" key="id" map="" class="ahrcc"/>
+                       <link field="current_shelf_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="usr_profile" reltype="has_a" key="id" map="" class="pgt"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_HOLD" context_field="pickup_lib" />
+                       </actions>
+               </permacrud>
+       </class>
+       <class id="aahr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::aged_hold_request" oils_persist:tablename="action.aged_hold_request" reporter:core="true" reporter:label="Aged Hold Request">
+               <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_id_seq">
+                       <field reporter:label="Status" name="status" oils_persist:virtual="true" />
+                       <field reporter:label="Capture Date/Time" name="capture_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Currently Targeted Copy" name="current_copy" />
+                       <field reporter:label="Notify by Email?" name="email_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Hold Expire Date/Time" name="expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Fulfilling Library" name="fulfillment_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Fulfilling Staff" name="fulfillment_staff" />
+                       <field reporter:label="Fulfillment Date/Time" name="fulfillment_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Hold Type" name="hold_type" reporter:datatype="text"/>
+                       <field reporter:label="Holdable Formats (for M-type hold)" name="holdable_formats" reporter:datatype="text"/>
+                       <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="Notify by Phone?" name="phone_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Notify by SMS?" name="sms_notify" reporter:datatype="bool"/>
+                       <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Last Targeting Date/Time" name="prev_check_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Requesting Library" name="request_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Request Date/Time" name="request_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Patron ZIP" name="usr_post_code" reporter:datatype="text"/>
+                       <field reporter:label="Patron Home Library" name="usr_home_ou" reporter:datatype="link"/>
+                       <field reporter:label="Patron Profile Group" name="usr_profile" reporter:datatype="link"/>
+                       <field reporter:label="Patron Birth Year" name="usr_birth_year" reporter:datatype="int"/>
+                       <field reporter:label="Staff Placed?" name="staff_placed" reporter:datatype="bool"/>
+                       <field reporter:label="Item Selection Depth" name="selection_depth" />
+                       <field reporter:label="Selection Locus" name="selection_ou" reporter:datatype="org_unit"/>
+                       <field reporter:label="Target Object ID" name="target" reporter:datatype="link"/>
+                       <field reporter:label="Hold Cancel Date/Time" name="cancel_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Bib Record link" name="bib_rec" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Currently Frozen" name="frozen" reporter:datatype="bool"/>
+                       <field reporter:label="Thaw Date (if frozen)" name="thaw_date" reporter:datatype="timestamp"/>
+                       <field reporter:label="Shelf Time" name="shelf_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Cancelation cause" name="cancel_cause" reporter:datatype="link" />
+                       <field reporter:label="Cancelation note" name="cancel_note" reporter:datatype="text" />
+                       <field reporter:label="Top of Queue" name="cut_in_line" reporter:datatype="bool" />
+                       <field reporter:label="Is Mint Condition" name="mint_condition" reporter:datatype="bool" />
+                       <field reporter:label="Shelf Expire Time" name="shelf_expire_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Current Shelf Lib" name="current_shelf_lib" reporter:datatype="org_unit"/>
+               </fields>
+               <links>
+                       <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="fulfillment_staff" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="selection_ou" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="current_copy" reltype="has_a" key="id" map="" class="acp"/>
+                       <link field="request_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="usr_home_ou" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="bib_rec" reltype="might_have" key="id" map="" class="rhrr"/>
+                       <link field="cancel_cause" reltype="might_have" key="id" map="" class="ahrcc"/>
+                       <link field="current_shelf_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="usr_profile" reltype="has_a" key="id" map="" class="pgt"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_HOLD" context_field="pickup_lib" />
+                       </actions>
+               </permacrud>
+       </class>
+
        <class id="aou" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit" oils_persist:tablename="actor.org_unit" reporter:label="Organizational Unit" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_id_seq">
                        <field reporter:label="Subordinate Organizational Units" name="children" oils_persist:virtual="true" reporter:datatype="org_unit"/>
@@ -4912,15 +5850,51 @@ SELECT  usr,
         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
             <actions>
                 <create permission="CREATE_ORG_UNIT" context_field="parent_ou"/>
-                <retrieve permission="CREATE_ORG_UNIT UPDATE_ORG_UNIT DELETE_ORG_UNIT">
-                    <context field="id"/>
-                    <context field="parent_ou"/>
-                               </retrieve>
+                <retrieve />
                 <update permission="UPDATE_ORG_UNIT" context_field="id"/>
                 <delete permission="DELETE_ORG_UNIT" context_field="parent_ou"/>
             </actions>
         </permacrud>
        </class>
+       <class id="aouct" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit_custom_tree" oils_persist:tablename="actor.org_unit_custom_tree" reporter:label="Org Unit Custom Tree">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_custom_tree_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Active" name="active" reporter:datatype="bool"/>
+                       <field reporter:label="Purpose" name="purpose" reporter:datatype="text"/>
+               </fields>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                               <retrieve/>
+                               <update permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                               <delete permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                       </actions>
+               </permacrud>
+       </class>
+       <class id="aouctn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit_custom_tree_node" oils_persist:tablename="actor.org_unit_custom_tree_node" reporter:label="Org Unit Custom Tree Node">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_custom_tree_node_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Tree" name="tree" reporter:datatype="link"/>
+                       <field reporter:label="Org Unit" name="org_unit" reporter:datatype="link"/>
+                       <field reporter:label="Parent" name="parent_node" reporter:datatype="link"/>
+                       <field reporter:label="Sibling Sort Order" name="sibling_order" reporter:datatype="int"/>
+                       <field reporter:label="Children" name="children" reporter:datatype="link" oils_persist:virtual="true" />
+               </fields>
+               <links>
+                       <link field="tree" reltype="has_a" key="id" map="" class="aouct"/>
+                       <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="parent_node" reltype="has_a" key="id" map="" class="aouctn"/>
+                       <link field="children" reltype="has_many" key="parent_node" map="" class="aouctn"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                               <retrieve/>
+                               <update permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                               <delete permission="ADMIN_ORG_UNIT_CUSTOM_TREE" global_required="true" />
+                       </actions>
+               </permacrud>
+       </class>
        <class id="ccnb" controller="open-ils.cstore" oils_obj:fieldmapper="container::call_number_bucket" oils_persist:tablename="container.call_number_bucket" reporter:label="Call Number Bucket">
                <fields oils_persist:primary="id" oils_persist:sequence="container.call_number_bucket_id_seq">
                        <field name="items" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -4965,7 +5939,7 @@ SELECT  usr,
                        <link field="entries" reltype="has_many" key="stat_cat" map="" class="asce"/>
                </links>
        </class>
-       <class id="ac" controller="open-ils.cstore" oils_obj:fieldmapper="actor::card" oils_persist:tablename="actor.card" reporter:label="Library Card">
+       <class id="ac" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::card" oils_persist:tablename="actor.card" reporter:label="Library Card">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.card_id_seq">
                        <field reporter:label="IsActive?" name="active" reporter:datatype="bool"/>
                        <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
@@ -4975,6 +5949,13 @@ SELECT  usr,
                <links>
                        <link field="usr" reltype="has_a" key="id" map="" class="au"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_USER">
+                                       <context link="usr" field="home_ou" />
+                               </retrieve>
+                       </actions>
+               </permacrud>
        </class>
     <class id="actscsf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::stat_cat_sip_fields" oils_persist:tablename="actor.stat_cat_sip_fields" reporter:label="SIP Statistical Category Field Identifier">
         <fields oils_persist:primary="field">
@@ -4995,6 +5976,7 @@ SELECT  usr,
        <class id="actsc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::stat_cat" oils_persist:tablename="actor.stat_cat" reporter:label="User Statistical Category">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_id_seq">
                        <field reporter:label="Entries" name="entries" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Default Entries" name="default_entries" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Stat Cat ID" name="id" reporter:datatype="id" reporter:selector="name"/>
                        <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
@@ -5003,11 +5985,14 @@ SELECT  usr,
                        <field reporter:label="SIP Field" name="sip_field" reporter:datatype="link"/>
                        <field reporter:label="SIP Format" name="sip_format" reporter:datatype="text"/>
                        <field reporter:label="Checkout Archive" name="checkout_archive" reporter:datatype="bool"/>
+                       <field reporter:label="Required" name="required" reporter:datatype="bool"/>
+                       <field reporter:label="Free Text" name="allow_freetext" reporter:datatype="bool"/>
                </fields>
                <links>
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="sip_field" reltype="has_a" key="field" map="" class="actscsf"/>
                        <link field="entries" reltype="has_many" key="stat_cat" map="" class="actsce"/>
+                       <link field="default_entries" reltype="has_many" key="stat_cat" map="" class="actsced"/>
                </links>
         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
             <actions>
@@ -5056,7 +6041,7 @@ SELECT  usr,
                        <link field="bucket" reltype="has_a" key="id" map="" class="cub"/>
                </links>
        </class>
-       <class id="mcrp" controller="open-ils.cstore" oils_obj:fieldmapper="money::credit_payment" oils_persist:tablename="money.credit_payment" reporter:label="House Credit Payment">
+       <class id="mcrp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::credit_payment" oils_persist:tablename="money.credit_payment" reporter:label="House Credit Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
@@ -5073,6 +6058,13 @@ SELECT  usr,
                        <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="afr" controller="open-ils.cstore" oils_obj:fieldmapper="authority::full_rec" oils_persist:tablename="authority.full_rec" reporter:label="Full Authority Record">
                <fields oils_persist:primary="id" oils_persist:sequence="authority.full_rec_id_seq">
@@ -5088,7 +6080,20 @@ SELECT  usr,
                        <link field="record" reltype="has_a" key="id" map="" class="are"/>
                </links>
        </class>
-       <class id="cnct" controller="open-ils.cstore" oils_obj:fieldmapper="config::non_cataloged_type" oils_persist:tablename="config.non_cataloged_type" reporter:label="Non-cataloged Type">
+       <class id="aalink" controller="open-ils.cstore" oils_obj:fieldmapper="authority::authority_linking" oils_persist:tablename="authority.authority_linking" reporter:label="Authority to Authority Linking">
+               <fields oils_persist:primary="id" oils_persist:sequence="authority.authority_linking_id_seq">
+                       <field name="id" reporter:label="ID" reporter:datatype="id" />
+                       <field name="source" reporter:label="Source Record" reporter:datatype="link" />
+                       <field name="target" reporter:label="Target Record" reporter:datatype="link" />
+                       <field name="field" reporter:label="Authority Field" reporter:datatype="link" />
+               </fields>
+               <links>
+                       <link field="source" reltype="has_a" key="id" map="" class="are"/>
+                       <link field="target" reltype="has_a" key="id" map="" class="are"/>
+                       <link field="field" reltype="has_a" key="id" map="" class="acsaf"/>
+               </links>
+       </class>
+       <class id="cnct" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::non_cataloged_type" oils_persist:tablename="config.non_cataloged_type" reporter:label="Non-cataloged Type">
                <fields oils_persist:primary="id" oils_persist:sequence="config.non_cataloged_type_id_seq">
                        <field reporter:label="Circulation Duration" name="circ_duration" reporter:datatype="interval"/>
                        <field reporter:label="Non-cat Type ID" name="id" reporter:selector="name" reporter:datatype="id"/>
@@ -5099,6 +6104,15 @@ SELECT  usr,
                <links>
                        <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="CREATE_NON_CAT_TYPE" context_field="owning_lib"/>
+                <retrieve/>
+                <update permission="CREATE_NON_CAT_TYPE" context_field="owning_lib"/>
+                <delete permission="CREATE_NON_CAT_TYPE" context_field="owning_lib"/>
+            </actions>
+        </permacrud>
+
        </class>
        <class id="aout" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit_type" oils_persist:tablename="actor.org_unit_type" reporter:label="Organizational Unit Type" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_type_id_seq">
@@ -5196,7 +6210,7 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
-       <class id="mbt" controller="open-ils.cstore" oils_obj:fieldmapper="money::billable_transaction" oils_persist:tablename="money.billable_xact" reporter:label="Billable Transaction">
+       <class id="mbt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::billable_transaction" oils_persist:tablename="money.billable_xact" reporter:label="Billable Transaction">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
                        <field reporter:label="Transaction ID" name="id" reporter:datatype="id" />
                        <field reporter:label="User" name="usr" reporter:datatype="link"/>
@@ -5221,6 +6235,13 @@ SELECT  usr,
                        <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
                        <link field="summary" reltype="might_have" key="id" map="" class="mbts"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve permission="VIEW_USER_TRANSACTIONS">
+                                       <context link="usr" field="home_ou" />
+                               </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="actsce" controller="open-ils.cstore" oils_obj:fieldmapper="actor::stat_cat_entry" oils_persist:tablename="actor.stat_cat_entry" reporter:label="User Stat Cat Entry">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_entry_id_seq">
@@ -5228,10 +6249,25 @@ SELECT  usr,
                        <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
                        <field reporter:label="Stat Cat" name="stat_cat" reporter:datatype="link"/>
                        <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
+                       <field reporter:label="Default Entries" name="default_entries" oils_persist:virtual="true" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="stat_cat" reltype="has_a" key="id" map="" class="actsc"/>
+                       <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="default_entries" reltype="has_many" key="stat_cat_entry" map="" class="actsced"/>
+               </links>
+       </class>
+       <class id="actsced" controller="open-ils.cstore" oils_obj:fieldmapper="actor::stat_cat_entry_default" oils_persist:tablename="actor.stat_cat_entry_default" reporter:label="User Stat Cat Default Entry">
+               <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_entry_default_id_seq">
+                       <field reporter:label="Default Entry ID" name="id" reporter:datatype="id" />
+                       <field reporter:label="Default Entry Value" name="stat_cat_entry" reporter:datatype="link"/>
+                       <field reporter:label="Stat Cat" name="stat_cat" reporter:datatype="link"/>
+                       <field reporter:label="Default for Owner" name="owner" reporter:datatype="link"/>
                </fields>
                <links>
                        <link field="stat_cat" reltype="has_a" key="id" map="" class="actsc"/>
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="stat_cat_entry" reltype="has_a" key="id" map="" class="actsce"/>
                </links>
        </class>
        <class id="cubi" controller="open-ils.cstore" oils_obj:fieldmapper="container::user_bucket_item" oils_persist:tablename="container.user_bucket_item" reporter:label="User Bucket Item">
@@ -5286,7 +6322,7 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
-       <class id="mwp" controller="open-ils.cstore" oils_obj:fieldmapper="money::work_payment" oils_persist:tablename="money.work_payment" reporter:label="Work Payment">
+       <class id="mwp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::work_payment" oils_persist:tablename="money.work_payment" reporter:label="Work Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
@@ -5303,8 +6339,15 @@ SELECT  usr,
                        <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
-       <class id="mgp" controller="open-ils.cstore" oils_obj:fieldmapper="money::goods_payment" oils_persist:tablename="money.goods_payment" reporter:label="Goods Payment">
+       <class id="mgp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::goods_payment" oils_persist:tablename="money.goods_payment" reporter:label="Goods Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
@@ -5321,6 +6364,13 @@ SELECT  usr,
                        <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="aoc" controller="open-ils.cstore" oils_obj:fieldmapper="action::open_circulation" oils_persist:tablename="action.open_circulation" reporter:label="Open Circulation">
                <fields oils_persist:primary="id" oils_persist:sequence="">
@@ -5390,7 +6440,7 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
-       <class id="mckp" controller="open-ils.cstore" oils_obj:fieldmapper="money::check_payment" oils_persist:tablename="money.check_payment" reporter:label="Check Payment">
+       <class id="mckp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::check_payment" oils_persist:tablename="money.check_payment" reporter:label="Check Payment">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
                        <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
@@ -5410,6 +6460,13 @@ SELECT  usr,
                        <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="acp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy" oils_persist:tablename="asset.copy" reporter:core="true" reporter:label="Item">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_id_seq">
@@ -5444,11 +6501,13 @@ SELECT  usr,
                        <field reporter:label="Copy Status" name="status" reporter:datatype="link"/>
                        <field reporter:label="Copy Status Changed Time" name="status_changed_time" reporter:datatype="timestamp"/>
                        <field reporter:label="Is Mint Condition" name="mint_condition" reporter:datatype="bool"/>
-                       <field reporter:label="Is Floating" name="floating" reporter:datatype="bool"/>
+                       <field reporter:label="Floating Group" name="floating" reporter:datatype="link"/>
                        <field reporter:label="Cost" name="cost" reporter:datatype="money"/>
                        <field reporter:label="Copy Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Stat-Cat entry maps" name="stat_cat_entry_copy_maps" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Circulations" name="circulations" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Aged (patronless) Circulations" name="aged_circulations" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Combined Aged and Active Circulations" name="all_circulations" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Total Circulations" name="total_circ_count" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Last Circulation Date" name="last_circ" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Holds" name="holds" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -5471,6 +6530,8 @@ SELECT  usr,
                        <link field="notes" reltype="has_many" key="owning_copy" map="" class="acpn"/>
                        <link field="stat_cat_entries" reltype="has_many" key="owning_copy" map="stat_cat_entry" class="ascecm"/>
                        <link field="circulations" reltype="has_many" key="target_copy" map="" class="circ"/>
+                       <link field="aged_circulations" reltype="has_many" key="target_copy" map="" class="acirc"/>
+                       <link field="all_circulations" reltype="has_many" key="target_copy" map="" class="combcirc"/>
                        <link field="total_circ_count" reltype="might_have" key="id" map="" class="erfcc"/>
                        <link field="last_circ" reltype="might_have" key="id" map="" class="rlc"/>
                        <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
@@ -5478,6 +6539,7 @@ SELECT  usr,
                        <link field="peer_record_maps" reltype="has_many" key="target_copy" map="" class="bpbcm"/>
                        <link field="peer_records" reltype="has_many" key="target_copy" map="peer_record" class="bpbcm"/>
                        <link field="last_captured_hold" reltype="has_a" key="current_copy" map="" class="alhr"/>
+                       <link field="floating" reltype="has_a" key="id" map="" class="cfg"/>
                </links>
         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
             <actions>
@@ -5520,7 +6582,7 @@ SELECT  usr,
                        <field reporter:label="Circ As Type" name="circ_as_type" reporter:datatype="text"/>
                        <field reporter:label="Alert Message" name="alert_message" reporter:datatype="text"/>
                        <field reporter:label="OPAC Visible?" name="opac_visible" reporter:datatype="bool"/>
-                       <field reporter:label="Floating?" name="floating" reporter:datatype="bool"/>
+                       <field reporter:label="Floating Group" name="floating" reporter:datatype="link"/>
                        <field reporter:label="Mint Condition?" name="mint_condition" reporter:datatype="bool"/>
                </fields>
                <links>
@@ -5531,6 +6593,7 @@ SELECT  usr,
                        <link field="status" reltype="has_a" key="id" map="" class="ccs"/>
                        <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
                        <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
+                       <link field="floating" reltype="has_a" key="id" map="" class="cfg"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
@@ -5790,7 +6853,7 @@ SELECT  usr,
                        <link field="perm" reltype="has_a" key="id" map="" class="ppl"/>
                </links>
        </class>
-       <class id="mp" controller="open-ils.cstore" oils_obj:fieldmapper="money::payment" oils_persist:tablename="money.payment_view" reporter:core="true" reporter:label="Payments: All">
+       <class id="mp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::payment" oils_persist:tablename="money.payment_view" reporter:core="true" reporter:label="Payments: All">
                <fields oils_persist:primary="id" oils_persist:sequence="">
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
                        <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
@@ -5817,6 +6880,13 @@ SELECT  usr,
                        <link field="goods_payment" reltype="might_have" key="id" map="" class="mgp"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="mbp" controller="open-ils.cstore" oils_obj:fieldmapper="money::bnm_payment" oils_persist:tablename="money.bnm_payment_view" reporter:core="true" reporter:label="Payments: Brick-and-mortar">
                <fields oils_persist:primary="id" oils_persist:sequence="">
@@ -5826,6 +6896,7 @@ SELECT  usr,
                        <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
                        <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
                        <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
+                       <field reporter:label="Accepting User" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
                        <field reporter:label="Cash Payment Detail" name="cash_payment" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Credit Card Payment Detail" name="credit_card_payment" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -5844,6 +6915,7 @@ SELECT  usr,
                        <link field="forgive_payment" reltype="might_have" key="id" map="" class="mfp"/>
                        <link field="goods_payment" reltype="might_have" key="id" map="" class="mgp"/>
                        <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
+                       <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
                </links>
        </class>
        <class id="mndp" controller="open-ils.reporter" oils_obj:fieldmapper="money::non_drawer_payment" oils_persist:tablename="money.non_drawer_payment_view" reporter:core="true" reporter:label="Payments: Non-drawer Staff">
@@ -5876,7 +6948,7 @@ SELECT  usr,
                        <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
                        <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
                        <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
-                       <field reporter:label="Accepting User" name="accepting_usr" />
+                       <field reporter:label="Accepting User" name="accepting_usr" reporter:datatype="link"/>
                        <field reporter:label="Cash Drawer" name="cash_drawer" reporter:datatype="link"/>
                        <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
                        <field reporter:label="Cash Payment" name="cash_payment" oils_persist:virtual="true" reporter:datatype="link"/>
@@ -6032,7 +7104,7 @@ SELECT  usr,
             </actions>
         </permacrud>
        </class>
-       <class id="mb" controller="open-ils.cstore" oils_obj:fieldmapper="money::billing" oils_persist:tablename="money.billing" reporter:label="Billing Line Item">
+       <class id="mb" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::billing" oils_persist:tablename="money.billing" reporter:label="Billing Line Item">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billing_id_seq">
                        <field reporter:label="Amount" name="amount" reporter:datatype="money" />
                        <field reporter:label="Billing Timestamp" name="billing_ts" reporter:datatype="timestamp"/>
@@ -6050,6 +7122,13 @@ SELECT  usr,
                        <link field="voider" reltype="has_a" key="id" map="" class="au"/>
                        <link field="btype" reltype="has_a" key="id" map="" class="cbt"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="VIEW_USER_TRANSACTIONS">
+                    <context link="xact" jump="usr" field="home_ou"/>
+                </retrieve>
+                       </actions>
+               </permacrud>
        </class>
        <class id="pugm" controller="open-ils.cstore" oils_obj:fieldmapper="permission::usr_grp_map" oils_persist:tablename="permission.usr_grp_map" reporter:label="User Group Map">
                <fields oils_persist:primary="id" oils_persist:sequence="permission.usr_grp_map_id_seq">
@@ -6264,6 +7343,7 @@ SELECT  usr,
                        <field reporter:label="Phone" name="phone" reporter:datatype="text" />
                        <field reporter:label="Fax Phone" name="fax_phone" reporter:datatype="text" />
                        <field reporter:label="Default Claim Policy" name="default_claim_policy" reporter:datatype="link" />
+                       <field reporter:label="Default # Copies" name="default_copy_count" reporter:datatype="int" />
                </fields>
                <links>
                        <link field="currency_type" reltype="has_a" key="code" map="" class="acqct"/>
@@ -6551,7 +7631,7 @@ SELECT  usr,
                </links>
        </class>
 
-       <class id="acqfc" controller="open-ils.cstore" oils_obj:fieldmapper="acq::fiscal_calendar" oils_persist:tablename="acq.fiscal_calendar" reporter:label="Fiscal Calendar">
+       <class id="acqfc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fiscal_calendar" oils_persist:tablename="acq.fiscal_calendar" reporter:label="Fiscal Calendar">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.fiscal_calendar_id_seq">
                        <field reporter:label="Fiscal Calendar ID" name="id" reporter:datatype="id" reporter:selector='name'/>
                        <field reporter:label="Fiscal Calendar Name" name="name" reporter:datatype="text"/>
@@ -6560,21 +7640,17 @@ SELECT  usr,
                <links>
             <link field="years" reltype="has_many" map="" key="calendar" class="acqfy"/>
                </links>
-               <!--
-                       For now, we don't have pcrud as one of the controllers, so the permacrud section is moot.
-                       But here's what it should look like if we ever do use pcrud.
-               -->
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
                                <create permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
-                               <retrieve permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
+                               <retrieve permission="STAFF_LOGIN" global_required="true"/>
                                <update permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
                                <delete permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
                        </actions>
                </permacrud>
        </class>
 
-       <class id="acqfy" controller="open-ils.cstore" oils_obj:fieldmapper="acq::fiscal_year" oils_persist:tablename="acq.fiscal_year" reporter:label="Fiscal Year">
+       <class id="acqfy" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fiscal_year" oils_persist:tablename="acq.fiscal_year" reporter:label="Fiscal Year">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.fiscal_year_id_seq">
                        <field reporter:label="Fiscal Year ID" name="id" reporter:datatype="id" reporter:selector='year'/>
                        <field reporter:label="Calendar" name="calendar" reporter:datatype="link"/>
@@ -6585,14 +7661,10 @@ SELECT  usr,
                <links>
                        <link field="calendar" reltype="has_a" key="id" map="" class="acqfc"/>
                </links>
-               <!--
-                       For now, we don't have pcrud as one of the controllers, so the permacrud section is moot.
-                       But here's what it should look like if we ever do use pcrud.
-               -->
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
                                <create permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
-                               <retrieve permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
+                               <retrieve permission="STAFF_LOGIN" global_required="true"/>
                                <update permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
                                <delete permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
                        </actions>
@@ -6722,6 +7794,12 @@ SELECT  usr,
                        <field reporter:label="Allocations" name="allocations" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Debits" name="debits" oils_persist:virtual="true" reporter:datatype="link"/>
                        <field reporter:label="Tags" name="tags" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Allocation Total" name="allocation_total" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Debit Total" name="debit_total" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Encumbrance Total" name="encumbrance_total" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Spent Total" name="spent_total" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Combined Balance" name="combined_balance" oils_persist:virtual="true" reporter:datatype="link"/>
+                       <field reporter:label="Spent Balance" name="spent_balance" oils_persist:virtual="true" reporter:datatype="link"/>
                </fields>
                <links>
                        <link field="org" reltype="has_a" key="id" map="" class="aou"/>
@@ -6729,8 +7807,14 @@ SELECT  usr,
             <link field="allocations" reltype="has_many" key="fund" map="" class="acqfa"/>
             <link field="debits" reltype="has_many" key="fund" map="" class="acqfdeb"/>
             <link field="tags" reltype="has_many" key="fund" map="" class="acqftm"/>
-               </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <link field="allocation_total" reltype="might_have" key="fund" map="" class="acqfat"/>
+            <link field="debit_total" reltype="might_have" key="fund" map="" class="acqfdt"/>
+            <link field="encumbrance_total" reltype="might_have" key="fund" map="" class="acqfet"/>
+            <link field="spent_total" reltype="might_have" key="fund" map="" class="acqfst"/>
+            <link field="combined_balance" reltype="might_have" key="fund" map="" class="acqfcb"/>
+            <link field="spent_balance" reltype="might_have" key="fund" map="" class="acqfsb"/>
+               </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1" ignore_object_perms="true">
             <actions>
                 <create permission="ADMIN_ACQ_FUND" context_field="org"/>
                 <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="org"/>
@@ -6740,7 +7824,7 @@ SELECT  usr,
         </permacrud>
        </class>
 
-       <class id="acqfat" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_allocation_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_allocation_total" reporter:label="Fund Allocation Total">
+       <class id="acqfat" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_allocation_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_allocation_total" reporter:label="Fund Allocation Total">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Total Allocation Amount" name="amount" reporter:datatype="money" />
@@ -6748,9 +7832,16 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
        </class>
 
-       <class id="acqfdt" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_debit_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_debit_total" reporter:label="Total Debit from Fund">
+       <class id="acqfdt" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_debit_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_debit_total" reporter:label="Total Debit from Fund">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Total Debit Amount" name="amount" reporter:datatype="money" />
@@ -6758,9 +7849,16 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
        </class>
 
-       <class id="acqfet" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_encumbrance_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_encumbrance_total" reporter:label="Total Fund Encumbrance">
+       <class id="acqfet" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_encumbrance_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_encumbrance_total" reporter:label="Total Fund Encumbrance">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Total Encumbrance Amount" name="amount" reporter:datatype="money" />
@@ -6768,9 +7866,16 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
        </class>
 
-       <class id="acqfst" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_total" reporter:label="Total Spent from Fund">
+       <class id="acqfst" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_total" reporter:label="Total Spent from Fund">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Total Spent Amount" name="amount" reporter:datatype="money" />
@@ -6778,9 +7883,16 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
        </class>
 
-       <class id="acqfcb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_combined_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_combined_balance" reporter:label="Fund Combined Balance">
+       <class id="acqfcb" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_combined_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_combined_balance" reporter:label="Fund Combined Balance">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Balance after Spent and Encumbered" name="amount" reporter:datatype="money" />
@@ -6788,6 +7900,13 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
        </class>
 
    <class id="acqafat" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::all_fund_allocation_total" oils_persist:readonly="true" oils_persist:tablename="acq.all_fund_allocation_total" reporter:label="All Fund Allocation Total">
@@ -6870,7 +7989,7 @@ SELECT  usr,
                </links>
        </class>
 
-       <class id="acqfsb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_balance" reporter:label="Fund Spent Balance">
+       <class id="acqfsb" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_balance" reporter:label="Fund Spent Balance">
                <fields oils_persist:primary="fund">
                        <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
                        <field reporter:label="Balance after Spent" name="amount" reporter:datatype="money" />
@@ -6878,8 +7997,59 @@ SELECT  usr,
                <links>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
+                                       <context link="fund" field="org" />
+                </retrieve>
+            </actions>
+        </permacrud>
+    </class>
+    <class id="acqfsum" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_summary" reporter:label="Fund Summary" reporter:core="true" oils_persist:readonly="true">
+        <oils_persist:source_definition><![CDATA[
+            SELECT
+                acqf.*,
+                COALESCE(acqfat.amount, 0.00) AS allocated_total,
+                COALESCE(acqfst.amount, 0.00) AS spent_total,
+                COALESCE(acqfet.amount, 0.00) AS encumbrance_total,
+                COALESCE(acqfcb.amount, 0.00) AS combined_balance
+            FROM
+                acq.fund acqf
+                LEFT JOIN acq.fund_allocation_total acqfat ON (acqfat.fund = acqf.id)
+                LEFT JOIN acq.fund_spent_total acqfst ON (acqfst.fund = acqf.id)
+                LEFT JOIN acq.fund_encumbrance_total acqfet ON (acqfet.fund = acqf.id)
+                LEFT JOIN acq.fund_combined_balance acqfcb ON (acqfcb.fund = acqf.id)
+        ]]></oils_persist:source_definition>
+        <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_id_seq">
+            <field reporter:label="Fund ID" name="id" reporter:datatype="id" reporter:selector='code'/>
+            <field reporter:label="Org Unit" name="org" reporter:datatype="org_unit" />
+            <field reporter:label="Name" name="name" reporter:datatype="text" />
+            <field reporter:label="Year" name="year" reporter:datatype="int" />
+            <field reporter:label="Currency Type" name="currency_type" reporter:datatype="link" />
+            <field reporter:label="Code" name="code" reporter:datatype="text" />
+            <field reporter:label="Rollover" name="rollover" reporter:datatype="bool" />
+            <field reporter:label="Propagate" name="propagate" reporter:datatype="bool" />
+            <field reporter:label="Active" name="active" reporter:datatype="bool" />
+            <field reporter:label="Balance Warning Percent" name="balance_warning_percent" reporter:datatype="int" />
+            <field reporter:label="Balance Stop Percent" name="balance_stop_percent" reporter:datatype="int" />
+
+            <!-- non fund-native fields -->
+            <field reporter:label="Total Allocated" name="allocated_total" reporter:datatype="money"/>
+            <field reporter:label="Total Spent" name="spent_total" reporter:datatype="money"/>
+            <field reporter:label="Total Encumbered" name="encumbrance_total" reporter:datatype="money"/>
+            <field reporter:label="Remaining Balance" name="combined_balance" reporter:datatype="money"/>
+        </fields>
+        <links>
+            <link field="id" reltype="has_a" key="id" map="" class="acqf"/>
+            <link field="org" reltype="has_a" key="id" map="" class="aou"/>
+            <link field="currency_type" reltype="has_a" key="code" map="" class="acqct"/>
+        </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="org"/>
+            </actions>
+        </permacrud>
        </class>
-
        <class id="acqfa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund_allocation" oils_persist:tablename="acq.fund_allocation" reporter:label="Fund Allocation">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_allocation_id_seq">
                        <field reporter:label="Allocation ID" name="id" reporter:datatype="id" />
@@ -6970,8 +8140,8 @@ SELECT  usr,
                <fields oils_persist:primary="id" oils_persist:sequence="acq.cancel_reason_id_seq">
                        <field reporter:label="ID" name="id" reporter:datatype="id" reporter:selector='label'/>
                        <field reporter:label="Using Library" name="org_unit" reporter:datatype="org_unit"/>
-                       <field reporter:label="Label" name="label" reporter:datatype="text"/>
-                       <field reporter:label="Description" name="description" reporter:datatype="text"/>
+                       <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
+                       <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                        <field reporter:label="Keep Debits?" name="keep_debits" reporter:datatype="bool"/>
                </fields>
                <links>
@@ -7288,6 +8458,7 @@ SELECT  usr,
                        <field reporter:label="Name" name="attr_name" reporter:datatype="text" />
                        <field reporter:label="Value" name="attr_value" reporter:datatype="text" />
                        <field reporter:label="Definition" name="definition" reporter:datatype="text" />
+                       <field reporter:label="Order Identifier" name="order_ident" reporter:datatype="bool" />
                </fields>
                <links>
                        <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
@@ -7307,7 +8478,7 @@ SELECT  usr,
                        <field reporter:label="Fund" name="fund" reporter:datatype="link" />
                        <field reporter:label="Fund Debit" name="fund_debit" reporter:datatype="link" />
                        <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit" />
-                       <field reporter:label="Shelving Location" name="location" reporter:datatype="link" />
+                       <field reporter:label="Copy Location" name="location" reporter:datatype="link" />
                        <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="link" />
                        <field reporter:label="Note" name="note" reporter:datatype="text" />
                        <field reporter:label="Collection Code" name="collection_code" reporter:datatype="text" />
@@ -7653,7 +8824,7 @@ SELECT  usr,
                        <link field="folder" reltype="has_a" key="id" map="" class="rof"/>
                </links>
        </class>
-       <class id="rmsr" controller="open-ils.reporter-store open-ils.cstore" oils_obj:fieldmapper="reporter::materialized_simple_record" oils_persist:tablename="reporter.materialized_simple_record" reporter:label="Fast Simple Record Extracts">
+       <class id="rmsr" controller="open-ils.reporter-store open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="reporter::materialized_simple_record" oils_persist:tablename="reporter.materialized_simple_record" reporter:label="Fast Simple Record Extracts">
                <fields oils_persist:primary="id">
                        <field reporter:label="Record ID" name="id" reporter:datatype="id" />
                        <field reporter:label="Fingerprint" name="fingerprint" reporter:datatype="text"/>
@@ -7671,6 +8842,11 @@ SELECT  usr,
                <links>
                        <link field="biblio_record" reltype="might_have" key="id" map="" class="bre"/>
                </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve />
+                       </actions>
+               </permacrud>
        </class>
        <class id="rssr" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::super_simple_record" oils_persist:tablename="reporter.super_simple_record" reporter:label="Simple Record Extracts">
                <fields oils_persist:primary="id">
@@ -7796,7 +8972,7 @@ SELECT  usr,
        </class>
        <class id="acqdf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::distribution_formula" oils_persist:tablename="acq.distribution_formula" reporter:label="Distribution Formula">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.distribution_formula_id_seq">
-                       <field reporter:label="Formula ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Formula ID" name="id" reporter:datatype="id" reporter:selector="name" />
                        <field reporter:label="Formula Owner" name="owner" reporter:datatype="org_unit"/>
                        <field reporter:label="Formula Name" name="name" reporter:datatype="text"/>
                        <field reporter:label="Skip Count" name="skip_count" reporter:datatype="int"/>
@@ -7824,11 +9000,16 @@ SELECT  usr,
                        <field reporter:label="Item Count" name="item_count" reporter:datatype="int"/>
                        <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
                        <field reporter:label="Location" name="location" reporter:datatype="link"/>
+                       <field reporter:label="Fund" name="fund" reporter:datatype="link"/>
+                       <field reporter:label="Circulation Modifier" name="circ_modifier" reporter:datatype="link"/>
+                       <field reporter:label="Collection Code" name="collection_code" reporter:datatype="text"/>
                </fields>
                <links>
                        <link field="formula" reltype="has_a" key="id" map="" class="acqdf"/>
                        <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
+                       <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
+                       <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
                </links>
                <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
                        <actions>
@@ -8040,9 +9221,9 @@ SELECT  usr,
        </class>
 
     <class id="stgu" controller="open-ils.cstore" oils_obj:fieldmapper="staging::user_stage" oils_persist:tablename="staging.user_stage" reporter:label="User Stage">
-        <fields oils_persist:primary="row_id" oils_persist:sequence="staging.usr_stage_row_id_seq">
+        <fields oils_persist:primary="row_id" oils_persist:sequence="staging.user_stage_row_id_seq">
             <field reporter:label="Row ID" name="row_id" reporter:datatype="id"/>
-            <field reporter:label="Row Date" name="row_date" reporter:datatype="timestamp"/>
+            <field reporter:label="Create Date" name="row_date" reporter:datatype="timestamp"/>
             <field reporter:label="User Name" name="usrname" reporter:datatype="text"/>
             <field reporter:label="Main (Profile) Permission Group" name="profile" reporter:datatype="text"/>
             <field reporter:label="Email Address" name="email" reporter:datatype="text"/>
@@ -8056,7 +9237,11 @@ SELECT  usr,
             <field reporter:label="Home Library" name="home_ou" reporter:datatype="int"/>
             <field reporter:label="Date of Birth" name="dob" reporter:datatype="text"/>
             <field reporter:label="Complete" name="complete" reporter:datatype="bool"/>
+            <field reporter:label="Requesting User" name="requesting_usr" reporter:datatype="link"/>
         </fields>
+        <links>
+            <link field="requesting_usr" reltype="has_a" key="id" map="" class="au"/>
+        </links>
     </class>
 
     <class id="stgc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="staging::card_stage" oils_persist:tablename="staging.card_stage" reporter:label="Card Stage">
@@ -8077,6 +9262,7 @@ SELECT  usr,
             <field reporter:label="Street (1)" name="street1" reporter:datatype="text"/>
             <field reporter:label="Street (2)" name="street2" reporter:datatype="text"/>
             <field reporter:label="City" name="city" reporter:datatype="text"/>
+            <field reporter:label="County" name="county"  reporter:datatype="text"/>
             <field reporter:label="State" name="state" reporter:datatype="text"/>
             <field reporter:label="Country" name="country" reporter:datatype="text"/>
             <field reporter:label="Postal Code" name="post_code" reporter:datatype="text"/>
@@ -8085,13 +9271,14 @@ SELECT  usr,
     </class>
 
     <class id="stgba" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="staging::billing_address_stage" oils_persist:tablename="staging.billing_address_stage" reporter:label="Billing Address Stage">
-        <fields oils_persist:primary="row_id" oils_persist:sequence="staging.billing_address_stage_row_id_seq">
+        <fields oils_persist:primary="row_id" oils_persist:sequence="staging.mailing_address_stage_row_id_seq">
             <field reporter:label="Row ID" name="row_id" reporter:datatype="id"/>
             <field reporter:label="Row Date" name="row_date" reporter:datatype="timestamp"/>
             <field reporter:label="User Name" name="usrname" reporter:datatype="text"/>
             <field reporter:label="Street (1)" name="street1" reporter:datatype="text"/>
             <field reporter:label="Street (2)" name="street2" reporter:datatype="text"/>
             <field reporter:label="City" name="city" reporter:datatype="text"/>
+            <field reporter:label="County" name="county"  reporter:datatype="text"/>
             <field reporter:label="State" name="state" reporter:datatype="text"/>
             <field reporter:label="Country" name="country" reporter:datatype="text"/>
             <field reporter:label="Postal Code" name="post_code" reporter:datatype="text"/>
@@ -8733,6 +9920,298 @@ SELECT  usr,
                </permacrud>
        </class>
 
+    <class
+        id="uvs"
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper="url_verify::session"
+        oils_persist:tablename="url_verify.session"
+        reporter:label="URL Verification Session"
+    >
+        <fields oils_persist:primary="id" oils_persist:sequence="url_verify.session_id_seq">
+            <field reporter:label="Session ID" name="id" reporter:datatype="id"/>
+            <field reporter:label="Name" name="name" reporter:datatype="text" oils_obj:required="true"/>
+                       <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit" oils_obj:required="true"/>
+            <field reporter:label="Creator" name="creator" reporter:datatype="link" oils_obj:required="true"/>
+            <field reporter:label="Record Container" name="container" reporter:datatype="link" oils_obj:required="true"/>
+            <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp"/>
+            <field reporter:label="Search Constraints" name="search" reporter:datatype="text" oils_obj:required="true"/>
+            <field reporter:label="URL Selectors" name="selectors" reporter:datatype="link" oils_persist:virtual="true"/>
+            <field reporter:label="Verification Attempts" name="attempts" reporter:datatype="link" oils_persist:virtual="true"/>
+        </fields>
+
+        <links>
+            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
+            <link field="creator" reltype="has_a" key="id" map="" class="au"/>
+            <link field="container" reltype="has_a" key="id" map="" class="cbreb"/>
+            <link field="selectors" reltype="has_many" key="session" map="" class="uvus"/>
+            <link field="attempts" reltype="has_many" key="session" map="" class="uvva"/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="URL_VERIFY" context_field="owning_lib"/>
+            </actions>
+        </permacrud>
+
+    </class>
+
+    <class id="uvsbrem" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="url_verify::session_biblio_record_entry_map" oils_persist:readonly="true" reporter:label="URL Verify Session Biblio Record Entry Map">
+        <oils_persist:source_definition>
+            SELECT
+                cbrebi.id AS id,  -- so we can have a pkey in our view
+                uvs.id AS session,
+                uvs.owning_lib,
+                cbrebi.target_biblio_record_entry
+            FROM url_verify.session uvs
+            JOIN container.biblio_record_entry_bucket cbreb
+                ON (uvs.container = cbreb.id)
+            JOIN container.biblio_record_entry_bucket_item cbrebi
+                ON (cbrebi.bucket = cbreb.id)
+        </oils_persist:source_definition>
+        <fields oils_persist:primary="id" oils_persist:sequence="container.biblio_record_entry_bucket_item_id_seq">
+            <field reporter:label="Bucket Item ID" name="id" reporter:datatype="id" />
+            <field reporter:label="Session" name="session" reporter:datatype="link" />
+            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit" />
+            <field reporter:label="Target Biblio Record Entry" name="target_biblio_record_entry" reporter:datatype="link" />
+        </fields>
+        <links>
+            <link field="target_biblio_record_entry" reltype="has_a" key="id" map="" class="bre" />
+            <link field="session" reltype="has_a" key="id" map="" class="uvs" />
+            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou" />
+        </links>
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <retrieve permission="URL_VERIFY" context_field="owning_lib" />
+            </actions>
+        </permacrud>
+    </class>
+
+    <class
+        id="uvus"
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper="url_verify::url_selector"
+        oils_persist:tablename="url_verify.url_selector"
+        reporter:label="URL Verification URL Selector"
+    >
+        <fields oils_persist:primary="id" oils_persist:sequence="url_verify.url_selector_id_seq">
+            <field reporter:label="URL Selector ID" name="id" reporter:datatype="id"/>
+            <field reporter:label="XPath" name="xpath" reporter:datatype="text" oils_obj:required="true"/>
+                       <field reporter:label="Session" name="session" reporter:datatype="link" oils_obj:required="true"/>
+            <field reporter:label="URLs" name="urls" reporter:datatype="link" oils_persist:virtual="true"/>
+        </fields>
+
+        <links>
+            <link field="session" reltype="has_a" key="id" map="" class="uvs"/>
+            <link field="urls" reltype="has_many" key="id" map="" class="uvu"/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </create>
+                <retrieve permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </retrieve>
+                <update permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </update>
+                <delete permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </delete>
+            </actions>
+        </permacrud>
+
+    </class>
+
+    <class
+        id="uvu"
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper="url_verify::url"
+        oils_persist:tablename="url_verify.url"
+        reporter:label="URL Verification URL"
+    >
+        <fields oils_persist:primary="id" oils_persist:sequence="url_verify.url_id_seq">
+            <field reporter:label="URL ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Redirected From" name="redirect_from" reporter:datatype="link"/>
+                       <field reporter:label="Container Item" name="item" reporter:datatype="link" oils_obj:required="true"/>
+                       <field reporter:label="Session" name="session" reporter:datatype="link" oils_obj:required="true"/>
+                       <field reporter:label="URL Selector" name="url_selector" reporter:datatype="link"/>
+            <field reporter:label="Tag" name="tag" reporter:datatype="text"/>
+            <field reporter:label="Subfield" name="subfield" reporter:datatype="text"/>
+            <field reporter:label="Ordinal Position" name="ord" reporter:datatype="int"/>
+            <field reporter:label="URL" name="full_url" reporter:datatype="text"/>
+            <field reporter:label="Scheme" name="scheme" reporter:datatype="text"/>
+            <field reporter:label="Host" name="host" reporter:datatype="text"/>
+            <field reporter:label="Domain" name="domain" reporter:datatype="text"/>
+            <field reporter:label="TLD" name="tld" reporter:datatype="text"/>
+            <field reporter:label="Path" name="path" reporter:datatype="text"/>
+            <field reporter:label="Page" name="page" reporter:datatype="text"/>
+            <field reporter:label="Query" name="query" reporter:datatype="text"/>
+            <field reporter:label="Fragment" name="fragment" reporter:datatype="text"/>
+            <field reporter:label="Verifications" name="verifications" reporter:datatype="link" oils_persist:virtual="true" />
+        </fields>
+
+        <links>
+            <link field="redirect_from" reltype="has_a" key="id" map="" class="uvu"/>
+            <link field="item" reltype="has_a" key="id" map="" class="uvsbrem" />
+            <link field="session" reltype="has_a" key="id" map="" class="uvs"/>
+            <link field="url_selector" reltype="has_a" key="id" map="" class="uvus"/>
+            <link field="verifications" reltype="has_many" key="url" map="" class="uvuv"/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </create>
+                <retrieve permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </retrieve>
+                <update permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </update>
+                <delete permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </delete>
+            </actions>
+        </permacrud>
+
+    </class>
+
+    <class
+        id="uvva"
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper="url_verify::verification_attempt"
+        oils_persist:tablename="url_verify.verification_attempt"
+        reporter:label="URL Verification Attempt"
+    >
+        <fields oils_persist:primary="id" oils_persist:sequence="url_verify.verification_attempt_id_seq">
+            <field reporter:label="Attempt ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="User" name="usr" reporter:datatype="link"/>
+                       <field reporter:label="Session" name="session" reporter:datatype="link"/>
+            <field reporter:label="Start Time" name="start_time" reporter:datatype="timestamp"/>
+            <field reporter:label="Finish Time" name="finish_time" reporter:datatype="timestamp"/>
+        </fields>
+
+        <links>
+            <link field="session" reltype="has_a" key="id" map="" class="uvs"/>
+            <link field="usr" reltype="has_a" key="id" map="" class="au"/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </create>
+                <retrieve permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </retrieve>
+                <update permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </update>
+                <delete permission="URL_VERIFY">
+                    <context link="session" field="owning_lib"/>
+                </delete>
+            </actions>
+        </permacrud>
+
+    </class>
+
+    <class
+        id="uvuv"
+        controller="open-ils.cstore open-ils.pcrud"
+        oils_obj:fieldmapper="url_verify::url_verification"
+        oils_persist:tablename="url_verify.url_verification"
+        reporter:label="URL Verification"
+    >
+        <fields oils_persist:primary="id" oils_persist:sequence="url_verify.url_verification_id_seq">
+            <field reporter:label="Verification ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="URL" name="url" reporter:datatype="link"/>
+                       <field reporter:label="Attempt" name="attempt" reporter:datatype="link"/>
+            <field reporter:label="Request Time" name="req_time" reporter:datatype="timestamp"/>
+            <field reporter:label="Result Time" name="res_time" reporter:datatype="timestamp"/>
+            <field reporter:label="Result Code" name="res_code" reporter:datatype="int"/>
+            <field reporter:label="Result Text" name="res_text" reporter:datatype="text"/>
+                       <field reporter:label="Redirected To" name="redirect_to" reporter:datatype="link"/>
+        </fields>
+
+        <links>
+            <link field="url" reltype="has_a" key="id" map="" class="uvu"/>
+            <link field="attempt" reltype="has_a" key="id" map="" class="uvva"/>
+            <link field="redirect_to" reltype="has_a" key="id" map="" class="uvu"/>
+        </links>
+
+        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+            <actions>
+                <create permission="URL_VERIFY">
+                    <context link="attempt" jump="session" field="owning_lib"/>
+                </create>
+                <retrieve permission="URL_VERIFY">
+                    <context link="attempt" jump="session" field="owning_lib"/>
+                </retrieve>
+                <update permission="URL_VERIFY">
+                    <context link="attempt" jump="session" field="owning_lib"/>
+                </update>
+                <delete permission="URL_VERIFY">
+                    <context link="attempt" jump="session" field="owning_lib"/>
+                </delete>
+            </actions>
+        </permacrud>
+
+    </class>
+
+       <class
+               id="cfdi"
+               controller="open-ils.cstore open-ils.pcrud"
+               oils_obj:fieldmapper="config::filter_dialog_interface"
+               oils_persist:tablename="config.filter_dialog_interface"
+               reporter:label="FilterDialog Interface">
+               <fields oils_persist:primary="key" oils_persist:sequence="config.filter_dialog_interface_pkey">
+                       <field reporter:label="Interface Key" name="key" reporter:datatype="text" />
+                       <field reporter:label="Description" name="description" reporter:datatype="text" />
+               </fields>
+               <links>
+                       <link field="filter_sets" reltype="has_many" key="interface" map="" class="cfdfs"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve />
+                       </actions>
+               </permacrud>
+       </class>
+
+       <class
+               id="cfdfs"
+               controller="open-ils.cstore open-ils.pcrud"
+               oils_obj:fieldmapper="config::filter_dialog_filter_set"
+               oils_persist:tablename="config.filter_dialog_filter_set"
+               reporter:label="FilterDialog Filter Set">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.filter_dialog_filter_set_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Name" name="name" reporter:datatype="text"/>
+                       <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
+                       <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
+                       <field reporter:label="Interface" name="interface" reporter:datatype="link"/>
+                       <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp"/>
+                       <field reporter:label="Filters" name="filters" reporter:datatype="text"/>
+               </fields>
+               <links>
+                       <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
+                       <link field="creator" reltype="has_a" key="id" map="" class="au"/>
+                       <link field="interface" reltype="has_a" key="key" map="" class="cfdi"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="SAVED_FILTER_DIALOG_FILTERS" context_field="owning_lib"/>
+                               <retrieve permission="SAVED_FILTER_DIALOG_FILTERS" context_field="owning_lib"/>
+                               <update permission="SAVED_FILTER_DIALOG_FILTERS" context_field="owning_lib"/>
+                               <delete permission="SAVED_FILTER_DIALOG_FILTERS" context_field="owning_lib"/>
+                       </actions>
+               </permacrud>
+
+       </class>
+
        <class id="cmrtm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::marc21_rec_type_map" oils_persist:tablename="config.marc21_rec_type_map" reporter:label="MARC21 Record Type Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="code">
                        <field reporter:label="Code" name="code" reporter:datatype="id"/>
@@ -8805,7 +10284,7 @@ SELECT  usr,
                         SELECT 
                             (SELECT id
                                 FROM biblio.record_entry 
-                                WHERE id = (SELECT record FROM asset.call_number WHERE id = call_number)
+                                WHERE id = (SELECT record FROM asset.call_number WHERE id = call_number and deleted is false)
                             ) AS "bre", 
                             COUNT(*) AS "copy_count"
                         FROM asset.copy
@@ -8925,6 +10404,68 @@ SELECT  usr,
                </permacrud>
        </class>
 
+       <class id="ctcl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::ts_config_list" oils_persist:tablename="config.ts_config_list" reporter:label="Text Search Configs">
+               <fields oils_persist:primary="id">
+                       <field reporter:label="Text Search Config" reporter:selector="name" reporter:datatype="text" name="id"/>
+                       <field reporter:label="Text Search Config Name" reporter:datatype="text" name="name"/>
+               </fields>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <retrieve/>
+                       </actions>
+               </permacrud>
+       </class>
+
+       <class id="cmcts" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_class_ts_map" oils_persist:tablename="config.metabib_class_ts_map" reporter:label="Metabib Class TS Map">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.metabib_class_ts_map_id_seq">
+                       <field reporter:label="Map ID" reporter:datatype="id" name="id"/>
+                       <field reporter:label="Metabib Class" reporter:datatype="text" name="field_class"/>
+                       <field reporter:label="Text Search Config" reporter:datatype="text" name="ts_config"/>
+                       <field reporter:label="Active?" reporter:datatype="bool" name="active"/>
+                       <field reporter:label="Index Weight" reporter:datatype="text" name="index_weight"/>
+                       <field reporter:label="Index Language" reporter:datatype="text" name="index_lang"/>
+                       <field reporter:label="Search Language" reporter:datatype="text" name="search_lang"/>
+                       <field reporter:label="Always Apply?" reporter:datatype="bool" name="always"/>
+               </fields>
+               <links>
+                       <link field="field_class" reltype="has_a" key="name" map="" class="cmc"/>
+                       <link field="ts_config" reltype="has_a" key="id" map="" class="ctcl"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                               <retrieve/>
+                               <update permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                               <delete permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
+
+       <class id="cmfts" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_field_ts_map" oils_persist:tablename="config.metabib_field_ts_map" reporter:label="Metabib Field TS Map">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.metabib_field_ts_map_id_seq">
+                       <field reporter:label="Map ID" reporter:datatype="id" name="id"/>
+                       <field reporter:label="Metabib Field" reporter:datatype="text" name="metabib_field"/>
+                       <field reporter:label="Text Search Config" reporter:datatype="text" name="ts_config"/>
+                       <field reporter:label="Active?" reporter:datatype="bool" name="active"/>
+                       <field reporter:label="Index Weight" reporter:datatype="text" name="index_weight"/>
+                       <field reporter:label="Index Language" reporter:datatype="text" name="index_lang"/>
+                       <field reporter:label="Search Language" reporter:datatype="text" name="search_lang"/>
+               </fields>
+               <links>
+                       <link field="metabib_field" reltype="has_a" key="id" map="" class="cmf"/>
+                       <link field="ts_config" reltype="has_a" key="id" map="" class="ctcl"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                               <retrieve/>
+                               <update permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                               <delete permission="ADMIN_INDEX_NORMALIZER" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
+
+
        <!-- ********************************************************************************************************************* -->
        <!-- What follows is a set of example extensions that are useful for PINES.  Comment out or remove if you don't want them. -->
        <!-- ********************************************************************************************************************* -->
@@ -9103,64 +10644,34 @@ SELECT  usr,
                        <link field="claim_policy_action" reltype="has_a" key="id" map="" class="acqclpa"/>
                </links>
        </class>
-
-       <class id="acqlisum" controller="open-ils.cstore" oils_obj:fieldmapper="acq::lineitem_summary" oils_persist:readonly="true" reporter:label="Lineitem Summary">
+       <class id="acqlisum" controller="open-ils.cstore" oils_obj:fieldmapper="acq::lineitem_summary" oils_persist:readonly="true" reporter:label="Lineitem Summary" oils_persist:tablename="acq.lineitem_summary">
+               <fields oils_persist:primary="lineitem" oils_persist:sequence="acq.lineitem_id_seq">
+                       <field reporter:label="Lineitem" name="lineitem" reporter:datatype="link"/>
+                       <field reporter:label="Item Count" name="item_count" reporter:datatype="int"/>
+                       <field reporter:label="Receive Count" name="recv_count" reporter:datatype="int"/>
+                       <field reporter:label="Cancel Count" name="cancel_count" reporter:datatype="int"/>
+                       <field reporter:label="Delay Count" name="delay_count" reporter:datatype="int"/>
+                       <field reporter:label="Invoice Count" name="invoice_count" reporter:datatype="int"/>
+                       <field reporter:label="Claim Count" name="claim_count" reporter:datatype="int"/>
+                       <field reporter:label="Estimated Amount" name="estimated_amount" reporter:datatype="money"/>
+                       <field reporter:label="Encumbrance Amount" name="encumbrance_amount" reporter:datatype="money"/>
+                       <field reporter:label="Paid Amount" name="paid_amount" reporter:datatype="money"/>
+               </fields>
+               <links>
+                       <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
+               </links>
+    </class>
+       <class id="acqlisumi" controller="open-ils.cstore" oils_obj:fieldmapper="acq::lineitem_summary_invoiceable" oils_persist:readonly="true" reporter:label="Invoiceable Lineitem Summary">
                <oils_persist:source_definition>
-
-            SELECT 
-                li.id AS lineitem, 
-                (
-                    SELECT COUNT(lid.id) 
-                    FROM acq.lineitem_detail lid
-                    WHERE lineitem = li.id
-                ) AS item_count,
-                (
-                    SELECT COUNT(lid.id) 
-                    FROM acq.lineitem_detail lid
-                    WHERE recv_time IS NOT NULL AND lineitem = li.id
-                ) AS recv_count,
-                (
-                    SELECT COUNT(lid.id) 
-                    FROM acq.lineitem_detail lid
-                    WHERE cancel_reason IS NOT NULL AND lineitem = li.id
-                ) AS cancel_count,
-                (
-                    SELECT COUNT(lid.id) 
-                    FROM acq.lineitem_detail lid
-                        JOIN acq.fund_debit debit ON (lid.fund_debit = debit.id)
-                    WHERE NOT debit.encumbrance AND lineitem = li.id
-                ) AS invoice_count,
-                (
-                    SELECT COUNT(DISTINCT(lid.id)) 
-                    FROM acq.lineitem_detail lid
-                        JOIN acq.claim claim ON (claim.lineitem_detail = lid.id)
-                    WHERE lineitem = li.id
-                ) AS claim_count,
-                (
-                    SELECT (COUNT(lid.id) * li.estimated_unit_price)::NUMERIC(8,2)
-                    FROM acq.lineitem_detail lid
-                    WHERE lid.cancel_reason IS NULL AND lineitem = li.id
-                ) AS estimated_amount,
-                (
-                    SELECT SUM(debit.amount)::NUMERIC(8,2)
-                    FROM acq.lineitem_detail lid
-                        JOIN acq.fund_debit debit ON (lid.fund_debit = debit.id)
-                    WHERE debit.encumbrance AND lineitem = li.id
-                ) AS encumbrance_amount,
-                (
-                    SELECT SUM(debit.amount)::NUMERIC(8,2)
-                    FROM acq.lineitem_detail lid
-                        JOIN acq.fund_debit debit ON (lid.fund_debit = debit.id)
-                    WHERE NOT debit.encumbrance AND lineitem = li.id
-                ) AS paid_amount
-
-                FROM acq.lineitem AS li
+            SELECT * FROM acq.lineitem_summary 
+                               WHERE item_count > (invoice_count + cancel_count)
         </oils_persist:source_definition>
                <fields oils_persist:primary="lineitem" oils_persist:sequence="acq.lineitem_id_seq">
                        <field reporter:label="Lineitem" name="lineitem" reporter:datatype="link"/>
                        <field reporter:label="Item Count" name="item_count" reporter:datatype="int"/>
                        <field reporter:label="Receive Count" name="recv_count" reporter:datatype="int"/>
                        <field reporter:label="Cancel Count" name="cancel_count" reporter:datatype="int"/>
+                       <field reporter:label="Delay Count" name="delay_count" reporter:datatype="int"/>
                        <field reporter:label="Invoice Count" name="invoice_count" reporter:datatype="int"/>
                        <field reporter:label="Claim Count" name="claim_count" reporter:datatype="int"/>
                        <field reporter:label="Estimated Amount" name="estimated_amount" reporter:datatype="money"/>
@@ -9171,8 +10682,6 @@ SELECT  usr,
                        <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
                </links>
     </class>
-
-
        <class id="iatc" controller="open-ils.reporter-store" oils_obj:fieldmapper="action::intersystem_transit_copy" oils_persist:readonly="true" reporter:core="true" reporter:label="Inter-system Copy Transit">
                <oils_persist:source_definition>
 
@@ -9218,7 +10727,7 @@ SELECT  usr,
                        asset.copy cp
                                JOIN action.circulation circ ON (cp.id = circ.target_copy)
                GROUP BY 1, 3, 4
-               UNION
+               UNION ALL
                SELECT
                        cp.id as copy,
                        COUNT(circ.id),
@@ -9228,7 +10737,7 @@ SELECT  usr,
                        asset.copy cp
                                JOIN action.aged_circulation circ ON (cp.id = circ.target_copy)
                GROUP BY 1, 3, 4
-               UNION
+               UNION ALL
                SELECT
                        id as copy,
                        circ_count,
@@ -9311,7 +10820,7 @@ SELECT  usr,
         <fields oils_persist:primary="id">
             <field reporter:label="Title" name="title" reporter:datatype="text"/>
             <field reporter:label="Author" name="author" reporter:datatype="text"/>
-            <field reporter:label="Pubdate" name="pubdate" reporter:datatype="int"/>
+            <field reporter:label="Pubdate" name="pubdate" reporter:datatype="text"/>
             <field reporter:label="Copy ID" name="id" reporter:datatype="id"/>
             <field reporter:label="Price" name="price" reporter:datatype="money"/>
             <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
@@ -9346,6 +10855,7 @@ SELECT  usr,
         </fields>
         <links>
             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
+            <link field="id" reltype="has_a" key="id" map="" class="acp"/>
             <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
             <link field="creator" reltype="has_a" key="id" map="" class="au"/>
             <link field="age_protect" reltype="has_a" key="id" map="" class="crahp"/>
@@ -9479,6 +10989,69 @@ SELECT  usr,
                        </actions>
                </permacrud>
        </class>
+       <class id="acqmapinv" controller="open-ils.cstore" oils_obj:fieldmapper="acq::map_to_invoice" reporter:label="Acq Map to Invoice View" oils_persist:readonly="true">
+               <oils_persist:source_definition><![CDATA[
+               SELECT
+                       poi.purchase_order AS purchase_order,
+                       ii.invoice AS invoice,
+                       NULL AS lineitem,
+                       poi.id AS po_item,
+                       NULL AS picklist
+               FROM
+                       acq.po_item poi
+                       JOIN acq.invoice_item ii ON (ii.po_item = poi.id)
+               UNION SELECT
+                       jub.purchase_order AS purchase_order,
+                       ie.invoice AS invoice,
+                       jub.id AS lineitem,
+                       NULL AS po_item,
+                       jub.picklist AS picklist
+               FROM
+                       acq.lineitem jub
+                       JOIN acq.invoice_entry ie ON (ie.lineitem = jub.id)
+               UNION SELECT
+                       ii.purchase_order AS purchase_order,
+                       ii.invoice AS invoice,
+                       NULL AS lineitem,
+                       NULL AS po_item,
+                       NULL AS picklist
+               FROM
+                       acq.invoice_item ii
+               WHERE ii.po_item IS NULL
+               UNION SELECT
+                       ie.purchase_order AS purchase_order,
+                       ie.invoice AS invoice,
+                       NULL AS lineitem,
+                       NULL AS po_item,
+                       NULL AS picklist
+               FROM
+                       acq.invoice_entry ie
+               WHERE ie.lineitem IS NULL
+               UNION SELECT
+                       NULL AS purchase_order,
+                       NULL AS invoice,
+                       jub.id AS lineitem,
+                       NULL AS po_item,
+                       jub.picklist AS picklist
+               FROM
+                       acq.lineitem jub
+               WHERE jub.purchase_order IS NULL
+               ]]></oils_persist:source_definition>
+               <fields>
+                       <field reporter:label="Purchase Order ID" name="purchase_order" reporter:datatype="link"/>
+                       <field reporter:label="Lineitem ID" name="lineitem" reporter:datatype="link"/>
+                       <field reporter:label="Invoice ID" name="invoice" reporter:datatype="link"/>
+                       <field reporter:label="Purchase Order Item ID" name="po_item" reporter:datatype="link"/>
+                       <field reporter:label="Picklist ID" name="picklist" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo" />
+                       <link field="lineitem" reltype="has_a" key="id" map="" class="jub" />
+                       <link field="invoice" reltype="has_a" key="id" map="" class="acqinv" />
+                       <link field="po_item" reltype="has_a" key="id" map="" class="acqpoi" />
+                       <link field="picklist" reltype="has_a" key="id" map="" class="acqpl" />
+               </links>
+       </class>
        <class id="cbc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::barcode_completion" oils_persist:tablename="config.barcode_completion" reporter:label="Barcode Completions">
                <fields oils_persist:primary="id" oils_persist:sequence="config.barcode_completion_id_seq">
                        <field reporter:label="ID" name="id" reporter:datatype="id"/>
@@ -9551,7 +11124,47 @@ SELECT  usr,
                        <link field="stat_cat" reltype="has_a" key="id" map="" class="asc"/>
                </links>
        </class>
-
+       <class id="cfg" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::floating_group" oils_persist:tablename="config.floating_group" reporter:label="Floating Group">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.floating_group_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Name" name="name" reporter:datatype="text"/>
+                       <field reporter:label="Manual" name="manual" reporter:datatype="bool"/>
+                       <field reporter:label="Group Members" name="members" oils_persist:virtual="true" reporter:datatype="link"/>
+               </fields>
+               <links>
+                       <link field="members" reltype="has_many" key="floating_group" class="cfgm"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                               <retrieve/>
+                               <update permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                               <delete permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
+       <class id="cfgm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::floating_group_member" oils_persist:tablename="config.floating_group_member" reporter:label="Floating Group Members">
+               <fields oils_persist:primary="id" oils_persist:sequence="config.floating_group_member_id_seq">
+                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
+                       <field reporter:label="Floating Group" name="floating_group" reporter:datatype="link"/>
+                       <field reporter:label="Org Unit" name="org_unit" reporter:datatype="link"/>
+                       <field reporter:label="Stop Depth" name="stop_depth" reporter:datatype="int"/>
+                       <field reporter:label="Max Depth" name="max_depth" reporter:datatype="int"/>
+                       <field reporter:label="Exclude" name="exclude" reporter:datatype="bool"/>
+               </fields>
+               <links>
+                       <link field="floating_group" reltype="has_a" key="id" class="cfg"/>
+                       <link field="org_unit" reltype="has_a" key="id" class="aou"/>
+               </links>
+               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
+                       <actions>
+                               <create permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                               <retrieve/>
+                               <update permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                               <delete permission="ADMIN_FLOAT_GROUPS" global_required="true"/>
+                       </actions>
+               </permacrud>
+       </class>
 
        <!-- ********************************************************************************************************************* -->