Step 1 in IDL speedup: Use the fm_IDL.xml from assets instead of
authorkenstir <kenstir@gmail.com>
Sat, 2 Nov 2013 22:59:36 +0000 (18:59 -0400)
committerkenstir <kenstir@gmail.com>
Sat, 2 Nov 2013 22:59:36 +0000 (18:59 -0400)
downloading; shrink fm_IDL.xml by removing unused elements.  Under the
emulator parsing the IDL is ridiculously slow (35s).  Still loads of work
to do; it's only slightly faster on the emulator (30s) and still
noticeably slow on hardware (~5s).

Removed openils_idl.jar and instead put the modified sources under
Android/src/java/org/open_ils/.  Nat at least it's obvious that it's
modified version of the code in Open-ILS/src/java.  It's modified because
the javax.xml.stream parser is not available on Android and was replaced
with an xmlpull parser.

15 files changed:
Open-ILS/src/Android/.classpath
Open-ILS/src/Android/assets/fm_IDL.xml
Open-ILS/src/Android/libs/org.openils_idl.jar [deleted file]
Open-ILS/src/Android/src/org/evergreen/android/globals/GlobalConfigs.java
Open-ILS/src/Android/src/org/evergreen/android/views/ApplicationPreferences.java
Open-ILS/src/Android/src/org/open_ils/Event.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/Sys.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/idl/IDLException.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/idl/IDLField.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/idl/IDLLink.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/idl/IDLObject.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/idl/IDLParser.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/test/TestIDL.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/test/TestLogin.java [new file with mode: 0644]
Open-ILS/src/Android/src/org/open_ils/util/Utils.java [new file with mode: 0644]

index fa0f7bc..35ddea7 100644 (file)
@@ -3,7 +3,6 @@
        <classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
        <classpathentry exported="true" kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
        <classpathentry kind="lib" path="libs/android-support-v4.jar"/>
-       <classpathentry kind="lib" path="libs/org.openils_idl.jar"/>
        <classpathentry kind="lib" path="libs/org.opensrf2_serialized_reg.jar"/>
        <classpathentry kind="lib" path="libs/simple-xml-2.6.4.jar"/>
        <classpathentry kind="lib" path="libs/zxing_barcode.jar"/>
index 88b1b71..aa984f2 100644 (file)
@@ -20,10 +20,9 @@ along with this program; if not, write to the Free Software
 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
 
 -->
-
 <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">
-
        <!-- Virtual classes -->
+<!--
        <class id="mups" controller="open-ils.cstore" oils_obj:fieldmapper="money::user_payment_summary" oils_persist:virtual="true" reporter:label="User Payment Summary">
                <fields>
                        <field name="usr" oils_persist:virtual="true" />
@@ -48,6 +47,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="workstation" reltype="has_a" key="id" map="" class="aws"/>
                </links>
        </class>
+-->
 
        <class id="brn" controller="open-ils.cstore" oils_obj:fieldmapper="biblio::record_node" oils_persist:virtual="true" reporter:label="Record Node">
                <fields>
@@ -153,14 +153,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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="ADMIN_MERGE_PROFILE CREATE_MERGE_PROFILE" context_field="owner"/>
-                               <retrieve permission="ADMIN_MERGE_PROFILE CREATE_MERGE_PROFILE UPDATE_MERGE_PROFILE DELETE_MERGE_PROFILE VIEW_MERGE_PROFILE" context_field="owner"/>
-                               <update permission="ADMIN_MERGE_PROFILE UPDATE_MERGE_PROFILE" context_field="owner"/>
-                               <delete permission="ADMIN_MERGE_PROFILE DELETE_MERGE_PROFILE" context_field="owner"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <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">
@@ -172,14 +164,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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"/>
-                               <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">
@@ -217,22 +201,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="definition" reltype="has_a" key="id" map="" class="viiad"/>
                        <link field="imported_as" reltype="has_a" key="id" map="" class="acp"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_IMPORT_ITEM">
-                    <context link="definition" field="owner"/>
-                               </create>
-                               <retrieve permission="CREATE_IMPORT_ITEM UPDATE_IMPORT_ITEM DELETE_IMPORT_ITEM">
-                    <context link="definition" field="owner"/>
-                               </retrieve>
-                               <update permission="UPDATE_IMPORT_ITEM">
-                    <context link="definition" field="owner"/>
-                               </update>
-                               <delete permission="DELETE_IMPORT_ITEM">
-                    <context link="definition" field="owner"/>
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="viiad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::import_item_attr_definition" oils_persist:tablename="vandelay.import_item_attr_definition" reporter:label="Import Item Attribute Definition">
@@ -265,14 +233,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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_ITEM_ATTR_DEF ADMIN_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
-                               <retrieve permission="CREATE_IMPORT_ITEM_ATTR_DEF UPDATE_IMPORT_ITEM_ATTR_DEF DELETE_IMPORT_ITEM_ATTR_DEF ADMIN_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
-                               <update permission="UPDATE_IMPORT_ITEM_ATTR_DEF ADMIN_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
-                               <delete permission="DELETE_IMPORT_ITEM_ATTR_DEF ADMIN_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vbq" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::bib_queue" oils_persist:tablename="vandelay.bib_queue" reporter:label="Import/Overlay Bib Queue">
@@ -290,14 +250,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <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"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vie" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::import_error" oils_persist:tablename="vandelay.import_error" reporter:label="Import/Overlay Error Definitions">
@@ -310,11 +262,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <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"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqbr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::queued_bib_record" oils_persist:tablename="vandelay.queued_bib_record" reporter:label="Queued Bib Record">
@@ -343,14 +290,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="matches" reltype="has_many" key="queued_record" map="" class="vbm"/>
             <link field="import_items" reltype="has_many" key="record" map="" class="vii"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqbrad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::bib_attr_definition" oils_persist:tablename="vandelay.bib_attr_definition" reporter:label="Queued Bib Record Attribute Definition">
@@ -362,14 +301,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Remove RegExp" name="remove" reporter:datatype="text"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_BIB_IMPORT_FIELD_DEF" global_required="true"/>
-                <retrieve/>
-                               <update permission="UPDATE_BIB_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
-                               <delete permission="DELETE_BIB_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqbra" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::queued_bib_record_attr" oils_persist:tablename="vandelay.queued_bib_record_attr" reporter:label="Queued Bib Record Attribute">
@@ -383,14 +314,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="record" reltype="has_a" key="id" map="" class="vqbr"/>
                        <link field="field" reltype="has_a" key="id" map="" class="vqbrad"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vbm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::bib_match" oils_persist:tablename="vandelay.bib_match" reporter:label="Queued Bib Record Match">
@@ -405,14 +328,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
                        <link field="eg_record" reltype="has_a" key="id" map="" class="bre"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vaq" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::authority_queue" oils_persist:tablename="vandelay.authority_queue" reporter:label="Import/Overlay Authority Queue">
@@ -428,14 +343,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="match_set" reltype="has_a" key="id" map="" class="vms"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqar" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::queued_authority_record" oils_persist:tablename="vandelay.queued_authority_record" reporter:label="Queued Authority Record">
@@ -460,14 +367,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="attributes" reltype="has_many" key="record" map="" class="vqara"/>
             <link field="matches" reltype="has_many" key="queued_record" map="" class="vam"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqarad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::authority_attr_definition" oils_persist:tablename="vandelay.authority_attr_definition" reporter:label="Queued Authority Record Attribute Definition">
@@ -479,14 +378,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Remove RegExp" name="remove" reporter:datatype="text"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
-                <retrieve/>
-                               <update permission="UPDATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
-                               <delete permission="DELETE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vqara" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::queued_authority_record_attr" oils_persist:tablename="vandelay.queued_authority_record_attr" reporter:label="Queued Authority Record Attribute">
@@ -500,14 +391,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="record" reltype="has_a" key="id" map="" class="vqar"/>
                        <link field="field" reltype="has_a" key="id" map="" class="vqarad"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vam" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::authority_match" oils_persist:tablename="vandelay.authority_match" reporter:label="Queued Authority Record Match">
@@ -521,14 +404,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
                        <link field="eg_record" reltype="has_a" key="id" map="" class="bre"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                               <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vms" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::match_set" oils_persist:tablename="vandelay.match_set" reporter:label="Record Matching Definition Set">
@@ -541,14 +416,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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="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>
-               </permacrud>
        </class>
 
        <class id="vmsp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::match_set_point" oils_persist:tablename="vandelay.match_set_point" reporter:label="Record Matching Definition">
@@ -570,22 +437,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="svf" reltype="has_a" key="id" map="" class="crad"/>
                        <link field="children" reltype="has_many" key="parent" map="" class="vmsp"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </create>
-                               <retrieve permission="ADMIN_IMPORT_MATCH_SET VIEW_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </retrieve>
-                               <update permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </update>
-                               <delete permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="vmsq" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="vandelay::match_set_quality" oils_persist:tablename="vandelay.match_set_quality" reporter:label="Record Quality Metric">
@@ -601,22 +452,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="match_set" reltype="has_a" key="id" map="" class="vms"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </create>
-                               <retrieve permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </retrieve>
-                               <update permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </update>
-                               <delete permission="ADMIN_IMPORT_MATCH_SET">
-                    <context link="match_set" field="owner"/>
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="auoi" controller="open-ils.cstore" oils_obj:fieldmapper="actor::usr_org_unit_opt_in" oils_persist:tablename="actor.usr_org_unit_opt_in" reporter:label="User Sharing Opt-in">
@@ -643,14 +478,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Value" name="value"  reporter:datatype="text"/>
             <field reporter:label="Enabled" name="enabled"  reporter:datatype="bool"/>
         </fields>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_GLOBAL_FLAG" global_required="true"/>
-                <retrieve permission="ADMIN_GLOBAL_FLAG" global_required="true"/>
-                <update   permission="ADMIN_GLOBAL_FLAG" global_required="true"/>
-                <delete   permission="ADMIN_GLOBAL_FLAG" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="cin" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::index_normalizer" oils_persist:tablename="config.index_normalizer" reporter:label="Indexing Normalizer" oils_persist:field_safe="true">
@@ -661,14 +488,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Function" name="func"  reporter:datatype="text"/>
             <field reporter:label="Required Parameter Count" name="param_count"  reporter:datatype="int"/>
         </fields>
-        <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="cmfinm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_field_index_norm_map" oils_persist:tablename="config.metabib_field_index_norm_map" reporter:label="Metabib Field to Indexing Normalizer Map" oils_persist:field_safe="true">
@@ -683,14 +502,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
                        <link field="norm" reltype="has_a" key="id" map="" class="cin"/>
                </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="crad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::record_attr_definition" oils_persist:tablename="config.record_attr_definition" reporter:label="SVF Record Attribute Defintion" oils_persist:field_safe="true">
@@ -715,14 +526,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="format" reltype="has_a" key="name" map="" class="cxt"/>
                        <link field="normalizers" reltype="has_many" key="name" map="" class="crainm"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_SVF" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_SVF" global_required="true"/>
-                <delete permission="ADMIN_SVF" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="csc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::sms_carrier" oils_persist:tablename="config.sms_carrier" reporter:label="SMS Carrier" oils_persist:field_safe="true">
@@ -734,14 +537,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Email Gateway" name="email_gateway" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_SMS_CARRIER" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_SMS_CARRIER" global_required="true"/>
-                <delete permission="ADMIN_SMS_CARRIER" global_required="true"/>
-            </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">
@@ -752,11 +547,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="id" 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="crainm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::record_attr_index_norm_map" oils_persist:tablename="config.record_attr_index_norm_map" reporter:label="SVF Record Attribute to Indexing Normalizer Map" oils_persist:field_safe="true">
@@ -771,14 +561,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="attr" reltype="has_a" key="name" map="" class="crad"/>
                        <link field="norm" reltype="has_a" key="id" map="" class="cin"/>
                </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="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">
@@ -795,14 +577,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="ctype" reltype="has_a" key="name" map="" class="crad"/>
                </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="cracct" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::remote_account" oils_persist:tablename="config.remote_account" reporter:label="Remote (3rd party) Account">
@@ -820,14 +594,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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="ADMIN_CONFIG_REMOTE_ACCOUNT" context_field="owner"/>
-                <retrieve permission="ADMIN_CONFIG_REMOTE_ACCOUNT" context_field="owner"/>
-                <update   permission="ADMIN_CONFIG_REMOTE_ACCOUNT" context_field="owner"/>
-                <delete   permission="ADMIN_CONFIG_REMOTE_ACCOUNT" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
 
     <class id="czs" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::z3950_source" oils_persist:tablename="config.z3950_source" reporter:label="Z39.50 Source">
@@ -847,14 +613,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="attrs" reltype="has_many" key="source" map="" class="cza"/>
             <link field="use_perm" reltype="has_a" key="id" map="" class="ppl"/>
         </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="cza" controller="open-ils.cstore" oils_obj:fieldmapper="config::z3950_attr" oils_persist:tablename="config.z3950_attr" reporter:label="Z39.50 Attribute">
@@ -885,12 +643,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="events" reltype="has_many" key="template_output" map="" class="atev"/>
             <link field="error_events" reltype="has_many" key="error_output" map="" class="atev"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                               <delete permission="ADMIN_TRIGGER_TEMPLATE_OUTPUT DELETE_TRIGGER_TEMPLATE_OUTPUT" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="ath" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::hook" oils_persist:tablename="action_trigger.hook" reporter:label="Trigger Hook Point">
@@ -901,14 +653,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Passive" name="passive"  reporter:datatype="bool"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_HOOK CREATE_TRIGGER_HOOK" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_TRIGGER_HOOK UPDATE_TRIGGER_HOOK" global_required="true"/>
-                               <delete permission="ADMIN_TRIGGER_HOOK DELETE_TRIGGER_HOOK" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atcol" controller="open-ils.cstore" oils_obj:fieldmapper="action_trigger::collector" oils_persist:tablename="action_trigger.collector" reporter:label="Trigger Environment Collector">
@@ -925,14 +669,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_VALIDATOR CREATE_TRIGGER_VALIDATOR" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_TRIGGER_VALIDATOR UPDATE_TRIGGER_VALIDATOR" global_required="true"/>
-                               <delete permission="ADMIN_TRIGGER_VALIDATOR DELETE_TRIGGER_VALIDATOR" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atreact" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::reactor" oils_persist:tablename="action_trigger.reactor" reporter:label="Trigger Event Reactor">
@@ -941,14 +677,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_REACTOR CREATE_TRIGGER_REACTOR" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_TRIGGER_REACTOR UPDATE_TRIGGER_REACTOR" global_required="true"/>
-                               <delete permission="ADMIN_TRIGGER_REACTOR DELETE_TRIGGER_REACTOR" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atclean" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::cleanup" oils_persist:tablename="action_trigger.cleanup" reporter:label="Trigger Event Cleanup">
@@ -957,14 +685,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_CLEANUP CREATE_TRIGGER_CLEANUP" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_TRIGGER_CLEANUP UPDATE_TRIGGER_CLEANUP" global_required="true"/>
-                               <delete permission="ADMIN_TRIGGER_CLEANUP DELETE_TRIGGER_CLEANUP" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atenv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::environment" oils_persist:tablename="action_trigger.environment" reporter:label="Trigger Event Environment Entry">
@@ -979,22 +699,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="event_def" reltype="has_a" key="id" map="" class="atevdef"/>
                        <link field="collector" reltype="has_a" key="id" map="" class="atcol"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_EVENT_DEF CREATE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </create>
-                               <retrieve permission="ADMIN_TRIGGER_EVENT_DEF VIEW_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </retrieve>
-                               <update permission="ADMIN_TRIGGER_EVENT_DEF UPDATE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </update>
-                               <delete permission="ADMIN_TRIGGER_EVENT_DEF DELETE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atevdef" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::event_definition" oils_persist:tablename="action_trigger.event_definition" reporter:label="Trigger Event Definition">
@@ -1030,14 +734,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="params" reltype="has_many" key="event_def" map="" class="atevparam"/>
                        <link field="opt_in_setting" reltype="has_a" key="name" map="" class="cust"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_EVENT_DEF CREATE_TRIGGER_EVENT_DEF" context_field="owner"/>
-                               <retrieve permission="ADMIN_TRIGGER_EVENT_DEF VIEW_TRIGGER_EVENT_DEF" context_field="owner"/>
-                               <update permission="ADMIN_TRIGGER_EVENT_DEF UPDATE_TRIGGER_EVENT_DEF" context_field="owner"/>
-                               <delete permission="ADMIN_TRIGGER_EVENT_DEF DELETE_TRIGGER_EVENT_DEF" context_field="owner"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="atev" controller="open-ils.cstore" oils_obj:fieldmapper="action_trigger::event" oils_persist:tablename="action_trigger.event" reporter:label="Trigger Event Entry">
@@ -1075,22 +771,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="event_def" reltype="has_a" key="id" map="" class="atevdef"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_TRIGGER_EVENT_DEF CREATE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </create>
-                               <retrieve permission="ADMIN_TRIGGER_EVENT_DEF VIEW_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </retrieve>
-                               <update permission="ADMIN_TRIGGER_EVENT_DEF UPDATE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </update>
-                               <delete permission="ADMIN_TRIGGER_EVENT_DEF DELETE_TRIGGER_EVENT_DEF">
-                    <context link="event_def" field="owner"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="aws" controller="open-ils.cstore" oils_obj:fieldmapper="actor::workstation" oils_persist:tablename="actor.workstation" reporter:label="Workstation">
@@ -1118,14 +798,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Average Wait Time" name="avg_wait_time" reporter:datatype="interval"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MOD" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_CIRC_MOD" global_required="true"/>
-                <delete permission="ADMIN_CIRC_MOD" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="aiit" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::invoice_item_type" oils_persist:tablename="acq.invoice_item_type" reporter:label="Non-bibliographic Invoice Item Type" oils_persist:field_safe="true">
@@ -1135,14 +807,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Prorate?" name="prorate" reporter:datatype="bool"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_INVOICE_ITEM_TYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_INVOICE_ITEM_TYPE" global_required="true"/>
-                <delete permission="DELETE_INVOICE_ITEM_TYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqim" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::invoice_method" oils_persist:tablename="acq.invoice_method" reporter:label="Invoice Method used by Vendor" oils_persist:field_safe="true">
@@ -1151,14 +815,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Label" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_INVOICE_METHOD CREATE_INVOICE_METHOD" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_INVOICE_METHOD UPDATE_INVOICE_METHOD" global_required="true"/>
-                <delete permission="ADMIN_INVOICE_METHOD DELETE_INVOICE_METHOD" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="ccpbt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="container::copy_bucket_type" oils_persist:tablename="container.copy_bucket_type" reporter:label="Copy Bucket Type" oils_persist:field_safe="true">
@@ -1167,14 +823,6 @@ 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"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_COPY_BTYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_COPY_BTYPE" global_required="true"/>
-                <delete permission="DELETE_COPY_BTYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="ccnbt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="container::call_number_bucket_type" oils_persist:tablename="container.call_number_bucket_type" reporter:label="Call Number Bucket Type" oils_persist:field_safe="true">
@@ -1183,14 +831,6 @@ 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"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_CN_BTYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_CN_BTYPE" global_required="true"/>
-                <delete permission="DELETE_CN_BTYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="bpt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="biblio::peer_type" oils_persist:tablename="biblio.peer_type" reporter:label="Bibliographic Record Peer Type" oils_persist:field_safe="true">
@@ -1199,14 +839,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_BIB_PTYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_BIB_PTYPE" global_required="true"/>
-                <delete permission="DELETE_BIB_PTYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="bpbcm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="biblio::peer_bib_copy_map" oils_persist:tablename="biblio.peer_bib_copy_map" reporter:label="Bibliographic Record Peer Copy Map">
@@ -1221,20 +853,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="peer_record" reltype="has_a" key="id" map="" class="bre"/>
             <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
         </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="UPDATE_COPY">
-                    <context link="target_copy" field="circ_lib"/>
-                </create>
-                <retrieve/>
-                <update permission="UPDATE_COPY">
-                    <context link="target_copy" field="circ_lib"/>
-                </update>
-                <delete permission="UPDATE_COPY">
-                    <context link="target_copy" field="circ_lib"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="cbrebt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="container::biblio_record_entry_bucket_type" oils_persist:tablename="container.biblio_record_entry_bucket_type" reporter:label="Bibliographic Record Bucket Type" oils_persist:field_safe="true">
@@ -1243,14 +861,6 @@ 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"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_BIB_BTYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_BIB_BTYPE" global_required="true"/>
-                <delete permission="DELETE_BIB_BTYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="cubt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="container::user_bucket_type" oils_persist:tablename="container.user_bucket_type" reporter:label="User Bucket Type" oils_persist:field_safe="true">
@@ -1259,14 +869,6 @@ 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"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_USER_BTYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_USER_BTYPE" global_required="true"/>
-                <delete permission="DELETE_USER_BTYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="cvrfm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::videorecording_format_map" oils_persist:tablename="config.videorecording_format_map" reporter:label="Videorecording Format" oils_persist:field_safe="true">
@@ -1275,14 +877,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Format" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_MARC_CODE" global_required="true"/>
-                <delete permission="ADMIN_MARC_CODE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
     <class id="chmw" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::hold_matrix_weights" oils_persist:tablename="config.hold_matrix_weights" reporter:label="Hold Matrix Weights">
@@ -1306,14 +900,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Item Age &lt;" name="item_age" reporter:datatype="float"/>
         </fields>
         <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-                <delete permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="ccmw" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_matrix_weights" oils_persist:tablename="config.circ_matrix_weights" reporter:label="Circ Matrix Weights">
@@ -1338,14 +924,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Item Age &lt;" name="item_age" reporter:datatype="float"/>
         </fields>
         <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="cwa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::weight_assoc" oils_persist:tablename="config.weight_assoc" reporter:label="Matrix Weight Association">
@@ -1361,14 +939,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="circ_weights" reltype="has_a" key="id" map="" class="ccmw"/>
             <link field="hold_weights" reltype="has_a" key="id" map="" class="chmw"/>
         </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT ADMIN_HOLD_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <retrieve permission="ADMIN_CIRC_MATRIX_MATCHPOINT ADMIN_HOLD_MATRIX_MATCHPOINT VIEW_CIRC_MATRIX_MATCHPOINT VIEW_HOLD_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT ADMIN_HOLD_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT ADMIN_HOLD_MATRIX_MATCHPOINT" context_field='org_unit'/>
-            </actions>
-        </permacrud>
     </class>
 
        <class id="chmm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::hold_matrix_matchpoint" oils_persist:tablename="config.hold_matrix_matchpoint" reporter:label="Hold Matrix Matchpoint">
@@ -1413,14 +983,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="age_hold_protect_rule" reltype="has_a" key="id" map="" class="crahp"/>
             <link field="transit_range" reltype="has_a" key="id" map="" class="aout"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-                <retrieve permission="ADMIN_HOLD_MATRIX_MATCHPOINT VIEW_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-                <update permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-                <delete permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="ccmm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_matrix_matchpoint" oils_persist:tablename="config.circ_matrix_matchpoint" reporter:label="Circulation Matrix Matchpoint">
@@ -1470,14 +1032,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="recurring_fine_rule" reltype="has_a" key="id" map="" class="crrf"/>
             <link field="hard_due_date" reltype="has_a" key="id" map="" class="chdd"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <retrieve permission="ADMIN_CIRC_MATRIX_MATCHPOINT VIEW_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
-            </actions>
-        </permacrud>
        </class>
 
     <class id="cclg" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_limit_group" oils_persist:tablename="config.circ_limit_group" reporter:label="Circulation Limit Group">
@@ -1487,14 +1041,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Description" name="description" reporter:datatype="text"/>
         </fields>
         <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="ccls" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_limit_set" oils_persist:tablename="config.circ_limit_set" reporter:label="Circulation Limit Set">
@@ -1510,14 +1056,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
         <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="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field="owning_lib"/>
-                <retrieve/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field="owning_lib"/>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field="owning_lib"/>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="ccmlsm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_matrix_limit_set_map" oils_persist:tablename="config.circ_matrix_limit_set_map" reporter:label="Circulation Matrix Limit Set Map">
@@ -1532,20 +1070,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="matchpoint" reltype="has_a" key="id" map="" class="ccmm"/>
             <link field="limit_set" reltype="has_a" key="id" map="" class="ccls"/>
         </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
-                    <context link="matchpoint" field="org_unit"/>
-                </create>
-                <retrieve/>
-                <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
-                    <context link="matchpoint" field="org_unit"/>
-                </update>
-                <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT">
-                    <context link="matchpoint" field="org_unit"/>
-                </delete>
-            </actions>
-        </permacrud>
     </class>
 
     <class id="cclscmm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_limit_set_circ_mod_map" oils_persist:tablename="config.circ_limit_set_circ_mod_map" reporter:label="Circulation Limit Set Circ Mod Map">
@@ -1558,20 +1082,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="limit_set" reltype="has_a" key="id" map="" class="ccls"/>
             <link field="circ_mod" reltype="has_a" key="code" map="" class="ccm"/>
         </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">
@@ -1585,20 +1095,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="limit_set" reltype="has_a" key="id" map="" class="ccls"/>
             <link field="limit_group" reltype="has_a" key="id" map="" class="cclg"/>
         </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="cit" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::identification_type" oils_persist:tablename="config.identification_type" reporter:label="Identification Type">
@@ -1607,14 +1103,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Identification Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_IDENT_TYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_IDENT_TYPE" global_required="true"/>
-                <delete permission="ADMIN_IDENT_TYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="asvq" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::survey_question" oils_persist:tablename="action.survey_question" reporter:label="User Survey Question">
@@ -1630,21 +1118,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="responses" reltype="has_many" key="question" map="" class="asvr"/>
                        <link field="answers" reltype="has_many" key="question" map="" class="asva"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </create>
-                <retrieve/>
-                <update permission="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </update>
-                <delete permission="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </delete>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="">
                        <field reporter:label="Balance Owed" name="balance_owed" reporter:datatype="money"/>
@@ -1689,6 +1164,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">
                <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"/>
@@ -1790,16 +1266,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="dest" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="TRANSIT_COPY" context_field="owner">
-                    <context link="target_copy" field="circ_lib"/>
-                </create>
-                <retrieve/>
-                <update permission="UPDATE_TRANSIT" context_field="dest source"/>
-                <delete permission="DELETE_TRANSIT" context_field="dest source"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="asvr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::survey_response" oils_persist:tablename="action.survey_response" reporter:label="Survey Response">
                <fields oils_persist:primary="id" oils_persist:sequence="action.survey_response_id_seq">
@@ -1818,20 +1284,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="answer" reltype="has_a" key="id" map="" class="asva"/>
                        <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="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </create>
-                <retrieve/>
-                <update permission="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </update>
-                <delete permission="ADMIN_SURVEY">
-                    <context link="survey" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
        <class id="ccbi" controller="open-ils.cstore" oils_obj:fieldmapper="container::copy_bucket_item" oils_persist:tablename="container.copy_bucket_item" reporter:label="Copy Bucket Item">
                <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_item_id_seq">
@@ -1871,14 +1323,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="authority_fields" reltype="has_many" key="control_set" map="" class="acsaf"/>
                        <link field="thesauri" reltype="has_many" key="control_set" map="" class="at"/>
                </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="DELETE_AUTHORITY_CONTROL_SET" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acsaf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::control_set_authority_field" oils_persist:tablename="authority.control_set_authority_field" reporter:label="Authority Control Set Authority Field" oils_persist:field_safe="true">
@@ -1904,14 +1348,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="main_entry" reltype="has_a" key="id" map="" class="acsaf"/>
                        <link field="sub_entries" reltype="has_many" key="main_entry" map="" class="acsaf"/>
                </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="acsbf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::control_set_bib_field" oils_persist:tablename="authority.control_set_bib_field" reporter:label="Authority Control Set Bib Field" oils_persist:field_safe="true">
@@ -1923,14 +1359,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="authority_field" reltype="has_a" key="id" map="" class="acsaf"/>
                </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">
@@ -1943,14 +1371,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="control_set" reltype="has_a" key="id" map="" class="acs"/>
                </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="aba" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::browse_axis" oils_persist:tablename="authority.browse_axis" reporter:label="Authority Browse Axis" oils_persist:field_safe="true">
@@ -1967,14 +1387,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="fields" reltype="has_many" key="axis" map="field" class="abaafm"/>
                        <link field="maps" reltype="has_many" key="axis" map="" class="abaafm"/>
                </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="abaafm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::browse_axis_authority_field_map" oils_persist:tablename="authority.browse_axis_authority_field_map" reporter:label="Authority Browse Axis Field Map" oils_persist:field_safe="true">
@@ -1987,14 +1399,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <link field="field" reltype="has_a" key="id" map="" class="acsaf"/>
             <link field="axis" reltype="has_a" key="code" map="" class="aba"/>
         </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="are" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::record_entry" oils_persist:tablename="authority.record_entry" reporter:label="Authority Record Entry">
@@ -2024,14 +1428,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="bib_links" reltype="has_many" key="authority" map="" class="abl"/>
                        <link field="fixed_fields" reltype="might_have" key="record" map="" class="ard"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_MARC IMPORT_MARC" global_required="true"/>
-                               <retrieve/>
-                               <update permission="UPDATE_MARC" global_required="true"/>
-                               <delete permission="UPDATE_MARC" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
        <class id="ard" controller="open-ils.cstore" oils_obj:fieldmapper="authority::record_descriptor" oils_persist:tablename="authority.rec_descriptor" reporter:label="Authority Record Descriptor">
                <fields oils_persist:primary="id" oils_persist:sequence="authority.rec_descriptor_id_seq">
@@ -2063,14 +1459,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Language" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MARC_CODE" global_required="true"/>
-                <delete permission="DELETE_MARC_CODE" global_required="true"/>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
@@ -2109,14 +1497,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="XSLT" name="xslt" reporter:datatype="text" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_XML_TRANSFORM" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_XML_TRANSFORM" global_required="true"/>
-                <delete permission="DELETE_XML_TRANSFORM" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="cmsa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_search_alias" oils_persist:tablename="config.metabib_search_alias" reporter:label="Metabib Search Alias" oils_persist:field_safe="true">
@@ -2129,14 +1509,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="field_class" reltype="has_a" key="name" map="" class="cmc"/>
                        <link field="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_METABIB_SEARCH_ALIAS" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_METABIB_SEARCH_ALIAS" global_required="true"/>
-                <delete permission="DELETE_METABIB_SEARCH_ALIAS" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="cmc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::metabib_class" oils_persist:tablename="config.metabib_class" reporter:label="Metabib Class" oils_persist:field_safe="true">
@@ -2150,14 +1522,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="fields" reltype="has_many" key="name" map="" class="cmf"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_METABIB_CLASS" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_METABIB_CLASS" global_required="true"/>
-                <delete permission="DELETE_METABIB_CLASS" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <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">
@@ -2179,14 +1543,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="field_class" reltype="has_a" key="name" map="" class="cmc"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_METABIB_FIELD" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_METABIB_FIELD" global_required="true"/>
-                <delete permission="DELETE_METABIB_FIELD" 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">
@@ -2197,14 +1553,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="first_word" reporter:datatype="bool" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_BIBLIO_FINGERPRINT" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_BIBLIO_FINGERPRINT" global_required="true"/>
-                <delete permission="DELETE_BIBLIO_FINGERPRINT" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="cam" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::audience_map" oils_persist:tablename="config.audience_map" reporter:label="Audience Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="code" oils_persist:sequence="">
@@ -2213,14 +1561,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Audience" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MARC_CODE" global_required="true"/>
-                <delete permission="DELETE_MARC_CODE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="cifm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::item_form_map" oils_persist:tablename="config.item_form_map" reporter:label="Item Form Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="code" oils_persist:sequence="">
@@ -2228,14 +1568,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field reporter:label="Item Form" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_MARC_CODE" global_required="true"/>
-                <delete permission="ADMIN_MARC_CODE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
     <class id="acnc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::call_number_class" oils_persist:tablename="asset.call_number_class" reporter:label="Call number classification scheme">
         <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_class_id_seq">
@@ -2244,11 +1576,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
             <field reporter:label="Normalizer function" name="normalizer" reporter:datatype="text"/>
             <field reporter:label="Call number fields" name="field" reporter:datatype="text"/>
         </fields>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <retrieve/>
-            </actions>
-        </permacrud>
     </class>
        <class id="acns" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::call_number_suffix" oils_persist:tablename="asset.call_number_suffix" reporter:label="Call Number/Volume Suffix">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_suffix_id_seq">
@@ -2260,14 +1587,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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_VOLUME_SUFFIX" context_field="owning_lib"/>
-                <retrieve/>
-                <update permission="UPDATE_VOLUME_SUFFIX" context_field="owning_lib"/>
-                <delete permission="DELETE_VOLUME_SUFFIX" context_field="owning_lib"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="acnp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::call_number_prefix" oils_persist:tablename="asset.call_number_prefix" reporter:label="Call Number/Volume Prefix">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_prefix_id_seq">
@@ -2279,14 +1598,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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_VOLUME_PREFIX" context_field="owning_lib"/>
-                <retrieve/>
-                <update permission="UPDATE_VOLUME_PREFIX" context_field="owning_lib"/>
-                <delete permission="DELETE_VOLUME_PREFIX" context_field="owning_lib"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="acn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::call_number" oils_persist:tablename="asset.call_number" reporter:label="Call Number/Volume">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_id_seq">
@@ -2321,14 +1632,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="prefix" reltype="has_a" key="id" map="" class="acnp"/>
                        <link field="suffix" reltype="has_a" key="id" map="" class="acns"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_VOLUME" context_field="owning_lib"/>
-                <retrieve/>
-                <update permission="UPDATE_VOLUME" context_field="owning_lib"/>
-                <delete permission="DELETE_VOLUME" context_field="owning_lib"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="auri" controller="open-ils.cstore" oils_obj:fieldmapper="asset::uri" oils_persist:tablename="asset.uri" reporter:label="Electronic Access URI">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.uri_id_seq">
@@ -2373,13 +1676,6 @@ 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">
-                    <context link="usr" field="home_ou"/>
-                </retrieve>
-            </actions>
-        </permacrud>
        </class>
        <class id="mct" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="money::collections_tracker" oils_persist:tablename="money.collections_tracker" reporter:label="Collections Tracker">
                <fields oils_persist:primary="id" oils_persist:sequence="money.collections_tracker_id_seq">
@@ -2394,13 +1690,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="collector" reltype="has_a" key="id" map="" class="au"/>
                        <link field="location" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="money.collections_tracker.create" context_field="location"/>
-                <retrieve permission="money.collections_tracker.create" context_field="location"/> 
-                <delete permission="money.collections_tracker.create" context_field="location"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="bre" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="biblio::record_entry" oils_persist:tablename="biblio.record_entry" reporter:core="true" reporter:label="Bibliographic Record">
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry_id_seq">
@@ -2459,13 +1748,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="attrs" reltype="might_have" key="id" map="" class="mra"/>
                        <link field="source" reltype="has_a" key="id" map="" class="cbs"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MARC IMPORT_MARC" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MARC" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="aouhoo" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit::hours_of_operation" oils_persist:tablename="actor.hours_of_operation" reporter:label="Hours of Operation">
                <fields oils_persist:primary="id">
@@ -2489,14 +1771,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="id" reltype="might_have" key="id" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_HOURS_OF_OPERATION" context_field="id"/>
-                <retrieve/>
-                <update permission="UPDATE_HOURS_OF_OPERATION" context_field="id"/>
-                <delete permission="DELETE_HOURS_OF_OPERATION" context_field="id"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="bmp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="biblio::monograph_part" oils_persist:tablename="biblio.monograph_part" reporter:label="Monograph Parts" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.monograph_part_id_seq">
@@ -2508,14 +1782,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="record" reltype="has_a" key="id" map="" class="bre"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MONOGRAPH_PART" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MONOGRAPH_PART" global_required="true"/>
-                <delete permission="DELETE_MONOGRAPH_PART" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="acpm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_part_map" oils_persist:tablename="asset.copy_part_map" reporter:label="Copy Monograph Part Map">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_part_map_id_seq">
@@ -2527,14 +1793,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
                        <link field="part" reltype="has_a" key="id" map="" class="bmp"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="MAP_MONOGRAPH_PART" global_required="true"/>
-                <retrieve/>
-                <update permission="MAP_MONOGRAPH_PART" global_required="true"/>
-                <delete permission="MAP_MONOGRAPH_PART" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="aoucd" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit::closed_date" oils_persist:tablename="actor.org_unit_closed" reporter:label="Closed Dates">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_closed_id_seq">
@@ -2547,14 +1805,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_ORG_UNIT_CLOSING" context_field="org_unit"/>
-                <retrieve/>
-                <update permission="UPDATE_ORG_UNIT_CLOSING" context_field="org_unit"/>
-                <delete permission="DELETE_ORG_UNIT_CLOSING" context_field="org_unit"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="crcd" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::rules::circ_duration" oils_persist:tablename="config.rule_circ_duration" reporter:label="Circulation Duration Rule">
                <fields oils_persist:primary="id" oils_persist:sequence="config.rule_circ_duration_id_seq">
@@ -2567,14 +1817,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                </fields>
                <links>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_CIRC_DURATION" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_CIRC_DURATION" global_required="true"/>
-                <delete permission="DELETE_CIRC_DURATION" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="chdd" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::hard_due_date" oils_persist:tablename="config.hard_due_date" reporter:label="Hard Due Date">
@@ -2588,14 +1830,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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_CIRC_DURATION" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_CIRC_DURATION" global_required="true"/>
-                <delete permission="DELETE_CIRC_DURATION" global_required="true"/>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="chddv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::hard_due_date_values" oils_persist:tablename="config.hard_due_date_values" reporter:label="Hard Due Date Values">
@@ -2608,14 +1842,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="hard_due_date" reltype="has_a" key="id" map="" class="chdd"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_CIRC_DURATION" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_CIRC_DURATION" global_required="true"/>
-                <delete permission="DELETE_CIRC_DURATION" global_required="true"/>
-            </actions>
-               </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">
@@ -2747,11 +1973,6 @@ 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">
@@ -2764,14 +1985,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="enabled" reporter:label="Enabled" reporter:datatype="bool"/>
                        <field name="transient" reporter:label="Transient" reporter:datatype="bool"/>
         </fields>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_USER_ACTIVITY_TYPE" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_USER_ACTIVITY_TYPE" global_required="true"/>
-                               <delete permission="ADMIN_USER_ACTIVITY_TYPE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
        <class id="auact" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::usr_activity" oils_persist:tablename="actor.usr_activity" reporter:label="User Activity">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_activity_id_seq">
@@ -2784,13 +1997,6 @@ 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="etype" reltype="has_a" key="id" map="" class="cuat"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve permission="RUN_REPORTS">
-                                       <context link="usr" field="home_ou" />
-                               </retrieve>
-                       </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">
@@ -2806,26 +2012,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <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">
@@ -2833,14 +2019,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="label" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_USER_SETTING_GROUP" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_USER_SETTING_GROUP" global_required="true"/>
-                               <delete permission="ADMIN_USER_SETTING_GROUP" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
        <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">
@@ -2856,14 +2034,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="name" reltype="has_many" key="name" map="" class="aus"/>
                        <link field="grp" reltype="has_a" key="name" map="" class="csg"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_USER_SETTING_TYPE" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_USER_SETTING_TYPE" global_required="true"/>
-                               <delete permission="ADMIN_USER_SETTING_TYPE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
        <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">
@@ -2882,14 +2052,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="update_perm" reltype="has_a" key="id" map="" class="ppl"/>
                        <link field="grp" reltype="has_a" key="name" map="" class="csg"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ORG_UNIT_SETTING_TYPE" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_ORG_UNIT_SETTING_TYPE" global_required="true"/>
-                               <delete permission="ADMIN_ORG_UNIT_SETTING_TYPE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
        <class id="aous" controller="open-ils.cstore" oils_obj:fieldmapper="actor::org_unit_setting" oils_persist:tablename="actor.org_unit_setting" reporter:label="Organizational Unit Setting">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_setting_id_seq">
@@ -2917,22 +2079,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="owning_copy" reltype="has_a" key="id" map="" class="acp"/>
                        <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="CREATE_COPY_NOTE">
-                    <context link="owning_copy" field="circ_lib"/>
-                </create>
-                <retrieve permission="VIEW_COPY_NOTES">
-                    <context link="owning_copy" field="circ_lib"/>
-                </retrieve>
-                <update permission="UPDATE_COPY_NOTE">
-                    <context link="owning_copy" field="circ_lib"/>
-                </update>
-                <delete permission="DELETE_COPY_NOTE">
-                    <context link="owning_copy" field="circ_lib"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
        <class id="mfr" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::full_rec" oils_persist:tablename="metabib.full_rec" reporter:label="Flattened MARC Fields">
                <fields oils_persist:primary="id" oils_persist:sequence="metabib.full_rec_id_seq">
@@ -2967,14 +2113,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="name"  reporter:datatype="text"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_NET_ACCESS_LEVEL" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_NET_ACCESS_LEVEL" global_required="true"/>
-                <delete permission="DELETE_NET_ACCESS_LEVEL" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ppl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="permission::perm_list" oils_persist:tablename="permission.perm_list" reporter:label="Permission List">
                <fields oils_persist:primary="id" oils_persist:sequence="permission.perm_list_id_seq">
@@ -2983,14 +2121,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="id" reporter:selector="code" reporter:datatype="id"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_PERM" global_required="true"/>
-                <retrieve permission="CREATE_PERM UPDATE_PERM DELETE_PERM" global_required="true"/>
-                <update permission="UPDATE_PERM" global_required="true"/>
-                <delete permission="DELETE_PERM" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="mmrsm" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::metarecord_source_map" oils_persist:tablename="metabib.metarecord_source_map" oils_persist:field_safe="true" reporter:label="Metarecord Source Map">
                <fields oils_persist:primary="id" oils_persist:sequence="metabib.metarecord_source_map_id_seq">
@@ -3039,19 +2169,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                </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
-                       SELECT * FROM metabib.identifier_field_entry
-                                               UNION ALL
-                       SELECT * FROM metabib.title_field_entry
-                                               UNION ALL
-                       SELECT * FROM metabib.subject_field_entry
-                                               UNION ALL
-                       SELECT * FROM metabib.series_field_entry
-               </oils_persist:source_definition>
                <fields>
                        <field name="field" reporter:datatype="link"/>
                        <field name="id" reporter:datatype="id" />
@@ -3154,14 +2271,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <field name="org_depth" reporter:datatype="int"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_STANDING_PENALTY" global_required="true"/>
-                <retrieve permission="ADMIN_STANDING_PENALTY VIEW_STANDING_PENALTY" global_required="true"/>
-                <update permission="ADMIN_STANDING_PENALTY" global_required="true"/>
-                <delete permission="ADMIN_STANDING_PENALTY" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="pgpt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="permission::grp_penalty_threshold" oils_persist:tablename="permission.grp_penalty_threshold" reporter:label="Group Penalty Threshold">
                <fields oils_persist:primary="id" oils_persist:sequence="permission.grp_penalty_threshold_id_seq">
@@ -3176,14 +2285,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
         </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
-                <retrieve permission="VIEW_GROUP_PENALTY_THRESHOLD ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
-                <update permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
-                <delete permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ccs" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::copy_status" oils_persist:tablename="config.copy_status" oils_persist:restrict_primary="100" reporter:label="Copy Status" oils_persist:field_safe="true">
                <fields oils_persist:primary="id" oils_persist:sequence="config.copy_status_id_seq">
@@ -3195,14 +2296,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
            <field name="restrict_copy_delete" reporter:datatype="bool"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_COPY_STATUS" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_COPY_STATUS" global_required="true"/>
-                <delete permission="DELETE_COPY_STATUS" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ausp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::user_standing_penalty" oils_persist:tablename="actor.usr_standing_penalty" oils_persist:restrict_primary="100" reporter:label="User Standing Penalty">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_standing_penalty_id_seq">
@@ -3221,14 +2314,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                        <link field="staff" reltype="has_a" key="id" map="" class="au"/>
                        <link field="standing_penalty" reltype="has_a" key="id" map="" class="csp"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="UPDATE_USER"><context link="usr" field="home_ou"/></create>
-                               <retrieve permission="VIEW_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="aua" controller="open-ils.cstore" oils_obj:fieldmapper="actor::user_address" oils_persist:tablename="actor.usr_address" reporter:label="User Address">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_address_id_seq">
@@ -3272,14 +2357,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <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   context_field='owner' permission="ADMIN_ADDRESS_ALERT"/>
-                               <retrieve context_field='owner' permission="ADMIN_ADDRESS_ALERT VIEW_ADDRESS_ALERT CREATE_USER"/>
-                               <update   context_field='owner' permission="ADMIN_ADDRESS_ALERT"/>
-                               <delete   context_field='owner' permission="ADMIN_ADDRESS_ALERT"/>
-                       </actions>
-               </permacrud>
        </class>
 
 
@@ -3311,22 +2388,6 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_VOLUME_NOTE">
-                    <context link="call_number" field="owning_lib"/>
-                </create>
-                <retrieve permission="VIEW_VOLUME_NOTES">
-                    <context link="call_number" field="owning_lib"/>
-                </retrieve>
-                <update permission="UPDATE_VOLUME_NOTE">
-                    <context link="call_number" field="owning_lib"/>
-                </update>
-                <delete permission="DELETE_VOLUME_NOTE">
-                    <context link="call_number" field="owning_lib"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
        <class id="arn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="authority::record_note" oils_persist:tablename="authority.record_note" reporter:label="Authority Record Note">
                <fields oils_persist:primary="id" oils_persist:sequence="authority.record_note_id_seq">
@@ -3341,45 +2402,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
                <links>
                        <link field="record" reltype="has_a" key="id" map="" class="are"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_AUTHORITY_RECORD_NOTE" global_required='true'/>
-                <retrieve/>
-                <update permission="UPDATE_AUTHORITY_RECORD_NOTE" global_required='true'/>
-                <delete permission="DELETE_AUTHORITY_RECORD_NOTE" global_required='true'/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ocirccount" controller="open-ils.cstore" oils_obj:fieldmapper="action::open_circ_count" reporter:label="Open Circulation Count" oils_persist:readonly="true">
-        <oils_persist:source_definition>
-SELECT  usr,
-        SUM(
-            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 1
-                ELSE 0
-            END
-        ) AS out,
-
-        SUM(
-            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 1
-                ELSE 0
-            END
-        ) 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
-  FROM  action.circulation
-  WHERE checkin_time IS NULL
-  GROUP BY 1
-        </oils_persist:source_definition>
         <fields oils_persist:primary="usr">
             <field reporter:label="User ID" name="usr" reporter:datatype="link"/>
             <field reporter:label="Out" name="out" reporter:datatype="text"/>
@@ -3393,35 +2417,6 @@ SELECT  usr,
         </links>
        </class>
        <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(
-            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
-            END
-        ),',') AS out,
-
-        ARRAY_TO_STRING(ARRAY_ACCUM(
-            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
-            END
-        ),',') 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
-  FROM  action.circulation
-  WHERE checkin_time IS NULL
-  GROUP BY 1
-        </oils_persist:source_definition>
         <fields oils_persist:primary="usr">
             <field reporter:label="User ID" name="usr" reporter:datatype="link"/>
             <field reporter:label="Out" name="out" reporter:datatype="text"/>
@@ -3672,14 +2667,6 @@ SELECT  usr,
                        <link field="resource_attrs" reltype="has_many" key="type" map="" class="bra"/>
                        <link field="tgt_rsrc_types" reltype="has_many" key="type" map="" class="bresv"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESOURCE_TYPE" context_field='owner'/>
-                               <retrieve permission="ADMIN_BOOKING_RESOURCE_TYPE" context_field='owner'/>
-                               <update permission="ADMIN_BOOKING_RESOURCE_TYPE" context_field='owner'/>
-                               <delete permission="ADMIN_BOOKING_RESOURCE_TYPE" context_field='owner'/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="brsrc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::resource" oils_persist:tablename="booking.resource" reporter:label="Resource">
@@ -3704,14 +2691,6 @@ SELECT  usr,
                        <link field="tgt_rsrcs" reltype="has_many" key="targeted_resource" map="" class="bresv"/>
                        <link field="curr_rsrcs" reltype="has_many" key="current_resource" map="" class="bresv"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESOURCE" context_field='owner'/>
-                               <retrieve permission="ADMIN_BOOKING_RESOURCE" context_field='owner'/>
-                               <update permission="ADMIN_BOOKING_RESOURCE" context_field='owner'/>
-                               <delete permission="ADMIN_BOOKING_RESOURCE" context_field='owner'/>
-                       </actions>
-               </permacrud>
        </class>
        
        <class id="bra" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::resource_attr" oils_persist:tablename="booking.resource_attr" reporter:label="Resource Attribute">
@@ -3730,14 +2709,6 @@ SELECT  usr,
                        <link field="valid_values" reltype="has_many" key="attr" map="" class="brav"/>
                        <link field="attr_maps" reltype="has_many" key="attr" map="" class="bram"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESOURCE_ATTR" context_field='owner'/>
-                               <retrieve permission="ADMIN_BOOKING_RESOURCE_ATTR" context_field='owner'/>
-                               <update permission="ADMIN_BOOKING_RESOURCE_ATTR" context_field='owner'/>
-                               <delete permission="ADMIN_BOOKING_RESOURCE_ATTR" context_field='owner'/>
-                       </actions>
-               </permacrud>
        </class>
        
        <class id="brav" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::resource_attr_value" oils_persist:tablename="booking.resource_attr_value" reporter:label="Resource Attribute Value">
@@ -3755,14 +2726,6 @@ SELECT  usr,
                        <link field="attr_maps" reltype="has_many" key="id" map="" class="bram"/>
                        <link field="attr_val_maps" reltype="has_many" key="attr_value" map="" class="bravm"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESOURCE_ATTR_VALUE" context_field='owner'/>
-                               <retrieve permission="ADMIN_BOOKING_RESOURCE_ATTR_VALUE" context_field='owner'/>
-                               <update permission="ADMIN_BOOKING_RESOURCE_ATTR_VALUE" context_field='owner'/>
-                               <delete permission="ADMIN_BOOKING_RESOURCE_ATTR_VALUE" context_field='owner'/>
-                       </actions>
-               </permacrud>
        </class>
        
        <class id="bram" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::resource_attr_map" oils_persist:tablename="booking.resource_attr_map" reporter:label="Resource Attribute Map">
@@ -3777,22 +2740,6 @@ SELECT  usr,
                        <link field="resource_attr" reltype="has_a" key="id" map="" class="bra"/>
                        <link field="value" reltype="has_a" key="id" map="" class="brav"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESOURCE_ATTR_MAP">
-                    <context link="resource" field="owner" />
-                </create>
-                               <retrieve permission="ADMIN_BOOKING_RESOURCE_ATTR_MAP">
-                    <context link="resource" field="owner" />
-                </retrieve>
-                               <update permission="ADMIN_BOOKING_RESOURCE_ATTR_MAP">
-                    <context link="resource" field="owner" />
-                </update>
-                               <delete permission="ADMIN_BOOKING_RESOURCE_ATTR_MAP">
-                    <context link="resource" field="owner" />
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
        
        <class id="bresv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::reservation" oils_persist:tablename="booking.reservation" reporter:label="Reservation">
@@ -3842,14 +2789,6 @@ SELECT  usr,
                        <link field="capture_staff" reltype="might_have" key="id" map="" class="au"/>
                        <link field="attr_val_maps" reltype="has_many" key="reservation" map="" class="bravm"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESERVATION" global_required='true'/>
-                               <retrieve permission="STAFF_LOGIN" global_required='true'/>
-                               <update permission="ADMIN_BOOKING_RESERVATION" global_required='true'/>
-                               <delete permission="ADMIN_BOOKING_RESERVATION" global_required='true'/>
-                       </actions>
-               </permacrud>
        </class>
        
        <class id="bravm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="booking::reservation_attr_value_map" oils_persist:tablename="booking.reservation_attr_value_map" reporter:label="Reservation Attribute Value Map">
@@ -3862,14 +2801,6 @@ SELECT  usr,
                        <link field="reservation" reltype="has_a" key="id" map="" class="bresv"/>
                        <link field="attr_value" reltype="has_a" key="id" map="" class="brav"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_BOOKING_RESERVATION_ATTR_MAP" global_required='true'/>
-                               <retrieve permission="STAFF_LOGIN" global_required='true'/>
-                               <update permission="ADMIN_BOOKING_RESERVATION_ATTR_MAP" global_required='true'/>
-                               <delete permission="ADMIN_BOOKING_RESERVATION_ATTR_MAP" global_required='true'/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="ccnbi" controller="open-ils.cstore" oils_obj:fieldmapper="container::call_number_bucket_item" oils_persist:tablename="container.call_number_bucket_item" reporter:label="Call Number Bucket Item">
@@ -3969,14 +2900,6 @@ SELECT  usr,
                        <link field="orders" reltype="has_many" key="location" map="" class="acplo"/>
                        <link field="copies" reltype="has_many" key="location" map="" class="acp"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_COPY_LOCATION" context_field="owning_lib"/>
-                <retrieve/>
-                <update permission="UPDATE_COPY_LOCATION" context_field="owning_lib"/>
-                <delete permission="DELETE_COPY_LOCATION" context_field="owning_lib"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="acplg" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location_group" oils_persist:tablename="asset.copy_location_group" reporter:label="Copy/Shelving Location Group">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_location_group_id_seq">
@@ -3992,14 +2915,6 @@ SELECT  usr,
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="location_maps" reltype="has_many" key="lgroup" map="" class="acplgm"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_COPY_LOCATION_GROUP" context_field="owner"/>
-                <retrieve/>
-                <update permission="ADMIN_COPY_LOCATION_GROUP" context_field="owner"/>
-                <delete permission="ADMIN_COPY_LOCATION_GROUP" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="acplgm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location_group_map" oils_persist:tablename="asset.copy_location_group_map" reporter:label="Copy/Shelving Location Group Map">
                <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_location_group_map_id_seq">
@@ -4011,20 +2926,6 @@ SELECT  usr,
                        <link field="lgroup" reltype="has_a" key="id" map="" class="acplg"/>
                        <link field="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_COPY_LOCATION_GROUP">
-                                       <context link="lgroup" field="owner" />
-                </create>
-                <retrieve/>
-                <update permission="ADMIN_COPY_LOCATION_GROUP">
-                                       <context link="lgroup" field="owner" />
-                </update>
-                <delete permission="ADMIN_COPY_LOCATION_GROUP">
-                                       <context link="lgroup" field="owner" />
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
     <class id="acplo" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location_order" oils_persist:tablename="asset.copy_location_order" reporter:label="Copy/Shelving Location Order">
@@ -4038,14 +2939,6 @@ SELECT  usr,
             <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
             <link field="org" reltype="has_a" key="id" map="" class="aou"/>
         </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                               <create permission="ADMIN_COPY_LOCATION_ORDER" context_field="org"/>
-                <retrieve/>
-                               <update permission="ADMIN_COPY_LOCATION_ORDER" context_field="org"/>
-                               <delete permission="ADMIN_COPY_LOCATION_ORDER" context_field="org"/>
-            </actions>
-        </permacrud>
     </class>
 
        <class id="svr" controller="open-ils.cstore" oils_obj:fieldmapper="serial::virtual_record" oils_persist:virtual="true" reporter:label="Serial Virtual Record">
@@ -4086,14 +2979,6 @@ SELECT  usr,
                        <link field="creator" reltype="has_a" key="id" map="" class="au"/>
                        <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_MFHD_RECORD" context_field="owning_lib"/>
-                               <retrieve/>
-                               <update permission="UPDATE_MFHD_RECORD" context_field="owning_lib"/>
-                               <delete permission="DELETE_MFHD_RECORD" context_field="owning_lib"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="scap" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::caption_and_pattern" oils_persist:tablename="serial.caption_and_pattern" reporter:label="Caption and Pattern">
@@ -4121,20 +3006,6 @@ SELECT  usr,
                <links>
                        <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_CAPTION_PATTERN">
-                                       <context link="subscription" field="owning_lib" />
-                               </create>
-                               <retrieve />
-                               <update permission="ADMIN_SERIAL_CAPTION_PATTERN">
-                                       <context link="subscription" field="owning_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_CAPTION_PATTERN">
-                                       <context link="subscription" field="owning_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="ssub" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::subscription" oils_persist:tablename="serial.subscription" reporter:label="Subscription">
@@ -4158,14 +3029,6 @@ SELECT  usr,
                        <link field="scaps" reltype="has_many" key="subscription" map="" class="scap"/>
                        <link field="notes" reltype="has_many" key="subscription" map="" class="ssubn"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_SUBSCRIPTION" context_field="owning_lib"/>
-                               <retrieve />
-                               <update permission="ADMIN_SERIAL_SUBSCRIPTION" context_field="owning_lib"/>
-                               <delete permission="ADMIN_SERIAL_SUBSCRIPTION" context_field="owning_lib"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="ssubn" controller="open-ils.cstore" oils_obj:fieldmapper="serial::subscription_note" oils_persist:tablename="serial.subscription_note" reporter:label="Subscription Note">
@@ -4219,14 +3082,6 @@ SELECT  usr,
                        <link field="supplement_summary" reltype="might_have" key="distribution" map="" class="sssum"/>
                        <link field="index_summary" reltype="might_have" key="distribution" map="" class="sisum"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_DISTRIBUTION" context_field="holding_lib" />
-                               <retrieve />
-                               <update permission="ADMIN_SERIAL_DISTRIBUTION" context_field="holding_lib" />
-                               <delete permission="ADMIN_SERIAL_DISTRIBUTION" context_field="holding_lib" />
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sdistn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::distribution_note" oils_persist:tablename="serial.distribution_note" reporter:label="Distribution Note">
@@ -4243,22 +3098,6 @@ SELECT  usr,
                        <link field="distribution" reltype="has_a" key="id" map="" class="sdist"/>
                        <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="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </retrieve>
-                               <update permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sstr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::stream" oils_persist:tablename="serial.stream" reporter:label="Stream">
@@ -4274,20 +3113,6 @@ SELECT  usr,
                        <link field="items" reltype="has_many" key="id" map="" class="sitem"/>
                        <link field="routing_list_users" reltype="has_many" key="stream" map="" class="srlu"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_STREAM">
-                                       <context link="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve />
-                               <update permission="ADMIN_SERIAL_STREAM">
-                                       <context link="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_STREAM">
-                                       <context link="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="srlu" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::routing_list_user" oils_persist:tablename="serial.routing_list_user" reporter:label="Routing List User">
@@ -4303,22 +3128,6 @@ SELECT  usr,
                        <link field="stream" reltype="has_a" key="id" map="" class="sstr"/>
                        <link field="reader" reltype="has_a" key="id" map="" class="au"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_STREAM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve permission="RECEIVE_SERIAL">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </retrieve>
-                               <update permission="ADMIN_SERIAL_STREAM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_STREAM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="siss" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::issuance" oils_persist:tablename="serial.issuance" reporter:label="Issuance">
@@ -4344,20 +3153,6 @@ SELECT  usr,
                        <link field="caption_and_pattern" reltype="has_a" key="id" map="" class="scap"/>
                        <link field="items" reltype="has_many" key="issuance" map="" class="sitem"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_SUBSCRIPTION">
-                                       <context link="subscription" field="owning_lib" />
-                               </create>
-                               <retrieve/>
-                               <update permission="ADMIN_SERIAL_SUBSCRIPTION">
-                                       <context link="subscription" field="owning_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_SUBSCRIPTION">
-                                       <context link="subscription" field="owning_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sunit" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::unit" oils_persist:tablename="serial.unit" reporter:label="Unit">
@@ -4421,14 +3216,6 @@ SELECT  usr,
                        <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"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="RECEIVE_SERIAL ADMIN_SERIAL_SUBSCRIPTION" context_field="circ_lib" />
-                               <retrieve/>
-                               <update permission="RECEIVE_SERIAL ADMIN_SERIAL_SUBSCRIPTION" context_field="circ_lib" />
-                               <delete permission="RECEIVE_SERIAL ADMIN_SERIAL_SUBSCRIPTION" context_field="circ_lib" />
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sitem" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::item" oils_persist:tablename="serial.item" reporter:label="Item">
@@ -4457,22 +3244,6 @@ SELECT  usr,
                        <link field="uri" reltype="has_a" key="id" map="" class="auri"/>
                        <link field="notes" reltype="has_many" key="item" map="" class="sin"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_ITEM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve permission="ADMIN_SERIAL_ITEM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </retrieve>
-                               <update permission="ADMIN_SERIAL_ITEM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_ITEM">
-                                       <context link="stream" jump="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sin" controller="open-ils.cstore" oils_obj:fieldmapper="serial::item_note" oils_persist:tablename="serial.item_note" reporter:label="Item Note">
@@ -4528,20 +3299,6 @@ SELECT  usr,
                <links>
                        <link field="distribution" reltype="has_a" key="id" map="" class="sdist"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve/>
-                               <update permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sssum" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::supplement_summary" oils_persist:tablename="serial.supplement_summary" reporter:label="Supplemental Issue Summary">
@@ -4555,20 +3312,6 @@ SELECT  usr,
                <links>
                        <link field="distribution" reltype="has_a" key="id" map="" class="sdist"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve/>
-                               <update permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="sisum" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="serial::index_summary" oils_persist:tablename="serial.index_summary" reporter:label="Index Issue Summary">
@@ -4582,20 +3325,6 @@ SELECT  usr,
                <links>
                        <link field="distribution" reltype="has_a" key="id" map="" class="sdist"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </create>
-                               <retrieve/>
-                               <update permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </update>
-                               <delete permission="ADMIN_SERIAL_DISTRIBUTION">
-                                       <context link="distribution" field="holding_lib" />
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="ascecm" controller="open-ils.cstore" oils_obj:fieldmapper="asset::stat_cat_entry_copy_map" oils_persist:tablename="asset.stat_cat_entry_copy_map" reporter:label="Statistical Category Entry Copy Map">
@@ -4617,14 +3346,6 @@ SELECT  usr,
                        <field reporter:label="Item Type" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_MARC_CODE" global_required="true"/>
-                <delete permission="ADMIN_MARC_CODE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="cblvl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::bib_level_map" oils_persist:tablename="config.bib_level_map" reporter:label="Bib Level Map" oils_persist:field_safe="true">
                <fields oils_persist:primary="code">
@@ -4632,14 +3353,6 @@ SELECT  usr,
                        <field reporter:label="Bib Level" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MARC_CODE" global_required="true"/>
-                <delete permission="DELETE_MARC_CODE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="sra" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="search::relevance_adjustment" oils_persist:tablename="search.relevance_adjustment" reporter:label="Relevance Adjustment">
                <fields oils_persist:primary="id" oils_persist:sequence="search.relevance_adjustment_id_seq">
@@ -4652,14 +3365,6 @@ SELECT  usr,
                <links>
             <link field="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_RELEVANCE_ADJUSTMENT" global_required="true"/>
-                <retrieve permission="CREATE_RELEVANCE_ADJUSTMENT UPDATE_RELEVANCE_ADJUSTMENT DELETE_RELEVANCE_ADJUSTMENT" global_required="true"/>
-                <update permission="UPDATE_RELEVANCE_ADJUSTMENT" global_required="true"/>
-                <delete permission="DELETE_RELEVANCE_ADJUSTMENT" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="lasso" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_lasso" oils_persist:tablename="actor.org_lasso" reporter:label="Org Lasso">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_lasso_id_seq">
@@ -4667,14 +3372,6 @@ SELECT  usr,
                        <field name="name" reporter:datatype="text"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_LASSO" global_required="true"/>
-                <retrieve permission="CREATE_LASSO UPDATE_LASSO DELETE_LASSO" global_required="true"/>
-                <update permission="UPDATE_LASSO" global_required="true"/>
-                <delete permission="DELETE_LASSO" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="lmap" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_lasso_map" oils_persist:tablename="actor.org_lasso_map" reporter:label="Org Lasso Map">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_lasso_map_id_seq">
@@ -4686,14 +3383,6 @@ SELECT  usr,
                        <link field="lasso" reltype="has_a" key="id" map="" class="lasso"/>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_LASSO_MAP" global_required="true"/>
-                <retrieve permission="CREATE_LASSO_MAP UPDATE_LASSO_MAP DELETE_LASSO_MAP" global_required="true"/>
-                <update permission="UPDATE_LASSO_MAP" global_required="true"/>
-                <delete permission="DELETE_LASSO_MAP" 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">
@@ -4740,14 +3429,6 @@ SELECT  usr,
                        <link field="responses" reltype="has_many" key="survey" map="" class="asvr"/>
                        <link field="questions" reltype="has_many" key="survey" map="" class="asvq"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_SURVEY" context_field="owner"/>
-                <retrieve/>
-                <update permission="ADMIN_SURVEY" context_field="owner"/>
-                <delete permission="ADMIN_SURVEY" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="aoa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_address" oils_persist:tablename="actor.org_address" reporter:label="Org Address">
                <fields oils_persist:primary="id" oils_persist:sequence="actor.org_address_id_seq">
@@ -4767,14 +3448,6 @@ SELECT  usr,
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_ORG_ADDRESS" context_field="org_unit"/>
-                <retrieve/>
-                <update permission="UPDATE_ORG_ADDRESS" context_field="org_unit"/>
-                <delete permission="DELETE_ORG_ADDRESS" context_field="org_unit"/>
-            </actions>
-        </permacrud>
        </class>
        <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">
@@ -4782,11 +3455,6 @@ SELECT  usr,
                        <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">
@@ -4802,14 +3470,6 @@ SELECT  usr,
                        <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">
@@ -4822,20 +3482,6 @@ SELECT  usr,
                        <link field="grp" reltype="has_a" key="id" map="" class="asfge"/>
                        <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 -->
@@ -4902,43 +3548,6 @@ SELECT  usr,
                </links>
        </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, 999) AS
-                               copy_location_order_position,
-                       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_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
-               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)
-               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
-                       (ahr.expire_time is NULL OR ahr.expire_time > NOW())
-               ]]></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" />
@@ -5004,16 +3613,8 @@ SELECT  usr,
                        <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="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>
-                       SELECT ahr.* FROM action.hold_request ahr JOIN (SELECT current_copy, MAX(capture_time) AS capture_time FROM action.hold_request WHERE capture_time IS NOT NULL GROUP BY current_copy)x USING (current_copy, capture_time)
-               </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" />
@@ -5086,14 +3687,6 @@ SELECT  usr,
                <links>
                        <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="UPDATE_HOLD"><context link="hold" field="request_lib"/></create>
-                               <retrieve permission="VIEW_USER"><context link="hold" field="request_lib"/></retrieve>
-                               <update permission="UPDATE_HOLD"><context link="hold" field="request_lib"/></update>
-                               <delete permission="UPDATE_HOLD"><context link="hold" field="request_lib"/></delete>
-                       </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">
@@ -5156,17 +3749,6 @@ SELECT  usr,
                        <link field="attr_vals" reltype="has_many" key="owner" map="" class="brav"/>
                        <link field="hours_of_operation" reltype="might_have" key="id" map="" class="aouhoo"/>
                </links>
-        <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>
-                <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">
@@ -5174,14 +3756,6 @@ SELECT  usr,
                        <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">
@@ -5198,14 +3772,6 @@ SELECT  usr,
                        <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">
@@ -5261,13 +3827,6 @@ 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">
@@ -5276,14 +3835,6 @@ SELECT  usr,
             <field reporter:label="Exclusive?" name="one_only" reporter:datatype="bool"/>
         </fields>
         <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_PATRON_STAT_CAT" global_required="true"/>
-                <retrieve />
-                <update permission="UPDATE_PATRON_STAT_CAT" global_required="true"/>
-                <delete permission="DELETE_PATRON_STAT_CAT" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
        <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">
@@ -5306,14 +3857,6 @@ SELECT  usr,
                        <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>
-                <create permission="CREATE_PATRON_STAT_CAT" context_field="owner"/>
-                <retrieve />
-                <update permission="UPDATE_PATRON_STAT_CAT" context_field="owner"/>
-                <delete permission="DELETE_PATRON_STAT_CAT" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="msefe" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::series_field_entry" oils_persist:tablename="metabib.series_field_entry" reporter:label="Series Field Entry">
                <fields oils_persist:primary="id" oils_persist:sequence="metabib.series_field_entry_id_seq">
@@ -5414,14 +3957,6 @@ SELECT  usr,
                        <link field="children" reltype="has_many" key="parent" map="" class="aout"/>
                        <link field="org_units" reltype="has_many" key="ou_type" map="" class="aou"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_ORG_TYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_ORG_TYPE" global_required="true"/>
-                <delete permission="DELETE_ORG_TYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="bren" controller="open-ils.cstore" oils_obj:fieldmapper="biblio::record_note" oils_persist:tablename="biblio.record_note" reporter:label="Bib Record Note">
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_note_id_seq">
@@ -5484,14 +4019,6 @@ SELECT  usr,
                        <field name="can_have_copies" reporter:datatype="bool"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_BIB_SOURCE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_BIB_SOURCE" global_required="true"/>
-                <delete permission="DELETE_BIB_SOURCE" global_required="true"/>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
@@ -5589,14 +4116,6 @@ SELECT  usr,
                        <field reporter:label="LitF Name" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_MARC_CODE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_MARC_CODE" global_required="true"/>
-                <delete permission="DELETE_MARC_CODE" global_required="true"/>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
@@ -5693,14 +4212,6 @@ SELECT  usr,
             <field name="grace_period" reporter:datatype="interval" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_RECURRING_FINE_RULE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_RECURRING_FINE_RULE" global_required="true"/>
-                <delete permission="ADMIN_RECURRING_FINE_RULE" global_required="true"/>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
@@ -5791,20 +4302,6 @@ SELECT  usr,
                        <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"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_COPY">
-                    <context link="call_number" field="owning_lib"/>
-                </create>
-                <retrieve/>
-                <update permission="UPDATE_COPY">
-                    <context link="call_number" field="owning_lib"/>
-                </update>
-                <delete permission="DELETE_COPY">
-                    <context link="call_number" field="owning_lib"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="act" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_template" oils_persist:tablename="asset.copy_template" reporter:label="Asset Copy Template">
@@ -5844,14 +4341,6 @@ SELECT  usr,
                        <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
                        <link field="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_ASSET_COPY_TEMPLATE" global_required="true"/>
-                               <retrieve />
-                               <update permission="ADMIN_ASSET_COPY_TEMPLATE" global_required="true"/>
-                               <delete permission="ADMIN_ASSET_COPY_TEMPLATE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="crahp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::rules::age_hold_protect" oils_persist:tablename="config.rule_age_hold_protect" reporter:label="Age Hold Protection Rule" oils_persist:field_safe="true">
@@ -5862,14 +4351,6 @@ SELECT  usr,
                        <field reporter:label="Allowed Proximity" name="prox" reporter:datatype="int" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
-                <delete permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="crmf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::rules::max_fine" oils_persist:tablename="config.rule_max_fine" reporter:label="Max Fine Rule">
                <fields oils_persist:primary="id" oils_persist:sequence="config.rule_max_fine_id_seq">
@@ -5879,14 +4360,6 @@ SELECT  usr,
                        <field reporter:label="Is Percent" name="is_percent" reporter:datatype="bool"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
-                <delete permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="pgt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="permission::grp_tree" oils_persist:tablename="permission.grp_tree" reporter:label="Permission Group">
                <fields oils_persist:primary="id" oils_persist:sequence="permission.grp_tree_id_seq">
@@ -5904,14 +4377,6 @@ SELECT  usr,
                        <link field="parent" reltype="has_a" key="id" map="" class="pgt"/>
                        <link field="children" reltype="has_many" key="parent" map="" class="pgt"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_PERM" global_required="true"/>
-                <retrieve permission="STAFF_LOGIN" global_required="true"/>
-                <update permission="UPDATE_PERM" global_required="true"/>
-                <delete permission="DELETE_PERM" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="asva" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::survey_answer" oils_persist:tablename="action.survey_answer" reporter:label="Survey Answer">
                <fields oils_persist:primary="id" oils_persist:sequence="action.survey_answer_id_seq">
@@ -5924,20 +4389,6 @@ SELECT  usr,
                        <link field="question" reltype="has_a" key="id" map="" class="asvq"/>
                        <link field="responses" reltype="has_many" key="answer" map="" class="asvr"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_SURVEY">
-                    <context link="question" jump="survey" field="owner"/>
-                </create>
-                <retrieve/>
-                <update permission="ADMIN_SURVEY">
-                    <context link="question" jump="survey" field="owner"/>
-                </update>
-                <delete permission="ADMIN_SURVEY">
-                    <context link="question" jump="survey" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
        <class id="ancc" controller="open-ils.cstore" oils_obj:fieldmapper="action::non_cataloged_circulation" oils_persist:tablename="action.non_cataloged_circulation" reporter:core="true" reporter:label="Non-cataloged Circulation">
                <fields oils_persist:primary="id" oils_persist:sequence="action.non_cataloged_circulation_id_seq">
@@ -6029,14 +4480,6 @@ SELECT  usr,
                        <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
                        <link field="perm" reltype="has_a" key="id" map="" class="ppl"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ASSIGN_GROUP_PERM" global_required="true"/>
-                <retrieve permission="ASSIGN_GROUP_PERM UPDATE_GROUP_PERM REMOVE_GROUP_PERM" global_required="true"/>
-                <update permission="UPDATE_GROUP_PERM" global_required="true"/>
-                <delete permission="REMOVE_GROUP_PERM" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ccb" controller="open-ils.cstore" oils_obj:fieldmapper="container::copy_bucket" oils_persist:tablename="container.copy_bucket" reporter:label="Copy Bucket">
                <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_id_seq">
@@ -6248,14 +4691,6 @@ SELECT  usr,
             <field reporter:label="Exclusive?" name="one_only" reporter:datatype="bool"/>
         </fields>
         <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_COPY_STAT_CAT" global_required="true"/>
-                <retrieve />
-                <update permission="UPDATE_COPY_STAT_CAT" global_required="true"/>
-                <delete permission="DELETE_COPY_STAT_CAT" global_required="true"/>
-            </actions>
-        </permacrud>
     </class>
        <class id="ahrcc" controller="open-ils.cstore open-ils.reporter-store open-ils.pcrud" oils_obj:fieldmapper="action::hold_request_cancel_cause" oils_persist:tablename="action.hold_request_cancel_cause" oils_persist:restrict_primary="100" reporter:label="Hold Request Cancel Cause">
                <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_cancel_cause_id_seq">
@@ -6263,14 +4698,6 @@ SELECT  usr,
                        <field reporter:label="Cause Label" name="label" reporter:datatype="text" oils_persist:i18n="true" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
-                <delete permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
 
@@ -6298,16 +4725,6 @@ SELECT  usr,
                        <link field="prev_dest" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="reservation" reltype="has_a" key="id" map="" class="bresv"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="TRANSIT_COPY">
-                    <context link="target_copy" field="owner"/>
-                </create>
-                <retrieve/>
-                <update permission="UPDATE_TRANSIT" context_field="dest source"/>
-                <delete permission="DELETE_TRANSIT" context_field="dest source"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="ahtc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::hold_transit_copy" oils_persist:tablename="action.hold_transit_copy" reporter:core="true" reporter:label="Hold Transit">
                <fields oils_persist:primary="id" oils_persist:sequence="action.transit_copy_id_seq">
@@ -6333,16 +4750,6 @@ SELECT  usr,
                        <link field="prev_dest" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="TRANSIT_COPY" context_field="owner">
-                    <context link="target_copy" field="circ_lib"/>
-                </create>
-                <retrieve/>
-                <update permission="UPDATE_TRANSIT" context_field="dest source"/>
-                <delete permission="DELETE_TRANSIT" context_field="dest source"/>
-            </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">
                <fields oils_persist:primary="id" oils_persist:sequence="money.billing_id_seq">
@@ -6385,14 +4792,6 @@ SELECT  usr,
                <links>
                        <link field="translation" reltype="has_a" key="code" map="" class="i18n_l"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_TRANSLATION" global_required="true"/>
-                <retrieve permission="CREATE_TRANSLATION UPDATE_TRANSLATION DELETE_TRANSLATION" global_required="true"/>
-                <update permission="UPDATE_TRANSLATION" global_required="true"/>
-                <delete permission="DELETE_TRANSLATION" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="fdoc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::idl_field_doc" oils_persist:tablename="config.idl_field_doc" oils_persist:field_safe="true" reporter:label="IDL Field Doc">
                <fields oils_persist:primary="id" oils_persist:sequence="config.idl_field_doc_id_seq">
@@ -6405,14 +4804,6 @@ SELECT  usr,
                <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="ADMIN_FIELD_DOC" context_field="owner"/>
-                <retrieve/>
-                <update   permission="ADMIN_FIELD_DOC" context_field="owner"/>
-                <delete   permission="ADMIN_FIELD_DOC" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="i18n_l" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::i18n_locale" oils_persist:tablename="config.i18n_locale" oils_persist:field_safe="true" reporter:label="Locale">
                <fields oils_persist:primary="code">
@@ -6422,14 +4813,6 @@ SELECT  usr,
                        <field name="description" reporter:datatype="text" oils_persist:i18n="true"/>
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_LOCALE" global_required="true"/>
-                <retrieve/>
-                <update permission="UPDATE_LOCALE" global_required="true"/>
-                <delete permission="DELETE_LOCALE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
        <class id="cbt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::billing_type" oils_persist:tablename="config.billing_type" oils_persist:restrict_primary="100" reporter:label="Billing Type">
                <fields oils_persist:primary="id" oils_persist:sequence="config.billing_type_id_seq">
@@ -6441,14 +4824,6 @@ SELECT  usr,
                <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_BILLING_TYPE" context_field="owner"/>
-                <retrieve permission="VIEW_BILLING_TYPE CREATE_BILLING_TYPE UPDATE_BILLING_TYPE DELETE_BILLING_TYPE" context_field="owner"/>
-                <update permission="UPDATE_BILLING_TYPE" context_field="owner"/>
-                <delete permission="DELETE_BILLING_TYPE" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="aurt" controller="open-ils.cstore open-ils.reporter-store open-ils.pcrud" oils_obj:fieldmapper="acq::user_request_type" oils_persist:tablename="acq.user_request_type" reporter:label="User Purchase Request Type">
@@ -6457,14 +4832,6 @@ SELECT  usr,
                        <field reporter:label="Type Label" name="label" reporter:datatype="text" oils_persist:i18n="true" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_USER_REQUEST_TYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_USER_REQUEST_TYPE" global_required="true"/>
-                <delete permission="ADMIN_USER_REQUEST_TYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="aur" controller="open-ils.cstore open-ils.reporter-store open-ils.pcrud" oils_obj:fieldmapper="acq::user_request" oils_persist:tablename="acq.user_request" reporter:label="User Purchase Request">
@@ -6503,22 +4870,6 @@ SELECT  usr,
                        <link field="request_type" reltype="has_a" key="id" map="" class="aurt"/>
                        <link field="cancel_reason" reltype="has_a" key="id" map="" class="acqcr"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="user_request.create">
-                    <context link="usr" field="home_ou"/>
-                               </create>
-                <retrieve permission="user_request.view">
-                    <context link="usr" field="home_ou"/>
-                               </retrieve>
-                <update permission="user_request.update">
-                    <context link="usr" field="home_ou"/>
-                               </update>
-                <delete permission="user_request.delete">
-                    <context link="usr" field="home_ou"/>
-                               </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqct" controller="open-ils.cstore open-ils.reporter-store open-ils.pcrud" oils_obj:fieldmapper="acq::currency_type" oils_persist:tablename="acq.currency_type" reporter:label="Currency Type">
@@ -6527,14 +4878,6 @@ SELECT  usr,
                        <field reporter:label="Currency Label" name="label" reporter:datatype="text" oils_persist:i18n="true" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-                <delete permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqexr" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="acq::exchange_rate" oils_persist:tablename="acq.exchange_rate" reporter:label="Exchange Rate">
@@ -6548,14 +4891,6 @@ SELECT  usr,
                        <link field="from_currency" reltype="has_a" key="code" map="" class="acqct"/>
                        <link field="to_currency" reltype="has_a" key="code" map="" class="acqct"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-                               <retrieve/>
-                               <update permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-                               <delete permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqpro" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider" oils_persist:tablename="acq.provider" reporter:label="Provider">
@@ -6584,14 +4919,6 @@ SELECT  usr,
             <link field="edi_default" reltype="has_a" map="" key="id" class="acqedi"/>
             <link field="default_claim_policy" reltype="has_a" map="" key="id" class="acqclp"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_PROVIDER" context_field="owner"/>
-                <retrieve permission="ADMIN_PROVIDER MANAGE_PROVIDER VIEW_PROVIDER" context_field="owner"/>
-                <update   permission="ADMIN_PROVIDER" context_field="owner"/>
-                <delete   permission="ADMIN_PROVIDER" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqpron" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::provider_note" oils_persist:tablename="acq.provider_note" reporter:label="Provider Note">
@@ -6616,14 +4943,6 @@ SELECT  usr,
                        <field reporter:label="Code" name="code" reporter:datatype="id" reporter:selector="name"/>
                        <field reporter:label="Name" name="name" reporter:datatype="text"/>
                </fields>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_INVOICE_PAYMENT_METHOD" global_required="true"/>
-                <retrieve/>
-                <update permission="ADMIN_INVOICE_PAYMENT_METHOD" global_required="true"/>
-                <delete permission="ADMIN_INVOICE_PAYMENT_METHOD" global_required="true"/>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="acqinv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::invoice" oils_persist:tablename="acq.invoice" reporter:label="Invoice">
@@ -6652,14 +4971,6 @@ SELECT  usr,
                        <link field="entries" reltype="has_many" key="invoice" map="" class="acqie"/>
                        <link field="items" reltype="has_many" key="invoice" map="" class="acqii"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="CREATE_INVOICE" context_field="receiver"/>
-                <retrieve permission="CREATE_INVOICE VIEW_INVOICE" context_field="receiver"/>
-                <update   permission="CREATE_INVOICE" context_field="receiver"/>
-                <delete   permission="CREATE_INVOICE" context_field="receiver"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqie" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::invoice_entry" oils_persist:tablename="acq.invoice_entry" reporter:label="Invoice Entry">
@@ -6681,22 +4992,6 @@ SELECT  usr,
                        <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo"/>
                        <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </create>
-                <retrieve permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </retrieve>
-                <update   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </update>
-                               <delete   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqii" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::invoice_item" oils_persist:tablename="acq.invoice_item" reporter:label="Non-bibliographic Invoice Item">
@@ -6724,22 +5019,6 @@ SELECT  usr,
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                        <link field="po_item" reltype="has_a" key="id" map="" class="acqpoi"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </create>
-                <retrieve permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </retrieve>
-                <update   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </update>
-                               <delete   permission="ADMIN_INVOICE">
-                                       <context link="invoice" field="receiver"/>
-                               </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqpa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider_address" oils_persist:tablename="acq.provider_address" reporter:label="Provider Address">
@@ -6760,22 +5039,6 @@ SELECT  usr,
                <links>
                        <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </create>
-                <retrieve permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </retrieve>
-                <update permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </update>
-                <delete permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqpc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider_contact" oils_persist:tablename="acq.provider_contact" reporter:label="Provider Contact">
@@ -6790,22 +5053,6 @@ SELECT  usr,
                <links>
                        <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </create>
-                <retrieve permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </retrieve>
-                <update permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </update>
-                <delete permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
     </class>
        <class id="acqpca" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider_contact_address" oils_persist:tablename="acq.provider_contact_address" reporter:label="Provider Contact Address">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_contact_address_id_seq">
@@ -6825,22 +5072,6 @@ SELECT  usr,
                <links>
                        <link field="contact" reltype="has_a" key="id" map="" class="acqpc"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_PROVIDER">
-                    <context link="contact" jump='provider' field="owner"/>
-                </create>
-                <retrieve permission="ADMIN_PROVIDER">
-                    <context link="contact" jump='provider' field="owner"/>
-                </retrieve>
-                <update permission="ADMIN_PROVIDER">
-                    <context link="contact" jump='provider' field="owner"/>
-                </update>
-                <delete permission="ADMIN_PROVIDER">
-                    <context link="contact" jump='provider' field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqftr" controller="open-ils.cstore" oils_obj:fieldmapper="acq::fund_transfer" oils_persist:tablename="acq.fund_transfer" reporter:label="Fund Transfer">
@@ -6876,14 +5107,6 @@ SELECT  usr,
                        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"/>
-                               <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">
@@ -6901,14 +5124,6 @@ SELECT  usr,
                        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"/>
-                               <update permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
-                               <delete permission="ADMIN_ACQ_FISCAL_YEAR" global_required="true"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqfs" controller="open-ils.cstore open-ils.reporter-store open-ils.pcrud" oils_obj:fieldmapper="acq::funding_source" oils_persist:tablename="acq.funding_source" reporter:label="Funding Source">
@@ -6930,14 +5145,6 @@ SELECT  usr,
             <link field="credits" reltype="has_many" key="funding_source" map="" class="acqfscred"/>
                        <link field="fund_alloc_pcts" reltype="has_many" key="funding_source" map="" class="acqfap"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
-                <retrieve permission="ADMIN_FUNDING_SOURCE MANAGE_FUNDING_SOURCE VIEW_FUNDING_SOURCE" context_field="owner"/>
-                <update   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
-                <delete   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqfscred" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::funding_source_credit" oils_persist:tablename="acq.funding_source_credit" reporter:label="Credit to Funding Source">
@@ -6952,22 +5159,6 @@ SELECT  usr,
                <links>
                        <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_FUNDING_SOURCE">
-                    <context link="funding_source" field="owner"/>
-                </create>
-                               <retrieve permission="ADMIN_FUNDING_SOURCE">
-                    <context link="funding_source" field="owner"/>
-                </retrieve>
-                               <update permission="ADMIN_FUNDING_SOURCE">
-                    <context link="funding_source" field="owner"/>
-                </update>
-                               <delete permission="ADMIN_FUNDING_SOURCE">
-                    <context link="funding_source" field="owner"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqofscred" controller="open-ils.cstore" oils_obj:fieldmapper="acq::ordered_funding_source_credit" oils_persist:tablename="acq.ordered_funding_source_credit" reporter:label="Ordered Funding Source Credit">
@@ -6999,22 +5190,6 @@ SELECT  usr,
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                        <link field="origin_currency_type" reltype="has_a" key="code" map="" class="acqct"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </create>
-                               <retrieve permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </retrieve>
-                               <update permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </update>
-                               <delete permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund" oils_persist:tablename="acq.fund" reporter:label="Fund">
@@ -7054,14 +5229,6 @@ SELECT  usr,
             <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">
-            <actions>
-                <create permission="ADMIN_ACQ_FUND" context_field="org"/>
-                <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="org"/>
-                <update permission="ADMIN_ACQ_FUND" context_field="org"/>
-                <delete permission="ADMIN_ACQ_FUND" context_field="org"/>
-            </actions>
-        </permacrud>
        </class>
 
        <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">
@@ -7072,13 +5239,6 @@ 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.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">
@@ -7089,13 +5249,6 @@ 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.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">
@@ -7106,13 +5259,6 @@ 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.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">
@@ -7123,13 +5269,6 @@ 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.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">
@@ -7140,13 +5279,6 @@ 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">
@@ -7237,13 +5369,6 @@ 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="acqfa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund_allocation" oils_persist:tablename="acq.fund_allocation" reporter:label="Fund Allocation">
@@ -7261,22 +5386,6 @@ SELECT  usr,
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                        <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </create>
-                               <retrieve permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </retrieve>
-                               <update permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </update>
-                               <delete permission="ADMIN_ACQ_FUND">
-                    <context link="fund" field="org"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
     <class id="acqfap" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund_allocation_percent" oils_persist:tablename="acq.fund_allocation_percent" reporter:label="Fund Allocation Percent">
@@ -7295,14 +5404,6 @@ SELECT  usr,
             <link field="org" reltype="has_a" key="id" map="" class="aou"/>
             <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
         </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_FUND_ALLOCATION_PERCENT" global_required="true"/>
-                               <retrieve permission="VIEW_ACQ_FUND_ALLOCATION_PERCENT" global_required="true"/>
-                               <update permission="ADMIN_ACQ_FUND_ALLOCATION_PERCENT" global_required="true"/>
-                               <delete permission="ADMIN_ACQ_FUND_ALLOCATION_PERCENT" global_required="true"/>
-                       </actions>
-               </permacrud>
     </class>
 
        <class id="acqpl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::picklist" oils_persist:tablename="acq.picklist" reporter:label="Selection List">
@@ -7325,11 +5426,6 @@ SELECT  usr,
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="entries" reltype="has_many" key="picklist" map="" class="jub"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve permission="CREATE_PICKLIST VIEW_PICKLIST" context_field="org_unit"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqcr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::cancel_reason" oils_persist:tablename="acq.cancel_reason" reporter:label="Cancel Reason">
@@ -7343,14 +5439,6 @@ SELECT  usr,
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
-                               <retrieve permission="STAFF_LOGIN" context_field="org_unit"/>
-                               <update permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
-                               <delete permission="ADMIN_ACQ_CANCEL_CAUSE" context_field="org_unit"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqpo" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::purchase_order" oils_persist:tablename="acq.purchase_order" reporter:label="Purchase Order">
@@ -7387,14 +5475,6 @@ SELECT  usr,
                        <link field="ordering_agency" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="cancel_reason" reltype="has_a" key="id" map="" class="acqcr"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
-                               <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER" context_field="ordering_agency"/>
-                               <update permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
-                               <delete permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqpoh" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::acq_purchase_order_history" oils_persist:tablename="acq.acq_purchase_order_history" reporter:label="Purchase Order History">
@@ -7425,11 +5505,6 @@ SELECT  usr,
                        <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
                        <link field="cancel_reason" reltype="has_a" key="id" map="" class="acqcr"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER" context_field="ordering_agency"/>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="acqpon" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::po_note" oils_persist:tablename="acq.po_note" reporter:label="PO Note">
@@ -7448,22 +5523,6 @@ SELECT  usr,
                        <link field="editor" reltype="has_a" key="id" map="" class="au"/>
                        <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </create>
-                <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </retrieve>
-                <update permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </update>
-                <delete permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </delete>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="acqpoi" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::po_item" oils_persist:tablename="acq.po_item" reporter:label="Purchase Order Item">
@@ -7485,22 +5544,6 @@ SELECT  usr,
                        <link field="inv_item_type" reltype="has_a" key="code" map="" class="aiit"/>
                        <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </create>
-                <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </retrieve>
-                <update permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </update>
-                <delete permission="CREATE_PURCHASE_ORDER">
-                    <context link="purchase_order" field="ordering_agency"/>
-                </delete>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="jub" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::lineitem" oils_persist:tablename="acq.lineitem" reporter:label="Line Item">
@@ -7549,14 +5592,6 @@ SELECT  usr,
                        <link field="order_summary" reltype="might_have" key="lineitem" map="" class="acqlisum"/>
                        <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER CREATE_PICKLIST VIEW_PICKLIST">
-                                       <context link="purchase_order" field="ordering_agency"/>
-                                       <context link="picklist" field="org_unit"/>
-                               </retrieve>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqlih" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::acq_lineitem_history" oils_persist:tablename="acq.acq_lineitem_history" reporter:label="Line Item History">
@@ -7596,14 +5631,6 @@ SELECT  usr,
                        <link field="claim_policy" reltype="has_a" key="id" map="" class="acqclp"/>
                        <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER">
-                                       <context link="purchase_order" field="ordering_agency"/>
-                                       <context link="picklist" field="org_unit"/>
-                               </retrieve>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqliat" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::lineitem_alert_text" oils_persist:tablename="acq.lineitem_alert_text" reporter:label="Line Item Alert Text">
@@ -7616,14 +5643,6 @@ 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="ADMIN_ACQ_LINEITEM_ALERT_TEXT" context_field="owning_lib"/>
-                               <retrieve permission="STAFF_LOGIN" context_field="owning_lib"/>
-                               <update permission="ADMIN_ACQ_LINEITEM_ALERT_TEXT" context_field="owning_lib"/>
-                               <delete permission="ADMIN_ACQ_LINEITEM_ALERT_TEXT" context_field="owning_lib"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqlin" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_note" oils_persist:tablename="acq.lineitem_note" reporter:label="Line Item Note">
@@ -7702,11 +5721,6 @@ SELECT  usr,
                        <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve />
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqlimad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::lineitem_marc_attr_definition" oils_persist:tablename="acq.lineitem_marc_attr_definition" reporter:label="Line Item MARC Attribute Definition">
@@ -7719,14 +5733,6 @@ SELECT  usr,
             <field reporter:label="Remove" name="remove" reporter:datatype="text" />
                </fields>
                <links/>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create permission="ADMIN_LINEITEM_MARC_ATTR_DEF" global_required="true"/>
-                <retrieve />
-                <update permission="ADMIN_LINEITEM_MARC_ATTR_DEF" global_required="true"/>
-                <delete permission="ADMIN_LINEITEM_MARC_ATTR_DEF" global_required="true"/>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqligad" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_generated_attr_definition" oils_persist:tablename="acq.lineitem_generated_attr_definition" reporter:label="Line Item Generated Attribute Definition">
@@ -7766,22 +5772,6 @@ SELECT  usr,
            <links>
                <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
            </links>
-            <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                <actions>
-                    <create permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </create>
-                    <retrieve permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </retrieve>
-                    <update permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </update>
-                    <delete permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </delete>
-                </actions>
-            </permacrud>
        </class>
         
        <class id="acqphsm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider_holding_subfield_map" oils_persist:tablename="acq.provider_holding_subfield_map" reporter:label="Provider Holding Subfield Map">
@@ -7794,22 +5784,6 @@ SELECT  usr,
            <links>
                <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
            </links>
-            <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                <actions>
-                    <create permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </create>
-                    <retrieve permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </retrieve>
-                    <update permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </update>
-                    <delete permission="ADMIN_PROVIDER">
-                        <context link="provider" field="owner"/>
-                    </delete>
-                </actions>
-            </permacrud>
        </class>
         
        <class id="acqlilad" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_local_attr_definition" oils_persist:tablename="acq.lineitem_local_attr_definition" reporter:label="Line Item Local Attribute Definition">
@@ -7842,22 +5816,6 @@ SELECT  usr,
                        <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
                        <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="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </create>
-                <retrieve permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </retrieve>
-                <update permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </update>
-                <delete permission="ADMIN_PROVIDER">
-                    <context link="provider" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
        <class id="acqedim" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::edi_message" oils_persist:tablename="acq.edi_message" reporter:label="EDI Message">
@@ -7880,19 +5838,6 @@ SELECT  usr,
                        <link field="account" reltype="has_a" key="id" map="" class="acqedi"/>
                        <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo"/>
                </links>
-        <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <retrieve permission="ADMIN_PROVIDER MANAGE_PROVIDER VIEW_PROVIDER">
-                    <context link="account" jump="provider" field="owner"/>
-                </retrieve>
-                <update   permission="ADMIN_PROVIDER MANAGE_PROVIDER VIEW_PROVIDER">
-                    <context link="account" jump="provider" field="owner"/>
-                </update>
-                <delete   permission="ADMIN_PROVIDER MANAGE_PROVIDER VIEW_PROVIDER">
-                    <context link="account" jump="provider" field="owner"/>
-                </delete>
-            </actions>
-        </permacrud>
        </class>
 
 
@@ -8037,11 +5982,6 @@ 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">
@@ -8178,14 +6118,6 @@ SELECT  usr,
                        <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="entries" reltype="has_many" key="formula" map="" class="acqdfe"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
-                               <retrieve permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
-                               <update permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
-                               <delete permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
-                       </actions>
-               </permacrud>
        </class>
        <class id="acqdfe" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::distribution_formula_entry" oils_persist:tablename="acq.distribution_formula_entry" reporter:label="Distribution Formula Entry">
                <fields oils_persist:primary="id" oils_persist:sequence="acq.distribution_formula_entry_id_seq">
@@ -8201,22 +6133,6 @@ SELECT  usr,
                        <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
                        <link field="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_ACQ_DISTRIB_FORMULA">
-                                       <context link="formula" field="owner"/>
-                               </create>
-                               <retrieve permission="ADMIN_ACQ_DISTRIB_FORMULA">
-                                       <context link="formula" field="owner"/>
-                               </retrieve>
-                               <update permission="ADMIN_ACQ_DISTRIB_FORMULA">
-                                       <context link="formula" field="owner"/>
-                               </update>
-                               <delete permission="ADMIN_ACQ_DISTRIB_FORMULA">
-                                       <context link="formula" field="owner"/>
-                               </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqdfa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::distribution_formula_application" oils_persist:tablename="acq.distribution_formula_application" reporter:label="Distribution Formula Application">
@@ -8232,22 +6148,6 @@ SELECT  usr,
                        <link field="formula" reltype="has_a" key="id" map="" class="acqdf"/>
                        <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="CREATE_PURCHASE_ORDER">
-                                       <context link="formula" field="owner"/>
-                </create>
-                               <retrieve permission="CREATE_PURCHASE_ORDER">
-                                       <context link="formula" field="owner"/>
-                </retrieve>
-                               <update permission="CREATE_PURCHASE_ORDER">
-                                       <context link="formula" field="owner"/>
-                </update>
-                               <delete permission="CREATE_PURCHASE_ORDER">
-                                       <context link="formula" field="owner"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqda" controller="open-ils.cstore" oils_obj:fieldmapper="acq::debit_attribution" oils_persist:tablename="acq.debit_attribution" reporter:label="Debit Attribution">
@@ -8274,14 +6174,6 @@ SELECT  usr,
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_CLAIM_TYPE" context_field="org_unit"/>
-                               <retrieve permission="ADMIN_ACQ_CLAIM_TYPE ADMIN_ACQ_CLAIM VIEW_CLAIM MANAGE_CLAIM" context_field="org_unit"/>
-                               <update permission="ADMIN_ACQ_CLAIM_TYPE" context_field="org_unit"/>
-                               <delete permission="ADMIN_ACQ_CLAIM_TYPE" context_field="org_unit"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqclet" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::claim_event_type" oils_persist:tablename="acq.claim_event_type" reporter:label="Claim Event Type">
@@ -8295,14 +6187,6 @@ SELECT  usr,
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_CLAIM_EVENT_TYPE" context_field="org_unit"/>
-                               <retrieve permission="ADMIN_ACQ_CLAIM_EVENT_TYPE ADMIN_ACQ_CLAIM VIEW_CLAIM MANAGE_CLAIM" context_field="org_unit"/>
-                               <update permission="ADMIN_ACQ_CLAIM_EVENT_TYPE" context_field="org_unit"/>
-                               <delete permission="ADMIN_ACQ_CLAIM_EVENT_TYPE" context_field="org_unit"/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="acqcl" controller="open-ils.cstore" oils_obj:fieldmapper="acq::claim" oils_persist:tablename="acq.claim" reporter:label="Claim">
@@ -8371,14 +6255,6 @@ SELECT  usr,
                <links>
                        <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-            <actions>
-                <create   permission="ADMIN_CLAIM_POLICY" context_field="org_unit"/>
-                <retrieve permission="ADMIN_CLAIM_POLICY VIEW_PROVIDER" context_field="org_unit"/>
-                <update   permission="ADMIN_CLAIM_POLICY" context_field="org_unit"/>
-                <delete   permission="ADMIN_CLAIM_POLICY" context_field="org_unit"/>
-            </actions>
-               </permacrud>
        </class>
 
        <class id="acqclpa" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::claim_policy_action" oils_persist:tablename="acq.claim_policy_action" reporter:label="Claim Policy Action">
@@ -8392,22 +6268,6 @@ SELECT  usr,
                        <link field="claim_policy" reltype="has_a" key="id" map="" class="acqclp"/>
                        <link field="action" reltype="has_a" key="id" map="" class="acqclet"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_CLAIM_POLICY">
-                                       <context link="claim_policy" field="org_unit"/>
-                </create>
-                               <retrieve permission="ADMIN_CLAIM_POLICY VIEW_PROVIDER">
-                                       <context link="claim_policy" field="org_unit"/>
-                </retrieve>
-                               <update permission="ADMIN_CLAIM_POLICY">
-                                       <context link="claim_policy" field="org_unit"/>
-                </update>
-                               <delete permission="ADMIN_CLAIM_POLICY">
-                                       <context link="claim_policy" field="org_unit"/>
-                </delete>
-                       </actions>
-               </permacrud>
        </class>
 
     <class id="stgu" controller="open-ils.cstore" oils_obj:fieldmapper="staging::user_stage" oils_persist:tablename="staging.user_stage" reporter:label="User Stage">
@@ -8559,14 +6419,6 @@ SELECT  usr,
     </class>
 
     <class id="aufhol" controller="open-ils.cstore" oils_obj:fieldmapper="action::unfulfilled_hold_outermost_loop" oils_persist:readonly="true">
-               <oils_persist:source_definition>
-
-           SELECT  DISTINCT l.*
-             FROM  action.unfulfilled_hold_loops l
-                   JOIN action.unfulfilled_hold_max_loop m USING (hold)
-             WHERE l.count = m.max
-
-               </oils_persist:source_definition>
         <fields>
             <field reporter:label="Hold ID" name="hold" reporter:datatype="link"/>
             <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="link"/>
@@ -9048,11 +6900,6 @@ SELECT  usr,
                        <field reporter:label="Default Value" name="default_val" reporter:datatype="text"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="cmpctm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::marc21_physical_characteristic_type_map" oils_persist:tablename="config.marc21_physical_characteristic_type_map" reporter:label="MARC21 Physical Characteristic Type Map" oils_persist:field_safe="true">
@@ -9061,11 +6908,6 @@ SELECT  usr,
                        <field reporter:label="Label" name="label" reporter:datatype="text"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="cmpcsm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::marc21_physical_characteristic_subfield_map" oils_persist:tablename="config.marc21_physical_characteristic_subfield_map" reporter:label="MARC21 Physical Characteristic Subfield Map" oils_persist:field_safe="true">
@@ -9080,11 +6922,6 @@ SELECT  usr,
                <links>
                        <link field="ptype_key" reltype="has_a" key="id" map="" class="cmpctm"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="cmpcvm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::marc21_physical_characteristic_value_map" oils_persist:tablename="config.marc21_physical_characteristic_value_map" reporter:label="MARC21 Physical Characteristic Value Map" oils_persist:field_safe="true">
@@ -9097,11 +6934,6 @@ SELECT  usr,
                <links>
                        <link field="ptype_subfield" reltype="has_a" key="id" map="" class="cmpcsm"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </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">
@@ -9111,26 +6943,9 @@ SELECT  usr,
                        <field reporter:label="BLvl Value" name="blvl_val" reporter:datatype="text"/>
                </fields>
                <links/>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="rlcd" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="reporter::last_copy_deleted" oils_persist:readonly="true" reporter:core="true" reporter:label="Last Copy Delete Time">
-               <oils_persist:source_definition>
-
-            SELECT  b.id,
-                    MAX(dcp.edit_date) AS last_delete_date
-             FROM   biblio.record_entry b
-                    JOIN asset.call_number cn ON (cn.record = b.id)
-                    JOIN asset.copy dcp ON (cn.id = dcp.call_number)
-             WHERE  NOT b.deleted
-             GROUP BY b.id
-             HAVING SUM( CASE WHEN NOT dcp.deleted THEN 1 ELSE 0 END) = 0 
-
-               </oils_persist:source_definition>
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry">
                        <field reporter:label="Record ID" name="id" reporter:datatype="id"/>
                        <field reporter:label="Delete Date/Time" name="last_delete_date" reporter:datatype="timestamp"/>
@@ -9138,62 +6953,9 @@ SELECT  usr,
                <links>
                        <link field="id" 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="rhcrpb" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="reporter::hold_copy_ratio_per_bib" oils_persist:readonly="true" reporter:core="true" reporter:label="Hold/Copy Ratio per Bib">
-               <oils_persist:source_definition>
-
-            -- -- If we uncomment the RIGHT JOIN against biblio.record_entry, then we'll get a row for every non-deleted bib, whether it has active holds or not.
-            -- -- If we expect to use pcrud to query against specific bibs, we probably want to do this.  However, if we're using this to populate a report, we
-            -- -- may not.
-            -- SELECT
-            --     bre.id AS "bib_id",
-            --     COALESCE( z.copy_count, 0 ) AS "copy_count",
-            --     COALESCE( z.hold_count, 0 ) AS "hold_count",
-            --     COALESCE( z.copy_hold_ratio, 0 ) AS "hold_copy_ratio"
-            -- FROM (
-                SELECT
-                    y.bre AS "id",
-                    COALESCE( x.copy_count, 0 ) AS "copy_count",
-                    y.hold_count AS "hold_count",
-                    (y.hold_count::REAL / (CASE WHEN x.copy_count = 0 OR x.copy_count IS NULL THEN 0.1 ELSE x.copy_count::REAL END)) AS "hold_copy_ratio"
-                FROM (
-                        SELECT
-                            (SELECT bib_record FROM reporter.hold_request_record r WHERE r.id = h.id LIMIT 1) AS "bre",
-                            COUNT(*) AS "hold_count"
-                        FROM action.hold_request h
-                        WHERE
-                            cancel_time IS NULL
-                            AND fulfillment_time IS NULL
-                            -- AND NOT frozen  -- a frozen hold is still a desired hold, eh?
-                        GROUP BY 1
-                    )y LEFT JOIN (
-                        SELECT 
-                            (SELECT id
-                                FROM biblio.record_entry 
-                                WHERE id = (SELECT record FROM asset.call_number WHERE id = call_number)
-                            ) AS "bre", 
-                            COUNT(*) AS "copy_count"
-                        FROM asset.copy
-                            JOIN asset.copy_location loc ON (copy.location = loc.id AND loc.holdable)
-                        WHERE copy.holdable 
-                            AND NOT copy.deleted 
-                            AND copy.status IN ( SELECT id FROM config.copy_status WHERE holdable ) 
-                        GROUP BY 1
-                    )x ON x.bre = y.bre
-                -- )z RIGHT JOIN (
-                --     SELECT id
-                --     FROM biblio.record_entry
-                --     WHERE NOT deleted
-                -- )bre ON (z.bib_id = bre.id)
-                
-
-               </oils_persist:source_definition>
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry">
                        <field reporter:label="Record ID" name="id" reporter:datatype="id"/>
                        <field reporter:label="Holdable Copy Count" name="copy_count" reporter:datatype="int"/>
@@ -9203,43 +6965,9 @@ SELECT  usr,
                <links>
                        <link field="id" 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="rhcrpbap" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="reporter::hold_copy_ratio_per_bib_and_pickup" oils_persist:readonly="true" reporter:label="Hold/Copy Ratio per Bib and Pickup Library">
-               <oils_persist:source_definition>
-            SELECT *,
-                CASE WHEN copy_count_at_pickup_library = 0 THEN 'Infinity'::FLOAT ELSE holds_at_pickup_library::FLOAT/copy_count_at_pickup_library END AS pickup_library_ratio,
-                CASE WHEN copy_count_everywhere = 0 THEN 'Infinity'::FLOAT ELSE holds_everywhere::FLOAT/copy_count_everywhere END AS everywhere_ratio
-            FROM
-                (SELECT bib_record as id, pickup_lib, count(DISTINCT ahr.id) AS holds_at_pickup_library, COALESCE(count(DISTINCT ac.id),0) as copy_count_at_pickup_library
-                    FROM
-                        action.hold_request ahr
-                        JOIN reporter.hold_request_record rhrr USING (id)
-                        LEFT JOIN action.hold_copy_map ahcm ON (ahr.id = ahcm.hold)
-                        LEFT JOIN asset.copy ac ON (ahcm.target_copy = ac.id AND ahr.pickup_lib = ac.circ_lib)
-                    WHERE
-                        ahr.cancel_time IS NULL
-                        AND ahr.fulfillment_time IS NULL
-                    GROUP BY bib_record, pickup_lib
-                )x
-                JOIN
-                (SELECT bib_record as id, count(DISTINCT ahr.id) AS holds_everywhere, COALESCE(count(DISTINCT target_copy),0) as copy_count_everywhere
-                    FROM
-                        action.hold_request ahr
-                        JOIN reporter.hold_request_record rhrr USING (id)
-                        LEFT JOIN action.hold_copy_map ahcm ON (ahr.id = ahcm.hold)
-                    WHERE
-                        ahr.cancel_time IS NULL
-                        AND ahr.fulfillment_time IS NULL
-                    GROUP BY bib_record
-                )y
-                USING (id)
-               </oils_persist:source_definition>
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry">
                        <field reporter:label="Record ID" name="id" reporter:datatype="link"/>
                        <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
@@ -9254,33 +6982,9 @@ SELECT  usr,
                        <link field="id" reltype="has_a" key="id" map="" class="bre"/>
                        <link field="pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
        </class>
 
        <class id="rlc" controller="open-ils.cstore open-ils.pcrud open-ils.reporter-store" oils_obj:fieldmapper="reporter::last_circ_date" oils_persist:readonly="true" reporter:label="Last Circulation or Creation Date">
-               <oils_persist:source_definition>
-            SELECT
-                ac.id,
-                COALESCE(MAX(actac.xact_start), ac.create_date) AS last_circ_or_create,
-                MAX(actac.xact_start) AS last_circ
-            FROM asset.copy ac
-                 LEFT JOIN action.all_circulation actac ON ac.id = actac.target_copy
-            GROUP BY ac.id
-
-            -- Alternate version, say if you have migrated last checkout information in extend_reporter.legacy_circ_timestamp:
-            --SELECT
-            --    ac.id,
-            --    GREATEST(MAX(actac.xact_start), erlct.last_cko_ts, ac.create_date) AS last_circ_or_create,
-            --    GREATEST(MAX(actac.xact_start), erlct.last_cko_ts) AS last_circ
-            --FROM asset.copy ac
-            --     LEFT JOIN action.all_circulation actac ON ac.id = actac.target_copy
-            --     LEFT JOIN extend_reporter.legacy_circ_timestamp erlct ON ac.id = erlct.id
-            --GROUP BY ac.id, ac.create_date, erlct.last_cko_ts
-               </oils_persist:source_definition>
                <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry">
                        <field reporter:label="Copy ID" name="id" reporter:datatype="link"/>
                        <field reporter:label="Last Circulation or Creation Date" name="last_circ_or_create" reporter:datatype="timestamp"/>
@@ -9289,708 +6993,5 @@ SELECT  usr,
                <links>
                        <link field="id" reltype="has_a" key="id" map="" class="acp"/>
                </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </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. -->
-       <!-- ********************************************************************************************************************* -->
-       <class id="rccc" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::classic_current_circ" oils_persist:tablename="reporter.classic_current_circ" reporter:core="true" reporter:label="Classic Circulation View">
-               <fields oils_persist:primary="id">
-                       <field reporter:label="Circulation" name="id" reporter:datatype="id" />
-                       <field reporter:label="Library Circulation Location Short (Policy) Name" name="circ_lib" reporter:datatype="text"/>
-                       <field reporter:label="Library Circulation Location Link" name="circ_lib_id" reporter:datatype="org_unit"/>
-                       <field reporter:label="Circulation Date/Time" name="xact_start" reporter:datatype="timestamp"/>
-                       <field reporter:label="Circulation Type" name="circ_type" reporter:datatype="text"/>
-                       <field reporter:label="Copy Link" name="copy_id" reporter:datatype="link"/>
-                       <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="text"/>
-                       <field reporter:label="Owning Library Short (Policy) Name" name="owning_lib_name" reporter:datatype="text"/>
-                       <field reporter:label="Item Language" name="language" reporter:datatype="text"/>
-                       <field reporter:label="Literary Form" name="lit_form" reporter:datatype="text"/>
-                       <field reporter:label="MARC Form" name="item_form" reporter:datatype="text"/>
-                       <field reporter:label="MARC Type" name="item_type" reporter:datatype="text"/>
-                       <field reporter:label="Shelving Location" name="shelving_location" reporter:datatype="text"/>
-                       <field reporter:label="Patron Profile Group" name="profile_group" reporter:datatype="text"/>
-                       <field reporter:label="Patron Age Demographic" name="demographic_general_division" reporter:datatype="text"/>
-                       <field reporter:label="Call Number Link" name="call_number" reporter:datatype="link"/>
-                       <field reporter:label="Call Number Label" name="call_number_label" reporter:datatype="text"/>
-                       <field reporter:label="Call Number Dewey/Prefix" name="dewey" reporter:datatype="text"/>
-                       <field reporter:label="Patron Link" name="patron_id" reporter:datatype="link"/>
-                       <field reporter:label="Patron Home Library Link" name="patron_home_lib" reporter:datatype="link"/>
-                       <field reporter:label="Patron Home Library Short (Policy) Name" name="patron_home_lib_shortname" reporter:datatype="text"/>
-                       <field reporter:label="Patron County" name="patron_county" reporter:datatype="text"/>
-                       <field reporter:label="Patron City" name="patron_city" reporter:datatype="text"/>
-                       <field reporter:label="Patron ZIP Code" name="patron_zip" reporter:datatype="text"/>
-                       <field reporter:label="Legacy CAT1 Link" name="stat_cat_1" reporter:datatype="link"/>
-                       <field reporter:label="Legacy CAT2 Link" name="stat_cat_2" reporter:datatype="link"/>
-                       <field reporter:label="Dewey Range - Tens" name="dewey_range_tens" reporter:datatype="text"/>
-                       <field reporter:label="Dewey Range - Hundreds" name="dewey_range_hundreds" reporter:datatype="text"/>
-                       <field reporter:label="Dewey Block - Tens" name="dewey_block_tens" reporter:datatype="text"/>
-                       <field reporter:label="Dewey Block - Hundreds" name="dewey_block_hundreds" reporter:datatype="text"/>
-                       <field reporter:label="Legacy CAT1 Value" name="stat_cat_1_value" reporter:datatype="text"/>
-                       <field reporter:label="Legacy CAT2 Value" name="stat_cat_2_value" reporter:datatype="text"/>
-               </fields>
-               <links>
-                       <link field="id" reltype="has_a" key="id" map="" class="circ"/>
-                       <link field="copy_id" reltype="has_a" key="id" map="" class="acp"/>
-                       <link field="patron_id" reltype="has_a" key="id" map="" class="au"/>
-                       <link field="circ_lib_id" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
-                       <link field="patron_home_lib" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="stat_cat_1" reltype="has_a" key="id" map="" class="rsce1"/>
-                       <link field="stat_cat_2" reltype="has_a" key="id" map="" class="rsce2"/>
-               </links>
-       </class>
-
-       <class id="rsce1" controller="open-ils.reporter-store open-ils.cstore" oils_obj:fieldmapper="reporter::legacy_cat1" oils_persist:tablename="reporter.legacy_cat1" reporter:label="CAT1 Entry">
-               <fields oils_persist:primary="id">
-                       <field reporter:label="Entry ID" name="id" reporter:selector="value" reporter:datatype="id" />
-                       <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
-                       <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
-               </fields>
-               <links>
-                       <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
-               </links>
-       </class>
-
-       <class id="rsce2" controller="open-ils.reporter-store open-ils.cstore" oils_obj:fieldmapper="reporter::legacy_cat2" oils_persist:tablename="reporter.legacy_cat2" reporter:label="CAT2 Entry">
-               <fields oils_persist:primary="id">
-                       <field reporter:label="Entry ID" name="id" reporter:selector="value" reporter:datatype="id" />
-                       <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
-                       <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
-               </fields>
-               <links>
-                       <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
-               </links>
-       </class>
-
-       <class id="rccbs" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::classic_current_billing_summary" oils_persist:tablename="reporter.classic_current_billing_summary" reporter:core="true" reporter:label="Classic Open Transaction Summary">
-               <fields oils_persist:primary="id">
-                       <field reporter:label="Transaction ID" name="id" reporter:datatype="id" />
-
-                       <field reporter:label="Billing Location Short (Policy) Name" name="billing_location_shortname" reporter:datatype="text"/>
-                       <field reporter:label="Billing Location Name" name="billing_location_name" reporter:datatype="text"/>
-                       <field reporter:label="Billing Location Link" name="billing_location" reporter:datatype="org_unit"/>
-
-                       <field reporter:label="User Home Library Short (Policy) Name" name="usr_home_ou_shortname" reporter:datatype="text"/>
-                       <field reporter:label="User Home Library Name" name="usr_home_ou_name" reporter:datatype="text"/>
-                       <field reporter:label="User Home Library Link" name="usr_home_ou" reporter:datatype="org_unit"/>
-
-                       <field reporter:label="User Barcode" name="barcode" reporter:datatype="text"/>
-                       <field reporter:label="User Link" name="usr" reporter:datatype="link"/>
-
-                       <field reporter:label="Transaction Start Date/Time" name="xact_start" reporter:datatype="timestamp"/>
-                       <field reporter:label="Transaction End Date/Time" name="xact_finish" reporter:datatype="timestamp"/>
-                       <field reporter:label="Transaction Type" name="xact_type" reporter:datatype="text"/>
-
-                       <field reporter:label="Total Paid" name="total_paid" reporter:datatype="money"/>
-                       <field reporter:label="Total Billed" name="total_owed" reporter:datatype="money"/>
-
-                       <field reporter:label="Last Payment Date/Time" name="last_payment_ts" reporter:datatype="timestamp"/>
-                       <field reporter:label="Last Payment Note" name="last_payment_note" reporter:datatype="text"/>
-                       <field reporter:label="Last Payment Type" name="last_payment_type" reporter:datatype="text"/>
-
-                       <field reporter:label="Last Billing Date/Time" name="last_billing_ts" reporter:datatype="timestamp"/>
-                       <field reporter:label="Last Billing Note" name="last_billing_note" reporter:datatype="text"/>
-                       <field reporter:label="Last Billing Type" name="last_billing_type" reporter:datatype="text"/>
-
-                       <field reporter:label="User Age Demographic" name="demographic_general_division" reporter:datatype="text"/>
-                       <field reporter:label="User County" name="patron_county" reporter:datatype="text"/>
-                       <field reporter:label="User City" name="patron_city" reporter:datatype="text"/>
-                       <field reporter:label="User ZIP Code" name="patron_zip" reporter:datatype="text"/>
-
-                       <field reporter:label="Balance Owed" name="balance_owed" reporter:datatype="money"/>
-                       <field reporter:label="User Profile Group" name="profile_group" reporter:datatype="text"/>
-
-               </fields>
-               <links>
-                       <link field="id" reltype="has_a" key="id" map="" class="mbt"/>
-                       <link field="usr" reltype="has_a" key="id" map="" class="au"/>
-                       <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="usr_home_ou" reltype="has_a" key="id" map="" class="aou"/>
-               </links>
-       </class>
-
-       <class id="acrlid" controller="open-ils.cstore" oils_obj:fieldmapper="acq::claim_ready_lineitem_detail" oils_persist:readonly="true" reporter:label="Claim Ready Lineitem Details">
-               <oils_persist:source_definition>
-
-            SELECT
-                po.ordering_agency AS ordering_agency,
-                po.id AS purchase_order,
-                li.id AS lineitem,
-                lid.id AS lineitem_detail,
-                cpa.id AS claim_policy_action
-            FROM
-                acq.lineitem_detail lid
-                JOIN acq.lineitem li ON (li.id = lid.lineitem)
-                JOIN acq.purchase_order po ON (po.id = li.purchase_order)
-                JOIN acq.claim_policy cp ON (li.claim_policy = cp.id)
-                JOIN acq.claim_policy_action cpa ON (
-                    cpa.claim_policy = cp.id
-
-                    -- we only care about claim policy actions whose claim
-                    -- interval we'd reached or exceeded
-                    AND (NOW() - cpa.action_interval) &gt; po.order_date
-
-                    -- filter out all claim policy actions where claim events
-                    -- have occurred on or after the action's action_interval
-                    AND NOT EXISTS (
-                        SELECT 1
-                        FROM
-                            acq.claim_event evt
-                            JOIN acq.claim claim ON (
-                                claim.id = evt.claim
-                                AND claim.lineitem_detail = lid.id
-                            )
-                        WHERE
-                            evt.event_date &gt;= (po.order_date + cpa.action_interval)
-                    )
-                )
-            WHERE
-                lid.cancel_reason IS NULL
-                AND li.cancel_reason IS NULL -- belt/suspenders
-                AND po.cancel_reason IS NULL -- belt/suspenders
-                AND lid.recv_time IS NULL
-                AND po.state = 'on-order'
-            ORDER BY 1, 2, 3, 4, 5
-
-               </oils_persist:source_definition>
-               <fields>
-                       <field reporter:label="Ordering Agency" name="ordering_agency" reporter:datatype="link"/>
-                       <field reporter:label="Purchase Order" name="purchase_order" reporter:datatype="link"/>
-                       <field reporter:label="Lineitem" name="lineitem" reporter:datatype="link"/>
-                       <field reporter:label="Lineitem Detail" name="lineitem_detail" reporter:datatype="link"/>
-                       <field reporter:label="Claim Policy Action" name="claim_policy_action" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="ordering_agency" reltype="has_a" key="id" map="" class="aou"/>
-                       <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="lineitem_detail" reltype="has_a" key="id" map="" class="acqlid"/>
-                       <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">
-               <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
-        </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="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="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>
-
-                       SELECT  t.*
-                         FROM  action.transit_copy t
-                               JOIN actor.org_unit AS s ON (t.source = s.id)
-                               JOIN actor.org_unit AS d ON (t.dest = d.id)
-                         WHERE s.parent_ou &lt;&gt; d.parent_ou
-
-               </oils_persist:source_definition>
-               <fields oils_persist:primary="id" oils_persist:sequence="action.transit_copy_id_seq">
-                       <field reporter:label="Pretransit Copy Status" name="copy_status" reporter:datatype="link"/>
-                       <field reporter:label="Destination" name="dest" reporter:datatype="link"/>
-                       <field reporter:label="Receive Date/Time" name="dest_recv_time" reporter:datatype="timestamp"/>
-                       <field reporter:label="Transit ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Is Persistent? (unused)" name="persistant_transfer" reporter:datatype="bool"/>
-                       <field reporter:label="Previous Hop (unused)" name="prev_hop" reporter:datatype="link"/>
-                       <field reporter:label="Source" name="source" reporter:datatype="link"/>
-                       <field reporter:label="Send Date/Time" name="source_send_time" reporter:datatype="timestamp"/>
-                       <field reporter:label="Transited Copy" name="target_copy" reporter:datatype="link"/>
-                       <field reporter:label="Hold Transit" name="hold_transit_copy" oils_persist:virtual="true" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="hold_transit_copy" reltype="might_have" key="id" map="" class="ahtc"/>
-                       <link field="source" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="copy_status" reltype="has_a" key="id" map="" class="ccs"/>
-                       <link field="dest" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
-                       <link field="prev_hop" reltype="has_a" key="id" map="" class="atc"/>
-               </links>
-       </class>
-
-    <class id="circbyyr" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::circ_counts_by_year" oils_persist:readonly="true">
-               <oils_persist:source_definition>
-
-       SELECT copy, SUM(count) AS count, year, is_renewal FROM (
-               SELECT
-                       cp.id as copy,
-                       COUNT(circ.id),
-                       EXTRACT(YEAR FROM circ.xact_start) AS year,
-                       (phone_renewal OR desk_renewal OR opac_renewal) as is_renewal
-               FROM
-                       asset.copy cp
-                               JOIN action.circulation circ ON (cp.id = circ.target_copy)
-               GROUP BY 1, 3, 4
-               UNION
-               SELECT
-                       cp.id as copy,
-                       COUNT(circ.id),
-                       EXTRACT(YEAR FROM circ.xact_start) AS year,
-                       (phone_renewal OR desk_renewal OR opac_renewal) as is_renewal
-               FROM
-                       asset.copy cp
-                               JOIN action.aged_circulation circ ON (cp.id = circ.target_copy)
-               GROUP BY 1, 3, 4
-               UNION
-               SELECT
-                       id as copy,
-                       circ_count,
-                       -1 AS year,
-                       false as is_renewal
-               FROM
-                       extend_reporter.legacy_circ_count
-       )x GROUP BY 1, 3, 4
-
-               </oils_persist:source_definition>
-        <fields>
-            <field reporter:label="Copy ID" name="copy" reporter:datatype="link"/>
-            <field reporter:label="Count" name="count" reporter:datatype="int"/>
-            <field reporter:label="Year" name="year" reporter:datatype="int"/>
-            <field reporter:label="Renewal" name="is_renewal" reporter:datatype="bool"/>
-        </fields>
-               <links>
-                       <link field="copy" reltype="has_a" key="id" map="" class="acp"/>
-               </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <retrieve/>
-                       </actions>
-               </permacrud>
-    </class>
-
-       <class id="rodcirc" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::overdue_circs" oils_persist:tablename="reporter.overdue_circs" reporter:core="true" reporter:label="Overdue 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"/>
-                       <field reporter:label="Check In Date/Time" name="checkin_time" reporter:datatype="timestamp"/>
-                       <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
-                       <field reporter:label="Circulating Staff" name="circ_staff" reporter:datatype="link"/>
-                       <field reporter:label="Desk Renewal" name="desk_renewal" reporter:datatype="bool"/>
-                       <field reporter:label="Due Date/Time" name="due_date" reporter:datatype="timestamp"/>
-                       <field reporter:label="Circulation Duration" name="duration" reporter:datatype="interval"/>
-                       <field reporter:label="Circ Duration Rule" name="duration_rule" reporter:datatype="link"/>
-                       <field reporter:label="Fine Interval" name="fine_interval" reporter:datatype="interval"/>
-                       <field reporter:label="Circ ID" name="id" reporter:datatype="id" />
-                       <field reporter:label="Max Fine Amount" name="max_fine" reporter:datatype="money" />
-                       <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
-                       <field reporter:label="OPAC Renewal" name="opac_renewal" reporter:datatype="bool"/>
-                       <field reporter:label="Phone Renewal" name="phone_renewal" reporter:datatype="bool"/>
-                       <field reporter:label="Recurring Fine Amount" name="recurring_fine" reporter:datatype="money" />
-                       <field reporter:label="Recurring Fine Rule" name="recurring_fine_rule" reporter:datatype="link"/>
-                       <field reporter:label="Remaining Renewals" name="renewal_remaining" reporter:datatype="int" />
-                       <field reporter:label="Fine Stop Reason" name="stop_fines" reporter:datatype="text"/>
-                       <field reporter:label="Fine Stop Date/Time" name="stop_fines_time" reporter:datatype="timestamp"/>
-                       <field reporter:label="Circulating Item" name="target_copy" reporter:datatype="link"/>
-                       <field reporter:label="Patron" name="usr" reporter:datatype="link"/>
-                       <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp" />
-                       <field reporter:label="Check Out Date/Time" name="xact_start" reporter:datatype="timestamp" />
-                       <field reporter:label="Transaction Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Transaction Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Base Transaction" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Circulation Type" name="circ_type" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="link"/>
-                       <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
-                       <link field="circ_staff" reltype="has_a" key="id" map="" class="au"/>
-                       <link field="checkin_lib" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
-                       <link field="checkin_staff" reltype="has_a" key="id" map="" class="au"/>
-                       <link field="usr" reltype="has_a" key="id" map="" class="au"/>
-                       <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
-                       <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
-                       <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
-                       <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
-                       <link field="recurring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
-                       <link field="circ_type" reltype="might_have" key="id" map="" class="rcirct"/>
-                       <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
-                       <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
-               </links>
-       </class>
-
-    <class id="rocit" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::classic_item_list" oils_persist:tablename="reporter.classic_item_list" reporter:core="true" reporter:label="Classic Item List">
-        <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="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"/>
-            <field reporter:label="Callnumber Label" name="call_number_label" reporter:datatype="text"/>
-            <field reporter:label="Dewy Tens" name="dewey_block_tens" reporter:datatype="text"/>
-            <field reporter:label="Dewy Hundreds" name="dewey_block_hundreds" reporter:datatype="text"/>
-            <field reporter:label="Use Count" name="use_count" reporter:datatype="int"/>
-            <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="text"/>
-            <field reporter:label="Shelving Location Name" name="shelving_location" reporter:datatype="text"/>
-            <field reporter:label="Legacy Stat Cat 1" name="stat_cat_1" reporter:datatype="text"/>
-            <field reporter:label="Legacy Stat Cat 2" name="stat_cat_2" reporter:datatype="text"/>
-            <field reporter:label="Legacy Stat Cat 1 Value" name="stat_cat_1_value" reporter:datatype="text"/>
-            <field reporter:label="Legacy Stat Cat 2 Value" name="stat_cat_2_value" reporter:datatype="text"/>
-            <field reporter:label="Edit Date" name="edit_date" reporter:datatype="timestamp"/>
-            <field reporter:label="Create Date" name="create_date" reporter:datatype="timestamp"/>
-            <field reporter:label="Owning Lib Name" name="owning_lib_name" reporter:datatype="text"/>
-            <field reporter:label="Circ Lib Name" name="circ_lib_name" reporter:datatype="text"/>
-            <field reporter:label="Owning Lib" name="owning_lib" reporter:datatype="link"/>
-            <field reporter:label="Circ Lib" name="circ_lib" reporter:datatype="link"/>
-            <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
-            <field reporter:label="Age Protection" name="age_protect" reporter:datatype="link"/>
-            <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
-            <field reporter:label="Reference" name="ref" reporter:datatype="bool"/>
-            <field reporter:label="Deposit Amount" name="deposit_amount" reporter:datatype="text"/>
-            <field reporter:label="Deleted" name="deleted" reporter:datatype="bool"/>
-            <field reporter:label="TCN" name="tcn_value" reporter:datatype="text"/>
-            <field reporter:label="Status" name="status" reporter:datatype="link"/>
-            <field reporter:label="Stop Fines Reason" name="stop_fines" reporter:datatype="text"/>
-            <field reporter:label="Due Date" name="due_date" reporter:datatype="timestamp"/>
-            <field reporter:label="Patron Barcode" name="patron_barcode" reporter:datatype="text"/>
-            <field reporter:label="Patron Name" name="patron_name" reporter:datatype="text"/>
-        </fields>
-        <links>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-            <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"/>
-            <link field="status" reltype="has_a" key="id" map="" class="ccs"/>
-        </links>
-    </class>
-
-    <class id="rmocbbol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_circ_balance_by_owning_lib" oils_persist:tablename="money.open_circ_balance_by_owning_lib" reporter:core="true" reporter:label="Open Circulation Billing by Owning Library">
-        <fields oils_persist:primary="id">
-            <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
-            <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="id" reltype="has_a" key="id" map="" class="circ"/>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-
-    <class id="rmobbol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_balance_by_owning_lib" oils_persist:tablename="money.open_balance_by_owning_lib" reporter:core="true" reporter:label="Open Circulation Balance by Owning Library">
-        <fields oils_persist:primary="owning_lib">
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
-            <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-
-    <class id="rmocbbcol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_circ_balance_by_circ_and_owning_lib" oils_persist:tablename="money.open_circ_balance_by_circ_and_owning_lib" reporter:core="true" reporter:label="Open Circulation Billing by Circulating Library and Owning Library">
-        <fields oils_persist:primary="id">
-            <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
-            <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
-            <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="id" reltype="has_a" key="id" map="" class="circ"/>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-            <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-
-    <class id="rmobbcol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_balance_by_circ_and_owning_lib" oils_persist:tablename="money.open_balance_by_circ_and_owning_lib" reporter:core="true" reporter:label="Open Circulation Balance by Circulating Library and Owning Library">
-        <fields oils_persist:primary="circ_lib">
-            <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
-            <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-            <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-
-    <class id="rmocbbhol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_circ_balance_by_usr_home_and_owning_lib" oils_persist:tablename="money.open_circ_balance_by_usr_home_and_owning_lib" reporter:core="true" reporter:label="Open Circulation Billing by User Home Library and Owning Library">
-        <fields oils_persist:primary="id">
-            <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
-            <field reporter:label="User Home Library" name="home_ou" reporter:datatype="org_unit"/>
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
-            <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="id" reltype="has_a" key="id" map="" class="circ"/>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-            <link field="home_ou" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-
-    <class id="rmobbhol" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::money::open_balance_by_usr_home_and_owning_lib" oils_persist:tablename="money.open_balance_by_usr_home_and_owning_lib" reporter:core="true" reporter:label="Open Circulation Balance by User Home Library and Owning Library">
-        <fields oils_persist:primary="home_ou">
-            <field reporter:label="User Home Library" name="home_ou" reporter:datatype="org_unit"/>
-            <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
-            <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
-            <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
-        </fields>
-        <links>
-            <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
-            <link field="home_ou" reltype="has_a" key="id" map="" class="aou"/>
-        </links>
-    </class>
-       <class id="acqft" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund_tag" oils_persist:tablename="acq.fund_tag" reporter:label="Fund Tag">
-               <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_tag_id_seq">
-                       <field reporter:label="Fund Tag ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Fund Tag Owner" name="owner" reporter:datatype="org_unit"/>
-                       <field reporter:label="Fund Tag Name" name="name" reporter:datatype="text"/>
-                       <field reporter:label="Map Entries" name="map_entries" oils_persist:virtual="true" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
-                       <link field="map_entries" reltype="has_many" key="fund" map="" class="acqftm"/>
-               </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
-                               <retrieve permission="ADMIN_ACQ_FUND_TAG ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="owner"/>
-                               <update permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
-                       <delete permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
-                       </actions>
-               </permacrud>
        </class>
-       <class id="acqftm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund_tag_map" oils_persist:tablename="acq.fund_tag_map" reporter:label="Fund Tag Map">
-               <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_tag_map_id_seq">
-                       <field reporter:label="Map Entry ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Fund ID" name="fund" reporter:datatype="link"/>
-                       <field reporter:label="Tag ID" name="tag" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
-                       <link field="tag" reltype="has_a" key="id" map="" class="acqft"/>
-                       </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-               <actions>
-                               <create permission="ADMIN_ACQ_FUND_TAG">
-                                       <context link="tag" field="owner"/>
-                               </create>
-                               <retrieve permission="ADMIN_ACQ_FUND_TAG ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
-                                       <context link="tag" field="owner"/>
-                               </retrieve>
-                               <update permission="ADMIN_ACQ_FUND_TAG">
-                                       <context link="tag" field="owner"/>
-                               </update>
-                               <delete permission="ADMIN_ACQ_FUND_TAG">
-                                       <context link="tag" field="owner"/>
-                               </delete>
-                       </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"/>
-                       <field reporter:label="Active" name="active" reporter:datatype="bool"/>
-                       <field reporter:label="Owner" name="org_unit" reporter:datatype="org_unit"/>
-                       <field reporter:label="Prefix" name="prefix" reporter:datatype="text"/>
-                       <field reporter:label="Suffix" name="suffix" reporter:datatype="text"/>
-                       <field reporter:label="Length" name="length" reporter:datatype="int"/>
-                       <field reporter:label="Padding" name="padding" reporter:datatype="text"/>
-                       <field reporter:label="Padding At End" name="padding_end" reporter:datatype="bool"/>
-                       <field reporter:label="Applies to Items" name="asset" reporter:datatype="bool"/>
-                       <field reporter:label="Applies to Users" name="actor" reporter:datatype="bool"/>
-               </fields>
-               <links>
-                       <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
-               </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="UPDATE_ORG_UNIT_SETTING_ALL" context_field="org_unit"/>
-                               <retrieve/>
-                               <update permission="UPDATE_ORG_UNIT_SETTING_ALL" context_field="org_unit"/>
-                               <delete permission="UPDATE_ORG_UNIT_SETTING_ALL" context_field="org_unit"/>
-                       </actions>
-               </permacrud>
-       </class>
-
-       <class id="coustl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::org_unit_setting_type_log" oils_persist:tablename="config.org_unit_setting_type_log" reporter:label="Organizational Unit Setting Type Log">
-               <fields oils_persist:primary="date_applied" oils_persist:sequence="config.org_unit_setting_type_log_id_seq">
-                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
-                       <field name="date_applied" reporter:datatype="timestamp"/>
-                       <field name="org" reporter:datatype="org_unit"/>
-                       <field name="original_value" reporter:datatype="text"/>
-                       <field name="new_value" reporter:datatype="text"/>
-                       <field name="field_name" reporter:datatype="link"/>
-               </fields>
-               <links>
-                       <link field="field_name" reltype="has_a" key="name" map="" class="coust"/>
-                       <link field="org" reltype="has_a" key="id" map="" class="aou"/>
-               </links>
-               <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
-                       <actions>
-                               <create permission="ADMIN_ORG_UNIT_SETTING_TYPE" context_field="org"/>
-                               <retrieve/>
-                               <update permission="ADMIN_ORG_UNIT_SETTING_TYPE_LOG" context_field="org"/>
-                               <delete permission="ADMIN_ORG_UNIT_SETTING_TYPE_LOG" context_field="org"/>
-                       </actions>
-               </permacrud>
-       </class>
-       <class id="aaactsc" controller="open-ils.reporter-store" oils_obj:fieldmapper="action::archive_actor_stat_cat" oils_persist:tablename="action.archive_actor_stat_cat" reporter:label="Circ-Archived Patron Statistical Category Entries">
-               <fields oils_persist:primary="id" oils_persist:sequence="action.archive_actor_stat_cat_id_seq">
-                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Circ" name="xact" reporter:datatype="link"/>
-                       <field reporter:label="Statistical Category" name="stat_cat" reporter:datatype="link"/>
-                       <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
-               </fields>
-               <links>
-                       <link field="xact" reltype="has_a" key="id" map="" class="combcirc"/>
-                       <link field="stat_cat" reltype="has_a" key="id" map="" class="actsc"/>
-               </links>
-       </class>
-       <class id="aaasc" controller="open-ils.reporter-store" oils_obj:fieldmapper="action::archive_asset_stat_cat" oils_persist:tablename="action.archive_asset_stat_cat" reporter:label="Circ-Archived Copy Statistical Category Entries">
-               <fields oils_persist:primary="id" oils_persist:sequence="action.archive_actor_stat_cat_id_seq">
-                       <field reporter:label="ID" name="id" reporter:datatype="id"/>
-                       <field reporter:label="Circ" name="xact" reporter:datatype="link"/>
-                       <field reporter:label="Statistical Category" name="stat_cat" reporter:datatype="link"/>
-                       <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
-               </fields>
-               <links>
-                       <link field="xact" reltype="has_a" key="id" map="" class="combcirc"/>
-                       <link field="stat_cat" reltype="has_a" key="id" map="" class="asc"/>
-               </links>
-       </class>
-
-
-       <!-- ********************************************************************************************************************* -->
-
 </IDL>
-
-<!--
-    vim:noet:ts=4:sw=4:
--->
diff --git a/Open-ILS/src/Android/libs/org.openils_idl.jar b/Open-ILS/src/Android/libs/org.openils_idl.jar
deleted file mode 100644 (file)
index f3f0d6b..0000000
Binary files a/Open-ILS/src/Android/libs/org.openils_idl.jar and /dev/null differ
index 06cebce..f5a6925 100644 (file)
@@ -42,7 +42,8 @@ import android.util.Log;
 
 public class GlobalConfigs {
 
-    public static String IDL_FILE_FROM_ROOT = "/reports/fm_IDL.xml";
+    public static String IDL_FILE_FROM_ASSETS = "fm_IDL.xml";
+    public static String IDL_FILE_FROM_WEB_ROOT = "/reports/fm_IDL.xml";
 
     public static String httpAddress = "";
 
@@ -119,7 +120,7 @@ public class GlobalConfigs {
 
             }
             if (!noNetworkAccess) {
-                loadIDLFile();
+                loadIDLFile(context);
                 getOrganisations();
 
                 getCopyStatusesAvailable((ConnectivityManager) context
@@ -139,16 +140,18 @@ public class GlobalConfigs {
         return false;
     }
 
-    public void loadIDLFile() {
+    public void loadIDLFile(Context context) {
 
         try {
             Log.d("debug", "loadIDLFile start");
-            InputStream in_IDL = Utils.getNetInputStream(httpAddress
-                    + IDL_FILE_FROM_ROOT);
+            InputStream in_IDL = context.getAssets().open(IDL_FILE_FROM_ASSETS);
             IDLParser parser = new IDLParser(in_IDL);
+            parser.setKeepIDLObjects(false);
             Log.d("debug", "loadIDLFile parse");
+            long start = System.currentTimeMillis();
             parser.parse();
-            Log.d("debug", "loadIDLFile done");
+            long duration_ms = System.currentTimeMillis() - start;
+            Log.d("debug", "loadIDLFile finished in "+duration_ms+"ms");
         } catch (Exception e) {
             System.err.println("Error in parsing IDL file "
                     + IDL_FILE_FROM_ROOT + " " + e.getMessage());
@@ -209,7 +212,7 @@ public class GlobalConfigs {
                 int start = arrayContent.indexOf("[", index) + 1;
                 int stop = arrayContent.indexOf("]", index);
 
-                Log.d(TAG, " start stop length index" + start + " " + stop
+                Log.d(TAG, "start stop length index " + start + " " + stop
                         + " " + arrayContent.length() + " " + index);
                 if (start == -1 || stop == -1)
                     break;
@@ -217,8 +220,7 @@ public class GlobalConfigs {
                 index = stop + 1;
 
                 String content = arrayContent.substring(start, stop);
-
-                System.out.println("Content " + content);
+                //System.out.println("Content " + content);
 
                 StringTokenizer tokenizer = new StringTokenizer(content, ",");
 
@@ -226,7 +228,7 @@ public class GlobalConfigs {
 
                 // first is ID
                 String element = (String) tokenizer.nextElement();
-                System.out.println("Id  " + element);
+                //System.out.println("Id  " + element);
                 try {
                     org.id = Integer.parseInt(element);
                 } catch (Exception e) {
@@ -235,7 +237,7 @@ public class GlobalConfigs {
 
                 // level
                 element = (String) tokenizer.nextElement();
-                System.out.println("Level   " + element);
+                //System.out.println("Level   " + element);
                 try {
                     org.level = Integer.parseInt(element);
                 } catch (Exception e) {
@@ -244,7 +246,7 @@ public class GlobalConfigs {
 
                 // parent
                 element = (String) tokenizer.nextElement();
-                System.out.println("parent  " + element);
+                //System.out.println("parent  " + element);
                 try {
                     org.parent = Integer.parseInt(element);
                 } catch (Exception e) {
@@ -253,12 +255,12 @@ public class GlobalConfigs {
 
                 // name
                 element = (String) tokenizer.nextToken("\",");
-                System.out.println("Element  " + element);
+                //System.out.println("Element  " + element);
                 org.name = element;
 
                 // can_have_volume_boo.
                 element = (String) tokenizer.nextElement();
-                System.out.println("Element  " + element);
+                //System.out.println("Element  " + element);
                 try {
                     org.canHaveVolumesBool = Integer.parseInt(element);
                 } catch (Exception e) {
@@ -267,7 +269,7 @@ public class GlobalConfigs {
 
                 // short name
                 element = (String) tokenizer.nextToken("\",");
-                System.out.println("Element  " + element);
+                //System.out.println("Element  " + element);
                 org.shortName = element;
 
                 organisations.add(org);
@@ -369,7 +371,7 @@ public class GlobalConfigs {
 
         try {
             date = sdf.parse(dateString);
-            System.out.println(date);
+            //System.out.println(date);
         } catch (ParseException e) {
             e.printStackTrace();
         }
@@ -385,12 +387,12 @@ public class GlobalConfigs {
     public String getOrganizationName(int id) {
 
         for (int i = 0; i < organisations.size(); i++) {
-            System.out.println("Id " + organisations.get(i).id + " " + i);
+            //System.out.println("Id " + organisations.get(i).id + " " + i);
             if (organisations.get(i).id == id)
                 return organisations.get(i).name;
         }
 
-        System.out.println("out here");
+        //System.out.println("out here");
         return null;
     }
 }
index 900e8e7..4273e31 100644 (file)
@@ -241,7 +241,7 @@ public class ApplicationPreferences extends PreferenceActivity implements
                 public void run() {
                     System.out.println("FM idl download");
                     GlobalConfigs sg = GlobalConfigs.getGlobalConfigs(context);
-                    sg.loadIDLFile();
+                    sg.loadIDLFile(context);
                     sg.getOrganisations();
                     sg.getCopyStatusesAvailable((ConnectivityManager) context
                             .getSystemService(Context.CONNECTIVITY_SERVICE));
diff --git a/Open-ILS/src/Android/src/org/open_ils/Event.java b/Open-ILS/src/Android/src/org/open_ils/Event.java
new file mode 100644 (file)
index 0000000..69a73a1
--- /dev/null
@@ -0,0 +1,33 @@
+package org.open_ils;
+
+import java.util.Map;
+import java.util.HashMap;
+
+public class Event extends HashMap<String, Object> {
+
+    public Event() {
+    }
+
+    public Event(Map<String, Object> map) {
+        super(map);
+    }
+
+    public static Event parseEvent(Object map) {
+        if( map != null && map instanceof Map) {
+            Map m = (Map) map;
+            if( m.containsKey("ilsevent") && m.containsKey("textcode")) 
+                return new Event(m);
+        }
+        
+        return null;
+    }
+
+    public String getTextCode() {
+        return (String) get("textcode");
+    }
+
+    public int getCode() {
+        return Integer.parseInt((String) get("ilsevent"));
+    }
+}
+
diff --git a/Open-ILS/src/Android/src/org/open_ils/Sys.java b/Open-ILS/src/Android/src/org/open_ils/Sys.java
new file mode 100644 (file)
index 0000000..0d66edc
--- /dev/null
@@ -0,0 +1,70 @@
+package org.open_ils;
+
+import org.opensrf.*;
+import org.opensrf.util.*;
+import org.open_ils.*;
+import org.open_ils.idl.*;
+import org.opensrf.util.*;
+
+import java.util.Map;
+import java.util.HashMap;
+import java.io.IOException;
+
+
+public class Sys {
+
+    private static IDLParser idlParser = null;
+
+    /**
+     * Initializes the connection to the OpenSRF network and parses the IDL file.
+     * @param attrs A map of configuration attributes.  Options include:<br/>
+     * <ul>
+     * <li>configFile - The OpenSRF core config file</li>
+     * <li>configContext - The path to the config chunk in the config XML, typically "opensrf"</li>
+     * <li>logProtocol - Currently supported option is "file".</li>
+     * <li>logLevel - The log level.  Options are 1,2,3, or 4 (error, warn, info, debug)</li>
+     * <li>syslogFacility - For future use, when syslog is a supported log option</li>
+     * <li>idlFile - The path to the IDL file.  May be relative or absolute.  If this option is 
+     * not provided, the system will ask the OpenSRF Settings server for the IDL file path.</li>
+     * </ul>
+     */
+    public static void init(Map<String, String> attrs) throws ConfigException, SessionException, IOException, IDLException {
+
+        String configFile = attrs.get("configFile");
+        String configContext = attrs.get("configContext");
+        String logProto = attrs.get("logProtocol");
+        String logFile = attrs.get("logFile");
+        String logLevel = attrs.get("logLevel");
+        String syslogFacility = attrs.get("syslogFacility");
+        String idlFile = attrs.get("idlFile");
+
+
+        if(idlParser != null) {
+            /** if we've parsed the IDL file, then all of the global setup has been done.
+            *   We just need to verify this thread is connected to the OpenSRF network. */
+            org.opensrf.Sys.bootstrapClient(configFile, configContext);
+            return;
+        }
+
+        /** initialize the logging infrastructure */
+        if("file".equals(logProto))
+            Logger.init(Short.parseShort(logLevel), new FileLogger(logFile));
+
+        if("syslog".equals(logProto)) 
+            throw new ConfigException("syslog not yet implemented");
+
+        /** connect to the opensrf network. */
+        org.opensrf.Sys.bootstrapClient(configFile, configContext);
+
+        /** Grab the IDL file setting if not explicitly provided */
+        if(idlFile == null) {
+            SettingsClient client = SettingsClient.instance();
+            idlFile = client.getString("/IDL");
+        }
+
+        /** Parse the IDL if necessary */
+        idlParser = new IDLParser(idlFile);
+        idlParser.parse();
+    }
+}
+
diff --git a/Open-ILS/src/Android/src/org/open_ils/idl/IDLException.java b/Open-ILS/src/Android/src/org/open_ils/idl/IDLException.java
new file mode 100644 (file)
index 0000000..1b84d24
--- /dev/null
@@ -0,0 +1,10 @@
+package org.open_ils.idl;
+
+public class IDLException extends Exception {
+    public IDLException(String info) {
+        super(info);
+    }
+    public IDLException(String info, Throwable cause) {
+        super(info, cause);
+    }
+}
diff --git a/Open-ILS/src/Android/src/org/open_ils/idl/IDLField.java b/Open-ILS/src/Android/src/org/open_ils/idl/IDLField.java
new file mode 100644 (file)
index 0000000..6955bc5
--- /dev/null
@@ -0,0 +1,46 @@
+package org.open_ils.idl;
+
+public class IDLField {
+
+    /** Field name */
+    private String name;
+
+    /** Where this field resides in the array when serilized */
+    private int arrayPos;
+
+    /** True if this field does not belong in the database */
+    private boolean isVirtual;
+
+    public void setName(String name) {
+      this.name = name;
+    }
+    public void setArrayPos(int arrayPos) {
+      this.arrayPos = arrayPos;
+    }
+    public void setIsVirtual(boolean isVirtual) {
+      this.isVirtual = isVirtual;
+    }
+    public String getName() {
+      return this.name;
+    }
+    public int getArrayPos() {
+      return this.arrayPos;
+    }
+    public boolean getIsVirtual() {
+      return this.isVirtual;
+    }
+
+    public void toXML(StringBuffer sb) {
+        sb.append("\t\t\t<field name='");
+        sb.append(name);
+        sb.append("' ");
+        sb.append(IDLParser.OILS_NS_OBJ_PREFIX);
+        sb.append(":array_position='");
+        sb.append(arrayPos);
+        sb.append("' ");
+        sb.append(IDLParser.OILS_NS_PERSIST_PREFIX);
+        sb.append(":virtual='");
+        sb.append(isVirtual);
+        sb.append("'/>\n");
+    }
+}
diff --git a/Open-ILS/src/Android/src/org/open_ils/idl/IDLLink.java b/Open-ILS/src/Android/src/org/open_ils/idl/IDLLink.java
new file mode 100644 (file)
index 0000000..69a5772
--- /dev/null
@@ -0,0 +1,46 @@
+package org.open_ils.idl;
+
+
+public class IDLLink {
+
+   /**The field on the IDLObject this link extends from */
+   private String field;
+   private String reltype;
+   private String key;
+   private String map;
+   /**The IDL class linked to */
+   private String IDLClass;
+
+
+   public void setField(String field) {
+      this.field = field;
+   }
+   public void setReltype(String reltype) {
+      this.reltype = reltype;
+   }
+   public void setKey(String key) {
+      this.key = key;
+   }
+   public void setMap(String map) {
+      this.map = map;
+   }
+   public void setIDLClass(String IDLClass) {
+      this.IDLClass = IDLClass;
+   }
+   public String getField() {
+      return this.field;
+   }
+   public String getReltype() {
+      return this.reltype;
+   }
+   public String getKey() {
+      return this.key;
+   }
+   public String getMap() {
+      return this.map;
+   }
+   public String getIDLClass() {
+      return this.IDLClass;
+   }
+}
+
diff --git a/Open-ILS/src/Android/src/org/open_ils/idl/IDLObject.java b/Open-ILS/src/Android/src/org/open_ils/idl/IDLObject.java
new file mode 100644 (file)
index 0000000..aafde6e
--- /dev/null
@@ -0,0 +1,96 @@
+package org.open_ils.idl;
+import java.util.HashMap;
+import java.util.Iterator;
+
+
+public class IDLObject {
+
+    private String IDLClass;
+    private String fieldMapper;
+    private String controller;
+    private String rptLabel;
+    private HashMap<String, IDLField> fields;
+    private HashMap<String, IDLLink> links;
+    
+    /** true if this is a virtual object (does not live in the database) */
+    private boolean isVirtual;
+    
+    public IDLObject() {
+       fields = new HashMap<String, IDLField>();
+       links = new HashMap<String, IDLLink>();
+    }
+    
+    public String getIDLClass() {
+       return IDLClass;
+    }
+    
+    public void addLink(IDLLink link) {
+       links.put(link.getField(), link);
+    }
+    
+    public void addField(IDLField field) {
+       fields.put(field.getName(), field);
+    }
+    
+    public IDLField getField(String name) {
+        return (IDLField) fields.get(name);
+    }
+
+    public HashMap getFields() {
+        return fields;
+    }
+
+
+    /**
+     * Returns the link object found at the given field on 
+     * this IDLObject.
+     */
+    public IDLLink getLink(String fieldName) {
+        return (IDLLink) links.get(fieldName);
+    }
+    
+    public String getFieldMapper() {
+       return fieldMapper;
+    }
+    
+    public String getController() {
+       return controller;
+    }
+    
+    public String getRptLabel() {
+       return rptLabel;
+    }
+    public boolean isVirtual() {
+       return isVirtual;
+    }
+    
+    public void setIDLClass(String IDLClass) {
+       this.IDLClass = IDLClass;
+    }
+    
+    public void setFieldMapper(String fm) {
+       this.fieldMapper = fm;
+    }
+    public void setController(String controller) {
+       this.controller = controller;
+    }
+    public void setRptLabel(String label) {
+       this.rptLabel = label;
+    }
+    public void setIsVirtual(boolean isVirtual) {
+       this.isVirtual = isVirtual;
+    }
+
+
+    public void toXML(StringBuffer sb) {
+
+        sb.append("\t\t<fields>");
+        Iterator itr = fields.keySet().iterator();        
+        IDLField field;
+        while(itr.hasNext()) {
+            field = fields.get((String) itr.next()); 
+            field.toXML(sb);
+        }
+        sb.append("\t\t</fields>");
+    }
+}
diff --git a/Open-ILS/src/Android/src/org/open_ils/idl/IDLParser.java b/Open-ILS/src/Android/src/org/open_ils/idl/IDLParser.java
new file mode 100644 (file)
index 0000000..370ffcc
--- /dev/null
@@ -0,0 +1,225 @@
+package org.open_ils.idl;
+
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Set;
+
+import org.opensrf.util.OSRFRegistry;
+import org.xmlpull.v1.XmlPullParser;
+import org.xmlpull.v1.XmlPullParserException;
+import org.xmlpull.v1.XmlPullParserFactory;
+
+
+public class IDLParser {
+
+    public static final String OILS_NS_BASE="http://opensrf.org/spec/IDL/base/v1";
+    public static final String OILS_NS_OBJ="http://open-ils.org/spec/opensrf/IDL/objects/v1";
+    public static final String OILS_NS_OBJ_PREFIX="oils_obj";
+    public static final String OILS_NS_PERSIST="http://open-ils.org/spec/opensrf/IDL/persistence/v1";
+    public static final String OILS_NS_PERSIST_PREFIX="oils_persist";
+    public static final String OILS_NS_REPORTER="http://open-ils.org/spec/opensrf/IDL/reporter/v1";
+    public static final String OILS_NS_REPORTER_PREFIX="reporter";
+
+    /** The source for the IDL XML */
+    InputStream inStream;
+    HashMap<String, IDLObject> IDLObjects;
+    IDLObject current;
+    private int fieldIndex;
+
+    /** If true, we retain the full set of IDL objects in memory.  This is true by default. */
+    private boolean keepIDLObjects;
+
+    private int parsedObjectCount;
+
+    public IDLParser() {
+        IDLObjects = new HashMap<String, IDLObject>();
+        this.keepIDLObjects = true;
+        parsedObjectCount = 0;
+        fieldIndex = 0;
+    }
+
+    public IDLParser(String fileName) throws IOException {
+        this(new FileInputStream(fileName));
+    }
+
+    public IDLParser(InputStream inStream) {
+        this();
+        this.inStream = inStream;
+    }
+
+    public boolean isKeepIDLObjects() {
+        return keepIDLObjects;
+    }
+
+    public void setKeepIDLObjects(boolean keepIDLObjects) {
+        this.keepIDLObjects = keepIDLObjects;
+    }
+
+    /**
+    * Parses the IDL XML
+    */
+    public void parse() throws IOException, IDLException {
+    
+        try {
+            //XMLInputFactory factory = XMLInputFactory.newInstance();
+            
+            XmlPullParserFactory factory = XmlPullParserFactory.newInstance();
+            factory.setNamespaceAware(true);
+            XmlPullParser xpp = factory.newPullParser();
+
+            xpp.setInput(this.inStream,null );
+            int eventType = xpp.getEventType();
+
+            /** disable as many unused features as possible to speed up the parsing */
+            /*
+            factory.setProperty(XMLInputFactory.IS_REPLACING_ENTITY_REFERENCES, Boolean.FALSE);
+            factory.setProperty(XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES, Boolean.FALSE);
+            factory.setProperty(XMLInputFactory.IS_NAMESPACE_AWARE, Boolean.TRUE);
+            factory.setProperty(XMLInputFactory.IS_COALESCING, Boolean.FALSE);
+            factory.setProperty(XMLInputFactory.SUPPORT_DTD, Boolean.FALSE);
+             */
+    
+        /** create the stream reader */
+    
+            while(eventType != XmlPullParser.END_DOCUMENT) {
+                /** cycle through the XML events */
+    
+               // eventType = reader.next();
+    
+                switch(eventType) {
+    
+                    case XmlPullParser.START_TAG:
+                        handleStartElement(xpp);
+                        break;
+    
+                    case XmlPullParser.END_TAG: 
+                        handleEndElement(xpp);
+                        break;
+                }
+                eventType = xpp.next();
+            }
+
+        } catch(XmlPullParserException se) {
+            throw new IDLException("Error parsing IDL XML", se);
+        }
+   }
+
+    /**
+    * Returns the IDLObject with the given IDLClass 
+    */
+    public IDLObject getObject(String IDLClass) {
+      return (IDLObject) IDLObjects.get(IDLClass);
+    }
+
+    /**
+     * Returns the full set of IDL objects as a hash from classname to object.
+     * If keepIDLObjects is false, the map will be empty.
+     */
+    public HashMap<String, IDLObject> getIDLObjects() {
+        return IDLObjects;
+    }
+
+    /**
+     * Returns the number of parsed objects, regardless of the keepIDLObjects setting.
+     */
+    public int getObjectCount() {
+        return parsedObjectCount;
+    }
+
+
+    public void handleStartElement(XmlPullParser reader) {
+
+        if(!OILS_NS_BASE.equals(reader.getNamespace())) return;
+        String localpart = reader.getName();
+    
+        if( "class".equals(localpart) ) {
+            fieldIndex = 0;
+            current = new IDLObject();
+            current.setIDLClass(reader.getAttributeValue(null, "id"));
+            current.setController(reader.getAttributeValue(null, "controller"));
+            String persist = reader.getAttributeValue(OILS_NS_PERSIST, "virtual");
+            current.setIsVirtual("persist".equals(reader.getAttributeValue(OILS_NS_PERSIST, "virtual")));
+            return;
+        }
+    
+        if( "field".equals(localpart) ) {
+            IDLField field = new IDLField();
+            field.setName(reader.getAttributeValue(null, "name"));
+            field.setArrayPos(fieldIndex++);
+            field.setIsVirtual("true".equals(reader.getAttributeValue(OILS_NS_PERSIST, "virtual")));
+            current.addField(field);
+            //Log.d("parser","Field " + localpart + " " + field );
+        }
+
+        if( "link".equals(localpart) ) {
+            IDLLink link = new IDLLink();
+            link.setField(reader.getAttributeValue(null, "field"));
+            link.setReltype(reader.getAttributeValue(null, "reltype"));
+            link.setKey(reader.getAttributeValue(null, "key"));
+            link.setMap(reader.getAttributeValue(null, "map"));
+            link.setIDLClass(reader.getAttributeValue(null, "class"));
+            current.addLink(link);
+        }
+    }
+
+    public void handleEndElement(XmlPullParser reader) throws IDLException {
+
+        if(!OILS_NS_BASE.equals(reader.getNamespace())) return;
+        String localpart = reader.getName();
+
+        if("class".equals(localpart)) {
+
+            if(keepIDLObjects)
+                IDLObjects.put(current.getIDLClass(), current);
+
+            HashMap fields = current.getFields();
+            String fieldNames[] = new String[fields.size()];
+
+            if (current.getIDLClass().equals("payments_combined_detail") || current.getIDLClass().equals("ahr")) {
+                System.out.println("kcxxx");
+            }
+            for(Iterator itr = fields.keySet().iterator(); itr.hasNext(); ) {
+                String key = (String) itr.next();
+                IDLField field = (IDLField) fields.get(key);
+                try {
+                    fieldNames[ field.getArrayPos() ] = field.getName();
+                } catch(ArrayIndexOutOfBoundsException E) {
+                    String msg = "class="+current.getIDLClass()+";field="+key+
+                        ";fieldcount="+fields.size()+";currentpos="+field.getArrayPos();
+                    throw new IDLException(msg, E);
+                }
+            }
+
+            OSRFRegistry.registerObject(
+                current.getIDLClass(), OSRFRegistry.WireProtocol.ARRAY, fieldNames);
+
+            parsedObjectCount++;
+
+            current = null;
+        }
+    }
+
+
+    public String toXML() {
+        StringBuffer sb = new StringBuffer();
+        Set keys = IDLObjects.keySet();
+        Iterator itr = IDLObjects.keySet().iterator();
+        String IDLClass;
+        IDLObject obj;
+        while(itr.hasNext()) {
+            IDLClass = (String) itr.next();
+            obj = IDLObjects.get(IDLClass);
+            obj.toXML(sb);
+        }
+        return sb.toString();
+    }
+}
+
+
+
+
+
+
diff --git a/Open-ILS/src/Android/src/org/open_ils/test/TestIDL.java b/Open-ILS/src/Android/src/org/open_ils/test/TestIDL.java
new file mode 100644 (file)
index 0000000..632c28e
--- /dev/null
@@ -0,0 +1,24 @@
+package org.open_ils.test;
+import org.open_ils.idl.*;
+import org.opensrf.*;
+import org.opensrf.util.*;
+
+public class TestIDL {
+    public static void main(String args[]) throws Exception {
+        String idlFile = "fm_IDL.xml";
+        IDLParser parser = new IDLParser(idlFile);
+        parser.parse();
+        //System.out.print(parser.toXML());
+
+        OSRFObject bre = new OSRFObject("bre");
+        bre.put("id", new Integer(1));
+        bre.put("isnew", new Boolean(false));
+        bre.put("isdeleted", new Boolean(true));
+        
+        
+        System.out.println(bre);
+        System.out.println(new JSONWriter(bre).write());
+        
+        
+    }
+}
diff --git a/Open-ILS/src/Android/src/org/open_ils/test/TestLogin.java b/Open-ILS/src/Android/src/org/open_ils/test/TestLogin.java
new file mode 100644 (file)
index 0000000..265fa37
--- /dev/null
@@ -0,0 +1,29 @@
+package org.open_ils.test;
+import org.open_ils.util.Utils;
+import org.open_ils.Event;
+import org.opensrf.*;
+import java.util.Map;
+import java.util.HashMap;
+
+
+public class TestLogin {
+    public static void main(String args[]) {
+        try {
+
+            if(args.length < 3) {
+                System.err.println("usage: java org.open_ils.test.TestLogin <opensrf_config> <username> <password>");
+                return;
+            }
+
+            Sys.bootstrapClient(args[0], "/config/opensrf");
+            Map<String,String> params = new HashMap<String,String>();
+            params.put("username", args[1]);
+            params.put("password", args[2]);
+            Event evt = Utils.login(params);
+            System.out.println(evt);
+        } catch(Exception e) {
+            System.err.println(e);
+        }
+    }
+}
+
diff --git a/Open-ILS/src/Android/src/org/open_ils/util/Utils.java b/Open-ILS/src/Android/src/org/open_ils/util/Utils.java
new file mode 100644 (file)
index 0000000..c91745c
--- /dev/null
@@ -0,0 +1,76 @@
+package org.open_ils.util;
+import org.open_ils.*;
+import org.opensrf.*;
+import org.opensrf.util.*;
+import java.util.Map;
+import java.util.HashMap;
+import java.security.MessageDigest;
+
+public class Utils {
+    
+    /**
+     * Logs in.
+     * @param params Login arguments, which may consist of<br/>
+     * username<br/>
+     * barcode - if username is provided, barcode will be ignored<br/>
+     * password<br/>
+     * workstation - name of the workstation where the login is occuring<br/>
+     * type - type of login, currently "opac", "staff", and "temp"<br/>
+     * org - optional org ID to provide login context when no workstation is used.
+     * @return An Event object.  On success, the event 'payload' will contain
+     * 'authtoken' and 'authtime' fields, which represent the session key and 
+     * session inactivity timeout, respectively.
+     */
+    public static Event login(Map params) throws MethodException {
+
+        Map<String, String> initMap = new HashMap<String, String>();
+        String init = (params.get("username") != null) ? 
+            params.get("username").toString() : params.get("barcode").toString();
+        System.out.println("login1");
+            
+        Object resp = ClientSession.atomicRequest(
+            "open-ils.auth",
+            "open-ils.auth.authenticate.init", new Object [] {initMap});
+
+        System.out.println("login2");
+        /** see if the server responded with some type of unexpected event */
+        Event evt = Event.parseEvent(resp);
+        if(evt != null) return evt;
+
+        params.put("password", md5Hex(resp + md5Hex(params.get("password").toString())));
+
+        resp = ClientSession.atomicRequest(
+            "open-ils.auth",
+            "open-ils.auth.authenticate.complete", new Object[]{params});
+
+        return Event.parseEvent(resp);
+    }
+
+    /**
+     * Generates the hex md5sum of a string.
+     * @param s The string to md5sum
+     * @return The 32-character hex md5sum
+     */
+    public static String md5Hex(String s) {
+        StringBuffer sb = new StringBuffer();
+        MessageDigest md;
+        try {
+            md = MessageDigest.getInstance("MD5");
+        } catch(Exception e) {
+            return null;
+        }
+
+        md.update(s.getBytes());
+        byte[] digest = md.digest();
+        for (int i = 0; i < digest.length; i++) {
+            int b = digest[i] & 0xff;
+            String hex = Integer.toHexString(b);
+            if (hex.length() == 1) sb.append("0");
+            sb.append(hex);
+        }
+        return sb.toString();
+    }
+}
+
+
+