]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/examples/fm_IDL.xml
pile of dojo layout fixes for 1.3 and to better ascimilate into the TT framework
[working/Evergreen.git] / Open-ILS / examples / fm_IDL.xml
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!--
3
4 Copyright (C) 2006-2008 Georgia Public Library Service
5 Copyright (C) 2008 Equinox Software, Inc
6 Author: Mike Rylander <miker@esilibrary.com>
7
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
21
22 -->
23
24 <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">
25
26         <!-- Virtual classes -->
27         <class id="mups" controller="open-ils.cstore" oils_obj:fieldmapper="money::user_payment_summary" oils_persist:virtual="true" reporter:label="User Payment Summary">
28                 <fields>
29                         <field name="usr" oils_persist:virtual="true" />
30                         <field name="forgive_payment" oils_persist:virtual="true" />
31                         <field name="work_payment" oils_persist:virtual="true" />
32                         <field name="credit_payment" oils_persist:virtual="true" />
33                         <field name="goods_payment" oils_persist:virtual="true" />
34                 </fields>
35                 <links>
36                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
37                 </links>
38         </class>
39
40         <class id="mwps" controller="open-ils.cstore" oils_obj:fieldmapper="money::workstation_payment_summary" oils_persist:virtual="true" reporter:label="Workstation Payment Summary">
41                 <fields>
42                         <field name="workstation" oils_persist:virtual="true" />
43                         <field name="cash_payment" oils_persist:virtual="true" />
44                         <field name="check_payment" oils_persist:virtual="true" />
45                         <field name="credit_card_payment" oils_persist:virtual="true" />
46                 </fields>
47                 <links>
48                         <link field="workstation" reltype="has_a" key="id" map="" class="aws"/>
49                 </links>
50         </class>
51
52         <class id="brn" controller="open-ils.cstore" oils_obj:fieldmapper="biblio::record_node" oils_persist:virtual="true" reporter:label="Record Node">
53                 <fields>
54                         <field name="id" oils_persist:virtual="true" />
55                         <field name="children" oils_persist:virtual="true" />
56                         <field name="owner_doc" oils_persist:virtual="true" />
57                         <field name="intra_doc_id" oils_persist:virtual="true" />
58                         <field name="parent_node" oils_persist:virtual="true" />
59                         <field name="node_type" oils_persist:virtual="true" />
60                         <field name="namespace_uri" oils_persist:virtual="true" />
61                         <field name="name" oils_persist:virtual="true" />
62                         <field name="value" oils_persist:virtual="true" />
63                 </fields>
64         </class>
65
66         <class id="mvr" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::virtual_record" oils_persist:virtual="true" reporter:label="Virtual Record">
67                 <fields>
68                         <field name="title" oils_persist:virtual="true" />
69                         <field name="author" oils_persist:virtual="true" />
70                         <field name="doc_id" oils_persist:virtual="true" />
71                         <field name="doc_type" oils_persist:virtual="true" />
72                         <field name="pubdate" oils_persist:virtual="true" />
73                         <field name="isbn" oils_persist:virtual="true" />
74                         <field name="publisher" oils_persist:virtual="true" />
75                         <field name="tcn" oils_persist:virtual="true" />
76                         <field name="subject" oils_persist:virtual="true" />
77                         <field name="types_of_resource" oils_persist:virtual="true" />
78                         <field name="call_numbers" oils_persist:virtual="true" />
79                         <field name="edition" oils_persist:virtual="true" />
80                         <field name="online_loc" oils_persist:virtual="true" />
81                         <field name="synopsis" oils_persist:virtual="true" />
82                         <field name="physical_description" oils_persist:virtual="true" />
83                         <field name="toc" oils_persist:virtual="true" />
84                         <field name="copy_count" oils_persist:virtual="true" />
85                         <field name="series" oils_persist:virtual="true" />
86                         <field name="serials" oils_persist:virtual="true" />
87                 </fields>
88         </class>
89
90         <class id="ex" controller="open-ils.cstore" oils_obj:fieldmapper="ex" oils_persist:virtual="true">
91                 <fields>
92                         <field name="err_msg" oils_persist:virtual="true" />
93                         <field name="type" oils_persist:virtual="true" />
94                 </fields>
95         </class>
96
97         <class id="perm_ex" controller="open-ils.cstore" oils_obj:fieldmapper="perm_ex" oils_persist:virtual="true">
98                 <fields>
99                         <field name="err_msg" oils_persist:virtual="true" />
100                         <field name="type" oils_persist:virtual="true" />
101                 </fields>
102         </class>
103
104         <class id="amtr" controller="open-ils.cstore" oils_obj:fieldmapper="action::matrix_test_result" oils_persist:virtual="true" reporter:label="Matrix Test Result">
105                 <fields oils_persist:primary="matchpoint">
106                         <field reporter:label="Matchpoint ID" name="matchpoint" reporter:datatype="id"/>
107                         <field reporter:label="Success" name="success" reporter:datatype="bool"/>
108                         <field reporter:label="Failure Part" name="fail_part" reporter:datatype="text"/>
109                 </fields>
110                 <links>
111                         <link field="matchpoint" reltype="has_a" key="id" map="" class="ccmm"/>
112                 </links>
113         </class>
114
115
116         <!-- Actually in the DB -->
117         <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">
118                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.import_bib_trash_fields_id_seq">
119                         <field reporter:label="Field ID" name="id" reporter:datatype="id"/>
120                         <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
121                         <field reporter:label="Field" name="field" reporter:datatype="text"/>
122                 </fields>
123                 <links>
124                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
125                 </links>
126                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
127                         <actions>
128                                 <create permission="CREATE_IMPORT_TRASH_FIELD" context_field="owner"/>
129                                 <retrieve permission="CREATE_IMPORT_TRASH_FIELD UPDATE_IMPORT_TRASH_FIELD DELETE_IMPORT_TRASH_FIELD" context_field="owner"/>
130                                 <update permission="UPDATE_IMPORT_TRASH_FIELD" context_field="owner"/>
131                                 <delete permission="DELETE_IMPORT_TRASH_FIELD" context_field="owner"/>
132                         </actions>
133                 </permacrud>
134         </class>
135
136         <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 Attribute Definition">
137                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.import_item_id_seq">
138                         <field reporter:label="Import Item ID" name="id" reporter:datatype="id"/>
139                         <field reporter:label="Import Record" name="record" reporter:datatype="link"/>
140                         <field reporter:label="Attribute Definition" name="definition" reporter:datatype="link"/>
141                         <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="int"/>
142                         <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="int"/>
143                         <field reporter:label="Call Number" name="call_number" reporter:datatype="text"/>
144                         <field reporter:label="Copy Number" name="copy_number" reporter:datatype="int"/>
145                         <field reporter:label="Status" name="status" reporter:datatype="int"/>
146                         <field reporter:label="Shelving Location" name="location" reporter:datatype="int"/>
147                         <field reporter:label="Circulate" name="circulate" reporter:datatype="bool"/>
148                         <field reporter:label="Deposit" name="deposit" reporter:datatype="bool"/>
149                         <field reporter:label="Deposit Amount" name="deposit_amount" reporter:datatype="money"/>
150                         <field reporter:label="Reference" name="ref" reporter:datatype="bool"/>
151                         <field reporter:label="Holdable" name="holdable" reporter:datatype="bool"/>
152                         <field reporter:label="Price" name="price" reporter:datatype="money"/>
153                         <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
154                         <field reporter:label="Circulation Modifier" name="circ_modifier" reporter:datatype="text"/>
155                         <field reporter:label="Circulate As MARC Type" name="circ_as_type" reporter:datatype="text"/>
156                         <field reporter:label="Alert Message" name="alert_message" reporter:datatype="text"/>
157                         <field reporter:label="Public Note" name="pub_note" reporter:datatype="text"/>
158                         <field reporter:label="Private Note" name="priv_note" reporter:datatype="text"/>
159                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
160                 </fields>
161                 <links>
162                         <link field="record" reltype="has_a" key="id" map="" class="vqbr"/>
163                         <link field="definition" reltype="has_a" key="id" map="" class="viiad"/>
164                 </links>
165                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
166                         <actions>
167                                 <create permission="CREATE_IMPORT_ITEM">
168                     <context link="definition" field="owner"/>
169                                 </create>
170                                 <retrieve permission="CREATE_IMPORT_ITEM UPDATE_IMPORT_ITEM DELETE_IMPORT_ITEM">
171                     <context link="definition" field="owner"/>
172                                 </retrieve>
173                                 <update permission="UPDATE_IMPORT_ITEM">
174                     <context link="definition" field="owner"/>
175                                 </update>
176                                 <delete permission="DELETE_IMPORT_ITEM">
177                     <context link="definition" field="owner"/>
178                                 </delete>
179                         </actions>
180                 </permacrud>
181         </class>
182
183         <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">
184                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.import_item_attr_definition_id_seq">
185                         <field reporter:label="Definition ID" name="id" reporter:datatype="id"/>
186                         <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
187                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
188                         <field reporter:label="Tag" name="tag" reporter:datatype="text"/>
189                         <field reporter:label="Keep" name="keep" reporter:datatype="bool"/>
190                         <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="text"/>
191                         <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="text"/>
192                         <field reporter:label="Call Number" name="call_number" reporter:datatype="text"/>
193                         <field reporter:label="Status" name="status" reporter:datatype="text"/>
194                         <field reporter:label="Shelving Location" name="location" reporter:datatype="text"/>
195                         <field reporter:label="Circulate" name="circulate" reporter:datatype="text"/>
196                         <field reporter:label="Deposit" name="deposit" reporter:datatype="text"/>
197                         <field reporter:label="Deposit Amount" name="deposit_amount" reporter:datatype="text"/>
198                         <field reporter:label="Reference" name="ref" reporter:datatype="text"/>
199                         <field reporter:label="Holdable" name="holdable" reporter:datatype="text"/>
200                         <field reporter:label="Price" name="price" reporter:datatype="text"/>
201                         <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
202                         <field reporter:label="Circulation Modifier" name="circ_modifier" reporter:datatype="text"/>
203                         <field reporter:label="Circulate As MARC Type" name="circ_as_type" reporter:datatype="text"/>
204                         <field reporter:label="Alert Message" name="alert_message" reporter:datatype="text"/>
205                         <field reporter:label="Public Note" name="pub_note" reporter:datatype="text"/>
206                         <field reporter:label="Private Note" name="priv_note" reporter:datatype="text"/>
207                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="text"/>
208                         <field reporter:label="Copy Number" name="copy_number" reporter:datatype="text"/>
209                 </fields>
210                 <links>
211                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
212                 </links>
213                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
214                         <actions>
215                                 <create permission="CREATE_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
216                                 <retrieve permission="CREATE_IMPORT_ITEM_ATTR_DEF UPDATE_IMPORT_ITEM_ATTR_DEF DELETE_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
217                                 <update permission="UPDATE_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
218                                 <delete permission="DELETE_IMPORT_ITEM_ATTR_DEF" context_field="owner"/>
219                         </actions>
220                 </permacrud>
221         </class>
222
223         <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">
224                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queue_id_seq">
225                         <field reporter:label="Queue ID" name="id" reporter:selector="name" reporter:datatype="id"/>
226                         <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
227                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
228                         <field reporter:label="Complete" name="complete" reporter:datatype="bool"/>
229                         <field reporter:label="Type" name="queue_type" reporter:datatype="text"/>
230                 </fields>
231                 <links>
232                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
233                 </links>
234                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
235                         <actions>
236                                 <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
237                                 <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
238                                 <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
239                                 <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
240                         </actions>
241                 </permacrud>
242         </class>
243
244         <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">
245                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queued_record_id_seq">
246                         <field reporter:label="Record ID" name="id" reporter:datatype="id"/>
247                         <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp"/>
248                         <field reporter:label="Import Time" name="import_time" reporter:datatype="timestamp"/>
249                         <field reporter:label="MARC" name="marc" reporter:datatype="text"/>
250                         <field reporter:label="Queue" name="queue" reporter:datatype="link"/>
251                         <field reporter:label="Bib Source" name="bib_source" reporter:datatype="link"/>
252                         <field reporter:label="Final Target Record" name="imported_as" reporter:datatype="link"/>
253                         <field reporter:label="Purpose" name="purpose" reporter:datatype="text"/>
254                         <field reporter:label="Attributes" name="attributes" oils_persist:virtual="true" reporter:datatype="text"/>
255                         <field reporter:label="Matches" name="matches" oils_persist:virtual="true" reporter:datatype="text"/>
256                 </fields>
257                 <links>
258                         <link field="queue" reltype="has_a" key="id" map="" class="vbq"/>
259                         <link field="bib_source" reltype="has_a" key="id" map="" class="cbs"/>
260                         <link field="imported_as" reltype="has_a" key="id" map="" class="bre"/>
261             <link field="attributes" reltype="has_many" key="record" map="" class="vqbra"/>
262             <link field="matches" reltype="has_many" key="queued_record" map="" class="vbm"/>
263                 </links>
264                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
265                         <actions>
266                                 <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
267                                 <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
268                                 <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
269                                 <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
270                         </actions>
271                 </permacrud>
272         </class>
273
274         <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">
275                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.bib_attr_definition_id_seq">
276                         <field reporter:label="ID" name="id" reporter:datatype="id"/>
277                         <field reporter:label="Code" name="code" reporter:datatype="text"/>
278                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
279                         <field reporter:label="XPath" name="xpath" reporter:datatype="text"/>
280                         <field reporter:label="Remove RegExp" name="remove" reporter:datatype="text"/>
281                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
282                 </fields>
283                 <links/>
284                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
285                         <actions>
286                                 <create permission="CREATE_BIB_IMPORT_FIELD_DEF" global_required="true"/>
287                 <retrieve/>
288                 <!--
289                                 <retrieve permission="CREATE_BIB_IMPORT_IMPORT_FIELD_DEF UPDATE_BIB_IMPORT_IMPORT_FIELD_DEF DELETE_BIB_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
290                 -->
291                                 <update permission="UPDATE_BIB_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
292                                 <delete permission="DELETE_BIB_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
293                         </actions>
294                 </permacrud>
295         </class>
296
297         <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">
298                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queued_bib_record_attr_id_seq">
299                         <field reporter:label="Attribute ID" name="id" reporter:datatype="id"/>
300                         <field reporter:label="Record" name="record" reporter:datatype="link"/>
301                         <field reporter:label="Field" name="field" reporter:datatype="link"/>
302                         <field reporter:label="Value" name="attr_value" reporter:datatype="text"/>
303                 </fields>
304                 <links>
305                         <link field="record" reltype="has_a" key="id" map="" class="vqbr"/>
306                         <link field="field" reltype="has_a" key="id" map="" class="vqbrad"/>
307                 </links>
308                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
309                         <actions>
310                                 <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
311                                 <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
312                                 <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
313                                 <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
314                         </actions>
315                 </permacrud>
316         </class>
317
318         <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">
319                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.bib_match_id_seq">
320                         <field reporter:label="Match ID" name="id" reporter:datatype="id"/>
321                         <field reporter:label="Queued Record" name="queued_record" reporter:datatype="link"/>
322                         <field reporter:label="Matched Attribute" name="matched_attr" reporter:datatype="link"/>
323                         <field reporter:label="Evergreen Record" name="eg_record" reporter:datatype="link"/>
324                         <field reporter:label="Field Type" name="field_type" reporter:datatype="text"/>
325                 </fields>
326                 <links>
327                         <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
328                         <link field="eg_record" reltype="has_a" key="id" map="" class="bre"/>
329                         <link field="matched_attr" reltype="has_a" key="id" map="" class="vqbra"/>
330                 </links>
331                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
332                         <actions>
333                                 <create permission="CREATE_BIB_IMPORT_QUEUE" global_required="true"/>
334                                 <retrieve permission="CREATE_BIB_IMPORT_QUEUE UPDATE_BIB_IMPORT_QUEUE DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
335                                 <update permission="UPDATE_BIB_IMPORT_QUEUE" global_required="true"/>
336                                 <delete permission="DELETE_BIB_IMPORT_QUEUE" global_required="true"/>
337                         </actions>
338                 </permacrud>
339         </class>
340
341         <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">
342                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queue_id_seq">
343                         <field reporter:label="Queue ID" name="id" reporter:selector="name" reporter:datatype="id"/>
344                         <field reporter:label="Owner" name="owner" reporter:datatype="link"/>
345                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
346                         <field reporter:label="Complete" name="complete" reporter:datatype="bool"/>
347                         <field reporter:label="Type" name="queue_type" reporter:datatype="text"/>
348                 </fields>
349                 <links>
350                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
351                 </links>
352                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
353                         <actions>
354                                 <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
355                                 <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
356                                 <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
357                                 <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
358                         </actions>
359                 </permacrud>
360         </class>
361
362         <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">
363                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queued_record_id_seq">
364                         <field reporter:label="Record ID" name="id" reporter:datatype="id"/>
365                         <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp"/>
366                         <field reporter:label="Import Time" name="import_time" reporter:datatype="timestamp"/>
367                         <field reporter:label="MARC" name="marc" reporter:datatype="text"/>
368                         <field reporter:label="Queue" name="queue" reporter:datatype="link"/>
369                         <field reporter:label="Final Target Record" name="imported_as" reporter:datatype="link"/>
370                         <field reporter:label="Purpose" name="purpose" reporter:datatype="text"/>
371                         <field reporter:label="Attributes" name="attributes" oils_persist:virtual="true" reporter:datatype="text"/>
372                         <field reporter:label="Matches" name="matches" oils_persist:virtual="true" reporter:datatype="text"/>
373                 </fields>
374                 <links>
375                         <link field="queue" reltype="has_a" key="id" map="" class="vaq"/>
376                         <link field="imported_as" reltype="has_a" key="id" map="" class="are"/>
377             <link field="attributes" reltype="has_many" key="record" map="" class="vqara"/>
378             <link field="matches" reltype="has_many" key="queued_record" map="" class="vam"/>
379                 </links>
380                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
381                         <actions>
382                                 <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
383                                 <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
384                                 <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
385                                 <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
386                         </actions>
387                 </permacrud>
388         </class>
389
390         <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">
391                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.authority_attr_definition_id_seq">
392                         <field reporter:label="ID" name="id" reporter:datatype="id"/>
393                         <field reporter:label="Code" name="code" reporter:datatype="text"/>
394                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
395                         <field reporter:label="XPath" name="xpath" reporter:datatype="text"/>
396                         <field reporter:label="Remove RegExp" name="remove" reporter:datatype="text"/>
397                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
398                 </fields>
399                 <links/>
400                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
401                         <actions>
402                                 <create permission="CREATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
403                 <retrieve/>
404                 <!--
405                                 <retrieve permission="CREATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF UPDATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF DELETE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
406                 -->
407                                 <update permission="UPDATE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
408                                 <delete permission="DELETE_AUTHORITY_IMPORT_IMPORT_FIELD_DEF" global_required="true"/>
409                         </actions>
410                 </permacrud>
411         </class>
412
413         <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">
414                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.queued_authority_record_attr_id_seq">
415                         <field reporter:label="Attribute ID" name="id" reporter:datatype="id"/>
416                         <field reporter:label="Record" name="record" reporter:datatype="link"/>
417                         <field reporter:label="Field" name="field" reporter:datatype="link"/>
418                         <field reporter:label="Value" name="attr_value" reporter:datatype="text"/>
419                 </fields>
420                 <links>
421                         <link field="record" reltype="has_a" key="id" map="" class="vaqr"/>
422                         <link field="field" reltype="has_a" key="id" map="" class="vqarad"/>
423                 </links>
424                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
425                         <actions>
426                                 <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
427                                 <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
428                                 <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
429                                 <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
430                         </actions>
431                 </permacrud>
432         </class>
433
434         <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">
435                 <fields oils_persist:primary="id" oils_persist:sequence="vandelay.authority_match_id_seq">
436                         <field reporter:label="Match ID" name="id" reporter:datatype="id"/>
437                         <field reporter:label="Queued Record" name="queued_record" reporter:datatype="link"/>
438                         <field reporter:label="Matched Attribute" name="matched_attr" reporter:datatype="link"/>
439                         <field reporter:label="Evergreen Record" name="eg_record" reporter:datatype="link"/>
440                 </fields>
441                 <links>
442                         <link field="queued_record" reltype="has_a" key="id" map="" class="vqbr"/>
443                         <link field="eg_record" reltype="has_a" key="id" map="" class="bre"/>
444                         <link field="matched_attr" reltype="has_a" key="id" map="" class="vqbra"/>
445                 </links>
446                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
447                         <actions>
448                                 <create permission="CREATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
449                                 <retrieve permission="CREATE_AUTHORITY_IMPORT_QUEUE UPDATE_AUTHORITY_IMPORT_QUEUE DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
450                                 <update permission="UPDATE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
451                                 <delete permission="DELETE_AUTHORITY_IMPORT_QUEUE" global_required="true"/>
452                         </actions>
453                 </permacrud>
454         </class>
455
456
457         <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">
458                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_org_unit_opt_in_id_seq">
459                         <field reporter:label="Opt-in ID" name="id" reporter:datatype="id"/>
460                         <field reporter:label="Workstation" name="opt_in_ws" reporter:datatype="link"/>
461                         <field reporter:label="Staff Member" name="staff" reporter:datatype="link"/>
462                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
463                         <field reporter:label="Allowed Org Unit" name="org_unit" reporter:datatype="link"/>
464                         <field reporter:label="Opt-in Date/Time" name="opt_in_ts" reporter:datatype="timestamp"/>
465                 </fields>
466                 <links>
467                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
468                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
469                         <link field="staff" reltype="has_a" key="id" map="" class="au"/>
470                         <link field="opt_in_ws" reltype="has_a" key="id" map="" class="aws"/>
471                 </links>
472         </class>
473
474     <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">
475         <fields oils_persist:primary="name">
476             <field reporter:label="Z39.50 Source" name="name" reporter:datatype="id"/>
477             <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
478             <field reporter:label="Host" name="host"  reporter:datatype="text"/>
479             <field reporter:label="Port" name="port"  reporter:datatype="int"/>
480             <field reporter:label="DB" name="db"  reporter:datatype="text"/>
481             <field reporter:label="Record Format" name="record_format"  reporter:datatype="text"/>
482             <field reporter:label="Transmission Format" name="transmission_format"  reporter:datatype="text"/>
483             <field reporter:label="Auth" name="auth"  reporter:datatype="bool"/>
484             <field reporter:label="Attrs" name="attrs" oils_persist:virtual="true"  reporter:datatype="link"/>
485         </fields>
486         <links>
487             <link field="attrs" reltype="has_many" key="source" map="" class="cza"/>
488         </links>
489         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
490             <actions>
491                 <create permission="ADMIN_Z3950_SOURCE" global_required="true"/>
492                 <retrieve/>
493                 <update permission="ADMIN_Z3950_SOURCE" global_required="true"/>
494                 <delete permission="ADMIN_Z3950_SOURCE" global_required="true"/>
495             </actions>
496         </permacrud>
497     </class>
498
499     <class id="cza" controller="open-ils.cstore" oils_obj:fieldmapper="config::z3950_attr" oils_persist:tablename="config.z3950_attr" reporter:label="Z39.50 Attribute">
500         <fields oils_persist:primary="id" oils_persist:sequence="config.z3950_attr_id_seq">
501             <field reporter:label="Z39.50 Attribute ID" name="id" reporter:datatype="id"/>
502             <field reporter:label="Z39.50 Source" name="source" reporter:datatype="link"/>
503             <field reporter:label="Name" name="name" reporter:datatype="text"/>
504             <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
505             <field reporter:label="Code" name="code"  reporter:datatype="int"/>
506             <field reporter:label="Format" name="format"  reporter:datatype="int"/>
507             <field reporter:label="Truncation" name="truncation"  reporter:datatype="int"/>
508         </fields>
509         <links>
510             <link field="source" reltype="has_a" key="name" map="" class="czs"/>
511         </links>
512     </class>
513
514         <class id="ateo" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::event_output" oils_persist:tablename="action_trigger.event_output" reporter:label="Event Output">
515                 <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.event_output_id_seq">
516                         <field reporter:label="Output ID" name="id" reporter:datatype="id"/>
517                         <field reporter:label="Create Date/Time" name="create_time" reporter:datatype="timestamp"/>
518                         <field reporter:label="Data" name="data" reporter:datatype="text"/>
519                         <field reporter:label="Is Error" name="is_error" reporter:datatype="bool"/>
520                         <field reporter:label="Events" name="events" oils_persist:virtual="true"  reporter:datatype="link"/>
521                         <field reporter:label="Events" name="error_events" oils_persist:virtual="true"  reporter:datatype="link"/>
522                 </fields>
523                 <links>
524             <link field="events" reltype="has_many" key="template_output" map="" class="atev"/>
525             <link field="error_events" reltype="has_many" key="error_output" map="" class="atev"/>
526                 </links>
527                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
528                         <actions>
529                                 <retrieve/>
530                                 <delete permission="ADMIN_TRIGGER_TEMPLATE_OUTPUT" global_required="true"/>
531                         </actions>
532                 </permacrud>
533         </class>
534
535         <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">
536                 <fields oils_persist:primary="key">
537                         <field reporter:label="Hook Key" name="key" reporter:datatype="text"/>
538                         <field reporter:label="Core Type" name="core_type" reporter:datatype="text"/>
539                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
540                         <field reporter:label="Passive" name="passive"  reporter:datatype="bool"/>
541                 </fields>
542                 <links/>
543                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
544                         <actions>
545                                 <create permission="ADMIN_TRIGGER_HOOK" global_required="true"/>
546                                 <retrieve/>
547                                 <update permission="ADMIN_TRIGGER_HOOK" global_required="true"/>
548                                 <delete permission="ADMIN_TRIGGER_HOOK" global_required="true"/>
549                         </actions>
550                 </permacrud>
551         </class>
552
553         <class id="atcol" controller="open-ils.cstore" oils_obj:fieldmapper="action_trigger::collector" oils_persist:tablename="action_trigger.collector" reporter:label="Trigger Environment Collector">
554                 <fields oils_persist:primary="module">
555                         <field reporter:label="Module Name" name="module" reporter:datatype="text"/>
556                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
557                 </fields>
558                 <links/>
559         </class>
560
561         <class id="atval" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::validator" oils_persist:tablename="action_trigger.validator" reporter:label="Trigger Condition Validator">
562                 <fields oils_persist:primary="module">
563                         <field reporter:label="Module Name" name="module" reporter:datatype="text"/>
564                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
565                 </fields>
566                 <links/>
567                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
568                         <actions>
569                                 <create permission="ADMIN_TRIGGER_VALIDATOR" global_required="true"/>
570                                 <retrieve/>
571                                 <update permission="ADMIN_TRIGGER_VALIDATOR" global_required="true"/>
572                                 <delete permission="ADMIN_TRIGGER_VALIDATOR" global_required="true"/>
573                         </actions>
574                 </permacrud>
575         </class>
576
577         <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">
578                 <fields oils_persist:primary="module">
579                         <field reporter:label="Module Name" name="module" reporter:datatype="text"/>
580                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
581                 </fields>
582                 <links/>
583                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
584                         <actions>
585                                 <create permission="ADMIN_TRIGGER_REACTOR" global_required="true"/>
586                                 <retrieve/>
587                                 <update permission="ADMIN_TRIGGER_REACTOR" global_required="true"/>
588                                 <delete permission="ADMIN_TRIGGER_REACTOR" global_required="true"/>
589                         </actions>
590                 </permacrud>
591         </class>
592
593         <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">
594                 <fields oils_persist:primary="module">
595                         <field reporter:label="Module Name" name="module" reporter:datatype="text"/>
596                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
597                 </fields>
598                 <links/>
599                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
600                         <actions>
601                                 <create permission="ADMIN_TRIGGER_CLEANUP" global_required="true"/>
602                                 <retrieve/>
603                                 <update permission="ADMIN_TRIGGER_CLEANUP" global_required="true"/>
604                                 <delete permission="ADMIN_TRIGGER_CLEANUP" global_required="true"/>
605                         </actions>
606                 </permacrud>
607         </class>
608
609         <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">
610                 <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.environment_id_seq">
611                         <field reporter:label="Definition ID" name="id" reporter:datatype="id"/>
612                         <field reporter:label="Event Definition" name="event_def" reporter:datatype="link"/>
613                         <field reporter:label="Field Path" name="path" reporter:datatype="text"/>
614                         <field reporter:label="Collector" name="collector" reporter:datatype="link"/>
615                         <field reporter:label="Label" name="label" reporter:datatype="text"/>
616                 </fields>
617                 <links>
618                         <link field="event_def" reltype="has_a" key="id" map="" class="atevdef"/>
619                         <link field="collector" reltype="has_a" key="id" map="" class="atcol"/>
620                 </links>
621                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
622                         <actions>
623                                 <create permission="ADMIN_TRIGGER_EVENT_DEF">
624                     <context link="event_def" field="owner"/>
625                 </create>
626                                 <retrieve permission="ADMIN_TRIGGER_EVENT_DEF">
627                     <context link="event_def" field="owner"/>
628                 </retrieve>
629                                 <update permission="ADMIN_TRIGGER_EVENT_DEF">
630                     <context link="event_def" field="owner"/>
631                 </update>
632                                 <delete permission="ADMIN_TRIGGER_EVENT_DEF">
633                     <context link="event_def" field="owner"/>
634                 </delete>
635                         </actions>
636                 </permacrud>
637         </class>
638
639         <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">
640                 <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.event_definition_id_seq">
641                         <field reporter:label="Definition ID" name="id" reporter:datatype="id"/>
642                         <field reporter:label="Active" name="active" reporter:datatype="bool"/>
643                         <field reporter:label="Owning Library" name="owner"  reporter:datatype="org_unit"/>
644                         <field reporter:label="Hook" name="hook"  reporter:datatype="link"/>
645                         <field reporter:label="Validator" name="validator"  reporter:datatype="link"/>
646                         <field reporter:label="Reactor" name="reactor"  reporter:datatype="link"/>
647                         <field reporter:label="Success Cleanup" name="cleanup_success"  reporter:datatype="link"/>
648                         <field reporter:label="Failure Cleanup" name="cleanup_failure"  reporter:datatype="link"/>
649                         <field reporter:label="Processing Delay" name="delay"  reporter:datatype="interval"/>
650                         <field reporter:label="Processing Delay Context Field" name="delay_field"  reporter:datatype="text"/>
651                         <field reporter:label="Processing Group Context Field" name="group_field"  reporter:datatype="text"/>
652                         <field reporter:label="Template" name="template"  reporter:datatype="text"/>
653                         <field reporter:label="Name" name="name"  reporter:datatype="text"/>
654                         <field reporter:label="Environmet Entries" name="env" oils_persist:virtual="true"  reporter:datatype="link"/>
655                         <field reporter:label="Parameters" name="params" oils_persist:virtual="true"  reporter:datatype="link"/>
656                 </fields>
657                 <links>
658                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
659                         <link field="hook" reltype="has_a" key="key" map="" class="ath"/>
660                         <link field="validator" reltype="has_a" key="module" map="" class="atval"/>
661                         <link field="reactor" reltype="has_a" key="module" map="" class="atreact"/>
662                         <link field="cleanup_success" reltype="has_a" key="module" map="" class="atclean"/>
663                         <link field="cleanup_failure" reltype="has_a" key="module" map="" class="atclean"/>
664                         <link field="env" reltype="has_many" key="event_def" map="" class="atenv"/>
665                         <link field="params" reltype="has_many" key="event_def" map="" class="atevparam"/>
666                 </links>
667                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
668                         <actions>
669                                 <create permission="ADMIN_TRIGGER_EVENT_DEF" context_field="owner"/>
670                                 <retrieve permission="ADMIN_TRIGGER_EVENT_DEF" context_field="owner"/>
671                                 <update permission="ADMIN_TRIGGER_EVENT_DEF" context_field="owner"/>
672                                 <delete permission="ADMIN_TRIGGER_EVENT_DEF" context_field="owner"/>
673                         </actions>
674                 </permacrud>
675         </class>
676
677         <class id="atev" controller="open-ils.cstore" oils_obj:fieldmapper="action_trigger::event" oils_persist:tablename="action_trigger.event" reporter:label="Trigger Event Entry">
678                 <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.event_id_seq">
679                         <field reporter:label="Event ID" name="id" reporter:datatype="id"/>
680                         <field reporter:label="Target ID" name="target" reporter:datatype="int"/>
681                         <field reporter:label="Event Definition" name="event_def" reporter:datatype="link"/>
682                         <field reporter:label="Add Time" name="add_time" reporter:datatype="timestamp"/>
683                         <field reporter:label="Run Time" name="run_time" reporter:datatype="timestamp"/>
684                         <field reporter:label="Start Time" name="start_time" reporter:datatype="timestamp"/>
685                         <field reporter:label="Update Time" name="update_time" reporter:datatype="timestamp"/>
686                         <field reporter:label="Complete Time" name="complete_time" reporter:datatype="timestamp"/>
687                         <field reporter:label="State" name="state" reporter:datatype="text"/>
688                         <field reporter:label="Template Output" name="template_output" reporter:datatype="link"/>
689                         <field reporter:label="Error Output" name="error_output" reporter:datatype="text"/>
690                         <field reporter:label="Update Process" name="update_process" reporter:datatype="int"/>
691                 </fields>
692                 <links>
693                         <link field="event_def" reltype="has_a" key="id" map="" class="atevdef"/>
694                         <link field="template_output" reltype="has_a" key="id" map="" class="ateo"/>
695                         <link field="error_output" reltype="has_a" key="id" map="" class="ateo"/>
696                 </links>
697         </class>
698
699         <class id="atevparam" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action_trigger::event_param" oils_persist:tablename="action_trigger.event_params" reporter:label="Trigger Event Parameter">
700                 <fields oils_persist:primary="id" oils_persist:sequence="action_trigger.event_params_id_seq">
701                         <field reporter:label="Event ID" name="id" reporter:datatype="id"/>
702                         <field reporter:label="Event Definition" name="event_def" reporter:datatype="link"/>
703                         <field reporter:label="Parameter Name" name="param" reporter:datatype="text"/>
704                         <field reporter:label="Parameter Value" name="value" reporter:datatype="text"/>
705                 </fields>
706                 <links>
707                         <link field="event_def" reltype="has_a" key="id" map="" class="atevdef"/>
708                 </links>
709                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
710                         <actions>
711                                 <create permission="ADMIN_TRIGGER_EVENT_DEF">
712                     <context link="event_def" field="owner"/>
713                 </create>
714                                 <retrieve permission="ADMIN_TRIGGER_EVENT_DEF">
715                     <context link="event_def" field="owner"/>
716                 </retrieve>
717                                 <update permission="ADMIN_TRIGGER_EVENT_DEF">
718                     <context link="event_def" field="owner"/>
719                 </update>
720                                 <delete permission="ADMIN_TRIGGER_EVENT_DEF">
721                     <context link="event_def" field="owner"/>
722                 </delete>
723                         </actions>
724                 </permacrud>
725         </class>
726
727         <class id="aws" controller="open-ils.cstore" oils_obj:fieldmapper="actor::workstation" oils_persist:tablename="actor.workstation" reporter:label="Workstation">
728                 <fields oils_persist:primary="id" oils_persist:sequence="actor.workstation_id_seq">
729                         <field reporter:label="Workstation ID" name="id" reporter:datatype="id"/>
730                         <field reporter:label="Workstation Name" name="name" reporter:datatype="text"/>
731                         <field reporter:label="Owning Library" name="owning_lib"  reporter:datatype="org_unit"/>
732                 </fields>
733                 <links>
734                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
735                 </links>
736         </class>
737
738         <class id="ccm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::circ_modifier" oils_persist:tablename="config.circ_modifier" reporter:label="Circulation Modifier">
739                 <fields oils_persist:primary="code">
740                         <field reporter:label="Code" name="code" reporter:selector="name" reporter:datatype="id"/>
741                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
742                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
743                         <field reporter:label="SIP2 Media Type" name="sip2_media_type" reporter:datatype="text" oils_persist:i18n="true"/>
744                         <field reporter:label="Magnetic Media" name="magnetic_media" reporter:datatype="bool"/>
745                 </fields>
746                 <links/>
747         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
748             <actions>
749                 <create permission="ADMIN_CIRC_MOD" global_required="true"/>
750                 <retrieve/>
751                 <update permission="ADMIN_CIRC_MOD" global_required="true"/>
752                 <delete permission="ADMIN_CIRC_MOD" global_required="true"/>
753             </actions>
754         </permacrud>
755         </class>
756
757         <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">
758                 <fields oils_persist:primary="code">
759                         <field reporter:label="Code" name="code" reporter:selector="name" reporter:datatype="id"/>
760                         <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
761                 </fields>
762                 <links/>
763         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
764             <actions>
765                 <create permission="CREATE_COPY_BTYPE" global_required="true"/>
766                 <retrieve permission="CREATE_COPY_BTYPE UPDATE_COPY_BTYPE DELETE_COPY_BTYPE" global_required="true"/>
767                 <update permission="UPDATE_COPY_BTYPE" global_required="true"/>
768                 <delete permission="DELETE_COPY_BTYPE" global_required="true"/>
769             </actions>
770         </permacrud>
771         </class>
772
773         <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">
774                 <fields oils_persist:primary="code">
775                         <field reporter:label="Code" name="code" reporter:selector="name" reporter:datatype="id"/>
776                         <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
777                 </fields>
778                 <links/>
779         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
780             <actions>
781                 <create permission="CREATE_CN_BTYPE" global_required="true"/>
782                 <retrieve permission="CREATE_CN_BTYPE UPDATE_CN_BTYPE DELETE_CN_BTYPE" global_required="true"/>
783                 <update permission="UPDATE_CN_BTYPE" global_required="true"/>
784                 <delete permission="DELETE_CN_BTYPE" global_required="true"/>
785             </actions>
786         </permacrud>
787         </class>
788
789         <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">
790                 <fields oils_persist:primary="code">
791                         <field reporter:label="Code" name="code" reporter:selector="name" reporter:datatype="id"/>
792                         <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
793                 </fields>
794                 <links/>
795         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
796             <actions>
797                 <create permission="CREATE_BIB_BTYPE" global_required="true"/>
798                 <retrieve permission="CREATE_BIB_BTYPE UPDATE_BIB_BTYPE DELETE_BIB_BTYPE" global_required="true"/>
799                 <update permission="UPDATE_BIB_BTYPE" global_required="true"/>
800                 <delete permission="DELETE_BIB_BTYPE" global_required="true"/>
801             </actions>
802         </permacrud>
803         </class>
804
805         <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">
806                 <fields oils_persist:primary="code">
807                         <field reporter:label="Code" name="code" reporter:selector="name" reporter:datatype="id"/>
808                         <field reporter:label="Label" name="label" reporter:datatype="text" oils_persist:i18n="true"/>
809                 </fields>
810                 <links/>
811         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
812             <actions>
813                 <create permission="CREATE_USER_BTYPE" global_required="true"/>
814                 <retrieve permission="CREATE_USER_BTYPE UPDATE_USER_BTYPE DELETE_USER_BTYPE" global_required="true"/>
815                 <update permission="UPDATE_USER_BTYPE" global_required="true"/>
816                 <delete permission="DELETE_USER_BTYPE" global_required="true"/>
817             </actions>
818         </permacrud>
819         </class>
820
821         <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">
822                 <fields oils_persist:primary="code">
823                         <field reporter:label="Code" name="code" reporter:selector="value" reporter:datatype="id"/>
824                         <field reporter:label="Format" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
825                 </fields>
826                 <links/>
827         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
828             <actions>
829                 <create permission="ADMIN_MARC_CODE" global_required="true"/>
830                 <retrieve/>
831                 <update permission="ADMIN_MARC_CODE" global_required="true"/>
832                 <delete permission="ADMIN_MARC_CODE" global_required="true"/>
833             </actions>
834         </permacrud>
835         </class>
836
837         <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">
838                 <fields oils_persist:primary="id" oils_persist:sequence="config.hold_matrix_matchpoint_id_seq">
839                         <field reporter:label="Matchpoint ID" name="id" reporter:datatype="id"/>
840                         <field reporter:label="Active?" name="active" reporter:datatype="bool"/>
841                         <field reporter:label="User Home Library" name="user_home_ou" reporter:datatype="org_unit"/>
842                         <field reporter:label="Request Library" name="request_ou" reporter:datatype="org_unit"/>
843                         <field reporter:label="Pickup Library" name="pickup_ou" reporter:datatype="org_unit"/>
844                         <field reporter:label="Owning Library" name="item_owning_ou" reporter:datatype="org_unit"/>
845                         <field reporter:label="Item Circ Library" name="item_circ_ou" reporter:datatype="org_unit"/>
846                         <field reporter:label="User Permission Group" name="usr_grp" reporter:datatype="link"/>
847                         <field reporter:label="Requestor Permission Group" name="requestor_grp" reporter:datatype="link"/>
848                         <field reporter:label="Circulation Modifier" name="circ_modifier" oils_persist:primitive="string" reporter:datatype="link"/>
849                         <field reporter:label="MARC Type" name="marc_type" oils_persist:primitive="string" reporter:datatype="link"/>
850                         <field reporter:label="MARC Form" name="marc_form" oils_persist:primitive="string" reporter:datatype="link"/>
851                         <field reporter:label="Videorecording Format" name="marc_vr_format" oils_persist:primitive="string" reporter:datatype="link"/>
852                         <field reporter:label="Reference?" name="ref_flag" reporter:datatype="bool"/>
853                         <field reporter:label="Holdable?" name="holdable" reporter:datatype="bool"/>
854                         <field reporter:label="Range is from Owning Lib?" name="distance_is_from_owner" reporter:datatype="bool"/>
855                         <field reporter:label="Transit Range" name="transit_range" reporter:datatype="int"/>
856                         <field reporter:label="Max Holds" name="max_holds" reporter:datatype="int"/>
857                         <field reporter:label="Max includes Frozen" name="include_frozen_holds" reporter:datatype="bool"/>
858                         <field reporter:label="Copy Age Hold Protection Rule" name="age_hold_protect_rule" reporter:datatype="link"/>
859                 </fields>
860                 <links>
861                         <link field="user_home_ou" reltype="has_a" key="id" map="" class="aou"/>
862                         <link field="request_ou" reltype="has_a" key="id" map="" class="aou"/>
863                         <link field="pickup_ou" reltype="has_a" key="id" map="" class="aou"/>
864                         <link field="item_owning_ou" reltype="has_a" key="id" map="" class="aou"/>
865                         <link field="item_circ_ou" reltype="has_a" key="id" map="" class="aou"/>
866                         <link field="usr_grp" reltype="has_a" key="id" map="" class="pgt"/>
867                         <link field="requestor_grp" reltype="has_a" key="id" map="" class="pgt"/>
868                         <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
869                         <link field="marc_type" reltype="has_a" key="code" map="" class="citm"/>
870                         <link field="marc_form" reltype="has_a" key="code" map="" class="cifm"/>
871                         <link field="marc_vr_format" reltype="has_a" key="code" map="" class="cvrfm"/>
872                         <link field="age_hold_protect_rule" reltype="has_a" key="id" map="" class="crahp"/>
873                 </links>
874         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
875             <actions>
876                 <create permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
877                 <retrieve permission="ADMIN_HOLD_MATRIX_MATCHPOINT VIEW_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
878                 <update permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
879                 <delete permission="ADMIN_HOLD_MATRIX_MATCHPOINT" global_required="true"/>
880             </actions>
881         </permacrud>
882         </class>
883
884         <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">
885                 <fields oils_persist:primary="id" oils_persist:sequence="config.circ_matrix_matchpoint_id_seq">
886                         <field reporter:label="Matchpoint ID" name="id" reporter:datatype="id"/>
887                         <field reporter:label="Active?" name="active" reporter:datatype="bool"/>
888                         <field reporter:label="Org Unit" name="org_unit" reporter:datatype="org_unit"/>
889                         <field reporter:label="Permission Group" name="grp" reporter:datatype="link"/>
890                         <field reporter:label="Circulation Modifier" name="circ_modifier" oils_persist:primitive="string" reporter:datatype="link"/>
891                         <field reporter:label="MARC Type" name="marc_type" oils_persist:primitive="string" reporter:datatype="link"/>
892                         <field reporter:label="MARC Form" name="marc_form" oils_persist:primitive="string" reporter:datatype="link"/>
893                         <field reporter:label="Videorecording Format" name="marc_vr_format" oils_persist:primitive="string" reporter:datatype="link"/>
894                         <field reporter:label="Reference?" name="ref_flag" reporter:datatype="bool"/>
895                         <field reporter:label="User Age: Lower Bound" name="usr_age_lower_bound" reporter:datatype="text"/>
896                         <field reporter:label="User Age: Upper Bound" name="usr_age_upper_bound" reporter:datatype="text"/>
897                         <field reporter:label="Circulate?" name="circulate" reporter:datatype="bool"/>
898                         <field reporter:label="Duration Rule" name="duration_rule" reporter:datatype="link"/>
899                         <field reporter:label="Recurring Fine Rule" name="recurring_fine_rule" reporter:datatype="link"/>
900                         <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
901                         <field reporter:label="Script Test" name="script_test" reporter:datatype="text"/>
902                 </fields>
903                 <links>
904                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
905                         <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
906                         <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
907                         <link field="marc_type" reltype="has_a" key="code" map="" class="citm"/>
908                         <link field="marc_form" reltype="has_a" key="code" map="" class="cifm"/>
909                         <link field="marc_vr_format" reltype="has_a" key="code" map="" class="cvrfm"/>
910                         <link field="duration_rule" reltype="has_a" key="id" map="" class="crcd"/>
911                         <link field="max_fine_rule" reltype="has_a" key="id" map="" class="crmf"/>
912                         <link field="recurring_fine_rule" reltype="has_a" key="id" map="" class="crrf"/>
913                 </links>
914         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
915             <actions>
916                 <create permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
917                 <retrieve permission="ADMIN_CIRC_MATRIX_MATCHPOINT VIEW_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
918                 <update permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
919                 <delete permission="ADMIN_CIRC_MATRIX_MATCHPOINT" context_field='org_unit'/>
920             </actions>
921         </permacrud>
922         </class>
923
924         <class id="ccmcmt" controller="open-ils.cstore" oils_obj:fieldmapper="config::circ_matrix_circ_mod_test" oils_persist:tablename="config.circ_matrix_circ_mod_test" reporter:label="Circulation Matrix Circulation Modifier Subtest">
925                 <fields oils_persist:primary="id" oils_persist:sequence="config.circ_matrix_circ_mod_test_id_seq">
926                         <field reporter:label="Test ID" name="id" reporter:datatype="id"/>
927                         <field reporter:label="Matchpoint ID" name="matchpoint" reporter:datatype="link"/>
928                         <field reporter:label="Items Out" name="items_out" reporter:datatype="int"/>
929                 </fields>
930                 <links>
931                         <link field="matchpoint" reltype="has_a" key="id" map="" class="ccmm"/>
932                 </links>
933         </class>
934
935         <class id="ccmcmtm" controller="open-ils.cstore" oils_obj:fieldmapper="config::circ_matrix_circ_mod_test_map" oils_persist:tablename="config.circ_matrix_circ_mod_test_map" reporter:label="Circulation Matrix Circulation Modifier Subtest Circulation Modifier Set">
936                 <fields oils_persist:primary="id" oils_persist:sequence="config.circ_matrix_circ_mod_test_map_id_seq">
937                         <field reporter:label="Entry ID" name="id" reporter:datatype="id"/>
938                         <field reporter:label="Circulation Modifier Subtest ID" name="circ_mod_test" reporter:datatype="link"/>
939                         <field reporter:label="Circulation Modifier" name="circ_mod" reporter:datatype="link"/>
940                 </fields>
941                 <links>
942                         <link field="circ_mod_test" reltype="has_a" key="id" map="" class="ccmcmt"/>
943                         <link field="circ_mod" reltype="has_a" key="code" map="" class="ccm"/>
944                 </links>
945         </class>
946
947         <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">
948                 <fields oils_persist:primary="id" oils_persist:sequence="config.identification_type_id_seq">
949                         <field reporter:label="Identification ID" name="id" reporter:selector="name" reporter:datatype="id"/>
950                         <field reporter:label="Identification Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
951                 </fields>
952                 <links/>
953         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
954             <actions>
955                 <create permission="ADMIN_IDENT_TYPE" global_required="true"/>
956                 <retrieve/>
957                 <update permission="ADMIN_IDENT_TYPE" global_required="true"/>
958                 <delete permission="ADMIN_IDENT_TYPE" global_required="true"/>
959             </actions>
960         </permacrud>
961         </class>
962
963         <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">
964                 <fields oils_persist:primary="id" oils_persist:sequence="action.survey_question_id_seq">
965                         <field reporter:label="Answers" name="answers" oils_persist:virtual="true" reporter:datatype="link"/>
966                         <field reporter:label="Responses" name="responses" oils_persist:virtual="true" reporter:datatype="link"/>
967                         <field reporter:label="Question ID" name="id" reporter:datatype="id" />
968                         <field reporter:label="Question" name="question" reporter:datatype="text"/>
969                         <field reporter:label="Survey" name="survey" reporter:datatype="link"/>
970                 </fields>
971                 <links>
972                         <link field="survey" reltype="has_a" key="id" map="" class="asv"/>
973                         <link field="responses" reltype="has_many" key="question" map="" class="asvr"/>
974                         <link field="answers" reltype="has_many" key="question" map="" class="asva"/>
975                 </links>
976         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
977             <actions>
978                 <create permission="ADMIN_SURVEY">
979                     <context link="survey" field="owner"/>
980                 </create>
981                 <retrieve/>
982                 <update permission="ADMIN_SURVEY">
983                     <context link="survey" field="owner"/>
984                 </update>
985                 <delete permission="ADMIN_SURVEY">
986                     <context link="survey" field="owner"/>
987                 </delete>
988             </actions>
989         </permacrud>
990         </class>
991         <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">
992                 <fields oils_persist:primary="id" oils_persist:sequence="">
993                         <field reporter:label="Balance Owed" name="balance_owed" reporter:datatype="money"/>
994                         <field reporter:label="Transaction ID" name="id" reporter:datatype="id"/>
995                         <field reporter:label="Last Billing Note" name="last_billing_note" reporter:datatype="text"/>
996                         <field reporter:label="Last Billing Timestamp" name="last_billing_ts" reporter:datatype="timestamp"/>
997                         <field reporter:label="Last Billing Type" name="last_billing_type" reporter:datatype="text"/>
998                         <field reporter:label="Last Payment Note" name="last_payment_note" reporter:datatype="text"/>
999                         <field reporter:label="Last Payment Timestamp" name="last_payment_ts" reporter:datatype="timestamp"/>
1000                         <field reporter:label="Last Payment Type" name="last_payment_type" reporter:datatype="text"/>
1001                         <field reporter:label="Total Owed" name="total_owed" reporter:datatype="money"/>
1002                         <field reporter:label="Total Paid" name="total_paid" reporter:datatype="money"/>
1003                         <field reporter:label="Billed User" name="usr" reporter:datatype="link"/>
1004                         <field reporter:label="Transaction Finish Time" name="xact_finish" reporter:datatype="timestamp" />
1005                         <field reporter:label="Transaction Start Time" name="xact_start" reporter:datatype="timestamp" />
1006                         <field reporter:label="Transaction Type" name="xact_type" reporter:datatype="text"/>
1007                 </fields>
1008                 <links>
1009                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1010                 </links>
1011         </class>
1012         <class id="aun" controller="open-ils.cstore" oils_obj:fieldmapper="actor::usr_note" oils_persist:tablename="actor.usr_note" reporter:label="User Note">
1013                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_note_id_seq">
1014                         <field reporter:label="Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
1015                         <field reporter:label="Creating Staff" name="creator" reporter:datatype="link"/>
1016                         <field reporter:label="Note ID" name="id" reporter:datatype="id" />
1017                         <field reporter:label="Is OPAC Visible?" name="pub" reporter:datatype="bool"/>
1018                         <field reporter:label="Note Title" name="title" reporter:datatype="text"/>
1019                         <field reporter:label="User" name="usr" reporter:datatype="link" />
1020                         <field reporter:label="Note Content" name="value" reporter:datatype="text"/>
1021                 </fields>
1022                 <links>
1023                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1024                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
1025                 </links>
1026         </class>
1027         <class id="aus" controller="open-ils.cstore" oils_obj:fieldmapper="actor::user_setting" oils_persist:tablename="actor.usr_setting" reporter:label="User Setting">
1028                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_setting_id_seq">
1029                         <field reporter:label="Setting ID" name="id" reporter:datatype="id" />
1030                         <field reporter:label="Name" name="name" reporter:datatype="text"/>
1031                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
1032                         <field reporter:label="Value" name="value" reporter:datatype="text"/>
1033                 </fields>
1034                 <links>
1035                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1036                 </links>
1037         </class>
1038         <class id="mafe" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::author_field_entry" oils_persist:tablename="metabib.author_field_entry" reporter:label="Author Field Entry">
1039                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.author_field_entry_id_seq">
1040                         <field name="field" reporter:datatype="link"/>
1041                         <field name="id" reporter:datatype="id" />
1042                         <field name="source" reporter:datatype="link"/>
1043                         <field name="value" reporter:datatype="text"/>
1044                 </fields>
1045                 <links>
1046                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
1047                         <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
1048                 </links>
1049         </class>
1050         <class id="aihu" controller="open-ils.cstore" oils_obj:fieldmapper="action::in_house_use" oils_persist:tablename="action.in_house_use" reporter:core="true" reporter:label="In House Use">
1051                 <fields oils_persist:primary="id" oils_persist:sequence="action.in_house_use_id_seq">
1052                         <field reporter:label="Use ID" name="id" reporter:datatype="id" />
1053                         <field reporter:label="Item" name="item" reporter:datatype="int" />
1054                         <field reporter:label="Using Library" name="org_unit" reporter:datatype="org_unit"/>
1055                         <field reporter:label="Recording Staff" name="staff" reporter:datatype="link"/>
1056                         <field reporter:label="Use Date/Time" name="use_time" reporter:datatype="timestamp"/>
1057                 </fields>
1058                 <links>
1059                         <link field="item" reltype="has_a" key="id" map="" class="acp"/>
1060                         <link field="staff" reltype="has_a" key="id" map="" class="au"/>
1061                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1062                 </links>
1063         </class>
1064         <class id="ancihu" controller="open-ils.cstore" oils_obj:fieldmapper="action::non_cat_in_house_use" oils_persist:tablename="action.non_cat_in_house_use" reporter:core="true" reporter:label="Non-cataloged In House Use">
1065                 <fields oils_persist:primary="id" oils_persist:sequence="action.non_cat_in_house_use_id_seq">
1066                         <field reporter:label="Use ID" name="id" reporter:datatype="id" />
1067                         <field reporter:label="Item Type" name="item_type" reporter:datatype="link"/>
1068                         <field reporter:label="Using Library" name="org_unit" reporter:datatype="org_unit"/>
1069                         <field reporter:label="Recording Staff" name="staff" reporter:datatype="link"/>
1070                         <field reporter:label="Use Date/Time" name="use_time" reporter:datatype="timestamp"/>
1071                 </fields>
1072                 <links>
1073                         <link field="item_type" reltype="has_a" key="id" map="" class="cnct"/>
1074                         <link field="staff" reltype="has_a" key="id" map="" class="au"/>
1075                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1076                 </links>
1077         </class>
1078         <class id="atc" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::transit_copy" oils_persist:tablename="action.transit_copy" reporter:core="true" reporter:label="Copy Transit">
1079                 <fields oils_persist:primary="id" oils_persist:sequence="action.transit_copy_id_seq">
1080                         <field reporter:label="Pretransit Copy Status" name="copy_status" reporter:datatype="bool"/>
1081                         <field reporter:label="Destination" name="dest" reporter:datatype="link"/>
1082                         <field reporter:label="Receive Date/Time" name="dest_recv_time" reporter:datatype="timestamp"/>
1083                         <field reporter:label="Transit ID" name="id" reporter:datatype="id"/>
1084                         <field reporter:label="Is Persistent? (unused)" name="persistant_transfer" reporter:datatype="bool"/>
1085                         <field reporter:label="Previous Hop (unused)" name="prev_hop" reporter:datatype="link"/>
1086                         <field reporter:label="Source" name="source" reporter:datatype="link"/>
1087                         <field reporter:label="Send Date/Time" name="source_send_time" reporter:datatype="timestamp"/>
1088                         <field reporter:label="Transited Copy" name="target_copy" reporter:datatype="link"/>
1089                         <field reporter:label="Hold Transit" name="hold_transit_copy" oils_persist:virtual="true" reporter:datatype="link"/>
1090                 </fields>
1091                 <links>
1092                         <link field="hold_transit_copy" reltype="might_have" key="id" map="" class="ahtc"/>
1093                         <link field="source" reltype="has_a" key="id" map="" class="aou"/>
1094                         <link field="copy_status" reltype="has_a" key="id" map="" class="ccs"/>
1095                         <link field="dest" reltype="has_a" key="id" map="" class="aou"/>
1096                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
1097                 </links>
1098         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1099             <actions>
1100                 <create permission="TRANSIT_COPY" context_field="owner">
1101                     <context link="target_copy" field="circ_lib"/>
1102                 </create>
1103                 <retrieve/>
1104                 <update permission="UPDATE_TRANSIT" context_field="dest source"/>
1105                 <delete permission="DELETE_TRANSIT" context_field="dest source"/>
1106             </actions>
1107         </permacrud>
1108         </class>
1109         <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">
1110                 <fields oils_persist:primary="id" oils_persist:sequence="action.survey_response_id_seq">
1111                         <field reporter:label="Answer" name="answer" reporter:datatype="link"/>
1112                         <field reporter:label="Answer Date/Time" name="answer_date" reporter:datatype="timestamp"/>
1113                         <field reporter:label="Effective Answer Date/Time" name="effective_date" reporter:datatype="timestamp"/>
1114                         <field reporter:label="Answer ID" name="id" reporter:datatype="id" />
1115                         <field reporter:label="Question" name="question" reporter:datatype="link"/>
1116                         <field reporter:label="Response Group ID" name="response_group_id" reporter:datatype="int" />
1117                         <field reporter:label="Survey" name="survey" reporter:datatype="link"/>
1118                         <field reporter:label="Responding User" name="usr" reporter:datatype="link"/>
1119                 </fields>
1120                 <links>
1121                         <link field="question" reltype="has_a" key="id" map="" class="asvq"/>
1122                         <link field="survey" reltype="has_a" key="id" map="" class="asv"/>
1123                         <link field="answer" reltype="has_a" key="id" map="" class="asva"/>
1124                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1125                 </links>
1126         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1127             <actions>
1128                 <create permission="ADMIN_SURVEY">
1129                     <context link="survey" field="owner"/>
1130                 </create>
1131                 <retrieve/>
1132                 <update permission="ADMIN_SURVEY">
1133                     <context link="survey" field="owner"/>
1134                 </update>
1135                 <delete permission="ADMIN_SURVEY">
1136                     <context link="survey" field="owner"/>
1137                 </delete>
1138             </actions>
1139         </permacrud>
1140         </class>
1141         <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">
1142                 <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_item_id_seq">
1143                         <field name="bucket" />
1144                         <field name="id" reporter:datatype="id" />
1145                         <field name="target_copy" reporter:datatype="link"/>
1146                         <field name="create_time" reporter:datatype="timestamp" />
1147                         <field name="pos" reporter:datatype="int" />
1148                         <field name="notes" oils_persist:virtual="true" reporter:datatype="link" />
1149                 </fields>
1150                 <links>
1151                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
1152                         <link field="bucket" reltype="has_a" key="id" map="" class="ccb"/>
1153             <link field="notes" reltype="has_many" map="" key="item" class="ccbin"/>
1154                 </links>
1155         </class>
1156         <class id="ccbin" controller="open-ils.cstore" oils_obj:fieldmapper="container::copy_bucket_item_note" oils_persist:tablename="container.copy_bucket_item_note" reporter:label="Copy Bucket Item Note">
1157                 <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_item_note_id_seq">
1158                         <field name="id" reporter:datatype="id" />
1159                         <field name="item" reporter:datatype="link"/>
1160                         <field name="note" reporter:datatype="text" />
1161                 </fields>
1162                 <links>
1163                         <link field="item" reltype="has_a" key="id" map="" class="ccbi"/>
1164                 </links>
1165         </class>
1166         <class id="are" controller="open-ils.cstore" oils_obj:fieldmapper="authority::record_entry" oils_persist:tablename="authority.record_entry" reporter:label="Authority Record Entry">
1167                 <fields oils_persist:primary="id" oils_persist:sequence="authority.record_entry_id_seq">
1168                         <field name="active" reporter:datatype="bool"/>
1169                         <field name="arn_source" />
1170                         <field name="arn_value" />
1171                         <field name="create_date" reporter:datatype="timestamp"/>
1172                         <field name="creator" />
1173                         <field name="deleted" reporter:datatype="bool"/>
1174                         <field name="edit_date" reporter:datatype="timestamp"/>
1175                         <field name="editor" />
1176                         <field name="id" reporter:datatype="id" />
1177                         <field name="last_xact_id" />
1178                         <field name="marc" />
1179                         <field name="source" />
1180                         <field name="fixed_fields" oils_persist:virtual="true" />
1181                         <field name="notes" oils_persist:virtual="true" />
1182                 </fields>
1183                 <links>
1184                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
1185                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
1186                         <link field="notes" reltype="has_many" key="record" map="" class="arn"/>
1187                         <link field="fixed_fields" reltype="might_have" key="record" map="" class="ard"/>
1188                 </links>
1189         </class>
1190         <class id="ard" controller="open-ils.cstore" oils_obj:fieldmapper="authority::record_descriptor" oils_persist:tablename="authority.rec_descriptor" reporter:label="Authority Record Descriptor">
1191                 <fields oils_persist:primary="id" oils_persist:sequence="authority.rec_descriptor_id_seq">
1192                         <field name="char_encoding" />
1193                         <field name="id" />
1194                         <field name="record" />
1195                         <field name="record_status" />
1196                 </fields>
1197                 <links>
1198                         <link field="record" reltype="has_a" key="id" map="" class="are"/>
1199                 </links>
1200         </class>
1201         <class id="clm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::language_map" oils_persist:tablename="config.language_map" reporter:label="Language Map" oils_persist:field_safe="true">
1202                 <fields oils_persist:primary="code" oils_persist:sequence="">
1203                         <field reporter:label="Language Code" name="code" reporter:selector="value" reporter:datatype="text"/>
1204                         <field reporter:label="Language" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
1205                 </fields>
1206                 <links/>
1207         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1208             <actions>
1209                 <create permission="CREATE_MARC_CODE" global_required="true"/>
1210                 <retrieve permission="CREATE_MARC_CODE UPDATE_MARC_CODE DELETE_MARC_CODE" global_required="true"/>
1211                 <update permission="UPDATE_MARC_CODE" global_required="true"/>
1212                 <delete permission="DELETE_MARC_CODE" global_required="true"/>
1213             </actions>
1214         </permacrud>
1215         </class>
1216         <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">
1217                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
1218                         <field name="accepting_usr" />
1219                         <field name="amount" reporter:datatype="money" />
1220                         <field name="amount_collected" reporter:datatype="money" />
1221                         <field name="approval_code" reporter:datatype="text"/>
1222                         <field name="cash_drawer" reporter:datatype="link"/>
1223                         <field name="cc_number" reporter:datatype="text"/>
1224                         <field name="cc_type" reporter:datatype="text"/>
1225                         <field name="expire_month" reporter:datatype="int" />
1226                         <field name="expire_year" reporter:datatype="int" />
1227                         <field name="id" reporter:datatype="id" />
1228                         <field name="note" reporter:datatype="text"/>
1229                         <field name="payment_ts" reporter:datatype="timestamp"/>
1230                         <field name="xact" reporter:datatype="link"/>
1231                         <field name="payment_type" oils_persist:virtual="true" reporter:datatype="text"/>
1232                         <field name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
1233                 </fields>
1234                 <links>
1235                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
1236                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
1237                         <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
1238                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
1239                 </links>
1240         </class>
1241         <class id="cxt" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::xml_transform" oils_persist:tablename="config.xml_transform" reporter:label="XML/XSLT Transform Definition">
1242                 <fields oils_persist:primary="name">
1243                         <field name="field_class" />
1244                         <field reporter:label="Name" name="name" reporter:datatype="text" />
1245                         <field reporter:label="Namespace URI" name="namespace_uri" reporter:datatype="text"/>
1246                         <field reporter:label="Namespace Prefix" name="prefix" reporter:datatype="text"/>
1247                         <field reporter:label="XSLT" name="xslt" reporter:datatype="text" />
1248                 </fields>
1249                 <links/>
1250         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1251             <actions>
1252                 <create permission="CREATE_XML_TRANSFORM" global_required="true"/>
1253                 <retrieve/>
1254                 <update permission="UPDATE_XML_TRANSFORM" global_required="true"/>
1255                 <delete permission="DELETE_XML_TRANSFORM" global_required="true"/>
1256             </actions>
1257         </permacrud>
1258         </class>
1259         <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">
1260                 <fields oils_persist:primary="id" oils_persist:sequence="config.metabib_field_id_seq">
1261                         <field name="field_class" />
1262                         <field name="id" reporter:datatype="id" />
1263                         <field name="name" reporter:datatype="text"/>
1264                         <field name="xpath" reporter:datatype="text"/>
1265                         <field name="weight" reporter:datatype="int" />
1266                         <field name="format" reporter:datatype="link"/>
1267                         <field name="search_field" reporter:datatype="bool" />
1268                         <field name="facet_field" reporter:datatype="bool" />
1269                 </fields>
1270                 <links/>
1271         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1272             <actions>
1273                 <create permission="CREATE_METABIB_FIELD" global_required="true"/>
1274                 <retrieve/>
1275                 <update permission="UPDATE_METABIB_FIELD" global_required="true"/>
1276                 <delete permission="DELETE_METABIB_FIELD" global_required="true"/>
1277             </actions>
1278         </permacrud>
1279         </class>
1280         <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">
1281                 <fields oils_persist:primary="code" oils_persist:sequence="">
1282                         <field reporter:label="Audience Code" name="code" reporter:selector="value" reporter:datatype="text"/>
1283                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
1284                         <field reporter:label="Audience" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
1285                 </fields>
1286                 <links/>
1287         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1288             <actions>
1289                 <create permission="CREATE_MARC_CODE" global_required="true"/>
1290                 <retrieve permission="CREATE_MARC_CODE UPDATE_MARC_CODE DELETE_MARC_CODE" global_required="true"/>
1291                 <update permission="UPDATE_MARC_CODE" global_required="true"/>
1292                 <delete permission="DELETE_MARC_CODE" global_required="true"/>
1293             </actions>
1294         </permacrud>
1295         </class>
1296         <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">
1297                 <fields oils_persist:primary="code" oils_persist:sequence="">
1298                         <field reporter:label="Item Form Code" name="code" reporter:selector="value" reporter:datatype="text"/>
1299                         <field reporter:label="Item Form" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
1300                 </fields>
1301                 <links/>
1302         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1303             <actions>
1304                 <create permission="ADMIN_MARC_CODE" global_required="true"/>
1305                 <retrieve/>
1306                 <update permission="ADMIN_MARC_CODE" global_required="true"/>
1307                 <delete permission="ADMIN_MARC_CODE" global_required="true"/>
1308             </actions>
1309         </permacrud>
1310         </class>
1311         <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">
1312                 <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_id_seq">
1313                         <field reporter:label="Copies" name="copies" oils_persist:virtual="true" reporter:datatype="link"/>
1314                         <field reporter:label="Create Date/Time" name="create_date" reporter:datatype="timestamp"/>
1315                         <field reporter:label="Creating User" name="creator" reporter:datatype="link"/>
1316                         <field reporter:label="Is Deleted" name="deleted" reporter:datatype="bool"/>
1317                         <field reporter:label="Last Edit Date/Time" name="edit_date" reporter:datatype="timestamp"/>
1318                         <field reporter:label="Last Editing User" name="editor" reporter:datatype="link"/>
1319                         <field reporter:label="Call Number/Volume ID" name="id" reporter:datatype="id" />
1320                         <field reporter:label="Call Number Label" name="label" reporter:datatype="text"/>
1321                         <field reporter:label="Owning Library" name="owning_lib"  reporter:datatype="org_unit"/>
1322                         <field reporter:label="Bib Record" name="record" reporter:datatype="link"/>
1323                         <field reporter:label="Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
1324                         <field reporter:label="URI Maps" name="uri_maps" oils_persist:virtual="true" reporter:datatype="link"/>
1325                         <field reporter:label="URIs" name="uris" oils_persist:virtual="true" reporter:datatype="link"/>
1326                 </fields>
1327                 <links>
1328                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
1329                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
1330                         <link field="record" reltype="has_a" key="id" map="" class="bre"/>
1331                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
1332                         <link field="notes" reltype="has_many" key="call_number" map="" class="acnn"/>
1333                         <link field="copies" reltype="has_many" key="call_number" map="" class="acp"/>
1334                         <link field="uris" reltype="has_many" key="call_number" map="uri" class="auricnm"/>
1335                         <link field="uri_maps" reltype="has_many" key="call_number" map="" class="auricnm"/>
1336                 </links>
1337         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1338             <actions>
1339                 <create permission="CREATE_VOLUME" context_field="owning_lib"/>
1340                 <retrieve/>
1341                 <update permission="UPDATE_VOLUME" context_field="owning_lib"/>
1342                 <delete permission="DELETE_VOLUME" context_field="owning_lib"/>
1343             </actions>
1344         </permacrud>
1345         </class>
1346         <class id="auri" controller="open-ils.cstore" oils_obj:fieldmapper="asset::uri" oils_persist:tablename="asset.uri" reporter:label="Electronic Access URI">
1347                 <fields oils_persist:primary="id" oils_persist:sequence="asset.uri_id_seq">
1348                         <field reporter:label="URI ID" name="id" reporter:datatype="id"/>
1349                         <field reporter:label="URI" name="href" reporter:datatype="text"/>
1350                         <field reporter:label="Label" name="label" reporter:datatype="text"/>
1351                         <field reporter:label="Use Information" name="use_restriction" reporter:datatype="text"/>
1352                         <field reporter:label="Active" name="active" reporter:datatype="bool"/>
1353                         <field reporter:label="Call Number Maps" name="call_number_maps" oils_persist:virtual="true" reporter:datatype="link"/>
1354                         <field reporter:label="Call Numbers" name="call_numbers" oils_persist:virtual="true" reporter:datatype="link"/>
1355                 </fields>
1356                 <links>
1357                         <link field="call_numbers" reltype="has_many" key="uri" map="call_number" class="auricnm"/>
1358                         <link field="call_number_maps" reltype="has_many" key="uri" map="" class="auricnm"/>
1359         </links>
1360         </class>
1361         <class id="auricnm" controller="open-ils.cstore" oils_obj:fieldmapper="asset::uri_call_number_map" oils_persist:tablename="asset.uri_call_number_map" reporter:label="Electronic Access URI to Call Number Map">
1362                 <fields oils_persist:primary="id" oils_persist:sequence="asset.uri_call_number_map_id_seq">
1363                         <field reporter:label="ID" name="id" reporter:datatype="id"/>
1364                         <field reporter:label="URI" name="uri" reporter:datatype="int"/>
1365                         <field reporter:label="Call Number" name="call_number" reporter:datatype="text"/>
1366                 </fields>
1367                 <links>
1368                         <link field="uri" reltype="has_a" key="id" map="" class="auri"/>
1369                         <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
1370                 </links>
1371         </class>
1372         <class id="cst" controller="open-ils.cstore" oils_obj:fieldmapper="config::standing" oils_persist:tablename="config.standing" reporter:label="Standing Penalty">
1373                 <fields oils_persist:primary="id" oils_persist:sequence="config.standing_id_seq">
1374                         <field name="id" reporter:datatype="id" />
1375                         <field name="value" oils_persist:i18n="true" />
1376                 </fields>
1377                 <links/>
1378         </class>
1379         <class id="mous" controller="open-ils.cstore" oils_obj:fieldmapper="money::open_user_summary" oils_persist:tablename="money.open_usr_summary" reporter:label="Open User Summary">
1380                 <fields oils_persist:primary="usr" oils_persist:sequence="">
1381                         <field name="balance_owed" reporter:datatype="money" />
1382                         <field name="total_owed" reporter:datatype="money" />
1383                         <field name="total_paid" reporter:datatype="money" />
1384                         <field name="usr" reporter:datatype="link"/>
1385                 </fields>
1386                 <links/>
1387         </class>
1388         <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">
1389                 <fields oils_persist:primary="id" oils_persist:sequence="money.collections_tracker_id_seq">
1390                         <field name="collector" />
1391                         <field name="enter_time" reporter:datatype="timestamp"/>
1392                         <field name="id" reporter:datatype="id" />
1393                         <field name="location" reporter:datatype="link"/>
1394                         <field name="usr" reporter:datatype="link"/>
1395                 </fields>
1396                 <links>
1397                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1398                         <link field="collector" reltype="has_a" key="id" map="" class="au"/>
1399                         <link field="location" reltype="has_a" key="id" map="" class="aou"/>
1400                 </links>
1401         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1402             <actions>
1403                 <create permission="money.collections_tracker.create" context_field="location"/>
1404                 <retrieve permission="money.collections_tracker.create" context_field="location"/> 
1405                 <delete permission="money.collections_tracker.create" context_field="location"/>
1406             </actions>
1407         </permacrud>
1408         </class>
1409         <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">
1410                 <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_entry_id_seq">
1411                         <field reporter:label="Call Numbers" name="call_numbers" oils_persist:virtual="true" reporter:datatype="link"/>
1412                         <field reporter:label="Fixed Field Entry" name="fixed_fields" oils_persist:virtual="true" reporter:datatype="link"/>
1413                         <field reporter:label="Is Active?" name="active" reporter:datatype="bool"/>
1414                         <field reporter:label="Record Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
1415                         <field reporter:label="Record Creator" name="creator" reporter:datatype="link"/>
1416                         <field reporter:label="Is Deleted?" name="deleted" reporter:datatype="bool"/>
1417                         <field reporter:label="Last Edit Data/Time" name="edit_date" reporter:datatype="timestamp"/>
1418                         <field reporter:label="Last Editing User" name="editor" reporter:datatype="link"/>
1419                         <field reporter:label="Fingerprint" name="fingerprint"  reporter:datatype="text"/>
1420                         <field reporter:label="Record ID" name="id" reporter:datatype="id" />
1421                         <field reporter:label="Last Transaction ID" name="last_xact_id"  reporter:datatype="text"/>
1422                         <field reporter:label="MARC21Slim" name="marc"  reporter:datatype="text"/>
1423                         <field reporter:label="Overall Quality" name="quality" reporter:datatype="int" />
1424                         <field reporter:label="Record Source" name="source" reporter:datatype="link"/>
1425                         <field reporter:label="TCN Source" name="tcn_source"  reporter:datatype="text"/>
1426                         <field reporter:label="TCN Value" name="tcn_value"  reporter:datatype="text"/>
1427                         <field reporter:label="Metarecord" name="metarecord" oils_persist:virtual="true" reporter:datatype="link"/>
1428                         <field reporter:label="Language Code" name="language" oils_persist:virtual="true" reporter:datatype="link"/>
1429                         <field reporter:label="Non-MARC Record Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
1430                         <field reporter:label="Indexed Keyword Field Entries" name="keyword_field_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1431                         <field reporter:label="Indexed Subject Field Entries" name="subject_field_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1432                         <field reporter:label="Indexed Title Field Entries" name="title_field_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1433                         <field reporter:label="Indexed Author Field Entries" name="author_field_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1434                         <field reporter:label="Indexed Series Field Entries" name="series_field_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1435                         <field reporter:label="Flattened MARC Fields " name="full_record_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1436                         <field reporter:label="Simple Record Extracts " name="simple_record" oils_persist:virtual="true" reporter:datatype="link"/>
1437                 </fields>
1438                 <links>
1439                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
1440                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
1441                         <link field="simple_record" reltype="might_have" key="id" map="" class="rmsr"/>
1442                         <link field="metarecord" reltype="might_have" key="source" map="metarecord" class="mmrsm"/>
1443                         <link field="call_numbers" reltype="has_many" key="record" map="" class="acn"/>
1444                         <link field="keyword_field_entries" reltype="has_many" key="source" map="" class="mkfe"/>
1445                         <link field="fixed_fields" reltype="might_have" key="record" map="" class="mrd"/>
1446                         <link field="language" reltype="might_have" key="record" map="item_lang" class="mrd"/>
1447                         <link field="subject_field_entries" reltype="has_many" key="source" map="" class="msfe"/>
1448                         <link field="title_field_entries" reltype="has_many" key="source" map="" class="mtfe"/>
1449                         <link field="notes" reltype="has_many" key="record" map="" class="bren"/>
1450                         <link field="author_field_entries" reltype="has_many" key="source" map="" class="mafe"/>
1451                         <link field="series_field_entries" reltype="has_many" key="source" map="" class="msefe"/>
1452                         <link field="full_record_entries" reltype="has_many" key="record" map="" class="mfr"/>
1453                 </links>
1454         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1455             <actions>
1456                 <create permission="CREATE_MARC IMPORT_MARC" global_required="true"/>
1457                 <retrieve/>
1458                 <update permission="UPDATE_MARC" global_required="true"/>
1459             </actions>
1460         </permacrud>
1461         </class>
1462         <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">
1463                 <fields oils_persist:primary="id" oils_persist:sequence="">
1464                         <field name="dow_0_close" />
1465                         <field name="dow_0_open" />
1466                         <field name="dow_1_close" />
1467                         <field name="dow_1_open" />
1468                         <field name="dow_2_close" />
1469                         <field name="dow_2_open" />
1470                         <field name="dow_3_close" />
1471                         <field name="dow_3_open" />
1472                         <field name="dow_4_close" />
1473                         <field name="dow_4_open" />
1474                         <field name="dow_5_close" />
1475                         <field name="dow_5_open" />
1476                         <field name="dow_6_close" />
1477                         <field name="dow_6_open" />
1478                         <field name="id" reporter:datatype="id" />
1479                         <field name="org_unit" oils_persist:virtual="true" reporter:datatype="org_unit"/>
1480                 </fields>
1481                 <links>
1482                         <link field="org_unit" reltype="might_have" key="id" map="" class="aou"/>
1483                 </links>
1484         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1485             <actions>
1486                 <create permission="CREATE_HOURS_OF_OPERATION" context_field="org_unit"/>
1487                 <retrieve/>
1488                 <update permission="UPDATE_HOURS_OF_OPERATION" context_field="org_unit"/>
1489                 <delete permission="DELETE_HOURS_OF_OPERATION" context_field="org_unit"/>
1490             </actions>
1491         </permacrud>
1492         </class>
1493         <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">
1494                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_closed_id_seq">
1495                         <field name="close_end" reporter:datatype="timestamp" />
1496                         <field name="close_start" reporter:datatype="timestamp" />
1497                         <field name="id" reporter:datatype="id" />
1498                         <field name="org_unit" reporter:datatype="org_unit"/>
1499                         <field name="reason" reporter:datatype="text"/>
1500                 </fields>
1501                 <links>
1502                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1503                 </links>
1504         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1505             <actions>
1506                 <create permission="CREATE_ORG_UNIT_CLOSING" context_field="org_unit"/>
1507                 <retrieve/>
1508                 <update permission="UPDATE_ORG_UNIT_CLOSING" context_field="org_unit"/>
1509                 <delete permission="DELETE_ORG_UNIT_CLOSING" context_field="org_unit"/>
1510             </actions>
1511         </permacrud>
1512         </class>
1513         <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">
1514                 <fields oils_persist:primary="id" oils_persist:sequence="config.rule_circ_duration_id_seq">
1515                         <field name="extended" reporter:datatype="interval"/>
1516                         <field name="id" reporter:datatype="id" reporter:selector="name"/>
1517                         <field name="max_renewals" reporter:datatype="int" />
1518                         <field name="name" reporter:datatype="text"/>
1519                         <field name="normal" reporter:datatype="interval"/>
1520                         <field name="shrt" reporter:datatype="interval"/>
1521                 </fields>
1522                 <links>
1523                 </links>
1524         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1525             <actions>
1526                 <create permission="CREATE_CIRC_DURATION" global_required="true"/>
1527                 <retrieve/>
1528                 <update permission="UPDATE_CIRC_DURATION" global_required="true"/>
1529                 <delete permission="DELETE_CIRC_DURATION" global_required="true"/>
1530             </actions>
1531         </permacrud>
1532         </class>
1533         <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">
1534                 <fields oils_persist:primary="id" oils_persist:sequence="">
1535                         <field name="balance_owed" reporter:datatype="money"/>
1536                         <field name="id" reporter:datatype="id" />
1537                         <field name="last_billing_note" reporter:datatype="text"/>
1538                         <field name="last_billing_ts" reporter:datatype="timestamp"/>
1539                         <field name="last_billing_type" reporter:datatype="text"/>
1540                         <field name="last_payment_note" reporter:datatype="text"/>
1541                         <field name="last_payment_ts" reporter:datatype="timestamp"/>
1542                         <field name="last_payment_type" reporter:datatype="text"/>
1543                         <field name="total_owed" reporter:datatype="money"/>
1544                         <field name="total_paid" reporter:datatype="money"/>
1545                         <field name="usr" reporter:datatype="link"/>
1546                         <field name="xact_finish" reporter:datatype="timestamp" />
1547                         <field name="xact_start" reporter:datatype="timestamp" />
1548                         <field name="xact_type" reporter:datatype="text"/>
1549                         <field name="xact" oils_persist:virtual="true" reporter:datatype="link"/>
1550                         <field name="grocery" oils_persist:virtual="true" reporter:datatype="link"/>
1551                         <field name="circulation" oils_persist:virtual="true" reporter:datatype="link"/>
1552                         <field name="billing_location" reporter:datatype="link"/>
1553                 </fields>
1554                 <links>
1555                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1556                         <link field="xact" reltype="might_have" key="id" map="" class="mbt"/>
1557                         <link field="circulation" reltype="might_have" key="id" map="" class="circ"/>
1558                         <link field="grocery" reltype="might_have" key="id" map="" class="mg"/>
1559                         <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
1560                 </links>
1561         </class>
1562         <class id="au" controller="open-ils.cstore" oils_obj:fieldmapper="actor::user" oils_persist:tablename="actor.usr" reporter:core="true" reporter:label="ILS User">
1563                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_id_seq">
1564                         <field reporter:label="All Addresses" name="addresses" oils_persist:virtual="true" reporter:datatype="link"/>
1565                         <field reporter:label="All Library Cards" name="cards" oils_persist:virtual="true" reporter:datatype="link"/>
1566                         <field reporter:label="All Circulations" name="checkouts" oils_persist:virtual="true" reporter:datatype="link"/>
1567                         <field reporter:label="All Hold Requests" name="hold_requests" oils_persist:virtual="true" reporter:datatype="link"/>
1568                         <field reporter:label="All Permissions" name="permissions" oils_persist:virtual="true" reporter:datatype="link"/>
1569                         <field reporter:label="All User Settings" name="settings" oils_persist:virtual="true" reporter:datatype="link"/>
1570                         <field reporter:label="Standing Penalties" name="standing_penalties" oils_persist:virtual="true" reporter:datatype="link"/>
1571                         <field reporter:label="Statistical Category Entries" name="stat_cat_entries" oils_persist:virtual="true" reporter:datatype="link"/>
1572                         <field reporter:label="Survey Responses" name="survey_responses" oils_persist:virtual="true" reporter:datatype="link"/>
1573                         <field name="ws_ou" oils_persist:virtual="true" reporter:datatype="link"/>
1574                         <field name="wsid" oils_persist:virtual="true" reporter:datatype="link"/>
1575                         <field reporter:label="Active" name="active" reporter:datatype="bool"/>
1576                         <field reporter:label="Alert Message" name="alert_message"  reporter:datatype="text"/>
1577                         <field reporter:label="Barred" name="barred" reporter:datatype="bool"/>
1578                         <field reporter:label="Physical Address" name="billing_address" reporter:datatype="link"/>
1579                         <field reporter:label="Current Library Card" name="card" reporter:datatype="link"/>
1580                         <field reporter:label="Claims-returned Count" name="claims_returned_count" reporter:datatype="int" />
1581                         <field reporter:label="Record Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
1582                         <field reporter:label="User Credit Balance" name="credit_forward_balance" reporter:datatype="money" />
1583                         <field reporter:label="Daytime Phone" name="day_phone"  reporter:datatype="text"/>
1584                         <field reporter:label="Date of Birth" name="dob" reporter:datatype="timestamp"/>
1585                         <field reporter:label="Email Address" name="email"  reporter:datatype="text"/>
1586                         <field reporter:label="Evening Phone" name="evening_phone"  reporter:datatype="text"/>
1587                         <field reporter:label="Privilege Expiration Date" name="expire_date" reporter:datatype="timestamp"/>
1588                         <field reporter:label="Last Name" name="family_name"  reporter:datatype="text"/>
1589                         <field reporter:label="First Name" name="first_given_name"  reporter:datatype="text"/>
1590                         <field reporter:label="Home Library" name="home_ou" reporter:datatype="org_unit"/>
1591                         <field reporter:label="User ID" name="id" reporter:datatype="id" />
1592                         <field reporter:label="Primary Identification Type" name="ident_type" reporter:datatype="link"/>
1593                         <field reporter:label="Secondary Identification Type" name="ident_type2" reporter:datatype="link"/>
1594                         <field reporter:label="Primary Identification" name="ident_value"  reporter:datatype="text"/>
1595                         <field reporter:label="Secondary Identification" name="ident_value2"  reporter:datatype="text"/>
1596                         <field name="last_xact_id" reporter:datatype="text"/>
1597                         <field reporter:label="Mailing Address" name="mailing_address" reporter:datatype="link"/>
1598                         <field reporter:label="Is Group Lead Account" name="master_account" reporter:datatype="bool"/>
1599                         <field reporter:label="Internet Access Level" name="net_access_level" reporter:datatype="link"/>
1600                         <field reporter:label="Other Phone" name="other_phone"  reporter:datatype="text"/>
1601                         <field reporter:label="Password (obfuscated)" name="passwd"  reporter:datatype="text"/>
1602                         <field reporter:label="Photo URL" name="photo_url"  reporter:datatype="text"/>
1603                         <field reporter:label="Prefix" name="prefix"  reporter:datatype="text"/>
1604                         <field reporter:label="Main (Profile) Permission Group" name="profile" reporter:datatype="link"/>
1605                         <field reporter:label="Middle Name" name="second_given_name"  reporter:datatype="text"/>
1606                         <field reporter:label="Standing (unused)" name="standing" reporter:datatype="link"/>
1607                         <field reporter:label="Suffix/Title" name="suffix"  reporter:datatype="text"/>
1608                         <field reporter:label="Is Super User" name="super_user" reporter:datatype="bool"/>
1609                         <field reporter:label="Family Linkage or other Group" name="usrgroup" reporter:datatype="int"/>
1610                         <field reporter:label="OPAC/Staff Client User Name" name="usrname"  reporter:datatype="text"/>
1611                         <field reporter:label="OPAC/Staff Client Holds Alias" name="alias"  reporter:datatype="text"/>
1612                         <field reporter:label="Juvenile" name="juvenile"  reporter:datatype="bool"/>
1613                         <field reporter:label="Additional Permission Groups" name="groups" oils_persist:virtual="true" reporter:datatype="link"/>
1614                         <field reporter:label="Is Deleted" name="deleted" reporter:datatype="bool"/>
1615                         <field reporter:label="User Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
1616                         <field reporter:label="Demographic Info" name="demographic" oils_persist:virtual="true" reporter:datatype="link"/>
1617                         <field reporter:label="Billable Transactions" name="billable_transactions" oils_persist:virtual="true" reporter:datatype="link"/>
1618                         <field reporter:label="Checkins" name="checkins" oils_persist:virtual="true" reporter:datatype="link"/>
1619                         <field reporter:label="Circulations Performed as Staff" name="performed_circulations" oils_persist:virtual="true" reporter:datatype="link"/>
1620                 </fields>
1621                 <links>
1622                         <link field="demographic" reltype="might_have" key="id" map="" class="rud"/>
1623                         <link field="net_access_level" reltype="has_a" key="id" map="" class="cnal"/>
1624                         <link field="profile" reltype="has_a" key="id" map="" class="pgt"/>
1625                         <link field="ident_type" reltype="has_a" key="id" map="" class="cit"/>
1626                         <link field="billing_address" reltype="has_a" key="id" map="" class="aua"/>
1627                         <link field="mailing_address" reltype="has_a" key="id" map="" class="aua"/>
1628                         <link field="home_ou" reltype="has_a" key="id" map="" class="aou"/>
1629                         <link field="standing" reltype="has_a" key="id" map="" class="cst"/>
1630                         <link field="card" reltype="has_a" key="id" map="" class="ac"/>
1631                         <link field="ident_type2" reltype="has_a" key="id" map="" class="cit"/>
1632                         <link field="stat_cat_entries" reltype="has_many" key="target_usr" map="" class="actscecm"/>
1633                         <link field="groups" reltype="has_many" key="usr" map="grp" class="pugm"/>
1634                         <link field="usrgroup" reltype="has_many" key="usrgroup" map="" class="au"/>
1635                         <link field="checkouts" reltype="has_many" key="usr" map="" class="circ"/>
1636                         <link field="hold_requests" reltype="has_many" key="usr" map="" class="circ"/>
1637                         <link field="permissions" reltype="has_many" key="usr" map="perm" class="pupm"/>
1638                         <link field="settings" reltype="has_many" key="usr" map="" class="aus"/>
1639                         <link reporter:label="Billable Transactions" field="billable_transactions" reltype="has_many" key="usr" map="" class="mbt"/>
1640                         <link field="standing_penalties" reltype="has_many" key="usr" map="" class="ausp"/>
1641                         <link field="addresses" reltype="has_many" key="usr" map="" class="aua"/>
1642                         <link field="survey_responses" reltype="has_many" key="usr" map="" class="asvr"/>
1643                         <link field="notes" reltype="has_many" key="usr" map="" class="aun"/>
1644                         <link reporter:label="Check-ins Performed as Staff" field="checkins" reltype="has_many" key="checkin_staff" map="" class="circ"/>
1645                         <link field="cards" reltype="has_many" key="usr" map="" class="ac"/>
1646                         <link reporter:label="Circulations Performed as Staff" field="performed_circulations" reltype="has_many" key="circ_staff" map="" class="circ"/>
1647                 </links>
1648         </class>
1649         <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">
1650                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_setting_id_seq">
1651                         <field name="id" />
1652                         <field name="name"  reporter:datatype="text"/>
1653                         <field name="org_unit" reporter:datatype="org_unit"/>
1654                         <field name="value"  reporter:datatype="text"/>
1655                 </fields>
1656                 <links>
1657                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1658                 </links>
1659         </class>
1660         <class id="acpn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_note" oils_persist:tablename="asset.copy_note" reporter:label="Copy Note">
1661                 <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_note_id_seq">
1662                         <field reporter:label="Note Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
1663                         <field reporter:label="Note Creator" name="creator" reporter:datatype="link"/>
1664                         <field reporter:label="Note ID" name="id" reporter:datatype="id" />
1665                         <field reporter:label="Copy" name="owning_copy" reporter:datatype="link"/>
1666                         <field reporter:label="Is OPAC Visible?" name="pub" reporter:datatype="bool"/>
1667                         <field reporter:label="Note Title" name="title"  reporter:datatype="text"/>
1668                         <field reporter:label="Note Content" name="value"  reporter:datatype="text"/>
1669                 </fields>
1670                 <links>
1671                         <link field="owning_copy" reltype="has_a" key="id" map="" class="acp"/>
1672                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
1673                 </links>
1674         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1675             <actions>
1676                 <create permission="CREATE_COPY_NOTE">
1677                     <context link="owning_copy" field="circ_lib"/>
1678                 </create>
1679                 <retrieve permission="VIEW_COPY_NOTES">
1680                     <context link="owning_copy" field="circ_lib"/>
1681                 </retrieve>
1682                 <update permission="UPDATE_COPY_NOTE">
1683                     <context link="owning_copy" field="circ_lib"/>
1684                 </update>
1685                 <delete permission="DELETE_COPY_NOTE">
1686                     <context link="owning_copy" field="circ_lib"/>
1687                 </delete>
1688             </actions>
1689         </permacrud>
1690         </class>
1691         <class id="mfr" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::full_rec" oils_persist:tablename="metabib.full_rec" reporter:label="Flattened MARC Fields">
1692                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.full_rec_id_seq">
1693                         <field reporter:label="Field ID" name="id" reporter:datatype="id" />
1694                         <field reporter:label="Indicator 1" name="ind1" oils_persist:primitive="string"  reporter:datatype="text"/>
1695                         <field reporter:label="Indicator 2" name="ind2" oils_persist:primitive="string"  reporter:datatype="text"/>
1696                         <field reporter:label="Bib Record Entry" name="record" reporter:datatype="link"/>
1697                         <field reporter:label="Subfield" name="subfield" oils_persist:primitive="string"  reporter:datatype="text"/>
1698                         <field reporter:label="Tag" name="tag"  reporter:datatype="text"/>
1699                         <field reporter:label="Normalized Value" name="value"  reporter:datatype="text"/>
1700                 </fields>
1701                 <links>
1702                         <link field="record" reltype="has_a" key="id" map="" class="bre"/>
1703                 </links>
1704         </class>
1705         <class id="mmr" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::metarecord" oils_persist:tablename="metabib.metarecord" reporter:label="Metarecord">
1706                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.metarecord_id_seq">
1707                         <field name="fingerprint"  reporter:datatype="text"/>
1708                         <field name="id" reporter:datatype="id" />
1709                         <field name="master_record" reporter:datatype="link"/>
1710                         <field name="mods"  reporter:datatype="text"/>
1711                         <field name="source_records" oils_persist:virtual="true" reporter:datatype="link"/>
1712                 </fields>
1713                 <links>
1714                         <link field="master_record" reltype="has_a" key="id" map="" class="bre"/>
1715                         <link field="source_records" reltype="has_many" key="metarecord" map="source" class="mmrsm"/>
1716                 </links>
1717         </class>
1718         <class id="cnal" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::net_access_level" oils_persist:tablename="config.net_access_level" reporter:label="Net Access Level">
1719                 <fields oils_persist:primary="id" oils_persist:sequence="config.net_access_level_id_seq">
1720                         <field name="id" reporter:selector="name" reporter:datatype="id"/>
1721                         <field name="name"  reporter:datatype="text"/>
1722                 </fields>
1723                 <links/>
1724         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1725             <actions>
1726                 <create permission="CREATE_NET_ACCESS_LEVEL" global_required="true"/>
1727                 <retrieve/>
1728                 <update permission="UPDATE_NET_ACCESS_LEVEL" global_required="true"/>
1729                 <delete permission="DELETE_NET_ACCESS_LEVEL" global_required="true"/>
1730             </actions>
1731         </permacrud>
1732         </class>
1733         <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">
1734                 <fields oils_persist:primary="id" oils_persist:sequence="permission.perm_list_id_seq">
1735                         <field name="code"  reporter:datatype="text"/>
1736                         <field name="description"  reporter:datatype="text" oils_persist:i18n="true"/>
1737                         <field name="id" reporter:selector="code" reporter:datatype="id"/>
1738                 </fields>
1739                 <links/>
1740         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1741             <actions>
1742                 <create permission="CREATE_PERM" global_required="true"/>
1743                 <retrieve permission="CREATE_PERM UPDATE_PERM DELETE_PERM" global_required="true"/>
1744                 <update permission="UPDATE_PERM" global_required="true"/>
1745                 <delete permission="DELETE_PERM" global_required="true"/>
1746             </actions>
1747         </permacrud>
1748         </class>
1749         <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">
1750                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.metarecord_source_map_id_seq">
1751                         <field name="id" reporter:datatype="id" />
1752                         <field name="metarecord" reporter:datatype="link"/>
1753                         <field name="source" reporter:datatype="link"/>
1754                 </fields>
1755                 <links>
1756                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
1757                         <link field="metarecord" reltype="has_a" key="id" map="" class="mmr"/>
1758                 </links>
1759         </class>
1760         <class id="mkfe" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::keyword_field_entry" oils_persist:tablename="metabib.keyword_field_entry" reporter:label="Keyword Field Entry">
1761                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.keyword_field_entry_id_seq">
1762                         <field name="field" reporter:datatype="link"/>
1763                         <field name="id" reporter:datatype="id" />
1764                         <field name="source" reporter:datatype="link"/>
1765                         <field name="value"  reporter:datatype="text"/>
1766                 </fields>
1767                 <links>
1768                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
1769                         <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
1770                 </links>
1771         </class>
1772         <class id="mcp" controller="open-ils.cstore" oils_obj:fieldmapper="money::cash_payment" oils_persist:tablename="money.cash_payment" reporter:label="Cash Payment">
1773                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
1774                         <field name="accepting_usr" reporter:datatype="link"/>
1775                         <field name="amount" reporter:datatype="money" />
1776                         <field name="amount_collected" reporter:datatype="money" />
1777                         <field name="cash_drawer" reporter:datatype="link"/>
1778                         <field name="id" reporter:datatype="id" />
1779                         <field name="note"  reporter:datatype="text"/>
1780                         <field name="payment_ts" reporter:datatype="timestamp"/>
1781                         <field name="xact" reporter:datatype="link"/>
1782                         <field name="payment_type" oils_persist:virtual="true"  reporter:datatype="text"/>
1783                         <field name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
1784                 </fields>
1785                 <links>
1786                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
1787                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
1788                         <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
1789                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
1790                 </links>
1791         </class>
1792         <class id="mfp" controller="open-ils.cstore" oils_obj:fieldmapper="money::forgive_payment" oils_persist:tablename="money.forgive_payment" reporter:label="Forgive Payment">
1793                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
1794                         <field name="accepting_usr" reporter:datatype="link"/>
1795                         <field name="amount" reporter:datatype="money" />
1796                         <field name="amount_collected" reporter:datatype="money" />
1797                         <field name="id" reporter:datatype="id" />
1798                         <field name="note"  reporter:datatype="text"/>
1799                         <field name="payment_ts" reporter:datatype="timestamp"/>
1800                         <field name="xact" reporter:datatype="link"/>
1801                         <field name="payment_type" oils_persist:virtual="true"  reporter:datatype="text"/>
1802                         <field name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
1803                 </fields>
1804                 <links>
1805                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
1806                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
1807                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
1808                 </links>
1809         </class>
1810         <class id="mrd" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::record_descriptor" oils_persist:tablename="metabib.rec_descriptor" reporter:label="Basic Record Descriptor">
1811                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.rec_descriptor_id_seq">
1812                         <field reporter:label="Audn" name="audience" oils_persist:primitive="string"  reporter:datatype="text"/>
1813                         <field reporter:label="BLvl" name="bib_level" oils_persist:primitive="string"  reporter:datatype="text"/>
1814                         <field reporter:label="Cat Form" name="cat_form" oils_persist:primitive="string"  reporter:datatype="text"/>
1815                         <field reporter:label="Character Encoding" name="char_encoding" oils_persist:primitive="string"  reporter:datatype="text"/>
1816                         <field reporter:label="Ctrl" name="control_type" oils_persist:primitive="string"  reporter:datatype="text"/>
1817                         <field reporter:label="ELvl" name="enc_level" oils_persist:primitive="string"  reporter:datatype="text"/>
1818                         <field reporter:label="Descriptor ID" name="id" reporter:datatype="id" />
1819                         <field reporter:label="Form" name="item_form" oils_persist:primitive="string"  reporter:datatype="text"/>
1820                         <field reporter:label="Lang" name="item_lang" oils_persist:primitive="string"  reporter:datatype="text"/>
1821                         <field reporter:label="Type" name="item_type" oils_persist:primitive="string"  reporter:datatype="text"/>
1822                         <field reporter:label="LitF" name="lit_form" oils_persist:primitive="string"  reporter:datatype="text"/>
1823                         <field reporter:label="Pub Status" name="pub_status" oils_persist:primitive="string"  reporter:datatype="text"/>
1824                         <field reporter:label="Bib Record Entry" name="record" reporter:datatype="link"/>
1825                         <field reporter:label="TMat" name="type_mat" oils_persist:primitive="string"  reporter:datatype="text"/>
1826                         <field reporter:label="Video Recording Format" name="vr_format" oils_persist:primitive="string"  reporter:datatype="text"/>
1827                         <field reporter:label="Date1" name="date1" oils_persist:primitive="string"  reporter:datatype="text"/>
1828                         <field reporter:label="Date2" name="date2" oils_persist:primitive="string"  reporter:datatype="text"/>
1829                 </fields>
1830                 <links>
1831                         <link field="record" reltype="has_a" key="id" map="" class="bre"/>
1832                         <link field="item_lang" reltype="has_a" key="code" map="" class="clm"/>
1833                         <link field="item_type" reltype="has_a" key="code" map="" class="citm"/>
1834                         <link field="bib_level" reltype="has_a" key="code" map="" class="cblvl"/>
1835                         <link field="item_form" reltype="has_a" key="code" map="" class="cifm"/>
1836                         <link field="audience" reltype="has_a" key="code" map="" class="cam"/>
1837                         <link field="lit_form" reltype="has_a" key="code" map="" class="clfm"/>
1838                 </links>
1839         </class>
1840
1841         <class id="csp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::standing_penalty" oils_persist:tablename="config.standing_penalty" reporter:label="Standing Penalty">
1842                 <fields oils_persist:primary="id" oils_persist:sequence="config.standing_penalty_id_seq">
1843                         <field name="id" reporter:selector="name" reporter:datatype="id"/>
1844                         <field name="name"  reporter:datatype="text"/>
1845                         <field name="label"  reporter:datatype="text" oils_persist:i18n="true"/>
1846                         <field name="block_list" reporter:datatype="text"/>
1847                 </fields>
1848                 <links/>
1849         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1850             <actions>
1851                 <create permission="ADMIN_STANDING_PENALTY" global_required="true"/>
1852                 <retrieve permission="ADMIN_STANDING_PENALTY VIEW_STANDING_PENALTY" global_required="true"/>
1853                 <update permission="ADMIN_STANDING_PENALTY" global_required="true"/>
1854                 <delete permission="ADMIN_STANDING_PENALTY" global_required="true"/>
1855             </actions>
1856         </permacrud>
1857         </class>
1858         <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">
1859                 <fields oils_persist:primary="id" oils_persist:sequence="permission.grp_penalty_threshold_id_seq">
1860                         <field name="id" reporter:selector="name" reporter:datatype="id" reporter:label="ID"/>
1861                         <field name="grp"  reporter:datatype="link" reporter:label="Group"/>
1862                         <field name="penalty"  reporter:datatype="link" reporter:label="Penalty"/>
1863                         <field name="threshold" reporter:datatype="float" reporter:label="Threshold"/>
1864                         <field name="org_unit" reporter:datatype="org_unit" reporter:label="Org Unit"/>
1865                 </fields>
1866                 <links>
1867                         <link field="penalty" reltype="has_a" key="id" map="" class="csp"/>
1868                         <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
1869                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1870         </links>
1871         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1872             <actions>
1873                 <create permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
1874                 <retrieve permission="VIEW_GROUP_PENALTY_THRESHOLD ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
1875                 <update permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
1876                 <delete permission="ADMIN_GROUP_PENALTY_THRESHOLD" context_field='org_unit'/>
1877             </actions>
1878         </permacrud>
1879         </class>
1880         <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">
1881                 <fields oils_persist:primary="id" oils_persist:sequence="config.copy_status_id_seq">
1882                         <field name="holdable" reporter:datatype="bool"/>
1883                         <field name="id" reporter:selector="name" reporter:datatype="id"/>
1884                         <field name="name"  reporter:datatype="text" oils_persist:i18n="true"/>
1885                         <field name="opac_visible" reporter:datatype="bool"/>
1886                 </fields>
1887                 <links/>
1888         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1889             <actions>
1890                 <create permission="CREATE_COPY_STATUS" global_required="true"/>
1891                 <retrieve permission="CREATE_COPY_STATUS UPDATE_COPY_STATUS DELETE_COPY_STATUS" global_required="true"/>
1892                 <update permission="UPDATE_COPY_STATUS" global_required="true"/>
1893                 <delete permission="DELETE_COPY_STATUS" global_required="true"/>
1894             </actions>
1895         </permacrud>
1896         </class>
1897         <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">
1898                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_standing_penalty_id_seq">
1899                         <field name="id" reporter:datatype="id" reporter:label="ID" />
1900                         <field name="set_date"  reporter:datatype="timestamp" reporter:label="Set Date"/>
1901                         <field name="usr" reporter:datatype="link" reporter:label="User"/>
1902                         <field name="staff" reporter:datatype="link" reporter:label="Staff"/>
1903                         <field name="standing_penalty" reporter:datatype="link" reporter:label="Standing Penalty"/>
1904                         <field name="org_unit" reporter:datatype="link" reporter:label="Org Unit"/>
1905                         <field name="note" reporter:datatype="text" reporter:label="Note"/>
1906                 </fields>
1907                 <links>
1908                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1909                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
1910                         <link field="staff" reltype="has_a" key="id" map="" class="au"/>
1911                         <link field="standing_penalty" reltype="has_a" key="id" map="" class="csp"/>
1912                 </links>
1913                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1914                         <actions>
1915                                 <create permission="UPDATE_USER"><context link="usr" field="home_ou"/></create>
1916                                 <retrieve permission="VIEW_USER"><context link="usr" field="home_ou"/></retrieve>
1917                                 <update permission="UPDATE_USER"><context link="usr" field="home_ou"/></update>
1918                                 <delete permission="UPDATE_USER"><context link="usr" field="home_ou"/></delete>
1919                         </actions>
1920                 </permacrud>
1921         </class>
1922         <class id="aua" controller="open-ils.cstore" oils_obj:fieldmapper="actor::user_address" oils_persist:tablename="actor.usr_address" reporter:label="User Address">
1923                 <fields oils_persist:primary="id" oils_persist:sequence="actor.usr_address_id_seq">
1924                         <field reporter:label="Type" name="address_type"  reporter:datatype="text"/>
1925                         <field reporter:label="City" name="city"  reporter:datatype="text"/>
1926                         <field reporter:label="Country" name="country"  reporter:datatype="text"/>
1927                         <field reporter:label="County" name="county"  reporter:datatype="text"/>
1928                         <field reporter:label="Address ID" name="id" reporter:datatype="id" />
1929                         <field reporter:label="Postal Code" name="post_code" reporter:datatype="text"/>
1930                         <field reporter:label="State" name="state"  reporter:datatype="text"/>
1931                         <field reporter:label="Street (1)" name="street1"  reporter:datatype="text"/>
1932                         <field reporter:label="Street (2)" name="street2"  reporter:datatype="text"/>
1933                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
1934                         <field reporter:label="Valid Address?" name="valid" reporter:datatype="bool"/>
1935                         <field reporter:label="Within City Limits?" name="within_city_limits" reporter:datatype="bool"/>
1936                         <field reporter:label="Replaces" name="replaces" reporter:datatype="link"/>
1937                         <field reporter:label="Pending" name="pending" reporter:datatype="bool"/>
1938                 </fields>
1939                 <links>
1940                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
1941                         <link field="replaces" reltype="has_a" key="id" map="" class="aua"/>
1942                 </links>
1943         </class>
1944         <class id="acnn" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::call_number_note" oils_persist:tablename="asset.call_number_note" reporter:label="Call Number Note">
1945                 <fields oils_persist:primary="id" oils_persist:sequence="asset.call_number_note_id_seq">
1946                         <field name="call_number" />
1947                         <field name="create_date" reporter:datatype="timestamp"/>
1948                         <field name="creator" reporter:datatype="link"/>
1949                         <field name="id" reporter:datatype="id" />
1950                         <field name="pub" reporter:datatype="bool"/>
1951                         <field name="title"  reporter:datatype="text"/>
1952                         <field name="value"  reporter:datatype="text"/>
1953                 </fields>
1954                 <links>
1955                         <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
1956                 </links>
1957         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1958             <actions>
1959                 <create permission="CREATE_VOLUME_NOTE">
1960                     <context link="call_number" field="owning_lib"/>
1961                 </create>
1962                 <retrieve permission="VIEW_VOLUME_NOTES">
1963                     <context link="call_number" field="owning_lib"/>
1964                 </retrieve>
1965                 <update permission="UPDATE_VOLUME_NOTE">
1966                     <context link="call_number" field="owning_lib"/>
1967                 </update>
1968                 <delete permission="DELETE_VOLUME_NOTE">
1969                     <context link="call_number" field="owning_lib"/>
1970                 </delete>
1971             </actions>
1972         </permacrud>
1973         </class>
1974         <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">
1975                 <fields oils_persist:primary="id" oils_persist:sequence="authority.record_note_id_seq">
1976                         <field name="create_date" reporter:datatype="timestamp"/>
1977                         <field name="creator" reporter:datatype="link"/>
1978                         <field name="edit_date" reporter:datatype="timestamp"/>
1979                         <field name="editor" reporter:datatype="link"/>
1980                         <field name="id" reporter:datatype="id" />
1981                         <field name="record" reporter:datatype="link"/>
1982                         <field name="value" reporter:datatype="text"/>
1983                 </fields>
1984                 <links>
1985                         <link field="record" reltype="has_a" key="id" map="" class="are"/>
1986                 </links>
1987         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
1988             <actions>
1989                 <create permission="CREATE_AUTHORITY_RECORD_NOTE" global_required='true'/>
1990                 <retrieve permission="VIEW_AUTHORITY_RECORD_NOTES" global_required='true'/>
1991                 <update permission="UPDATE_AUTHORITY_RECORD_NOTE" global_required='true'/>
1992                 <delete permission="DELETE_AUTHORITY_RECORD_NOTE" global_required='true'/>
1993             </actions>
1994         </permacrud>
1995         </class>
1996         <class id="circ" controller="open-ils.cstore" oils_obj:fieldmapper="action::circulation" oils_persist:tablename="action.circulation" reporter:core="true" reporter:label="Circulation">
1997                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
1998                         <field reporter:label="Check In Library" name="checkin_lib" reporter:datatype="org_unit"/>
1999                         <field reporter:label="Check In Staff" name="checkin_staff" reporter:datatype="link"/>
2000                         <field reporter:label="Check In Date/Time" name="checkin_time" reporter:datatype="timestamp"/>
2001                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
2002                         <field reporter:label="Circulating Staff" name="circ_staff" reporter:datatype="link"/>
2003                         <field reporter:label="Desk Renewal" name="desk_renewal" reporter:datatype="bool"/>
2004                         <field reporter:label="Due Date/Time" name="due_date" reporter:datatype="timestamp"/>
2005                         <field reporter:label="Circulation Duration" name="duration" reporter:datatype="interval"/>
2006                         <field reporter:label="Circ Duration Rule" name="duration_rule" reporter:datatype="link"/>
2007                         <field reporter:label="Fine Interval" name="fine_interval" reporter:datatype="interval"/>
2008                         <field reporter:label="Circ ID" name="id" reporter:datatype="id" />
2009                         <field reporter:label="Max Fine Amount" name="max_fine" reporter:datatype="money" />
2010                         <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
2011                         <field reporter:label="OPAC Renewal" name="opac_renewal" reporter:datatype="bool"/>
2012                         <field reporter:label="Phone Renewal" name="phone_renewal" reporter:datatype="bool"/>
2013                         <field reporter:label="Recurring Fine Amount" name="recuring_fine" reporter:datatype="money" />
2014                         <field reporter:label="Recurring Fine Rule" name="recuring_fine_rule" reporter:datatype="link"/>
2015                         <field reporter:label="Remaining Renewals" name="renewal_remaining" reporter:datatype="int" />
2016                         <field reporter:label="Fine Stop Reason" name="stop_fines" reporter:datatype="text"/>
2017                         <field reporter:label="Fine Stop Date/Time" name="stop_fines_time" reporter:datatype="timestamp"/>
2018                         <field reporter:label="Circulating Item" name="target_copy" reporter:datatype="link"/>
2019                         <field reporter:label="Patron" name="usr" reporter:datatype="link"/>
2020                         <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp" />
2021                         <field reporter:label="Check Out Date/Time" name="xact_start" reporter:datatype="timestamp" />
2022                         <field reporter:label="Record Creation Date/Time" name="create_time" reporter:datatype="timestamp" />
2023                         <field reporter:label="Transaction Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
2024                         <field reporter:label="Transaction Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
2025                         <field reporter:label="Base Transaction" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
2026                         <field reporter:label="Circulation Type" name="circ_type" oils_persist:virtual="true" reporter:datatype="text"/>
2027                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
2028                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
2029                 </fields>
2030                 <links>
2031                         <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
2032                         <link field="circ_staff" reltype="has_a" key="id" map="" class="au"/>
2033                         <link field="checkin_lib" reltype="has_a" key="id" map="" class="aou"/>
2034                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
2035                         <link field="checkin_staff" reltype="has_a" key="id" map="" class="au"/>
2036                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2037                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
2038                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
2039                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
2040                         <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
2041                         <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
2042                         <link field="recuring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
2043                         <link field="circ_type" reltype="might_have" key="id" map="" class="rcirct"/>
2044                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
2045                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
2046                 </links>
2047         </class>
2048         <class id="combcirc" controller="open-ils.cstore" oils_obj:fieldmapper="action::all_circulation" oils_persist:tablename="action.all_circulation" reporter:core="true" reporter:label="Combined Aged and Active Circulations" oils_persist:readonly="true">
2049                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
2050                         <field reporter:label="Check In Library" name="checkin_lib" reporter:datatype="org_unit"/>
2051                         <field reporter:label="Check In Staff" name="checkin_staff" reporter:datatype="link"/>
2052                         <field reporter:label="Check In Date/Time" name="checkin_time" reporter:datatype="timestamp"/>
2053                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
2054                         <field reporter:label="Circulating Staff" name="circ_staff" reporter:datatype="link"/>
2055                         <field reporter:label="Desk Renewal" name="desk_renewal" reporter:datatype="bool"/>
2056                         <field reporter:label="Due Date/Time" name="due_date" reporter:datatype="timestamp"/>
2057                         <field reporter:label="Circulation Duration" name="duration" reporter:datatype="interval"/>
2058                         <field reporter:label="Circ Duration Rule" name="duration_rule" reporter:datatype="link"/>
2059                         <field reporter:label="Fine Interval" name="fine_interval" reporter:datatype="interval"/>
2060                         <field reporter:label="Circ ID" name="id" reporter:datatype="id" />
2061                         <field reporter:label="Max Fine Amount" name="max_fine" reporter:datatype="money" />
2062                         <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
2063                         <field reporter:label="OPAC Renewal" name="opac_renewal" reporter:datatype="bool"/>
2064                         <field reporter:label="Phone Renewal" name="phone_renewal" reporter:datatype="bool"/>
2065                         <field reporter:label="Recurring Fine Amount" name="recuring_fine" reporter:datatype="money" />
2066                         <field reporter:label="Recurring Fine Rule" name="recuring_fine_rule" reporter:datatype="link"/>
2067                         <field reporter:label="Remaining Renewals" name="renewal_remaining" reporter:datatype="int" />
2068                         <field reporter:label="Fine Stop Reason" name="stop_fines" reporter:datatype="text"/>
2069                         <field reporter:label="Fine Stop Date/Time" name="stop_fines_time" reporter:datatype="timestamp"/>
2070                         <field reporter:label="Circulating Item" name="target_copy" reporter:datatype="link"/>
2071                         <field reporter:label="Patron ZIP" name="usr_post_code" reporter:datatype="text"/>
2072                         <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp" />
2073                         <field reporter:label="Check Out Date/Time" name="xact_start" reporter:datatype="timestamp" />
2074                         <field reporter:label="Record Creation Date/Time" name="create_time" reporter:datatype="timestamp" />
2075                         <field reporter:label="Transaction Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
2076                         <field reporter:label="Transaction Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
2077                         <field reporter:label="Base Transaction" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
2078                         <field reporter:label="Circulation Type" name="circ_type" oils_persist:virtual="true" reporter:datatype="text"/>
2079                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
2080                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
2081                         <field reporter:label="Patron Home Library" name="usr_home_ou" reporter:datatype="link"/>
2082                         <field reporter:label="Patron Profile Group" name="usr_profile" reporter:datatype="link"/>
2083                         <field reporter:label="Patron Birth Year" name="usr_birth_year" reporter:datatype="int"/>
2084                         <field reporter:label="Call Number" name="copy_call_number" reporter:datatype="link"/>
2085                         <field reporter:label="Shelving Location" name="copy_location" reporter:datatype="link"/>
2086                         <field reporter:label="Copy Owning Library" name="copy_owning_lib" reporter:datatype="link"/>
2087                         <field reporter:label="Copy Circulating Library" name="copy_circ_lib" reporter:datatype="link"/>
2088                         <field reporter:label="Bib Record" name="copy_bib_record" reporter:datatype="link"/>
2089                 </fields>
2090                 <links>
2091                         <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
2092                         <link field="circ_staff" reltype="has_a" key="id" map="" class="au"/>
2093                         <link field="checkin_lib" reltype="has_a" key="id" map="" class="aou"/>
2094                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
2095                         <link field="checkin_staff" reltype="has_a" key="id" map="" class="au"/>
2096                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
2097                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
2098                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
2099                         <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
2100                         <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
2101                         <link field="recuring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
2102                         <link field="circ_type" reltype="might_have" key="id" map="" class="rcirct"/>
2103                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
2104                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
2105                         <link field="copy_call_number" reltype="has_a" key="id" map="" class="acn"/>
2106                         <link field="copy_location" reltype="has_a" key="id" map="" class="acpl"/>
2107                         <link field="copy_owning_lib" reltype="has_a" key="id" map="" class="aou"/>
2108                         <link field="copy_circ_lib" reltype="has_a" key="id" map="" class="aou"/>
2109                         <link field="copy_bib_record" reltype="has_a" key="id" map="" class="bre"/>
2110                 </links>
2111         </class>
2112         <class id="acirc" controller="open-ils.cstore" oils_obj:fieldmapper="action::aged_circulation" oils_persist:tablename="action.aged_circulation" reporter:core="true" reporter:label="Aged (patronless) Circulation">
2113                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
2114                         <field reporter:label="Check In Library" name="checkin_lib" reporter:datatype="org_unit"/>
2115                         <field reporter:label="Check In Staff" name="checkin_staff" reporter:datatype="link"/>
2116                         <field reporter:label="Check In Date/Time" name="checkin_time" reporter:datatype="timestamp"/>
2117                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
2118                         <field reporter:label="Circulating Staff" name="circ_staff" reporter:datatype="link"/>
2119                         <field reporter:label="Desk Renewal" name="desk_renewal" reporter:datatype="bool"/>
2120                         <field reporter:label="Due Date/Time" name="due_date" reporter:datatype="timestamp"/>
2121                         <field reporter:label="Circulation Duration" name="duration" reporter:datatype="interval"/>
2122                         <field reporter:label="Circ Duration Rule" name="duration_rule" reporter:datatype="link"/>
2123                         <field reporter:label="Fine Interval" name="fine_interval" reporter:datatype="interval"/>
2124                         <field reporter:label="Circ ID" name="id" reporter:datatype="id" />
2125                         <field reporter:label="Max Fine Amount" name="max_fine" reporter:datatype="money" />
2126                         <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
2127                         <field reporter:label="OPAC Renewal" name="opac_renewal" reporter:datatype="bool"/>
2128                         <field reporter:label="Phone Renewal" name="phone_renewal" reporter:datatype="bool"/>
2129                         <field reporter:label="Recurring Fine Amount" name="recuring_fine" reporter:datatype="money" />
2130                         <field reporter:label="Recurring Fine Rule" name="recuring_fine_rule" reporter:datatype="link"/>
2131                         <field reporter:label="Remaining Renewals" name="renewal_remaining" reporter:datatype="int" />
2132                         <field reporter:label="Fine Stop Reason" name="stop_fines" reporter:datatype="text"/>
2133                         <field reporter:label="Fine Stop Date/Time" name="stop_fines_time" reporter:datatype="timestamp"/>
2134                         <field reporter:label="Circulating Item" name="target_copy" reporter:datatype="link"/>
2135                         <field reporter:label="Patron ZIP" name="usr_post_code" reporter:datatype="text"/>
2136                         <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp" />
2137                         <field reporter:label="Check Out Date/Time" name="xact_start" reporter:datatype="timestamp" />
2138                         <field reporter:label="Record Creation Date/Time" name="create_time" reporter:datatype="timestamp" />
2139                         <field reporter:label="Transaction Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
2140                         <field reporter:label="Transaction Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
2141                         <field reporter:label="Base Transaction" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
2142                         <field reporter:label="Circulation Type" name="circ_type" oils_persist:virtual="true" reporter:datatype="text"/>
2143                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
2144                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
2145                         <field reporter:label="Patron Home Library" name="usr_home_ou" reporter:datatype="link"/>
2146                         <field reporter:label="Patron Profile Group" name="usr_profile" reporter:datatype="link"/>
2147                         <field reporter:label="Patron Birth Year" name="usr_birth_year" reporter:datatype="int"/>
2148                         <field reporter:label="Call Number" name="copy_call_number" reporter:datatype="link"/>
2149                         <field reporter:label="Shelving Location" name="copy_location" reporter:datatype="link"/>
2150                         <field reporter:label="Copy Owning Library" name="copy_owning_lib" reporter:datatype="link"/>
2151                         <field reporter:label="Copy Circulating Library" name="copy_circ_lib" reporter:datatype="link"/>
2152                         <field reporter:label="Bib Record" name="copy_bib_record" reporter:datatype="link"/>
2153                 </fields>
2154                 <links>
2155                         <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
2156                         <link field="circ_staff" reltype="has_a" key="id" map="" class="au"/>
2157                         <link field="checkin_lib" reltype="has_a" key="id" map="" class="aou"/>
2158                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
2159                         <link field="checkin_staff" reltype="has_a" key="id" map="" class="au"/>
2160                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
2161                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
2162                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
2163                         <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
2164                         <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
2165                         <link field="recuring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
2166                         <link field="circ_type" reltype="might_have" key="id" map="" class="rcirct"/>
2167                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
2168                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
2169                         <link field="copy_call_number" reltype="has_a" key="id" map="" class="acn"/>
2170                         <link field="copy_location" reltype="has_a" key="id" map="" class="acpl"/>
2171                         <link field="copy_owning_lib" reltype="has_a" key="id" map="" class="aou"/>
2172                         <link field="copy_circ_lib" reltype="has_a" key="id" map="" class="aou"/>
2173                         <link field="copy_bib_record" reltype="has_a" key="id" map="" class="bre"/>
2174                 </links>
2175         </class>
2176         <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">
2177                 <fields oils_persist:primary="id" oils_persist:sequence="container.call_number_bucket_item_id_seq">
2178                         <field name="bucket" reporter:datatype="link"/>
2179                         <field name="id" reporter:datatype="id" />
2180                         <field name="target_call_number" reporter:datatype="link" />
2181                         <field name="create_time" reporter:datatype="timestamp" />
2182                         <field name="pos" reporter:datatype="int" />
2183                         <field name="notes" oils_persist:virtual="true" reporter:datatype="link" />
2184                 </fields>
2185                 <links>
2186                         <link field="target_call_number" reltype="has_a" key="id" map="" class="acn"/>
2187                         <link field="bucket" reltype="has_a" key="id" map="" class="ccnb"/>
2188             <link field="notes" reltype="has_many" map="" key="item" class="ccnbin"/>
2189                 </links>
2190         </class>
2191         <class id="ccnbin" controller="open-ils.cstore" oils_obj:fieldmapper="container::call_number_bucket_item_note" oils_persist:tablename="container.call_number_bucket_item_note" reporter:label="Call Number Bucket Item Note">
2192                 <fields oils_persist:primary="id" oils_persist:sequence="container.call_number_bucket_item_note_id_seq">
2193                         <field name="id" reporter:datatype="id" />
2194                         <field name="item" reporter:datatype="link"/>
2195                         <field name="note" reporter:datatype="text" />
2196                 </fields>
2197                 <links>
2198                         <link field="item" reltype="has_a" key="id" map="" class="ccnbi"/>
2199                 </links>
2200         </class>
2201         <class id="cbreb" controller="open-ils.cstore" oils_obj:fieldmapper="container::biblio_record_entry_bucket" oils_persist:tablename="container.biblio_record_entry_bucket" reporter:label="Bibliographic Record Entry Bucket">
2202                 <fields oils_persist:primary="id" oils_persist:sequence="container.biblio_record_entry_bucket_id_seq">
2203                         <field name="items" oils_persist:virtual="true" reporter:datatype="link"/>
2204                         <field name="btype" reporter:datatype="text"/>
2205                         <field name="id" reporter:datatype="id" />
2206                         <field name="name" reporter:datatype="text"/>
2207                         <field name="owner" reporter:datatype="link"/>
2208                         <field name="pub" reporter:datatype="bool"/>
2209                         <field name="create_time" reporter:datatype="timestamp" />
2210                 </fields>
2211                 <links>
2212                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
2213                         <link field="items" reltype="has_many" key="bucket" map="" class="cbrebi"/>
2214                 </links>
2215         </class>
2216         <class id="cbrebn" controller="open-ils.cstore" oils_obj:fieldmapper="container::biblio_record_entry_bucket_note" oils_persist:tablename="container.biblio_record_entry_bucket_note" reporter:label="Bibliographic Record Entry Bucket Note">
2217                 <fields oils_persist:primary="id" oils_persist:sequence="container.biblio_record_entry_bucket_note_id_seq">
2218                         <field name="id" reporter:datatype="id" />
2219                         <field name="bucket" reporter:datatype="link"/>
2220                         <field name="note" reporter:datatype="text" />
2221                 </fields>
2222                 <links>
2223                         <link field="bucket" reltype="has_a" key="id" map="" class="cbreb"/>
2224                 </links>
2225         </class>
2226         <class id="ahcm" controller="open-ils.cstore" oils_obj:fieldmapper="action::hold_copy_map" oils_persist:tablename="action.hold_copy_map" reporter:label="Hold Copy Map">
2227                 <fields oils_persist:primary="id" oils_persist:sequence="action.hold_copy_map_id_seq">
2228                         <field name="hold" reporter:datatype="link"/>
2229                         <field name="id" reporter:datatype="id" />
2230                         <field name="target_copy" reporter:datatype="link"/>
2231                 </fields>
2232                 <links>
2233                         <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
2234                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
2235                 </links>
2236         </class>
2237         <class id="ahn" controller="open-ils.cstore" oils_obj:fieldmapper="action::hold_notification" oils_persist:tablename="action.hold_notification" reporter:label="Hold Notification">
2238                 <fields oils_persist:primary="id" oils_persist:sequence="action.hold_notification_id_seq">
2239                         <field reporter:label="Hold" name="hold" reporter:datatype="link"/>
2240                         <field reporter:label="Notification ID" name="id" reporter:datatype="id" />
2241                         <field reporter:label="Notification Method" name="method"  reporter:datatype="text"/>
2242                         <field reporter:label="Notification Note" name="note"  reporter:datatype="text"/>
2243                         <field reporter:label="Notifying Staff" name="notify_staff" reporter:datatype="link"/>
2244                         <field reporter:label="Notification Date/Time" name="notify_time" reporter:datatype="timestamp"/>
2245                 </fields>
2246                 <links>
2247                         <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
2248                         <link field="notify_staff" reltype="has_a" key="id" map="" class="au"/>
2249                 </links>
2250         </class>
2251         <class id="acpl" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy_location" oils_persist:tablename="asset.copy_location" reporter:label="Copy/Shelving Location">
2252                 <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_location_id_seq">
2253                         <field reporter:label="Can Circulate?" name="circulate"  reporter:datatype="bool"/>
2254                         <field reporter:label="Is Holdable?" name="holdable" reporter:datatype="bool"/>
2255                         <field reporter:label="Hold Capture Requires Verification" name="hold_verify" reporter:datatype="bool"/>
2256                         <field reporter:label="Location ID" name="id" reporter:selector="name" reporter:datatype="id"/>
2257                         <field reporter:label="Name" name="name"  reporter:datatype="text" oils_persist:i18n="true"/>
2258                         <field reporter:label="Is OPAC Visible?" name="opac_visible" reporter:datatype="bool"/>
2259                         <field reporter:label="Owning Org Unit" name="owning_lib"  reporter:datatype="org_unit"/>
2260                 </fields>
2261                 <links>
2262                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
2263                         <link field="distribution_formula_entries" reltype="has_many" key="location" map="" class="acqdfe"/>
2264                 </links>
2265         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2266             <actions>
2267                 <create permission="CREATE_COPY_LOCATION" context_field="owning_lib"/>
2268                 <retrieve/>
2269                 <update permission="UPDATE_COPY_LOCATION" context_field="owning_lib"/>
2270                 <delete permission="DELETE_COPY_LOCATION" context_field="owning_lib"/>
2271             </actions>
2272         </permacrud>
2273         </class>
2274         <class id="svr" controller="open-ils.cstore" oils_obj:fieldmapper="serial::virtual_record" oils_persist:virtual="true" reporter:label="Serial Virtual Record">
2275                 <fields>
2276                         <field name="holdings" oils_persist:virtual="true" />
2277                         <field name="current_holdings" oils_persist:virtual="true" />
2278                         <field name="supplements" oils_persist:virtual="true" />
2279                         <field name="current_supplements" oils_persist:virtual="true" />
2280                         <field name="indexes" oils_persist:virtual="true" />
2281                         <field name="current_indexes" oils_persist:virtual="true" />
2282                         <field name="online" oils_persist:virtual="true" />
2283                         <field name="missing" oils_persist:virtual="true" />
2284                         <field name="incomplete" oils_persist:virtual="true" />
2285                 </fields>
2286         </class>
2287         <class id="sre" controller="open-ils.cstore" oils_obj:fieldmapper="serial::record_entry" oils_persist:tablename="serial.record_entry" reporter:label="Record Entry">
2288                 <fields oils_persist:primary="id" oils_persist:sequence="serial.record_entry_id_seq">
2289                         <field name="active" reporter:datatype="bool"/>
2290                         <field reporter:label="Bib Record" name="record" reporter:datatype="link"/>
2291                         <field name="create_date" reporter:datatype="timestamp"/>
2292                         <field name="creator" />
2293                         <field name="deleted" reporter:datatype="bool"/>
2294                         <field name="edit_date" reporter:datatype="timestamp"/>
2295                         <field name="editor" />
2296                         <field name="id" reporter:datatype="id" />
2297                         <field name="last_xact_id" />
2298                         <field name="marc" />
2299                         <field name="source" />
2300                 </fields>
2301                 <links>
2302                         <link field="record" reltype="has_a" key="id" map="" class="bre"/>
2303                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
2304                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
2305                 </links>
2306         </class>
2307         <class id="sfr" controller="open-ils.cstore" oils_obj:fieldmapper="serial::full_rec" oils_persist:tablename="serial.full_rec" reporter:label="Full Record">
2308                 <fields oils_persist:primary="id" oils_persist:sequence="serial.full_rec_id_seq">
2309                         <field name="id" reporter:datatype="id" />
2310                         <field name="ind1" />
2311                         <field name="ind2" />
2312                         <field name="record" />
2313                         <field name="subfield" />
2314                         <field name="tag" />
2315                         <field name="value" />
2316                 </fields>
2317                 <links>
2318                         <link field="record" reltype="has_a" key="id" map="" class="sre"/>
2319                 </links>
2320         </class>
2321         <class id="ssub" controller="open-ils.cstore" oils_obj:fieldmapper="serial::subscription" oils_persist:tablename="serial.subscription" reporter:label="Subscription">
2322                 <fields oils_persist:primary="id" oils_persist:sequence="serial.subscription_id_seq">
2323                         <field name="active" reporter:datatype="bool"/>
2324                         <field reporter:label="Call Number" name="call_number" reporter:datatype="link"/>
2325                         <field reporter:label="URI" name="uri" reporter:datatype="link"/>
2326                         <field reporter:label="Start date" name="start_date" reporter:datatype="timestamp"/>
2327                         <field reporter:label="End date" name="end_date" reporter:datatype="timestamp"/>
2328                 </fields>
2329                 <links>
2330                         <link field="call_number" reltype="might_have" key="id" map="" class="acn"/>
2331                         <link field="uri" reltype="might_have" key="id" map="" class="auri"/>
2332                 </links>
2333         </class>
2334         <class id="sbu" controller="open-ils.cstore" oils_obj:fieldmapper="serial::binding_unit" oils_persist:tablename="serial.binding_unit" reporter:label="Binding Unit">
2335                 <fields oils_persist:primary="id" oils_persist:sequence="serial.binding_unit_id_seq">
2336                         <field name="active" reporter:datatype="bool"/>
2337                         <field reporter:label="Subscription" name="subscription" reporter:datatype="link"/>
2338                         <field reporter:label="Label" name="label" />
2339                 </fields>
2340                 <links>
2341                         <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
2342                 </links>
2343         </class>
2344         <class id="siss" controller="open-ils.cstore" oils_obj:fieldmapper="serial::issuance" oils_persist:tablename="serial.issuance" reporter:label="Issuance">
2345                 <fields oils_persist:primary="id" oils_persist:sequence="serial.issuance_id_seq">
2346                         <field name="id" reporter:datatype="id" />
2347                         <field name="subscription" reporter:datatype="link"/>
2348                         <field name="target_copy" reporter:datatype="link"/>
2349                         <field name="location" reporter:datatype="link"/>
2350                         <field name="binding_unit" reporter:datatype="link"/>
2351                         <field name="label" />
2352                 </fields>
2353                 <links>
2354                         <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
2355                         <link field="target_copy" reltype="might_have" key="id" map="" class="acp"/>
2356                         <link field="location" reltype="might_have" key="id" map="" class="acpl"/>
2357                         <link field="binding_unit" reltype="might_have" key="id" map="" class="sbu"/>
2358                 </links>
2359         </class>
2360         <class id="sbsum" controller="open-ils.cstore" oils_obj:fieldmapper="serial::bib_summary" oils_persist:tablename="serial.bib_summary" reporter:label="Bib Summary">
2361                 <fields oils_persist:primary="id" oils_persist:sequence="serial.bib_summary_id_seq">
2362                         <field name="id" reporter:datatype="id" />
2363                         <field name="subscription" reporter:datatype="link"/>
2364                         <field name="generated_coverage" reporter:datatype="text"/>
2365                         <field name="textual_holdings" reporter:datatype="text"/>
2366                 </fields>
2367                 <links>
2368                         <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
2369                 </links>
2370         </class>
2371         <class id="sssum" controller="open-ils.cstore" oils_obj:fieldmapper="serial::sup_summary" oils_persist:tablename="serial.sup_summary" reporter:label="Supplemental Issue Summary">
2372                 <fields oils_persist:primary="id" oils_persist:sequence="serial.sup_summary_id_seq">
2373                         <field name="id" reporter:datatype="id" />
2374                         <field name="subscription" reporter:datatype="link"/>
2375                         <field name="generated_coverage" reporter:datatype="text"/>
2376                         <field name="textual_holdings" reporter:datatype="text"/>
2377                 </fields>
2378                 <links>
2379                         <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
2380                 </links>
2381         </class>
2382         <class id="sisum" controller="open-ils.cstore" oils_obj:fieldmapper="serial::index_summary" oils_persist:tablename="serial.index_summary" reporter:label="Index Summary">
2383                 <fields oils_persist:primary="id" oils_persist:sequence="serial.index_summary_id_seq">
2384                         <field name="id" reporter:datatype="id" />
2385                         <field name="subscription" reporter:datatype="link"/>
2386                         <field name="generated_coverage" reporter:datatype="text"/>
2387                         <field name="textual_holdings" reporter:datatype="text"/>
2388                 </fields>
2389                 <links>
2390                         <link field="subscription" reltype="has_a" key="id" map="" class="ssub"/>
2391                 </links>
2392         </class>
2393
2394         <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">
2395                 <fields oils_persist:primary="id" oils_persist:sequence="asset.stat_cat_entry_copy_map_id_seq">
2396                         <field name="id" reporter:datatype="id" />
2397                         <field name="owning_copy" reporter:datatype="link"/>
2398                         <field name="stat_cat" reporter:datatype="link"/>
2399                         <field name="stat_cat_entry" reporter:datatype="link"/>
2400                 </fields>
2401                 <links>
2402                         <link field="owning_copy" reltype="has_a" key="id" map="" class="acp"/>
2403                         <link field="stat_cat_entry" reltype="has_a" key="id" map="" class="asce"/>
2404                         <link field="stat_cat" reltype="has_a" key="id" map="" class="asc"/>
2405                 </links>
2406         </class>
2407         <class id="citm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::item_type_map" oils_persist:tablename="config.item_type_map" reporter:label="Item Type Map" oils_persist:field_safe="true">
2408                 <fields oils_persist:primary="code">
2409                         <field reporter:label="Item Type Code" name="code" reporter:selector="value" reporter:datatype="text"/>
2410                         <field reporter:label="Item Type" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
2411                 </fields>
2412                 <links/>
2413         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2414             <actions>
2415                 <create permission="ADMIN_MARC_CODE" global_required="true"/>
2416                 <retrieve/>
2417                 <update permission="ADMIN_MARC_CODE" global_required="true"/>
2418                 <delete permission="ADMIN_MARC_CODE" global_required="true"/>
2419             </actions>
2420         </permacrud>
2421         </class>
2422         <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">
2423                 <fields oils_persist:primary="code">
2424                         <field reporter:label="Bib Level Code" name="code"  reporter:datatype="text"/>
2425                         <field reporter:label="Bib Level" name="value"  reporter:datatype="text" oils_persist:i18n="true"/>
2426                 </fields>
2427                 <links/>
2428         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2429             <actions>
2430                 <create permission="CREATE_MARC_CODE" global_required="true"/>
2431                 <retrieve permission="CREATE_MARC_CODE UPDATE_MARC_CODE DELETE_MARC_CODE" global_required="true"/>
2432                 <update permission="UPDATE_MARC_CODE" global_required="true"/>
2433                 <delete permission="DELETE_MARC_CODE" global_required="true"/>
2434             </actions>
2435         </permacrud>
2436         </class>
2437         <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">
2438                 <fields oils_persist:primary="id" oils_persist:sequence="search.relevance_adjustment_id_seq">
2439                         <field reporter:label="ID" name="id"  reporter:datatype="id"/>
2440                         <field reporter:label="Active" name="active"  reporter:datatype="bool"/>
2441                         <field reporter:label="Index Field" name="field"  reporter:datatype="link"/>
2442                         <field reporter:label="Bump Type" name="bump_type"  reporter:datatype="text"/>
2443                         <field reporter:label="Multiplier" name="multiplier"  reporter:datatype="number"/>
2444                 </fields>
2445                 <links>
2446             <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
2447         </links>
2448         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2449             <actions>
2450                 <create permission="CREATE_RELEVANCE_ADJUSTMENT" global_required="true"/>
2451                 <retrieve permission="CREATE_RELEVANCE_ADJUSTMENT UPDATE_RELEVANCE_ADJUSTMENT DELETE_RELEVANCE_ADJUSTMENT" global_required="true"/>
2452                 <update permission="UPDATE_RELEVANCE_ADJUSTMENT" global_required="true"/>
2453                 <delete permission="DELETE_RELEVANCE_ADJUSTMENT" global_required="true"/>
2454             </actions>
2455         </permacrud>
2456         </class>
2457         <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">
2458                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_lasso_id_seq">
2459                         <field name="id" reporter:datatype="id" />
2460                         <field name="name" reporter:datatype="text"/>
2461                 </fields>
2462                 <links/>
2463         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2464             <actions>
2465                 <create permission="CREATE_LASSO" global_required="true"/>
2466                 <retrieve permission="CREATE_LASSO UPDATE_LASSO DELETE_LASSO" global_required="true"/>
2467                 <update permission="UPDATE_LASSO" global_required="true"/>
2468                 <delete permission="DELETE_LASSO" global_required="true"/>
2469             </actions>
2470         </permacrud>
2471         </class>
2472         <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">
2473                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_lasso_map_id_seq">
2474                         <field name="id" reporter:datatype="id" />
2475                         <field name="lasso" reporter:datatype="link"/>
2476                         <field name="org_unit" reporter:datatype="org_unit"/>
2477                 </fields>
2478                 <links>
2479                         <link field="lasso" reltype="has_a" key="id" map="" class="lasso"/>
2480                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
2481                 </links>
2482         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2483             <actions>
2484                 <create permission="CREATE_LASSO_MAP" global_required="true"/>
2485                 <retrieve permission="CREATE_LASSO_MAP UPDATE_LASSO_MAP DELETE_LASSO_MAP" global_required="true"/>
2486                 <update permission="UPDATE_LASSO_MAP" global_required="true"/>
2487                 <delete permission="DELETE_LASSO_MAP" global_required="true"/>
2488             </actions>
2489         </permacrud>
2490         </class>
2491         <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">
2492                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_proximity_id_seq">
2493                         <field name="id" reporter:datatype="id" />
2494                         <field name="from_org" reporter:datatype="org_unit"/>
2495                         <field name="to_org" reporter:datatype="org_unit"/>
2496                         <field name="prox" reporter:datatype="int" />
2497                 </fields>
2498                 <links>
2499                         <link field="from_org" reltype="has_a" key="id" map="" class="aou"/>
2500                         <link field="to_org" reltype="has_a" key="id" map="" class="aou"/>
2501                 </links>
2502         </class>
2503         <class id="ssr" controller="open-ils.cstore" oils_obj:fieldmapper="search::search_result" oils_persist:tablename="search.search_result" oils_persist:readonly="true" reporter:label="Search Result">
2504                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_proximity_id_seq">
2505                         <field reporter:label="ID" name="id" reporter:datatype="id" />
2506                         <field reporter:label="Relevance" name="rel" reporter:datatype="float"/>
2507                         <field reporter:label="Record" name="record" reporter:datatype="link"/>
2508                         <field reporter:label="Total Results" name="total" reporter:datatype="int" />
2509                         <field reporter:label="Checked" name="checked" reporter:datatype="int"/>
2510                         <field reporter:label="Visible" name="visible" reporter:datatype="int"/>
2511                         <field reporter:label="Deleted" name="deleted" reporter:datatype="int"/>
2512                         <field reporter:label="Excluded" name="excluded" reporter:datatype="int"/>
2513                 </fields>
2514                 <links/>
2515         </class>
2516         <class id="asv" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="action::survey" oils_persist:tablename="action.survey" reporter:label="Survey">
2517                 <fields oils_persist:primary="id" oils_persist:sequence="action.survey_id_seq">
2518                         <field reporter:label="Questions" name="questions" oils_persist:virtual="true" reporter:datatype="link"/>
2519                         <field reporter:label="Responses" name="responses" oils_persist:virtual="true" reporter:datatype="link"/>
2520                         <field reporter:label="Description" name="description" reporter:datatype="text"/>
2521                         <field reporter:label="Survey End Date/Time" name="end_date" reporter:datatype="timestamp"/>
2522                         <field reporter:label="Survey ID" name="id" reporter:datatype="id"/>
2523                         <field reporter:label="Name" name="name" reporter:datatype="text"/>
2524                         <field reporter:label="OPAC Survey?" name="opac" reporter:datatype="bool"/>
2525                         <field reporter:label="Owning Library" name="owner" reporter:datatype="org_unit"/>
2526                         <field reporter:label="Poll Style?" name="poll" reporter:datatype="bool"/>
2527                         <field reporter:label="Is Required?" name="required" reporter:datatype="bool"/>
2528                         <field reporter:label="Survey Start Date/Time" name="start_date" reporter:datatype="timestamp"/>
2529                         <field reporter:label="Display in User Summary" name="usr_summary" reporter:datatype="bool"/>
2530                 </fields>
2531                 <links>
2532                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
2533                         <link field="responses" reltype="has_many" key="survey" map="" class="asvr"/>
2534                         <link field="questions" reltype="has_many" key="survey" map="" class="asvq"/>
2535                 </links>
2536         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2537             <actions>
2538                 <create permission="ADMIN_SURVEY" context_field="owner"/>
2539                 <retrieve/>
2540                 <update permission="ADMIN_SURVEY" context_field="owner"/>
2541                 <delete permission="ADMIN_SURVEY" context_field="owner"/>
2542             </actions>
2543         </permacrud>
2544         </class>
2545         <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">
2546                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_address_id_seq">
2547                         <field name="address_type"  reporter:datatype="text"/>
2548                         <field name="city"  reporter:datatype="text"/>
2549                         <field name="country"  reporter:datatype="text"/>
2550                         <field name="county"  reporter:datatype="text"/>
2551                         <field name="id" reporter:datatype="id" />
2552                         <field name="org_unit" reporter:datatype="org_unit"/>
2553                         <field name="post_code"  reporter:datatype="text"/>
2554                         <field name="state"  reporter:datatype="text"/>
2555                         <field name="street1"  reporter:datatype="text"/>
2556                         <field name="street2"  reporter:datatype="text"/>
2557                         <field name="valid" reporter:datatype="bool"/>
2558                 </fields>
2559                 <links>
2560                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
2561                 </links>
2562         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2563             <actions>
2564                 <create permission="CREATE_ORG_ADDRESS" context_field="org_unit"/>
2565                 <retrieve/>
2566                 <update permission="UPDATE_ORG_ADDRESS" context_field="org_unit"/>
2567                 <delete permission="DELETE_ORG_ADDRESS" context_field="org_unit"/>
2568             </actions>
2569         </permacrud>
2570         </class>
2571         <class id="ahr" controller="open-ils.cstore" oils_obj:fieldmapper="action::hold_request" oils_persist:tablename="action.hold_request" reporter:core="true" reporter:label="Hold Request">
2572                 <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_id_seq">
2573                         <field name="status" oils_persist:virtual="true" />
2574                         <field reporter:label="Transit" name="transit" oils_persist:virtual="true" />
2575                         <field reporter:label="Capture Date/Time" name="capture_time" reporter:datatype="timestamp"/>
2576                         <field reporter:label="Currently Targeted Copy" name="current_copy" />
2577                         <field reporter:label="Notify by Email?" name="email_notify" reporter:datatype="bool"/>
2578                         <field reporter:label="Hold Expire Date/Time" name="expire_time" reporter:datatype="timestamp"/>
2579                         <field reporter:label="Fulfilling Library" name="fulfillment_lib" reporter:datatype="org_unit"/>
2580                         <field reporter:label="Fulfilling Staff" name="fulfillment_staff" />
2581                         <field reporter:label="Fulfillment Date/Time" name="fulfillment_time" reporter:datatype="timestamp"/>
2582                         <field reporter:label="Hold Type" name="hold_type" reporter:datatype="text"/>
2583                         <field reporter:label="Holdable Formats (for M-type hold)" name="holdable_formats" reporter:datatype="text"/>
2584                         <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
2585                         <field reporter:label="Notifications Phone Number" name="phone_notify" reporter:datatype="text"/>
2586                         <field reporter:label="Pickup Library" name="pickup_lib" reporter:datatype="org_unit"/>
2587                         <field reporter:label="Last Targeting Date/Time" name="prev_check_time" reporter:datatype="timestamp"/>
2588                         <field reporter:label="Requesting Library" name="request_lib" reporter:datatype="org_unit"/>
2589                         <field reporter:label="Request Date/Time" name="request_time" reporter:datatype="timestamp"/>
2590                         <field reporter:label="Requesting User" name="requestor" reporter:datatype="link"/>
2591                         <field reporter:label="Item Selection Depth" name="selection_depth" />
2592                         <field reporter:label="Selection Locus" name="selection_ou" reporter:datatype="org_unit"/>
2593                         <field reporter:label="Target Object ID" name="target" reporter:datatype="link"/>
2594                         <field reporter:label="Hold User" name="usr" reporter:datatype="link"/>
2595                         <field reporter:label="Hold Cancel Date/Time" name="cancel_time" reporter:datatype="timestamp"/>
2596                         <field name="notify_time" oils_persist:virtual="true" reporter:datatype="timestamp"/>
2597                         <field name="notify_count" oils_persist:virtual="true" reporter:datatype="int" />
2598                         <field reporter:label="Notifications" name="notifications" oils_persist:virtual="true" reporter:datatype="link"/>
2599                         <field reporter:label="Bib Record link" name="bib_rec" oils_persist:virtual="true" reporter:datatype="link"/>
2600                         <field reporter:label="Eligible Copies" name="eligible_copies" oils_persist:virtual="true" reporter:datatype="link"/>
2601                         <field reporter:label="Currently Frozen" name="frozen" reporter:datatype="bool"/>
2602                         <field reporter:label="Thaw Date (if frozen)" name="thaw_date" reporter:datatype="timestamp"/>
2603                         <field reporter:label="Cancelation cause" name="cancel_cause" reporter:datatype="link" />
2604                         <field reporter:label="Cancelation note" name="cancel_note" reporter:datatype="text" />
2605                 </fields>
2606                 <links>
2607                         <link field="fulfillment_lib" reltype="has_a" key="id" map="" class="aou"/>
2608                         <link field="fulfillment_staff" reltype="has_a" key="id" map="" class="au"/>
2609                         <link field="pickup_lib" reltype="has_a" key="id" map="" class="aou"/>
2610                         <link field="selection_ou" reltype="has_a" key="id" map="" class="aou"/>
2611                         <link field="requestor" reltype="has_a" key="id" map="" class="au"/>
2612                         <link field="current_copy" reltype="has_a" key="id" map="" class="acp"/>
2613                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2614                         <link field="request_lib" reltype="has_a" key="id" map="" class="aou"/>
2615                         <link field="transit" reltype="might_have" key="hold" map="" class="ahtc"/>
2616                         <link field="notifications" reltype="has_many" key="hold" map="" class="ahn"/>
2617                         <link field="eligible_copies" reltype="has_many" key="hold" map="target_copy" class="ahcm"/>
2618                         <link field="bib_rec" reltype="might_have" key="id" map="" class="rhrr"/>
2619                         <link field="cancel_cause" reltype="might_have" key="id" map="" class="ahrcc"/>
2620                 </links>
2621         </class>
2622         <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">
2623                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_id_seq">
2624                         <field reporter:label="Subordinate Organizational Units" name="children" oils_persist:virtual="true" reporter:datatype="org_unit"/>
2625                         <field reporter:label="Billing Address" name="billing_address" reporter:datatype="link"/>
2626                         <field reporter:label="Holds Receiving Address" name="holds_address" reporter:datatype="link"/>
2627                         <field reporter:label="Organizational Unit ID" name="id" reporter:datatype="org_unit" reporter:selector="shortname"/>
2628                         <field reporter:label="ILL Receiving Address" name="ill_address" reporter:datatype="link"/>
2629                         <field reporter:label="Mailing Address" name="mailing_address" reporter:datatype="link"/>
2630                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
2631                         <field reporter:label="Organizational Unit Type" name="ou_type" reporter:datatype="link"/>
2632                         <field reporter:label="Parent Organizational Unit" name="parent_ou" reporter:datatype="link"/>
2633                         <field reporter:label="Short (Policy) Name" name="shortname" reporter:datatype="text"/>
2634                         <field reporter:label="Email Address" name="email" reporter:datatype="text"/>
2635                         <field reporter:label="Phone Number" name="phone" reporter:datatype="text"/>
2636                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
2637                         <field reporter:label="Users" name="users" oils_persist:virtual="true" reporter:datatype="link"/>
2638                         <field reporter:label="Closed Dates" name="closed_dates" oils_persist:virtual="true" reporter:datatype="link"/>
2639                         <field reporter:label="Circulations" name="circulations" oils_persist:virtual="true" reporter:datatype="link"/>
2640                         <field reporter:label="Settings" name="settings" oils_persist:virtual="true" reporter:datatype="link"/>
2641                         <field reporter:label="Addresses" name="addresses" oils_persist:virtual="true" reporter:datatype="link"/>
2642                         <field reporter:label="Checkins" name="checkins" oils_persist:virtual="true" reporter:datatype="link"/>
2643                         <field reporter:label="Workstations" name="workstations" oils_persist:virtual="true" reporter:datatype="link"/>
2644                 </fields>
2645                 <links>
2646                         <link field="billing_address" reltype="has_a" key="id" map="" class="aoa"/>
2647                         <link field="holds_address" reltype="has_a" key="id" map="" class="aoa"/>
2648                         <link field="ou_type" reltype="has_a" key="id" map="" class="aout"/>
2649                         <link field="mailing_address" reltype="has_a" key="id" map="" class="aoa"/>
2650                         <link field="parent_ou" reltype="has_a" key="id" map="" class="aou"/>
2651                         <link field="ill_address" reltype="has_a" key="id" map="" class="aoa"/>
2652                         <link field="users" reltype="has_many" key="home_ou" map="" class="au"/>
2653                         <link field="closed_dates" reltype="has_many" key="org_unit" map="" class="aoucd"/>
2654                         <link field="children" reltype="has_many" key="parent_ou" map="" class="aou"/>
2655                         <link field="circulations" reltype="has_many" key="circ_lib" map="" class="circ"/>
2656                         <link field="settings" reltype="has_many" key="org_unit" map="" class="aous"/>
2657                         <link field="addresses" reltype="has_many" key="org_unit" map="" class="aoa"/>
2658                         <link field="checkins" reltype="has_many" key="checkin_lib" map="" class="circ"/>
2659                         <link field="workstations" reltype="has_many" key="owning_lib" map="" class="aws"/>
2660                         <link field="distribution_formulas" reltype="has_many" key="owner" map="" class="acqdf"/>
2661                         <link field="distribution_formula_entries" reltype="has_many" key="owning_lib" map="" class="acqdfe"/>
2662                 </links>
2663         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2664             <actions>
2665                 <create permission="CREATE_ORG_UNIT" context_field="parent_ou"/>
2666                 <retrieve permission="CREATE_ORG_UNIT UPDATE_ORG_UNIT DELETE_ORG_UNIT">
2667                     <context field="id"/>
2668                     <context field="parent_ou"/>
2669                                 </retrieve>
2670                 <update permission="UPDATE_ORG_UNIT" context_field="id"/>
2671                 <delete permission="DELETE_ORG_UNIT" context_field="parent_ou"/>
2672             </actions>
2673         </permacrud>
2674         </class>
2675         <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">
2676                 <fields oils_persist:primary="id" oils_persist:sequence="container.call_number_bucket_id_seq">
2677                         <field name="items" oils_persist:virtual="true" reporter:datatype="link"/>
2678                         <field name="btype" reporter:datatype="text"/>
2679                         <field name="id" reporter:datatype="id" />
2680                         <field name="name"  reporter:datatype="text"/>
2681                         <field name="owner" reporter:datatype="link"/>
2682                         <field name="pub" reporter:datatype="bool"/>
2683                         <field name="create_time" reporter:datatype="timestamp" />
2684                 </fields>
2685                 <links>
2686                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
2687                         <link field="items" reltype="has_many" key="bucket" map="" class="ccnbi"/>
2688                 </links>
2689         </class>
2690         <class id="ccnbn" controller="open-ils.cstore" oils_obj:fieldmapper="container::call_number_bucket_note" oils_persist:tablename="container.call_number_bucket_note" reporter:label="Call Number Bucket Note">
2691                 <fields oils_persist:primary="id" oils_persist:sequence="container.call_number_bucket_note_id_seq">
2692                         <field name="id" reporter:datatype="id" />
2693                         <field name="bucket" reporter:datatype="link"/>
2694                         <field name="note" reporter:datatype="text" />
2695                 </fields>
2696                 <links>
2697                         <link field="bucket" reltype="has_a" key="id" map="" class="ccnb"/>
2698                 </links>
2699         </class>
2700         <class id="asc" controller="open-ils.cstore" oils_obj:fieldmapper="asset::stat_cat" oils_persist:tablename="asset.stat_cat" reporter:label="Asset Statistical Category">
2701                 <fields oils_persist:primary="id" oils_persist:sequence="asset.stat_cat_id_seq">
2702                         <field reporter:label="Entries" name="entries" oils_persist:virtual="true" reporter:datatype="link"/>
2703                         <field reporter:label="Stat Cat ID" name="id" reporter:datatype="id" reporter:selector="name"/>
2704                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
2705                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
2706                         <field reporter:label="Owning Library" name="owner" reporter:datatype="org_unit"/>
2707                 </fields>
2708                 <links>
2709                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
2710                         <link field="entries" reltype="has_many" key="stat_cat" map="" class="asce"/>
2711                 </links>
2712         </class>
2713         <class id="ac" controller="open-ils.cstore" oils_obj:fieldmapper="actor::card" oils_persist:tablename="actor.card" reporter:label="Library Card">
2714                 <fields oils_persist:primary="id" oils_persist:sequence="actor.card_id_seq">
2715                         <field reporter:label="IsActive?" name="active" reporter:datatype="bool"/>
2716                         <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
2717                         <field reporter:label="Card ID" name="id" reporter:datatype="id" />
2718                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
2719                 </fields>
2720                 <links>
2721                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2722                 </links>
2723         </class>
2724         <class id="actsc" controller="open-ils.cstore" oils_obj:fieldmapper="actor::stat_cat" oils_persist:tablename="actor.stat_cat" reporter:label="User Statistical Category">
2725                 <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_id_seq">
2726                         <field reporter:label="Entries" name="entries" oils_persist:virtual="true" reporter:datatype="link"/>
2727                         <field reporter:label="Stat Cat ID" name="id" reporter:datatype="id" reporter:selector="name"/>
2728                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
2729                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
2730                         <field reporter:label="Owning Library" name="owner" reporter:datatype="org_unit"/>
2731                 </fields>
2732                 <links>
2733                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
2734                         <link field="entries" reltype="has_many" key="stat_cat" map="" class="actsce"/>
2735                 </links>
2736         </class>
2737         <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">
2738                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.series_field_entry_id_seq">
2739                         <field name="field" reporter:datatype="link"/>
2740                         <field name="id" reporter:datatype="id" />
2741                         <field name="source" reporter:datatype="link"/>
2742                         <field name="value"  reporter:datatype="text"/>
2743                 </fields>
2744                 <links>
2745                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
2746                         <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
2747                 </links>
2748         </class>
2749         <class id="cub" controller="open-ils.cstore" oils_obj:fieldmapper="container::user_bucket" oils_persist:tablename="container.user_bucket" reporter:label="User Bucket">
2750                 <fields oils_persist:primary="id" oils_persist:sequence="container.user_bucket_id_seq">
2751                         <field name="items" oils_persist:virtual="true" reporter:datatype="link"/>
2752                         <field name="btype" reporter:datatype="text"/>
2753                         <field name="id" reporter:datatype="id" />
2754                         <field name="name"  reporter:datatype="text"/>
2755                         <field name="owner" reporter:datatype="link"/>
2756                         <field name="pub" reporter:datatype="bool"/>
2757                         <field name="create_time" reporter:datatype="timestamp" />
2758                 </fields>
2759                 <links>
2760                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
2761                         <link field="items" reltype="has_many" key="bucket" map="" class="cubi"/>
2762                 </links>
2763         </class>
2764         <class id="cubn" controller="open-ils.cstore" oils_obj:fieldmapper="container::user_bucket_note" oils_persist:tablename="container.user_bucket_note" reporter:label="User Bucket Note">
2765                 <fields oils_persist:primary="id" oils_persist:sequence="container.user_bucket_note_id_seq">
2766                         <field name="id" reporter:datatype="id" />
2767                         <field name="bucket" reporter:datatype="link"/>
2768                         <field name="note" reporter:datatype="text" />
2769                 </fields>
2770                 <links>
2771                         <link field="bucket" reltype="has_a" key="id" map="" class="cub"/>
2772                 </links>
2773         </class>
2774         <class id="mcrp" controller="open-ils.cstore" oils_obj:fieldmapper="money::credit_payment" oils_persist:tablename="money.credit_payment" reporter:label="House Credit Payment">
2775                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
2776                         <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
2777                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
2778                         <field reporter:label="Amount Collected" name="amount_collected" reporter:datatype="money" />
2779                         <field reporter:label="Pyament ID" name="id" reporter:datatype="id" />
2780                         <field reporter:label="Payment Note" name="note"  reporter:datatype="text"/>
2781                         <field reporter:label="Payment Timestamp" name="payment_ts" reporter:datatype="timestamp"/>
2782                         <field reporter:label="Transaction" name="xact" reporter:datatype="link"/>
2783                         <field reporter:label="Payment Type" name="payment_type" oils_persist:virtual="true"  reporter:datatype="text"/>
2784                         <field reporter:label="Payment link" name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
2785                 </fields>
2786                 <links>
2787                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
2788                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
2789                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
2790                 </links>
2791         </class>
2792         <class id="afr" controller="open-ils.cstore" oils_obj:fieldmapper="authority::full_rec" oils_persist:tablename="authority.full_rec" reporter:label="Full Authority Record">
2793                 <fields oils_persist:primary="id" oils_persist:sequence="authority.full_rec_id_seq">
2794                         <field name="id" reporter:datatype="id" />
2795                         <field name="ind1" />
2796                         <field name="ind2" />
2797                         <field name="record" />
2798                         <field name="subfield" />
2799                         <field name="tag" />
2800                         <field name="value" />
2801                 </fields>
2802                 <links>
2803                         <link field="record" reltype="has_a" key="id" map="" class="are"/>
2804                 </links>
2805         </class>
2806         <class id="cnct" controller="open-ils.cstore" oils_obj:fieldmapper="config::non_cataloged_type" oils_persist:tablename="config.non_cataloged_type" reporter:label="Non-cataloged Type">
2807                 <fields oils_persist:primary="id" oils_persist:sequence="config.non_cataloged_type_id_seq">
2808                         <field reporter:label="Circulation Duration" name="circ_duration" reporter:datatype="interval"/>
2809                         <field reporter:label="Non-cat Type ID" name="id" reporter:selector="name" reporter:datatype="id"/>
2810                         <field reporter:label="In House?" name="in_house" reporter:datatype="bool"/>
2811                         <field reporter:label="Name" name="name"  reporter:datatype="text" oils_persist:i18n="true"/>
2812                         <field reporter:label="Owning Library" name="owning_lib"  reporter:datatype="org_unit"/>
2813                 </fields>
2814                 <links>
2815                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
2816                 </links>
2817         </class>
2818         <class id="aout" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="actor::org_unit_type" oils_persist:tablename="actor.org_unit_type" reporter:label="Organizational Unit Type">
2819                 <fields oils_persist:primary="id" oils_persist:sequence="actor.org_unit_type_id_seq">
2820                         <field reporter:label="Subordinate Types" name="children" oils_persist:virtual="true" reporter:datatype="link"/>
2821                         <field reporter:label="Can Have Users?" name="can_have_users" reporter:datatype="bool"/>
2822                         <field reporter:label="Can Have Volumes?" name="can_have_vols" reporter:datatype="bool"/>
2823                         <field reporter:label="Type Depth" name="depth" reporter:datatype="int" />
2824                         <field reporter:label="Type ID" name="id" reporter:selector="name" reporter:datatype="id"/>
2825                         <field reporter:label="Type Name" name="name"  reporter:datatype="text" oils_persist:i18n="true"/>
2826                         <field reporter:label="OPAC Label" name="opac_label"  reporter:datatype="text" oils_persist:i18n="true"/>
2827                         <field reporter:label="Parent Type" name="parent" reporter:datatype="link"/>
2828                         <field reporter:label="Org Units" name="org_units" oils_persist:virtual="true"  reporter:datatype="org_unit"/>
2829                 </fields>
2830                 <links>
2831                         <link field="parent" reltype="has_a" key="id" map="" class="aout"/>
2832                         <link field="children" reltype="has_many" key="parent" map="" class="aout"/>
2833                         <link field="org_units" reltype="has_many" key="ou_type" map="" class="aou"/>
2834                 </links>
2835         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2836             <actions>
2837                 <create permission="CREATE_ORG_TYPE" global_required="true"/>
2838                 <retrieve permission="CREATE_ORG_UNIT UPDATE_ORG_UNIT DELETE_ORG_UNIT" global_required="true"/>
2839                 <update permission="UPDATE_ORG_TYPE" global_required="true"/>
2840                 <delete permission="DELETE_ORG_TYPE" global_required="true"/>
2841             </actions>
2842         </permacrud>
2843         </class>
2844         <class id="bren" controller="open-ils.cstore" oils_obj:fieldmapper="biblio::record_note" oils_persist:tablename="biblio.record_note" reporter:label="Bib Record Note">
2845                 <fields oils_persist:primary="id" oils_persist:sequence="biblio.record_note_id_seq">
2846                         <field name="create_date" reporter:datatype="timestamp"/>
2847                         <field name="creator" reporter:datatype="link"/>
2848                         <field name="edit_date" reporter:datatype="timestamp"/>
2849                         <field name="editor" reporter:datatype="link"/>
2850                         <field name="id" reporter:datatype="id" />
2851                         <field name="pub" reporter:datatype="bool"/>
2852                         <field name="record" reporter:datatype="link"/>
2853                         <field name="value"  reporter:datatype="text"/>
2854                 </fields>
2855                 <links>
2856                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
2857                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
2858                         <link field="record" reltype="has_a" key="id" map="" class="bre"/>
2859                 </links>
2860         </class>
2861         <class id="mucs" controller="open-ils.cstore" oils_obj:fieldmapper="money::user_circulation_summary" oils_persist:tablename="money.usr_circulation_summary" reporter:label="User Circulation Summary">
2862                 <fields oils_persist:primary="usr" oils_persist:sequence="">
2863                         <field name="balance_owed" reporter:datatype="money" />
2864                         <field name="total_owed" reporter:datatype="money" />
2865                         <field name="total_paid" reporter:datatype="money" />
2866                         <field name="usr" reporter:datatype="link"/>
2867                 </fields>
2868                 <links>
2869                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2870                 </links>
2871         </class>
2872         <class id="mg" controller="open-ils.cstore" oils_obj:fieldmapper="money::grocery" oils_persist:tablename="money.grocery" reporter:label="Grocery Transaction">
2873                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
2874                         <field reporter:label="Billing Location" name="billing_location" reporter:datatype="link"/>
2875                         <field reporter:label="Transaction ID" name="id" reporter:datatype="id" />
2876                         <field reporter:label="Note" name="note"  reporter:datatype="text"/>
2877                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
2878                         <field reporter:label="Transaction Finish Timestamp" name="xact_finish" reporter:datatype="timestamp" />
2879                         <field reporter:label="Transaction Start Timestamp" name="xact_start" reporter:datatype="timestamp" />
2880                         <field reporter:label="Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
2881                         <field reporter:label="Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
2882                         <field reporter:label="Billable Transaction link" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
2883                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
2884                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
2885                 </fields>
2886                 <links>
2887                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2888                         <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
2889                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
2890                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
2891                         <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
2892                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
2893                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
2894                 </links>
2895         </class>
2896         <class id="cbs" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::bib_source" oils_persist:tablename="config.bib_source" reporter:label="Bib Source">
2897                 <fields oils_persist:primary="id" oils_persist:sequence="config.bib_source_id_seq">
2898                         <field name="id" reporter:selector="source" reporter:datatype="id"/>
2899                         <field name="quality" reporter:datatype="int" />
2900                         <field name="source" reporter:datatype="text"/>
2901                         <field name="transcendant" reporter:datatype="bool"/>
2902                 </fields>
2903                 <links/>
2904         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2905             <actions>
2906                 <create permission="CREATE_BIB_SOURCE" global_required="true"/>
2907                 <retrieve/>
2908                 <update permission="UPDATE_BIB_SOURCE" global_required="true"/>
2909                 <delete permission="DELETE_BIB_SOURCE" global_required="true"/>
2910             </actions>
2911         </permacrud>
2912         </class>
2913         <class id="mbt" controller="open-ils.cstore" oils_obj:fieldmapper="money::billable_transaction" oils_persist:tablename="money.billable_xact" reporter:label="Billable Transaction">
2914                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
2915                         <field reporter:label="Transaction ID" name="id" reporter:datatype="id" />
2916                         <field reporter:label="User" name="usr" reporter:datatype="link"/>
2917                         <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp"/>
2918                         <field reporter:label="Transaction Start Date/Time" name="xact_start" reporter:datatype="timestamp"/>
2919                         <field reporter:label="Unrecovered Debt" name="unrecovered" reporter:datatype="bool"/>
2920                         <field reporter:label="Grocery Billing link" name="grocery" oils_persist:virtual="true" reporter:datatype="link"/>
2921                         <field reporter:label="Circulation Billing link" name="circulation" oils_persist:virtual="true" reporter:datatype="link"/>
2922                         <field reporter:label="Billing Line Items" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
2923                         <field reporter:label="Payment Line Items" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
2924                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
2925                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
2926                         <field reporter:label="Payment Summary" name="summary" oils_persist:virtual="true" reporter:datatype="link"/>
2927                 </fields>
2928                 <links>
2929                         <link field="grocery" reltype="might_have" key="id" map="" class="mg"/>
2930                         <link field="circulation" reltype="might_have" key="id" map="" class="circ"/>
2931                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2932                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
2933                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
2934                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
2935                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
2936                         <link field="summary" reltype="might_have" key="id" map="" class="mbts"/>
2937                 </links>
2938         </class>
2939         <class id="actsce" controller="open-ils.cstore" oils_obj:fieldmapper="actor::stat_cat_entry" oils_persist:tablename="actor.stat_cat_entry" reporter:label="User Stat Cat Entry">
2940                 <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_entry_id_seq">
2941                         <field reporter:label="Entry ID" name="id" reporter:datatype="id" />
2942                         <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
2943                         <field reporter:label="Stat Cat" name="stat_cat" reporter:datatype="link"/>
2944                         <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
2945                 </fields>
2946                 <links>
2947                         <link field="stat_cat" reltype="has_a" key="id" map="" class="actsc"/>
2948                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
2949                 </links>
2950         </class>
2951         <class id="cubi" controller="open-ils.cstore" oils_obj:fieldmapper="container::user_bucket_item" oils_persist:tablename="container.user_bucket_item" reporter:label="User Bucket Item">
2952                 <fields oils_persist:primary="id" oils_persist:sequence="container.user_bucket_item_id_seq">
2953                         <field name="bucket" reporter:datatype="link"/>
2954                         <field name="id" reporter:datatype="id" />
2955                         <field name="target_user" reporter:datatype="link"/>
2956                         <field name="create_time" reporter:datatype="timestamp" />
2957                         <field name="pos" reporter:datatype="int" />
2958                         <field name="notes" oils_persist:virtual="true" reporter:datatype="link" />
2959                 </fields>
2960                 <links>
2961                         <link field="target_user" reltype="has_a" key="id" map="" class="au"/>
2962                         <link field="bucket" reltype="has_a" key="id" map="" class="cub"/>
2963             <link field="notes" reltype="has_many" map="" key="item" class="cubin"/>
2964                 </links>
2965         </class>
2966         <class id="cubin" controller="open-ils.cstore" oils_obj:fieldmapper="container::user_bucket_item_note" oils_persist:tablename="container.user_bucket_item_note" reporter:label="User Bucket Item Note">
2967                 <fields oils_persist:primary="id" oils_persist:sequence="container.user_bucket_item_note_id_seq">
2968                         <field name="id" reporter:datatype="id" />
2969                         <field name="item" reporter:datatype="link"/>
2970                         <field name="note" reporter:datatype="text" />
2971                 </fields>
2972                 <links>
2973                         <link field="item" reltype="has_a" key="id" map="" class="cubi"/>
2974                 </links>
2975         </class>
2976         <class id="mus" controller="open-ils.cstore" oils_obj:fieldmapper="money::user_summary" oils_persist:tablename="money.usr_summary" reporter:label="User Summary">
2977                 <fields oils_persist:primary="usr" oils_persist:sequence="">
2978                         <field name="balance_owed" reporter:datatype="money" />
2979                         <field name="total_owed" reporter:datatype="money" />
2980                         <field name="total_paid" reporter:datatype="money" />
2981                         <field name="usr" reporter:datatype="link"/>
2982                 </fields>
2983                 <links>
2984                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
2985                 </links>
2986         </class>
2987         <class id="clfm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::lit_form_map" oils_persist:tablename="config.lit_form_map" reporter:label="Literary Form" oils_persist:field_safe="true">
2988                 <fields oils_persist:primary="code" oils_persist:sequence="">
2989                         <field reporter:label="LitF Code" name="code" reporter:datatype="text"/>
2990                         <field reporter:label="LitF Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
2991                         <field reporter:label="LitF Name" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
2992                 </fields>
2993                 <links/>
2994         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
2995             <actions>
2996                 <create permission="CREATE_MARC_CODE" global_required="true"/>
2997                 <retrieve permission="CREATE_MARC_CODE UPDATE_MARC_CODE DELETE_MARC_CODE" global_required="true"/>
2998                 <update permission="UPDATE_MARC_CODE" global_required="true"/>
2999                 <delete permission="DELETE_MARC_CODE" global_required="true"/>
3000             </actions>
3001         </permacrud>
3002         </class>
3003         <class id="mwp" controller="open-ils.cstore" oils_obj:fieldmapper="money::work_payment" oils_persist:tablename="money.work_payment" reporter:label="Work Payment">
3004                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
3005                         <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
3006                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3007                         <field reporter:label="Amount Collected" name="amount_collected" reporter:datatype="money" />
3008                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3009                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3010                         <field reporter:label="Payment Timestamp" name="payment_ts" reporter:datatype="timestamp"/>
3011                         <field reporter:label="Transaction ID" name="xact" reporter:datatype="link"/>
3012                         <field reporter:label="Payment link" name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
3013                         <field reporter:label="Payment Type" name="payment_type" oils_persist:virtual="true" reporter:datatype="text"/>
3014                 </fields>
3015                 <links>
3016                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
3017                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
3018                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3019                 </links>
3020         </class>
3021         <class id="mgp" controller="open-ils.cstore" oils_obj:fieldmapper="money::goods_payment" oils_persist:tablename="money.goods_payment" reporter:label="Goods Payment">
3022                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
3023                         <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
3024                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3025                         <field reporter:label="Amount Collected" name="amount_collected" reporter:datatype="money" />
3026                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3027                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3028                         <field reporter:label="Payment Timestamp" name="payment_ts" reporter:datatype="timestamp"/>
3029                         <field reporter:label="Transaction ID" name="xact" reporter:datatype="link"/>
3030                         <field reporter:label="Payment link" name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
3031                         <field reporter:label="Payment Type" name="payment_type" oils_persist:virtual="true" reporter:datatype="text"/>
3032                 </fields>
3033                 <links>
3034                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
3035                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
3036                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3037                 </links>
3038         </class>
3039         <class id="aoc" controller="open-ils.cstore" oils_obj:fieldmapper="action::open_circulation" oils_persist:tablename="action.open_circulation" reporter:label="Open Circulation">
3040                 <fields oils_persist:primary="id" oils_persist:sequence="">
3041                         <field name="checkin_lib" reporter:datatype="link"/>
3042                         <field name="checkin_staff" reporter:datatype="link"/>
3043                         <field name="checkin_time" reporter:datatype="timestamp"/>
3044                         <field name="circ_lib"  reporter:datatype="org_unit"/>
3045                         <field name="circ_staff" reporter:datatype="link"/>
3046                         <field name="desk_renewal" reporter:datatype="bool"/>
3047                         <field name="due_date" reporter:datatype="timestamp"/>
3048                         <field name="duration" reporter:datatype="interval"/>
3049                         <field name="duration_rule" reporter:datatype="link"/>
3050                         <field name="fine_interval" reporter:datatype="interval"/>
3051                         <field name="id" reporter:datatype="id" />
3052                         <field name="max_fine" reporter:datatype="money" />
3053                         <field name="max_fine_rule" reporter:datatype="link"/>
3054                         <field name="opac_renewal" reporter:datatype="bool"/>
3055                         <field name="phone_renewal" reporter:datatype="bool"/>
3056                         <field name="recuring_fine" reporter:datatype="money" />
3057                         <field name="recuring_fine_rule" reporter:datatype="link"/>
3058                         <field name="renewal_remaining" reporter:datatype="int" />
3059                         <field name="stop_fines" reporter:datatype="text"/>
3060                         <field name="stop_fines_time" reporter:datatype="timestamp"/>
3061                         <field name="target_copy" reporter:datatype="link"/>
3062                         <field name="usr" reporter:datatype="link"/>
3063                         <field name="xact_finish" reporter:datatype="timestamp" />
3064                         <field name="xact_start" reporter:datatype="timestamp" />
3065                         <field name="circulation" oils_persist:virtual="true" reporter:datatype="link"/>
3066                 </fields>
3067                 <links>
3068                         <link field="circulation" reltype="might_have" key="id" map="" class="circ"/>
3069                         <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
3070                         <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
3071                         <link field="recuring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
3072                 </links>
3073         </class>
3074         <class id="msfe" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::subject_field_entry" oils_persist:tablename="metabib.subject_field_entry" reporter:label="Subject Field Entry">
3075                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.subject_field_entry_id_seq">
3076                         <field name="field" reporter:datatype="link"/>
3077                         <field name="id" reporter:datatype="id" />
3078                         <field name="source" reporter:datatype="link"/>
3079                         <field name="value" reporter:datatype="text"/>
3080                 </fields>
3081                 <links>
3082                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
3083                         <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
3084                 </links>
3085         </class>
3086         <class id="crrf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::rules::recuring_fine" oils_persist:tablename="config.rule_recuring_fine" reporter:label="Recurring Fine Rule">
3087                 <fields oils_persist:primary="id" oils_persist:sequence="config.rule_recuring_fine_id_seq">
3088                         <field name="high" reporter:datatype="money" />
3089                         <field name="id" reporter:selector="name" reporter:datatype="id"/>
3090                         <field name="low" reporter:datatype="money" />
3091                         <field name="name" reporter:datatype="text"/>
3092                         <field name="normal" reporter:datatype="money" />
3093                         <field name="recurance_interval" reporter:datatype="interval"/>
3094                 </fields>
3095                 <links/>
3096         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3097             <actions>
3098                 <create permission="ADMIN_RECURING_FINE_RULE" global_required="true"/>
3099                 <retrieve/>
3100                 <update permission="ADMIN_RECURING_FINE_RULE" global_required="true"/>
3101                 <delete permission="ADMIN_RECURING_FINE_RULE" global_required="true"/>
3102             </actions>
3103         </permacrud>
3104         </class>
3105         <class id="mckp" controller="open-ils.cstore" oils_obj:fieldmapper="money::check_payment" oils_persist:tablename="money.check_payment" reporter:label="Check Payment">
3106                 <fields oils_persist:primary="id" oils_persist:sequence="money.payment_id_seq">
3107                         <field reporter:label="Accepting Staff Member" name="accepting_usr" reporter:datatype="link"/>
3108                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3109                         <field reporter:label="Amount Collected" name="amount_collected" reporter:datatype="money" />
3110                         <field reporter:label="Workstation link" name="cash_drawer" reporter:datatype="link"/>
3111                         <field reporter:label="Check Number" name="check_number" reporter:datatype="int" />
3112                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3113                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3114                         <field reporter:label="Payment Timestamp" name="payment_ts" reporter:datatype="timestamp"/>
3115                         <field reporter:label="Transaction link" name="xact" reporter:datatype="link"/>
3116                         <field reporter:label="Payment link" name="payment" oils_persist:virtual="true" reporter:datatype="link"/>
3117                         <field reporter:label="Payment Type" name="payment_type" oils_persist:virtual="true" reporter:datatype="text"/>
3118                 </fields>
3119                 <links>
3120                         <link field="payment" reltype="might_have" key="id" map="" class="mp"/>
3121                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
3122                         <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
3123                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3124                 </links>
3125         </class>
3126         <class id="acp" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="asset::copy" oils_persist:tablename="asset.copy" reporter:core="true" reporter:label="Item">
3127                 <fields oils_persist:primary="id" oils_persist:sequence="asset.copy_id_seq">
3128                         <field reporter:label="Statistical Category Entries" name="stat_cat_entries" oils_persist:virtual="true" reporter:datatype="link"/>
3129                         <field reporter:label="Age Hold Protection" name="age_protect" reporter:datatype="link"/>
3130                         <field reporter:label="Alert Message" name="alert_message" reporter:datatype="text"/>
3131                         <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
3132                         <field reporter:label="Call Number/Volume" name="call_number" reporter:datatype="link"/>
3133                         <field reporter:label="Circulation Type (MARC)" name="circ_as_type" reporter:datatype="text"/>
3134                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
3135                         <field reporter:label="Circulation Modifier" name="circ_modifier" reporter:datatype="text"/>
3136                         <field reporter:label="Can Circulate" name="circulate" reporter:datatype="bool"/>
3137                         <field reporter:label="Copy Number on Volume" name="copy_number" reporter:datatype="text"/>
3138                         <field reporter:label="Creation Date/Time" name="create_date" reporter:datatype="timestamp"/>
3139                         <field reporter:label="Creating User" name="creator" reporter:datatype="link"/>
3140                         <field reporter:label="Is Deleted" name="deleted" reporter:datatype="bool"/>
3141                         <field reporter:label="Is Deposit Required" name="deposit" reporter:datatype="bool"/>
3142                         <field reporter:label="Deposit Amount" name="deposit_amount" reporter:datatype="money" />
3143                         <field reporter:label="Precat Dummy Author" name="dummy_author" reporter:datatype="text"/>
3144                         <field reporter:label="Precat Dummy Title" name="dummy_title" reporter:datatype="text"/>
3145                         <field reporter:label="Last Edit Date/Time" name="edit_date" reporter:datatype="timestamp"/>
3146                         <field reporter:label="Last Editing User" name="editor" reporter:datatype="link"/>
3147                         <field reporter:label="Fine Level" name="fine_level" reporter:datatype="int"/>
3148                         <field reporter:label="Is Holdable" name="holdable" reporter:datatype="bool" />
3149                         <field reporter:label="Copy ID" name="id" reporter:datatype="id"/>
3150                         <field reporter:label="Loan Duration" name="loan_duration" reporter:datatype="int"/>
3151                         <field reporter:label="Shelving Location" name="location" reporter:datatype="link"/>
3152                         <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool" />
3153                         <field reporter:label="Price" name="price" reporter:datatype="money" />
3154                         <field reporter:label="Is Reference" name="ref" reporter:datatype="bool"/>
3155                         <field reporter:label="Copy Status" name="status" reporter:datatype="link"/>
3156                         <field reporter:label="Copy Notes" name="notes" oils_persist:virtual="true" reporter:datatype="link"/>
3157                         <field reporter:label="Stat-Cat entry maps" name="stat_cat_entry_copy_maps" oils_persist:virtual="true" reporter:datatype="link"/>
3158                         <field reporter:label="Circulations" name="circulations" oils_persist:virtual="true" reporter:datatype="link"/>
3159                         <field reporter:label="Total Circulations" name="total_circ_count" oils_persist:virtual="true" reporter:datatype="link"/>
3160                         <field reporter:label="Holds" name="holds" oils_persist:virtual="true" reporter:datatype="link"/>
3161                 </fields>
3162                 <links>
3163                         <link field="age_protect" reltype="has_a" key="id" map="" class="crahp"/>
3164                         <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
3165                         <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
3166                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
3167                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
3168                         <link field="status" reltype="has_a" key="id" map="" class="ccs"/>
3169                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
3170                         <link field="holds" reltype="has_many" key="target_copy" map="hold" class="ahcm"/>
3171                         <link field="stat_cat_entry_copy_maps" reltype="has_many" key="owning_copy" map="" class="ascecm"/>
3172                         <link field="notes" reltype="has_many" key="owning_copy" map="" class="acpn"/>
3173                         <link field="stat_cat_entries" reltype="has_many" key="owning_copy" map="stat_cat_entry" class="ascecm"/>
3174                         <link field="circulations" reltype="has_many" key="target_copy" map="" class="circ"/>
3175                         <link field="total_circ_count" reltype="might_have" key="id" map="" class="erfcc"/>
3176                 </links>
3177         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3178             <actions>
3179                 <create permission="CREATE_COPY">
3180                     <context link="call_number" field="owning_lib"/>
3181                 </create>
3182                 <retrieve/>
3183                 <update permission="UPDATE_COPY">
3184                     <context link="call_number" field="owning_lib"/>
3185                 </update>
3186                 <delete permission="DELETE_COPY">
3187                     <context link="call_number" field="owning_lib"/>
3188                 </delete>
3189             </actions>
3190         </permacrud>
3191         </class>
3192         <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">
3193                 <fields oils_persist:primary="id" oils_persist:sequence="config.rule_age_hold_protect_id_seq">
3194                         <field reporter:label="Item Age" name="age" reporter:datatype="interval"/>
3195                         <field reporter:label="Rule ID" name="id" reporter:selector="name" reporter:datatype="id"/>
3196                         <field reporter:label="Rule Name" name="name" reporter:datatype="text"/>
3197                         <field reporter:label="Allowed Proximity" name="prox" reporter:datatype="int" />
3198                 </fields>
3199                 <links/>
3200         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3201             <actions>
3202                 <create permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
3203                 <retrieve/>
3204                 <update permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
3205                 <delete permission="ADMIN_AGE_PROTECT_RULE" global_required="true"/>
3206             </actions>
3207         </permacrud>
3208         </class>
3209         <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">
3210                 <fields oils_persist:primary="id" oils_persist:sequence="config.rule_max_fine_id_seq">
3211                         <field reporter:label="Max Fine Amount" name="amount" reporter:datatype="money" />
3212                         <field reporter:label="Rule ID" name="id" reporter:selector="name" reporter:datatype="id"/>
3213                         <field reporter:label="Rule Name" name="name" reporter:datatype="text"/>
3214                         <field reporter:label="Is Percent" name="is_percent" reporter:datatype="bool"/>
3215                 </fields>
3216                 <links/>
3217         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3218             <actions>
3219                 <create permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
3220                 <retrieve/>
3221                 <update permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
3222                 <delete permission="ADMIN_MAX_FINE_RULE" global_required="true"/>
3223             </actions>
3224         </permacrud>
3225         </class>
3226         <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">
3227                 <fields oils_persist:primary="id" oils_persist:sequence="permission.grp_tree_id_seq">
3228                         <field reporter:label="Child Groups" name="children" oils_persist:virtual="true" reporter:datatype="link"/>
3229                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true"/>
3230                         <field reporter:label="Group ID" name="id" reporter:selector="name" reporter:datatype="id"/>
3231                         <field reporter:label="Group Name" name="name" reporter:datatype="text" oils_persist:i18n="true"/>
3232                         <field reporter:label="Parent Group" name="parent" reporter:datatype="link"/>
3233                         <field reporter:label="User Expiration Interval" name="perm_interval" reporter:datatype="interval"/>
3234                         <field reporter:label="Required Permission" name="application_perm" reporter:datatype="text"/>
3235                         <field reporter:label="Is User Group" name="usergroup" reporter:datatype="bool"/>
3236                 </fields>
3237                 <links>
3238                         <link field="parent" reltype="has_a" key="id" map="" class="pgt"/>
3239                         <link field="children" reltype="has_many" key="parent" map="" class="pgt"/>
3240                 </links>
3241         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3242             <actions>
3243                 <create permission="CREATE_PERM" global_required="true"/>
3244                 <retrieve permission="STAFF_LOGIN" global_required="true"/>
3245                 <update permission="UPDATE_PERM" global_required="true"/>
3246                 <delete permission="DELETE_PERM" global_required="true"/>
3247             </actions>
3248         </permacrud>
3249         </class>
3250         <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">
3251                 <fields oils_persist:primary="id" oils_persist:sequence="action.survey_answer_id_seq">
3252                         <field reporter:label="Responses using this Answer" name="responses" oils_persist:virtual="true" reporter:datatype="link"/>
3253                         <field reporter:label="Answer Text" name="answer" reporter:datatype="text"/>
3254                         <field reporter:label="Answer ID" name="id" reporter:datatype="id" />
3255                         <field reporter:label="Question" name="question" reporter:datatype="link"/>
3256                 </fields>
3257                 <links>
3258                         <link field="question" reltype="has_a" key="id" map="" class="asvq"/>
3259                         <link field="responses" reltype="has_many" key="answer" map="" class="asvr"/>
3260                 </links>
3261         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3262             <actions>
3263                 <create permission="ADMIN_SURVEY">
3264                     <context link="question" jump="survey" field="owner"/>
3265                 </create>
3266                 <retrieve/>
3267                 <update permission="ADMIN_SURVEY">
3268                     <context link="question" jump="survey" field="owner"/>
3269                 </update>
3270                 <delete permission="ADMIN_SURVEY">
3271                     <context link="question" jump="survey" field="owner"/>
3272                 </delete>
3273             </actions>
3274         </permacrud>
3275         </class>
3276         <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">
3277                 <fields oils_persist:primary="id" oils_persist:sequence="action.non_cataloged_circulation_id_seq">
3278                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
3279                         <field reporter:label="Circulation Date/Time" name="circ_time" reporter:datatype="timestamp"/>
3280                         <field reporter:label="Non-cat Circulation ID" name="id" reporter:datatype="id" />
3281                         <field reporter:label="Non-cat Item Type" name="item_type" reporter:datatype="link"/>
3282                         <field reporter:label="Patron" name="patron" reporter:datatype="link"/>
3283                         <field reporter:label="Circulating Staff" name="staff" reporter:datatype="link"/>
3284                 </fields>
3285                 <links>
3286                         <link field="item_type" reltype="has_a" key="id" map="" class="cnct"/>
3287                         <link field="staff" reltype="has_a" key="id" map="" class="au"/>
3288                         <link field="patron" reltype="has_a" key="id" map="" class="au"/>
3289                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
3290                 </links>
3291         </class>
3292         <class id="moucs" controller="open-ils.cstore" oils_obj:fieldmapper="money::open_user_circulation_summary" oils_persist:tablename="money.open_usr_circulation_summary" reporter:label="Open User Circulation Summary">
3293                 <fields oils_persist:primary="usr" oils_persist:sequence="">
3294                         <field name="balance_owed" reporter:datatype="money" />
3295                         <field name="total_owed" reporter:datatype="money" />
3296                         <field name="total_paid" reporter:datatype="money" />
3297                         <field name="usr" reporter:datatype="link"/>
3298                 </fields>
3299                 <links>
3300                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
3301                 </links>
3302         </class>
3303         <class id="aufh" controller="open-ils.cstore" oils_obj:fieldmapper="action::unfulfilled_hold_list" oils_persist:tablename="action.unfulfilled_hold_list" reporter:label="Unfulfilled Hold Targets">
3304                 <fields oils_persist:primary="id" oils_persist:sequence="action.unfulfilled_hold_list_id_seq">
3305                         <field reporter:label="Non-fulfilling Library" name="circ_lib"  reporter:datatype="org_unit"/>
3306                         <field reporter:label="Non-fulfilling Copy" name="current_copy" reporter:datatype="link"/>
3307                         <field reporter:label="Retargeting Date/Time" name="fail_time" reporter:datatype="timestamp"/>
3308                         <field reporter:label="Hold" name="hold" reporter:datatype="link"/>
3309                         <field reporter:label="Record ID" name="id" reporter:datatype="id" />
3310                 </fields>
3311                 <links>
3312                         <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
3313                         <link field="current_copy" reltype="has_a" key="id" map="" class="acp"/>
3314                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
3315                 </links>
3316         </class>
3317         <class id="mtfe" controller="open-ils.cstore" oils_obj:fieldmapper="metabib::title_field_entry" oils_persist:tablename="metabib.title_field_entry" reporter:label="Title Field Entry">
3318                 <fields oils_persist:primary="id" oils_persist:sequence="metabib.title_field_entry_id_seq">
3319                         <field name="field" reporter:datatype="link"/>
3320                         <field name="id" reporter:datatype="id" />
3321                         <field name="source" reporter:datatype="link"/>
3322                         <field name="value" reporter:datatype="text"/>
3323                 </fields>
3324                 <links>
3325                         <link field="source" reltype="has_a" key="id" map="" class="bre"/>
3326                         <link field="field" reltype="has_a" key="id" map="" class="cmf"/>
3327                 </links>
3328         </class>
3329         <class id="actscecm" controller="open-ils.cstore" oils_obj:fieldmapper="actor::stat_cat_entry_user_map" oils_persist:tablename="actor.stat_cat_entry_usr_map"  reporter:label="User Statistical Category Entry">
3330                 <fields oils_persist:primary="id" oils_persist:sequence="actor.stat_cat_entry_usr_map_id_seq">
3331                         <field reporter:label="Entry ID" name="id" reporter:datatype="id" />
3332                         <field reporter:label="Statistical Category" name="stat_cat" reporter:datatype="link"/>
3333                         <field reporter:label="Entry Text" name="stat_cat_entry" reporter:datatype="text"/>
3334                         <field reporter:label="User" name="target_usr" reporter:datatype="link"/>
3335                 </fields>
3336                 <links>
3337                         <link field="target_usr" reltype="has_a" key="id" map="" class="au"/>
3338                         <link field="stat_cat" reltype="has_a" key="id" map="" class="actsc"/>
3339                 </links>
3340         </class>
3341         <class id="pgpm" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="permission::grp_perm_map" oils_persist:tablename="permission.grp_perm_map" reporter:label="Group Permission Map">
3342                 <fields oils_persist:primary="id" oils_persist:sequence="permission.grp_perm_map_id_seq">
3343                         <field name="depth" reporter:datatype="int" />
3344                         <field name="grantable" reporter:datatype="bool"/>
3345                         <field name="grp" reporter:datatype="link"/>
3346                         <field name="id" reporter:datatype="id" />
3347                         <field name="perm" reporter:datatype="link"/>
3348                 </fields>
3349                 <links>
3350                         <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
3351                         <link field="perm" reltype="has_a" key="id" map="" class="ppl"/>
3352                 </links>
3353         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3354             <actions>
3355                 <create permission="ASSIGN_GROUP_PERM" global_required="true"/>
3356                 <retrieve permission="ASSIGN_GROUP_PERM UPDATE_GROUP_PERM REMOVE_GROUP_PERM" global_required="true"/>
3357                 <update permission="UPDATE_GROUP_PERM" global_required="true"/>
3358                 <delete permission="REMOVE_GROUP_PERM" global_required="true"/>
3359             </actions>
3360         </permacrud>
3361         </class>
3362         <class id="ccb" controller="open-ils.cstore" oils_obj:fieldmapper="container::copy_bucket" oils_persist:tablename="container.copy_bucket" reporter:label="Copy Bucket">
3363                 <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_id_seq">
3364                         <field name="items" oils_persist:virtual="true" />
3365                         <field name="btype" reporter:datatype="text"/>
3366                         <field name="id" reporter:datatype="id" />
3367                         <field name="name" reporter:datatype="text"/>
3368                         <field name="owner" reporter:datatype="link"/>
3369                         <field name="pub" reporter:datatype="bool"/>
3370                         <field name="create_time" reporter:datatype="timestamp" />
3371                 </fields>
3372                 <links>
3373                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
3374                         <link field="items" reltype="has_many" key="bucket" map="" class="ccbi"/>
3375                 </links>
3376         </class>
3377         <class id="ccbn" controller="open-ils.cstore" oils_obj:fieldmapper="container::copy_bucket_note" oils_persist:tablename="container.copy_bucket_note" reporter:label="Copy Bucket Note">
3378                 <fields oils_persist:primary="id" oils_persist:sequence="container.copy_bucket_note_id_seq">
3379                         <field name="id" reporter:datatype="id" />
3380                         <field name="bucket" reporter:datatype="link"/>
3381                         <field name="note" reporter:datatype="text" />
3382                 </fields>
3383                 <links>
3384                         <link field="bucket" reltype="has_a" key="id" map="" class="ccb"/>
3385                 </links>
3386         </class>
3387         <class id="puwoum" controller="open-ils.cstore" oils_obj:fieldmapper="permission::usr_work_ou_map" oils_persist:tablename="permission.usr_work_ou_map" reporter:label="User Work Org Unit Map">
3388                 <fields oils_persist:primary="id" oils_persist:sequence="permission.usr_work_ou_map_id_seq">
3389                         <field name="id" reporter:datatype="int" />
3390                         <field name="usr" reporter:datatype="link"/>
3391                         <field name="work_ou" reporter:datatype="link"/>
3392                 </fields>
3393                 <links>
3394                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
3395                         <link field="work_ou" reltype="has_a" key="id" map="" class="aou"/>
3396                 </links>
3397         </class>
3398         <class id="pupm" controller="open-ils.cstore" oils_obj:fieldmapper="permission::usr_perm_map" oils_persist:tablename="permission.usr_perm_map" reporter:label="User Permission Map">
3399                 <fields oils_persist:primary="id" oils_persist:sequence="permission.usr_perm_map_id_seq">
3400                         <field name="depth" reporter:datatype="int"/>
3401                         <field name="grantable" reporter:datatype="bool"/>
3402                         <field name="id" reporter:datatype="id" />
3403                         <field name="perm" reporter:datatype="link"/>
3404                         <field name="usr" reporter:datatype="link"/>
3405                 </fields>
3406                 <links>
3407                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
3408                         <link field="perm" reltype="has_a" key="id" map="" class="ppl"/>
3409                 </links>
3410         </class>
3411         <class id="puopm" controller="open-ils.cstore" oils_obj:fieldmapper="permission::usr_object_perm_map" oils_persist:tablename="permission.usr_object_perm_map" reporter:label="User Object Permission Map">
3412                 <fields oils_persist:primary="id" oils_persist:sequence="permission.usr_object_perm_map_id_seq">
3413                         <field name="object_id" reporter:datatype="text"/>
3414                         <field name="grantable" reporter:datatype="bool"/>
3415                         <field name="id" reporter:datatype="id" />
3416                         <field name="perm" reporter:datatype="link"/>
3417                         <field name="usr" reporter:datatype="link"/>
3418                         <field name="object_type" reporter:datatype="text"/>
3419                 </fields>
3420                 <links>
3421                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
3422                         <link field="perm" reltype="has_a" key="id" map="" class="ppl"/>
3423                 </links>
3424         </class>
3425         <class id="mp" controller="open-ils.cstore" oils_obj:fieldmapper="money::payment" oils_persist:tablename="money.payment_view" reporter:core="true" reporter:label="Payments: All">
3426                 <fields oils_persist:primary="id" oils_persist:sequence="">
3427                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3428                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3429                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3430                         <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
3431                         <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
3432                         <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
3433                         <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
3434                         <field reporter:label="Cash Payment Detail" name="cash_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3435                         <field reporter:label="Credit Card Payment Detail" name="credit_card_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3436                         <field reporter:label="Credit Payment Detail" name="credit_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3437                         <field reporter:label="Check Payment Detail" name="check_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3438                         <field reporter:label="Work Payment Detail" name="work_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3439                         <field reporter:label="Forgive Payment Detail" name="forgive_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3440                         <field reporter:label="Goods Payment Detail" name="goods_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3441                 </fields>
3442                 <links>
3443                         <link field="cash_payment" reltype="might_have" key="id" map="" class="mcp"/>
3444                         <link field="credit_card_payment" reltype="might_have" key="id" map="" class="mccp"/>
3445                         <link field="credit_payment" reltype="might_have" key="id" map="" class="mcrp"/>
3446                         <link field="check_payment" reltype="might_have" key="id" map="" class="mckp"/>
3447                         <link field="work_payment" reltype="might_have" key="id" map="" class="mwp"/>
3448                         <link field="forgive_payment" reltype="might_have" key="id" map="" class="mfp"/>
3449                         <link field="goods_payment" reltype="might_have" key="id" map="" class="mgp"/>
3450                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3451                 </links>
3452         </class>
3453         <class id="mbp" controller="open-ils.cstore" oils_obj:fieldmapper="money::bnm_payment" oils_persist:tablename="money.bnm_payment_view" reporter:core="true" reporter:label="Payments: Brick-and-mortar">
3454                 <fields oils_persist:primary="id" oils_persist:sequence="">
3455                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3456                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3457                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3458                         <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
3459                         <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
3460                         <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
3461                         <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
3462                         <field reporter:label="Cash Payment Detail" name="cash_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3463                         <field reporter:label="Credit Card Payment Detail" name="credit_card_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3464                         <field reporter:label="Credit Payment Detail" name="credit_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3465                         <field reporter:label="Check Payment Detail" name="check_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3466                         <field reporter:label="Work Payment Detail" name="work_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3467                         <field reporter:label="Forgive Payment Detail" name="forgive_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3468                         <field reporter:label="Goods Payment Detail" name="goods_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3469                 </fields>
3470                 <links>
3471                         <link field="cash_payment" reltype="might_have" key="id" map="" class="mcp"/>
3472                         <link field="credit_card_payment" reltype="might_have" key="id" map="" class="mccp"/>
3473                         <link field="credit_payment" reltype="might_have" key="id" map="" class="mcrp"/>
3474                         <link field="check_payment" reltype="might_have" key="id" map="" class="mckp"/>
3475                         <link field="work_payment" reltype="might_have" key="id" map="" class="mwp"/>
3476                         <link field="forgive_payment" reltype="might_have" key="id" map="" class="mfp"/>
3477                         <link field="goods_payment" reltype="might_have" key="id" map="" class="mgp"/>
3478                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3479                 </links>
3480         </class>
3481         <class id="mndp" controller="open-ils.reporter" oils_obj:fieldmapper="money::non_drawer_payment" oils_persist:tablename="money.non_drawer_payment_view" reporter:core="true" reporter:label="Payments: Non-drawer Staff">
3482                 <fields oils_persist:primary="id" oils_persist:sequence="">
3483                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3484                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3485                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3486                         <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
3487                         <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
3488                         <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
3489                         <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
3490                         <field reporter:label="Work Payment Detail" name="work_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3491                         <field reporter:label="Forgive Payment Detail" name="forgive_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3492                         <field reporter:label="Goods Payment Detail" name="goods_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3493                         <field reporter:label="Credit Payment Detail" name="credit_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3494                 </fields>
3495                 <links>
3496                         <link field="work_payment" reltype="might_have" key="id" map="" class="mwp"/>
3497                         <link field="forgive_payment" reltype="might_have" key="id" map="" class="mfp"/>
3498                         <link field="goods_payment" reltype="might_have" key="id" map="" class="mgp"/>
3499                         <link field="credit_payment" reltype="might_have" key="id" map="" class="mcrp"/>
3500                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3501                 </links>
3502         </class>
3503         <class id="mdp" controller="open-ils.cstore" oils_obj:fieldmapper="money::desk_payment" oils_persist:tablename="money.desk_payment_view" reporter:core="true" reporter:label="Payments: Desk">
3504                 <fields oils_persist:primary="id" oils_persist:sequence="">
3505                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3506                         <field reporter:label="Payment ID" name="id" reporter:datatype="id" />
3507                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3508                         <field reporter:label="Payment Date/Time" name="payment_ts" reporter:datatype="timestamp"/>
3509                         <field reporter:label="Payment Type" name="payment_type" reporter:datatype="text"/>
3510                         <field reporter:label="Billable Transaction" name="xact" reporter:datatype="link"/>
3511                         <field reporter:label="Accepting User" name="accepting_usr" />
3512                         <field reporter:label="Cash Drawer" name="cash_drawer" reporter:datatype="link"/>
3513                         <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
3514                         <field reporter:label="Cash Payment" name="cash_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3515                         <field reporter:label="Credit Card Payment" name="credit_card_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3516                         <field reporter:label="Check Payment" name="check_payment" oils_persist:virtual="true" reporter:datatype="link"/>
3517                 </fields>
3518                 <links>
3519                         <link field="cash_payment" reltype="might_have" key="id" map="" class="mcp"/>
3520                         <link field="credit_card_payment" reltype="might_have" key="id" map="" class="mccp"/>
3521                         <link field="check_payment" reltype="might_have" key="id" map="" class="mckp"/>
3522                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3523                         <link field="accepting_usr" reltype="has_a" key="id" map="" class="au"/>
3524                         <link field="cash_drawer" reltype="has_a" key="id" map="" class="aws"/>
3525                 </links>
3526         </class>
3527         <class id="cbrebi" controller="open-ils.cstore" oils_obj:fieldmapper="container::biblio_record_entry_bucket_item" oils_persist:tablename="container.biblio_record_entry_bucket_item" reporter:label="Biblio Record Entry Bucket Item">
3528                 <fields oils_persist:primary="id" oils_persist:sequence="container.biblio_record_entry_bucket_item_id_seq">
3529                         <field name="bucket" reporter:datatype="link"/>
3530                         <field name="id" reporter:datatype="id" />
3531                         <field name="target_biblio_record_entry" reporter:datatype="link"/>
3532                         <field name="create_time" reporter:datatype="timestamp" />
3533                         <field name="pos" reporter:datatype="int" />
3534                         <field name="notes" oils_persist:virtual="true" reporter:datatype="link" />
3535                 </fields>
3536                 <links>
3537                         <link field="target_biblio_record_entry" reltype="has_a" key="id" map="" class="bre"/>
3538                         <link field="bucket" reltype="has_a" key="id" map="" class="cbreb"/>
3539             <link field="notes" reltype="has_many" map="" key="item" class="cbrebin"/>
3540                 </links>
3541         </class>
3542         <class id="cbrebin" controller="open-ils.cstore" oils_obj:fieldmapper="container::biblio_record_entry_bucket_item_note" oils_persist:tablename="container.biblio_record_entry_bucket_item_note" reporter:label="Biblio Record Entry Bucket Item Note">
3543                 <fields oils_persist:primary="id" oils_persist:sequence="container.biblio_record_entry_bucket_item_note_id_seq">
3544                         <field name="id" reporter:datatype="id" />
3545                         <field name="item" reporter:datatype="link"/>
3546                         <field name="note" reporter:datatype="text" />
3547                 </fields>
3548                 <links>
3549                         <link field="item" reltype="has_a" key="id" map="" class="cbrebi"/>
3550                 </links>
3551         </class>
3552         <class id="asce" controller="open-ils.cstore" oils_obj:fieldmapper="asset::stat_cat_entry" oils_persist:tablename="asset.stat_cat_entry" reporter:label="Item Stat Cat Entry">
3553                 <fields oils_persist:primary="id" oils_persist:sequence="asset.stat_cat_entry_id_seq">
3554                         <field reporter:label="Entry ID" name="id" reporter:datatype="int" />
3555                         <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
3556                         <field reporter:label="Stat Cat" name="stat_cat" reporter:datatype="link"/>
3557                         <field reporter:label="Value" name="value" reporter:datatype="text" oils_persist:i18n="true"/>
3558                 </fields>
3559                 <links>
3560                         <link field="stat_cat" reltype="has_a" key="id" map="" class="asc"/>
3561                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
3562                 </links>
3563         </class>
3564
3565         <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">
3566                 <fields oils_persist:primary="id" oils_persist:sequence="action.hold_request_cancel_cause_id_seq">
3567                         <field reporter:label="Cause ID" name="id" reporter:datatype="id" />
3568                         <field reporter:label="Cause Label" name="label" reporter:datatype="text" oils_persist:i18n="true" />
3569                 </fields>
3570                 <links/>
3571         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3572             <actions>
3573                 <create permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
3574                 <retrieve/>
3575                 <update permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
3576                 <delete permission="ADMIN_HOLD_CANCEL_CAUSE" global_required="true"/>
3577             </actions>
3578         </permacrud>
3579         </class>
3580
3581
3582         <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">
3583                 <fields oils_persist:primary="id" oils_persist:sequence="action.transit_copy_id_seq">
3584                         <field reporter:label="Copy Status at Transit" name="copy_status" reporter:datatype="link"/>
3585                         <field reporter:label="Destination Library" name="dest" reporter:datatype="org_unit"/>
3586                         <field reporter:label="Receive Date/Time" name="dest_recv_time" reporter:datatype="timestamp"/>
3587                         <field reporter:label="Hold requiring Transit" name="hold" reporter:datatype="link"/>
3588                         <field reporter:label="Transit ID" name="id" reporter:datatype="id" />
3589                         <field reporter:label="Is Persistent?" name="persistant_transfer" reporter:datatype="bool"/>
3590                         <field reporter:label="Previous Stop" name="prev_hop" reporter:datatype="link"/>
3591                         <field reporter:label="Sending Library" name="source" reporter:datatype="org_unit"/>
3592                         <field reporter:label="Send Date/Time" name="source_send_time" reporter:datatype="timestamp"/>
3593                         <field reporter:label="Transited Copy" name="target_copy" reporter:datatype="link"/>
3594                         <field reporter:label="Base Transit" name="transit_copy" oils_persist:virtual="true" reporter:datatype="link"/>
3595                 </fields>
3596                 <links>
3597                         <link field="transit_copy" reltype="might_have" key="id" map="" class="atc"/>
3598                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
3599                         <link field="source" reltype="has_a" key="id" map="" class="aou"/>
3600                         <link field="copy_status" reltype="has_a" key="id" map="" class="ccs"/>
3601                         <link field="dest" reltype="has_a" key="id" map="" class="aou"/>
3602                         <link field="hold" reltype="has_a" key="id" map="" class="ahr"/>
3603                 </links>
3604         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3605             <actions>
3606                 <create permission="TRANSIT_COPY" context_field="owner">
3607                     <context link="target_copy" field="circ_lib"/>
3608                 </create>
3609                 <retrieve/>
3610                 <update permission="UPDATE_TRANSIT" context_field="dest source"/>
3611                 <delete permission="DELETE_TRANSIT" context_field="dest source"/>
3612             </actions>
3613         </permacrud>
3614         </class>
3615         <class id="mb" controller="open-ils.cstore" oils_obj:fieldmapper="money::billing" oils_persist:tablename="money.billing" reporter:label="Billing Line Item">
3616                 <fields oils_persist:primary="id" oils_persist:sequence="money.billing_id_seq">
3617                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3618                         <field reporter:label="Billing Timestamp" name="billing_ts" reporter:datatype="timestamp"/>
3619                         <field reporter:label="Legacy Billing Type" name="billing_type" reporter:datatype="text"/>
3620                         <field reporter:label="Billing ID" name="id" reporter:datatype="id" />
3621                         <field reporter:label="Note" name="note" reporter:datatype="text"/>
3622                         <field reporter:label="Void Timestamp" name="void_time" reporter:datatype="timestamp"/>
3623                         <field reporter:label="Voided?" name="voided" reporter:datatype="bool"/>
3624                         <field reporter:label="Voiding Staff Member" name="voider" reporter:datatype="link"/>
3625                         <field reporter:label="Transaction" name="xact" reporter:datatype="link"/>
3626                         <field reporter:label="Type" name="btype" reporter:datatype="link"/>
3627                 </fields>
3628                 <links>
3629                         <link field="xact" reltype="has_a" key="id" map="" class="mbt"/>
3630                         <link field="voider" reltype="has_a" key="id" map="" class="au"/>
3631                         <link field="btype" reltype="has_a" key="id" map="" class="cbt"/>
3632                 </links>
3633         </class>
3634         <class id="pugm" controller="open-ils.cstore" oils_obj:fieldmapper="permission::usr_grp_map" oils_persist:tablename="permission.usr_grp_map" reporter:label="User Group Map">
3635                 <fields oils_persist:primary="id" oils_persist:sequence="permission.usr_grp_map_id_seq">
3636                         <field name="grp" />
3637                         <field name="id" reporter:datatype="id" />
3638                         <field name="usr" />
3639                 </fields>
3640                 <links>
3641                         <link field="grp" reltype="has_a" key="id" map="" class="pgt"/>
3642                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
3643                 </links>
3644         </class>
3645         <class id="i18n" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="config::i18n_core" oils_persist:tablename="config.i18n_core" oils_persist:field_safe="true" reporter:label="i18n Core">
3646                 <fields oils_persist:primary="id" oils_persist:sequence="config.i18n_core_id_seq">
3647                         <field name="id" reporter:datatype="id" />
3648                         <field name="fq_field" reporter:datatype="text"/>
3649                         <field name="identity_value" reporter:datatype="text"/>
3650                         <field name="translation" reporter:datatype="text"/>
3651                         <field name="string" reporter:datatype="text"/>
3652                 </fields>
3653                 <links>
3654                         <link field="translation" reltype="has_a" key="code" map="" class="i18n_l"/>
3655                 </links>
3656         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3657             <actions>
3658                 <create permission="CREATE_TRANSLATION" global_required="true"/>
3659                 <retrieve permission="CREATE_TRANSLATION UPDATE_TRANSLATION DELETE_TRANSLATION" global_required="true"/>
3660                 <update permission="UPDATE_TRANSLATION" global_required="true"/>
3661                 <delete permission="DELETE_TRANSLATION" global_required="true"/>
3662             </actions>
3663         </permacrud>
3664         </class>
3665         <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">
3666                 <fields oils_persist:primary="id" oils_persist:sequence="config.idl_field_doc_id_seq">
3667                         <field name="id" reporter:datatype="id" />
3668                         <field name="fm_class" reporter:datatype="text"/>
3669                         <field name="field" reporter:datatype="text"/>
3670                         <field name="owner" reporter:datatype="org_unit"/>
3671                         <field name="string" reporter:datatype="text" oils_persist:i18n="true"/>
3672                 </fields>
3673                 <links>
3674                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
3675                 </links>
3676         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3677             <actions>
3678                 <create   permission="ADMIN_FIELD_DOC" context_field="owner"/>
3679                 <retrieve/>
3680                 <update   permission="ADMIN_FIELD_DOC" context_field="owner"/>
3681                 <delete   permission="ADMIN_FIELD_DOC" context_field="owner"/>
3682             </actions>
3683         </permacrud>
3684         </class>
3685         <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">
3686                 <fields oils_persist:primary="code">
3687                         <field name="code" reporter:datatype="id" />
3688                         <field name="marc_code" reporter:datatype="text"/>
3689                         <field name="name" reporter:datatype="text" oils_persist:i18n="true"/>
3690                         <field name="description" reporter:datatype="text" oils_persist:i18n="true"/>
3691                 </fields>
3692                 <links/>
3693         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3694             <actions>
3695                 <create permission="CREATE_LOCALE" global_required="true"/>
3696                 <retrieve permission="CREATE_LOCALE UPDATE_LOCALE DELETE_LOCALE" global_required="true"/>
3697                 <update permission="UPDATE_LOCALE" global_required="true"/>
3698                 <delete permission="DELETE_LOCALE" global_required="true"/>
3699             </actions>
3700         </permacrud>
3701         </class>
3702         <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">
3703                 <fields oils_persist:primary="id" oils_persist:sequence="config.billing_type_id_seq">
3704                         <field name="id" reporter:datatype="id" reporter:label="ID" />
3705                         <field name="name" reporter:datatype="text" reporter:label="Name" oils_persist:i18n="true"/>
3706                         <field name="owner" reporter:datatype="org_unit" reporter:label="Org Unit" />
3707             <field name="default_price" reporter:datatype="money" reporter:label="Default Price"/>
3708                 </fields>
3709                 <links>
3710                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
3711                 </links>
3712         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3713             <actions>
3714                 <create permission="CREATE_BILLING_TYPE" context_field="owner"/>
3715                 <retrieve permission="VIEW_BILLING_TYPE CREATE_BILLING_TYPE UPDATE_BILLING_TYPE DELETE_BILLING_TYPE" context_field="owner"/>
3716                 <update permission="UPDATE_BILLING_TYPE" context_field="owner"/>
3717                 <delete permission="DELETE_BILLING_TYPE" context_field="owner"/>
3718             </actions>
3719         </permacrud>
3720         </class>
3721         <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">
3722                 <fields oils_persist:primary="code">
3723                         <field reporter:label="Currency Code" name="code" reporter:datatype="text" reporter:selector='label'/>
3724                         <field reporter:label="Currency Label" name="label" reporter:datatype="text" oils_persist:i18n="true" />
3725                 </fields>
3726                 <links/>
3727         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3728             <actions>
3729                 <create permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3730                 <retrieve/>
3731                 <update permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3732                 <delete permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3733             </actions>
3734         </permacrud>
3735         </class>
3736
3737         <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">
3738                 <fields oils_persist:primary="id" oils_persist:sequence="acq.exchange_rate_id_seq">
3739                         <field reporter:label="Exchange Rate ID" name="id" reporter:datatype="id" />
3740                         <field reporter:label="From Currency" name="from_currency" reporter:datatype="link" />
3741                         <field reporter:label="To Currency" name="to_currency" reporter:datatype="link" />
3742                         <field reporter:label="Ratio" name="ratio" />
3743                 </fields>
3744                 <links>
3745                         <link field="from_currency" reltype="has_a" key="code" map="" class="acqct"/>
3746                         <link field="to_currency" reltype="has_a" key="code" map="" class="acqct"/>
3747                 </links>
3748                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3749                         <actions>
3750                                 <create permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3751                                 <retrieve/>
3752                                 <update permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3753                                 <delete permission="ADMIN_CURRENCY_TYPE" global_required="true"/>
3754                         </actions>
3755                 </permacrud>
3756         </class>
3757
3758         <class id="acqpro" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::provider" oils_persist:tablename="acq.provider" reporter:label="Provider">
3759                 <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_id_seq">
3760                         <field reporter:label="Provider ID" name="id" reporter:datatype="id" reporter:selector='code'/>
3761                         <field reporter:label="Provider Name" name="name" reporter:datatype="text" oils_persist:i18n="true" />
3762                         <field reporter:label="Owner" name="owner" reporter:datatype="org_unit" />
3763                         <field reporter:label="Currency" name="currency_type" oils_persist:primitive="string" reporter:datatype="link" />
3764                         <field reporter:label="Code" name="code" reporter:datatype="text" />
3765                         <field reporter:label="Holdings Tag" name="holding_tag" reporter:datatype="text" />
3766                         <field reporter:label="Addresses" name="addresses" oils_persist:virtual="true" reporter:datatype="link" />
3767                 </fields>
3768                 <links>
3769                         <link field="currency_type" reltype="has_a" key="code" map="" class="acqct"/>
3770                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
3771             <link field="addresses" reltype="has_many" map="" key="provider" class="acqpa"/>
3772                 </links>
3773         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3774             <actions>
3775                 <create   permission="ADMIN_PROVIDER" context_field="owner"/>
3776                 <retrieve permission="ADMIN_PROVIDER MANAGE_PROVIDER VIEW_PROVIDER" context_field="owner"/>
3777                 <update   permission="ADMIN_PROVIDER" context_field="owner"/>
3778                 <delete   permission="ADMIN_PROVIDER" context_field="owner"/>
3779             </actions>
3780         </permacrud>
3781         </class>
3782
3783         <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">
3784                 <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_address_id_seq">
3785                         <field name="address_type"  reporter:datatype="text"/>
3786                         <field name="city"  reporter:datatype="text"/>
3787                         <field name="country"  reporter:datatype="text"/>
3788                         <field name="county"  reporter:datatype="text"/>
3789                         <field name="id" reporter:datatype="id"/>
3790                         <field name="provider" reporter:datatype="link"/>
3791                         <field name="post_code"  reporter:datatype="text"/>
3792                         <field name="state"  reporter:datatype="text"/>
3793                         <field name="street1"  reporter:datatype="text"/>
3794                         <field name="street2"  reporter:datatype="text"/>
3795                         <field name="valid" reporter:datatype="bool"/>
3796                 </fields>
3797                 <links>
3798                         <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
3799                 </links>
3800         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3801             <actions>
3802                 <create permission="ADMIN_PROVIDER">
3803                     <context link="provider" field="owner"/>
3804                 </create>
3805                 <retrieve permission="ADMIN_PROVIDER">
3806                     <context link="provider" field="owner"/>
3807                 </retrieve>
3808                 <update permission="ADMIN_PROVIDER">
3809                     <context link="provider" field="owner"/>
3810                 </update>
3811                 <delete permission="ADMIN_PROVIDER">
3812                     <context link="provider" field="owner"/>
3813                 </delete>
3814             </actions>
3815         </permacrud>
3816         </class>
3817
3818         <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">
3819                 <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_contact_id_seq">
3820                         <field name="id" reporter:datatype="id"/>
3821                         <field name="provider" reporter:datatype="link"/>
3822                         <field name="name" reporter:datatype="text"/>
3823                         <field name="role" reporter:datatype="text"/>
3824                         <field name="email" reporter:datatype="text"/>
3825                         <field name="phone" reporter:datatype="text"/>
3826         </fields>
3827                 <links>
3828                         <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
3829                 </links>
3830         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3831             <actions>
3832                 <create permission="ADMIN_PROVIDER">
3833                     <context link="provider" field="owner"/>
3834                 </create>
3835                 <retrieve permission="ADMIN_PROVIDER">
3836                     <context link="provider" field="owner"/>
3837                 </retrieve>
3838                 <update permission="ADMIN_PROVIDER">
3839                     <context link="provider" field="owner"/>
3840                 </update>
3841                 <delete permission="ADMIN_PROVIDER">
3842                     <context link="provider" field="owner"/>
3843                 </delete>
3844             </actions>
3845         </permacrud>
3846     </class>
3847         <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">
3848                 <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_contact_address_id_seq">
3849                         <field reporter:label="Type" name="address_type"  reporter:datatype="text"/>
3850                         <field reporter:label="City" name="city"  reporter:datatype="text"/>
3851                         <field reporter:label="Country" name="country"  reporter:datatype="text"/>
3852                         <field reporter:label="County" name="county"  reporter:datatype="text"/>
3853                         <field reporter:label="Address ID" name="id" reporter:datatype="id" />
3854                         <field reporter:label="Postal Code" name="post_code" reporter:datatype="text"/>
3855                         <field reporter:label="State" name="state"  reporter:datatype="text"/>
3856                         <field reporter:label="Street (1)" name="street1"  reporter:datatype="text"/>
3857                         <field reporter:label="Street (2)" name="street2"  reporter:datatype="text"/>
3858                         <field reporter:label="Contact" name="contact" reporter:datatype="link"/>
3859                         <field reporter:label="Valid Address?" name="valid" reporter:datatype="bool"/>
3860                 </fields>
3861                 <links>
3862                         <link field="contact" reltype="has_a" key="id" map="" class="acqpc"/>
3863                 </links>
3864         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3865             <actions>
3866                 <create permission="ADMIN_PROVIDER">
3867                     <context link="contact" jump='provider' field="owner"/>
3868                 </create>
3869                 <retrieve permission="ADMIN_PROVIDER">
3870                     <context link="contact" jump='provider' field="owner"/>
3871                 </retrieve>
3872                 <update permission="ADMIN_PROVIDER">
3873                     <context link="contact" jump='provider' field="owner"/>
3874                 </update>
3875                 <delete permission="ADMIN_PROVIDER">
3876                     <context link="contact" jump='provider' field="owner"/>
3877                 </delete>
3878             </actions>
3879         </permacrud>
3880         </class>
3881
3882         <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">
3883                 <fields oils_persist:primary="id" oils_persist:sequence="acq.funding_source_id_seq">
3884                         <field reporter:label="Funding Source ID" name="id" reporter:datatype="id" reporter:selector='code'/>
3885                         <field reporter:label="Funding Source Name" name="name" reporter:datatype="text" oils_persist:i18n="true" />
3886                         <field reporter:label="Owner" name="owner" reporter:datatype="org_unit" />
3887                         <field reporter:label="Currency" name="currency_type" oils_persist:primitive="string" reporter:datatype="link" />
3888                         <field reporter:label="Code" name="code" reporter:datatype="text" />
3889                         <field name="summary" oils_persist:virtual="true"/>
3890                         <field reporter:label="Allocations" name="allocations" oils_persist:virtual="true" reporter:datatype="link"/>
3891                         <field reporter:label="Credits" name="credits" oils_persist:virtual="true" reporter:datatype="link"/>
3892                 </fields>
3893                 <links>
3894                         <link field="currency_type" reltype="has_a" key="code" map="" class="acqct"/>
3895                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
3896             <link field="allocations" reltype="has_many" map="" key="funding_source" class="acqfa"/>
3897             <link field="credits" reltype="has_many" key="funding_source" map="" class="acqfscred"/>
3898                 </links>
3899         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3900             <actions>
3901                 <create   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
3902                 <retrieve permission="ADMIN_FUNDING_SOURCE MANAGE_FUNDING_SOURCE VIEW_FUNDING_SOURCE" context_field="owner"/>
3903                 <update   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
3904                 <delete   permission="ADMIN_FUNDING_SOURCE" context_field="owner"/>
3905             </actions>
3906         </permacrud>
3907         </class>
3908
3909         <class id="acqfscred" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::funding_source_credit" oils_persist:tablename="acq.funding_source_credit" reporter:label="Credit to Funding Source">
3910                 <fields oils_persist:primary="id" oils_persist:sequence="acq.funding_source_credit_id_seq">
3911                         <field reporter:label="Credit ID" name="id" reporter:datatype="id" />
3912                         <field reporter:label="Funding Source ID" name="funding_source" reporter:datatype="link" />
3913                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3914                         <field reporter:label="Note" name="note" reporter:datatype="text" />
3915                 </fields>
3916                 <links>
3917                         <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
3918                 </links>
3919         </class>
3920
3921         <class id="acqfdeb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_debit" oils_persist:tablename="acq.fund_debit" reporter:label="Debit From Fund">
3922                 <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_debit_id_seq">
3923                         <field reporter:label="Debit ID" name="id" reporter:datatype="id" />
3924                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
3925                         <field reporter:label="Origin Amount" name="origin_amount" reporter:datatype="money" />
3926                         <field reporter:label="Origin Currency" name="origin_currency_type" reporter:datatype="link" />
3927                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
3928                         <field reporter:label="Encumbrance" name="encumbrance" reporter:datatype="text" />
3929                         <field reporter:label="Debit Type" name="debit_type" reporter:datatype="text" />
3930                         <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp" />
3931                 </fields>
3932                 <links>
3933                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
3934                         <link field="origin_currency_type" reltype="has_a" key="code" map="" class="acqct"/>
3935                 </links>
3936         </class>
3937
3938         <class id="acqf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::fund" oils_persist:tablename="acq.fund" reporter:label="Fund">
3939                 <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_id_seq">
3940                         <field reporter:label="Fund ID" name="id" reporter:datatype="id" reporter:selector='code'/>
3941                         <field reporter:label="Org Unit" name="org" reporter:datatype="org_unit" />
3942                         <field reporter:label="Name" name="name" reporter:datatype="text" />
3943                         <field reporter:label="Year" name="year" reporter:datatype="int" />
3944                         <field reporter:label="Currency Type" name="currency_type" reporter:datatype="link" />
3945                         <field reporter:label="Code" name="code" reporter:datatype="text" />
3946                         <field name="summary" oils_persist:virtual="true"/>
3947                         <field reporter:label="Allocations" name="allocations" oils_persist:virtual="true" reporter:datatype="link"/>
3948                         <field reporter:label="Debits" name="debits" oils_persist:virtual="true" reporter:datatype="link"/>
3949                         <field reporter:label="Tags" name="tags" oils_persist:virtual="true" reporter:datatype="link"/>
3950                 </fields>
3951                 <links>
3952                         <link field="org" reltype="has_a" key="id" map="" class="aou"/>
3953                         <link field="currency_type" reltype="has_a" key="code" map="" class="acqct"/>
3954             <link field="allocations" reltype="has_many" key="fund" map="" class="acqfa"/>
3955             <link field="debits" reltype="has_many" key="fund" map="" class="acqfdeb"/>
3956             <link field="tags" reltype="has_many" key="fund" map="" class="acqftm"/>
3957                 </links>
3958         <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
3959             <actions>
3960                 <create permission="ADMIN_ACQ_FUND" context_field="org"/>
3961                 <retrieve permission="ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="org"/>
3962                 <update permission="ADMIN_ACQ_FUND" context_field="org"/>
3963                 <delete permission="ADMIN_ACQ_FUND" context_field="org"/>
3964             </actions>
3965         </permacrud>
3966         </class>
3967
3968         <class id="acqfat" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_allocation_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_allocation_total" reporter:label="Fund Allocation Total">
3969                 <fields oils_persist:primary="fund">
3970                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
3971                         <field reporter:label="Total Allocation Amount" name="amount" reporter:datatype="money" />
3972                 </fields>
3973                 <links>
3974                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
3975                 </links>
3976         </class>
3977
3978         <class id="acqfdt" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_debit_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_debit_total" reporter:label="Total Debit from Fund">
3979                 <fields oils_persist:primary="fund">
3980                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
3981                         <field reporter:label="Total Debit Amount" name="amount" reporter:datatype="money" />
3982                 </fields>
3983                 <links>
3984                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
3985                 </links>
3986         </class>
3987
3988         <class id="acqfet" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_encumbrance_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_encumbrance_total" reporter:label="Total Fund Encumbrance">
3989                 <fields oils_persist:primary="fund">
3990                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
3991                         <field reporter:label="Total Encumbrance Amount" name="amount" reporter:datatype="money" />
3992                 </fields>
3993                 <links>
3994                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
3995                 </links>
3996         </class>
3997
3998         <class id="acqfst" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_total" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_total" reporter:label="Total Spent from Fund">
3999                 <fields oils_persist:primary="fund">
4000                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
4001                         <field reporter:label="Total Spent Amount" name="amount" reporter:datatype="money" />
4002                 </fields>
4003                 <links>
4004                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
4005                 </links>
4006         </class>
4007
4008         <class id="acqfcb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_combined_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_combined_balance" reporter:label="Fund Combined Balance">
4009                 <fields oils_persist:primary="fund">
4010                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
4011                         <field reporter:label="Balance after Spent and Encumbered" name="amount" reporter:datatype="money" />
4012                 </fields>
4013                 <links>
4014                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
4015                 </links>
4016         </class>
4017
4018         <class id="acqfsrcct" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::funding_source_credit_total" oils_persist:readonly="true" oils_persist:tablename="acq.funding_source_credit_total" reporter:label="Total Credit to Funding Source">
4019                 <fields oils_persist:primary="funding_source">
4020                         <field reporter:label="Funding Source" name="funding_source" reporter:datatype="link" />
4021                         <field reporter:label="Total Credits to Funding Source" name="amount" reporter:datatype="money" />
4022                 </fields>
4023                 <links>
4024                         <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
4025                 </links>
4026         </class>
4027
4028         <class id="acqfsrcat" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::funding_source_allocation_total" oils_persist:readonly="true" oils_persist:tablename="acq.funding_source_allocation_total" reporter:label="Total Allocation to Funding Source">
4029                 <fields oils_persist:primary="funding_source">
4030                         <field reporter:label="Funding Source" name="funding_source" reporter:datatype="link" />
4031                         <field reporter:label="Total Allocated from Funding Source" name="amount" reporter:datatype="money" />
4032                 </fields>
4033                 <links>
4034                         <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
4035                 </links>
4036         </class>
4037
4038         <class id="acqfsrcb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::funding_source_balance" oils_persist:readonly="true" oils_persist:tablename="acq.funding_source_balance" reporter:label="Funding Source Balance">
4039                 <fields oils_persist:primary="funding_source">
4040                         <field reporter:label="Funding Source" name="funding_source" reporter:datatype="link" />
4041                         <field reporter:label="Balance Remaining" name="amount" reporter:datatype="money" />
4042                 </fields>
4043                 <links>
4044                         <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
4045                 </links>
4046         </class>
4047
4048         <class id="acqfsb" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_spent_balance" oils_persist:readonly="true" oils_persist:tablename="acq.fund_spent_balance" reporter:label="Fund Spent Balance">
4049                 <fields oils_persist:primary="fund">
4050                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link" />
4051                         <field reporter:label="Balance after Spent" name="amount" reporter:datatype="money" />
4052                 </fields>
4053                 <links>
4054                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
4055                 </links>
4056         </class>
4057
4058         <class id="acqfa" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::fund_allocation" oils_persist:tablename="acq.fund_allocation" reporter:label="Fund Allocation">
4059                 <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_allocation_id_seq">
4060                         <field reporter:label="Allocation ID" name="id" reporter:datatype="id" />
4061                         <field reporter:label="Fund" name="fund" reporter:datatype="link" />
4062                         <field reporter:label="Funding Source" name="funding_source" reporter:datatype="link" />
4063                         <field reporter:label="Amount" name="amount" reporter:datatype="money" />
4064                         <field reporter:label="Percent" name="percent" reporter:datatype="float" />
4065                         <field reporter:label="Allocating User" name="allocator" reporter:datatype="link" />
4066                         <field reporter:label="Note" name="note" reporter:datatype="text" />
4067                         <field reporter:label="Create Time" name="create_time" reporter:datatype="timestamp" />
4068                 </fields>
4069                 <links>
4070                         <link field="allocator" reltype="has_a" key="id" map="" class="au"/>
4071                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
4072                         <link field="funding_source" reltype="has_a" key="id" map="" class="acqfs"/>
4073                 </links>
4074         </class>
4075
4076         <class id="acqpl" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::picklist" oils_persist:tablename="acq.picklist" reporter:label="Pick List">
4077                 <fields oils_persist:primary="id" oils_persist:sequence="acq.picklist_id_seq">
4078                         <field reporter:label="Picklist ID" name="id" reporter:datatype="id" />
4079                         <field reporter:label="Owner" name="owner" reporter:datatype="link" />
4080                         <field reporter:label="Org Unit" name="org_unit" reporter:datatype="link" />
4081                         <field reporter:label="Name" name="name" reporter:datatype="text" oils_persist:i18n="true" />
4082                         <field reporter:label="Creation Time" name="create_time" reporter:datatype="timestamp" />
4083                         <field reporter:label="Edit Time" name="edit_time" reporter:datatype="timestamp" />
4084                         <field reporter:label="Entries" name="entries" oils_persist:virtual="true" reporter:datatype="link" />
4085                         <field reporter:label="Entry Count" name="entry_count" oils_persist:virtual="true"/>
4086                         <field reporter:label="Creator" name="creator" reporter:datatype="link" />
4087                         <field reporter:label="Editor" name="editor" reporter:datatype="link" />
4088                 </fields>
4089                 <links>
4090                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4091                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4092                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
4093                         <link field="org_unit" reltype="has_a" key="id" map="" class="aou"/>
4094                         <link field="entries" reltype="has_many" key="picklist" map="" class="jub"/>
4095                 </links>
4096         </class>
4097
4098         <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">
4099                 <fields oils_persist:primary="id" oils_persist:sequence="acq.purchase_order_id_seq">
4100                         <field reporter:label="Purchase Order ID" name="id" reporter:datatype="id" />
4101                         <field reporter:label="Owner" name="owner" reporter:datatype="link" />
4102                         <field reporter:label="Creation Time" name="create_time" reporter:datatype="timestamp" />
4103                         <field reporter:label="Edit Time" name="edit_time" reporter:datatype="timestamp" />
4104                         <field reporter:label="Provider" name="provider" reporter:datatype="link" />
4105                         <field reporter:label="State" name="state" reporter:datatype="text" />
4106                         <field reporter:label="Ordering Agency" name="ordering_agency" reporter:datatype="org_unit" />
4107                         <field reporter:label="Creator" name="creator" reporter:datatype="link" />
4108                         <field reporter:label="Editor" name="editor" reporter:datatype="link" />
4109                         <field reporter:label="Line Items" name="lineitems" oils_persist:virtual="true" reporter:datatype="link" />
4110                         <field reporter:label="Line Item Count" name="lineitem_count" oils_persist:virtual="true" reporter:datatype="link" />
4111                         <field reporter:label="Amount Encumbered" name="amount_encumbered" oils_persist:virtual="true" reporter:datatype="float" />
4112                         <field reporter:label="Amount Spent" name="amount_spent" oils_persist:virtual="true" reporter:datatype="float" />
4113                 </fields>
4114                 <links>
4115                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4116                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4117                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
4118                         <link field="default_fund" reltype="has_a" key="id" map="" class="acqf"/>
4119                         <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
4120                         <link field="lineitems" reltype="has_many" key="purchase_order" map="" class="jub"/>
4121                         <link field="ordering_agency" reltype="has_a" key="id" map="" class="aou"/>
4122                 </links>
4123                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
4124                         <actions>
4125                                 <create permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
4126                                 <retrieve permission="CREATE_PURCHASE_ORDER VIEW_PURCHASE_ORDER" context_field="ordering_agency"/>
4127                                 <update permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
4128                                 <delete permission="CREATE_PURCHASE_ORDER" context_field="ordering_agency"/>
4129                         </actions>
4130                 </permacrud>
4131         </class>
4132
4133         <class id="acqpon" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::po_note" oils_persist:tablename="acq.po_note" reporter:label="PO Note">
4134                 <fields oils_persist:primary="id" oils_persist:sequence="acq.po_note_id_seq">
4135                         <field reporter:label="PO Note ID" name="id" reporter:datatype="id" />
4136                         <field reporter:label="Purchase Order" name="purchase_order" reporter:datatype="link" />
4137                         <field reporter:label="Creator" name="creator" reporter:datatype="link" />
4138                         <field reporter:label="Creation Time" name="create_time" reporter:datatype="timestamp" />
4139                         <field reporter:label="Edit Time" name="edit_time" reporter:datatype="timestamp" />
4140                         <field reporter:label="Editor" name="editor" reporter:datatype="link" />
4141                         <field reporter:label="Vote Value" name="value" reporter:datatype="text" />
4142                 </fields>
4143                 <links>
4144                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4145                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
4146                         <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo"/>
4147                 </links>
4148         </class>
4149
4150         <class id="jub" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem" oils_persist:tablename="acq.lineitem" reporter:label="Line Item">
4151                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_id_seq">
4152                         <field reporter:label="Lineitem ID" name="id" reporter:datatype="id" />
4153                         <field reporter:label="Selecting User" name="selector" reporter:datatype="link" />
4154                         <field reporter:label="Picklist" name="picklist" reporter:datatype="link" />
4155                         <field reporter:label="Purchase Order" name="purchase_order" reporter:datatype="link" />
4156                         <field reporter:label="Provider" name="provider" reporter:datatype="link" />
4157                         <field reporter:label="Creation Time" name="create_time" reporter:datatype="timestamp" />
4158                         <field reporter:label="Edit Time" name="edit_time" reporter:datatype="timestamp" />
4159                         <field reporter:label="MARC" name="marc" reporter:datatype="text" />
4160                         <field reporter:label="Evergreen Bib ID" name="eg_bib_id" reporter:datatype="link" />
4161                         <field reporter:label="Source Label" name="source_label" reporter:datatype="text" />
4162                         <field reporter:label="Expected Receive Date" name="expected_recv_time" reporter:datatype="timestamp" />
4163                         <field reporter:label="State" name="state" reporter:datatype="text" />
4164                         <field reporter:label="Creator" name="creator" reporter:datatype="link" />
4165                         <field reporter:label="Editor" name="editor" reporter:datatype="link" />
4166                         <field reporter:label="Item Count" name="item_count" oils_persist:virtual="true" reporter:datatype="int" />
4167                         <field reporter:label="Descriptive Attributes" name="attributes" oils_persist:virtual="true" reporter:datatype="link" />
4168                         <field reporter:label="Line Item Details" name="lineitem_details" oils_persist:virtual="true" reporter:datatype="link" />
4169                         <field reporter:label="Line Item Notes" name="lineitem_notes" oils_persist:virtual="true" reporter:datatype="link" />
4170                 </fields>
4171                 <links>
4172                         <link field="selector" reltype="has_a" key="id" map="" class="au"/>
4173                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
4174                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4175                         <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
4176                         <link field="purchase_order" reltype="has_a" key="id" map="" class="acqpo"/>
4177                         <link field="picklist" reltype="has_a" key="id" map="" class="acqpl"/>
4178                         <link field="eg_bib_id" reltype="has_a" key="id" map="" class="bre"/>
4179                         <link field="attributes" reltype="has_many" key="lineitem" map="" class="acqlia"/>
4180                         <link field="lineitem_details" reltype="has_many" key="lineitem" map="" class="acqlid"/>
4181                         <link field="lineitem_notes" reltype="has_many" key="lineitem" map="" class="acqlin"/>
4182                 </links>
4183         </class>
4184
4185         <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">
4186                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_note_id_seq">
4187                         <field reporter:label="PO Line Item Note ID" name="id" reporter:datatype="id" />
4188                         <field reporter:label="Line Item" name="lineitem" reporter:datatype="link" />
4189                         <field reporter:label="Creator" name="creator" reporter:datatype="link" />
4190                         <field reporter:label="Creation Time" name="create_time" reporter:datatype="timestamp" />
4191                         <field reporter:label="Edit Time" name="edit_time" reporter:datatype="timestamp" />
4192                         <field reporter:label="Editor" name="editor" reporter:datatype="link" />
4193                         <field reporter:label="Vote Value" name="value" reporter:datatype="text" />
4194                 </fields>
4195                 <links>
4196                         <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4197                         <link field="editor" reltype="has_a" key="id" map="" class="au"/>
4198                         <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
4199                 </links>
4200         </class>
4201
4202         <class id="acqlia" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_attr" oils_persist:tablename="acq.lineitem_attr" reporter:label="Line Item Attribute">
4203                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_id_seq">
4204                         <field reporter:label="Attribute Value ID" name="id" reporter:datatype="id" />
4205                         <field reporter:label="Lineitem" name="lineitem" reporter:datatype="link" />
4206                         <field reporter:label="Type" name="attr_type" reporter:datatype="text" />
4207                         <field reporter:label="Name" name="attr_name" reporter:datatype="text" />
4208                         <field reporter:label="Value" name="attr_value" reporter:datatype="text" />
4209                         <field reporter:label="Definition" name="definition" reporter:datatype="text" />
4210                 </fields>
4211                 <links>
4212                         <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
4213                         <link field="definition" reltype="has_a" key="id" map="" class="acqliad"/>
4214                 </links>
4215         </class>
4216
4217         <class id="acqlid" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_detail" oils_persist:tablename="acq.lineitem_detail" reporter:label="Line Item Detail">
4218                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_detail_id_seq">
4219                         <field reporter:label="Item Detail ID" name="id" reporter:datatype="id" />
4220                         <field reporter:label="PO Line Item" name="lineitem" reporter:datatype="link" />
4221                         <field reporter:label="Evergreen Copy ID" name="eg_copy_id" reporter:datatype="link" />
4222                         <field reporter:label="Barcode" name="barcode" reporter:datatype="text" />
4223                         <field reporter:label="Call Number Label" name="cn_label" reporter:datatype="text" />
4224                         <field reporter:label="Actual Receive Date" name="recv_time" reporter:datatype="timestamp" />
4225                         <field reporter:label="Fund" name="fund" reporter:datatype="link" />
4226                         <field reporter:label="Fund Debit" name="fund_debit" reporter:datatype="link" />
4227                         <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit" />
4228                         <field reporter:label="Shelving Location" name="location" reporter:datatype="link" />
4229                         <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="link" />
4230                         <field reporter:label="Note" name="note" reporter:datatype="text" />
4231                         <field reporter:label="Collection Code" name="collection_code" reporter:datatype="text" />
4232                 </fields>
4233                 <links>
4234                         <link field="lineitem" reltype="has_a" key="id" map="" class="jub"/>
4235                         <link field="eg_copy_id" reltype="has_a" key="id" map="" class="acp"/>
4236                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
4237                         <link field="fund_debit" reltype="has_a" key="id" map="" class="acqfdeb"/>
4238                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4239                         <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
4240                         <link field="circ_modifier" reltype="has_a" key="code" map="" class="ccm"/>
4241                 </links>
4242         </class>
4243
4244         <class id="acqliad" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_attr_definition" oils_persist:tablename="acq.lineitem_attr_definition" reporter:label="Line Item Attribute Definition">
4245                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4246                         <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4247                         <field reporter:label="Code" name="code" reporter:datatype="text" />
4248                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4249                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4250                 </fields>
4251                 <links/>
4252         </class>
4253
4254         <class id="acqlimad" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_marc_attr_definition" oils_persist:tablename="acq.lineitem_marc_attr_definition" reporter:label="Line Item MARC Attribute Definition">
4255                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4256                         <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4257                         <field reporter:label="Code" name="code" reporter:datatype="text" />
4258                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4259                         <field reporter:label="XPath" name="xpath" reporter:datatype="text" />
4260                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4261                 </fields>
4262                 <links/>
4263         </class>
4264
4265         <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">
4266                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4267                         <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4268                         <field reporter:label="Code" name="code" reporter:datatype="text" />
4269                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4270                         <field reporter:label="XPath" name="xpath" reporter:datatype="text" />
4271                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4272                 </fields>
4273                 <links/>
4274         </class>
4275         <class id="acqliuad" controller="open-ils.cstore open-ils.reporter-store" oils_obj:fieldmapper="acq::lineitem_usr_attr_definition" oils_persist:tablename="acq.lineitem_usr_attr_definition" reporter:label="Line Item User Attribute Definition">
4276                 <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4277                         <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4278                         <field reporter:label="Code" name="code" reporter:datatype="text" />
4279                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4280                         <field reporter:label="User" name="usr" reporter:datatype="link" />
4281                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4282                 </fields>
4283                 <links>
4284                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
4285                 </links>
4286         </class>
4287
4288         <class id="acqlipad" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::lineitem_provider_attr_definition" oils_persist:tablename="acq.lineitem_provider_attr_definition" reporter:label="Line Item Provider Attribute Definition">
4289             <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4290                 <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4291                 <field reporter:label="Code" name="code" reporter:datatype="text" />
4292                 <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4293                 <field reporter:label="XPath" name="xpath" reporter:datatype="text" />
4294                 <field reporter:label="Provider" name="provider" reporter:datatype="link" />
4295                 <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4296         <field reporter:label="Remove" name="remove" reporter:datatype="text" />
4297
4298             </fields>
4299             <links>
4300                 <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
4301             </links>
4302             <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
4303                 <actions>
4304                     <create permission="ADMIN_PROVIDER">
4305                         <context link="provider" field="owner"/>
4306                     </create>
4307                     <retrieve permission="ADMIN_PROVIDER">
4308                         <context link="provider" field="owner"/>
4309                     </retrieve>
4310                     <update permission="ADMIN_PROVIDER">
4311                         <context link="provider" field="owner"/>
4312                     </update>
4313                     <delete permission="ADMIN_PROVIDER">
4314                         <context link="provider" field="owner"/>
4315                     </delete>
4316                 </actions>
4317             </permacrud>
4318         </class>
4319         
4320         <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">
4321             <fields oils_persist:primary="id" oils_persist:sequence="acq.provider_holding_subfield_map_id_seq">
4322                 <field reporter:label="ID" name="id" reporter:datatype="id" />
4323                 <field reporter:label="Provider" name="provider" reporter:datatype="link" />
4324                 <field reporter:label="Name" name="name" reporter:datatype="text" />
4325                 <field reporter:label="Subfield" name="subfield" reporter:datatype="text" />
4326             </fields>
4327             <links>
4328                 <link field="provider" reltype="has_a" key="id" map="" class="acqpro"/>
4329             </links>
4330             <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
4331                 <actions>
4332                     <create permission="ADMIN_PROVIDER">
4333                         <context link="provider" field="owner"/>
4334                     </create>
4335                     <retrieve permission="ADMIN_PROVIDER">
4336                         <context link="provider" field="owner"/>
4337                     </retrieve>
4338                     <update permission="ADMIN_PROVIDER">
4339                         <context link="provider" field="owner"/>
4340                     </update>
4341                     <delete permission="ADMIN_PROVIDER">
4342                         <context link="provider" field="owner"/>
4343                     </delete>
4344                 </actions>
4345             </permacrud>
4346         </class>
4347         
4348         <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">
4349             <fields oils_persist:primary="id" oils_persist:sequence="acq.lineitem_attr_definition_id_seq">
4350                         <field reporter:label="Definition ID" name="id" reporter:datatype="id" />
4351                         <field reporter:label="Code" name="code" reporter:datatype="text" />
4352                         <field reporter:label="Description" name="description" reporter:datatype="text" oils_persist:i18n="true" />
4353                         <field reporter:label="Is Identifier?" name="ident" reporter:datatype="bool"/>
4354                 </fields>
4355                 <links/>
4356         </class>
4357
4358         <class id="rof" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::output_folder" oils_persist:tablename="reporter.output_folder" reporter:label="Output Folder">
4359                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.output_folder_id_seq">
4360                         <field name="id" reporter:datatype="id" />
4361                         <field name="parent" reporter:datatype="link"/>
4362                         <field name="owner" reporter:datatype="link"/>
4363                         <field name="create_time" reporter:datatype="timestamp"/>
4364                         <field name="name" reporter:datatype="text"/>
4365                         <field name="shared" reporter:datatype="bool"/>
4366                         <field name="share_with" reporter:datatype="link"/>
4367                         <field name="children" oils_persist:virtual="true" reporter:datatype="link"/>
4368                         <field name="outputs" oils_persist:virtual="true" reporter:datatype="link"/>
4369                 </fields>
4370                 <links>
4371                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4372                         <link field="parent" reltype="has_a" key="id" map="" class="rof"/>
4373                         <link field="children" reltype="has_many" key="parent" map="" class="rof"/>
4374                         <link field="share_with" reltype="has_a" key="id" map="" class="aou"/>
4375                         <link field="outputs" reltype="has_many" key="folder" map="" class="rs"/>
4376                 </links>
4377         </class>
4378         <class id="rtf" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::template_folder" oils_persist:tablename="reporter.template_folder" reporter:label="Template Folder">
4379                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.template_folder_id_seq">
4380                         <field name="id" reporter:datatype="id" />
4381                         <field name="parent" reporter:datatype="link"/>
4382                         <field name="owner" reporter:datatype="link"/>
4383                         <field name="create_time" reporter:datatype="timestamp"/>
4384                         <field name="name" reporter:datatype="text"/>
4385                         <field name="shared" reporter:datatype="bool"/>
4386                         <field name="share_with" reporter:datatype="link"/>
4387                         <field name="children" oils_persist:virtual="true" reporter:datatype="link"/>
4388                         <field name="templates" oils_persist:virtual="true" reporter:datatype="link"/>
4389                 </fields>
4390                 <links>
4391                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4392                         <link field="parent" reltype="has_a" key="id" map="" class="rtf"/>
4393                         <link field="children" reltype="has_many" key="parent" map="" class="rtf"/>
4394                         <link field="share_with" reltype="has_a" key="id" map="" class="aou"/>
4395                         <link field="templates" reltype="has_many" key="folder" map="" class="rt"/>
4396                 </links>
4397         </class>
4398         <class id="rrf" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::report_folder" oils_persist:tablename="reporter.report_folder" reporter:label="Report Folder">
4399                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.report_folder_id_seq">
4400                         <field name="id" reporter:datatype="id" />
4401                         <field name="parent" reporter:datatype="link"/>
4402                         <field name="owner" reporter:datatype="link"/>
4403                         <field name="create_time" reporter:datatype="timestamp"/>
4404                         <field name="name" reporter:datatype="text"/>
4405                         <field name="shared" reporter:datatype="bool"/>
4406                         <field name="share_with" reporter:datatype="link"/>
4407                         <field name="children" oils_persist:virtual="true" reporter:datatype="link"/>
4408                         <field name="reports" oils_persist:virtual="true" reporter:datatype="link"/>
4409                 </fields>
4410                 <links>
4411                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4412                         <link field="parent" reltype="has_a" key="id" map="" class="rrf"/>
4413                         <link field="children" reltype="has_many" key="parent" map="" class="rrf"/>
4414                         <link field="share_with" reltype="has_a" key="id" map="" class="aou"/>
4415                         <link field="reports" reltype="has_many" key="folder" map="" class="rr"/>
4416                 </links>
4417         </class>
4418         <class id="rt" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::template" oils_persist:tablename="reporter.template" reporter:label="Template">
4419                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.template_id_seq">
4420                         <field name="id" reporter:datatype="id" />
4421                         <field name="owner" reporter:datatype="link"/>
4422                         <field name="create_time" reporter:datatype="timestamp"/>
4423                         <field name="name" reporter:datatype="text"/>
4424                         <field name="data" reporter:datatype="text"/>
4425                         <field name="folder" reporter:datatype="link"/>
4426                         <field name="description" reporter:datatype="text"/>
4427                         <field name="reports" oils_persist:virtual="true" reporter:datatype="link"/>
4428                 </fields>
4429                 <links>
4430                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4431                         <link field="folder" reltype="has_a" key="id" map="" class="rtf"/>
4432                         <link field="reports" reltype="has_many" key="template" map="" class="rr"/>
4433                 </links>
4434         </class>
4435         <class id="rr" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::report" oils_persist:tablename="reporter.report" reporter:label="Report">
4436                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.report_id_seq">
4437                         <field name="id" reporter:datatype="id" />
4438                         <field name="owner" reporter:datatype="link"/>
4439                         <field name="create_time" reporter:datatype="timestamp"/>
4440                         <field name="template" reporter:datatype="link"/>
4441                         <field name="data" reporter:datatype="link"/>
4442                         <field name="folder" reporter:datatype="link"/>
4443                         <field name="recur" reporter:datatype="bool"/>
4444                         <field name="recurance" reporter:datatype="interval"/>
4445                         <field name="name" reporter:datatype="text"/>
4446                         <field name="description" reporter:datatype="text"/>
4447                         <field name="runs" oils_persist:virtual="true" reporter:datatype="link"/>
4448                 </fields>
4449                 <links>
4450                         <link field="owner" reltype="has_a" key="id" map="" class="au"/>
4451                         <link field="template" reltype="has_a" key="id" map="" class="rt"/>
4452                         <link field="folder" reltype="has_a" key="id" map="" class="rrf"/>
4453                         <link field="runs" reltype="has_many" key="report" map="" class="rs"/>
4454                 </links>
4455         </class>
4456         <class id="rs" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::schedule" oils_persist:tablename="reporter.schedule" reporter:label="Schedule">
4457                 <fields oils_persist:primary="id" oils_persist:sequence="reporter.schedule_id_seq">
4458                         <field name="id" reporter:datatype="id" />
4459                         <field name="runner" reporter:datatype="link"/>
4460                         <field name="start_time" reporter:datatype="timestamp"/>
4461                         <field name="complete_time" reporter:datatype="timestamp"/>
4462                         <field name="run_time" reporter:datatype="timestamp"/>
4463                         <field name="email" reporter:datatype="text"/>
4464                         <field name="excel_format" reporter:datatype="bool"/>
4465                         <field name="csv_format" reporter:datatype="bool"/>
4466                         <field name="html_format" reporter:datatype="bool"/>
4467                         <field name="error_code" reporter:datatype="int"/>
4468                         <field name="error_text" reporter:datatype="text"/>
4469                         <field name="report" reporter:datatype="link"/>
4470                         <field name="folder" reporter:datatype="link"/>
4471                         <field name="chart_pie" reporter:datatype="bool"/>
4472                         <field name="chart_bar" reporter:datatype="bool"/>
4473                         <field name="chart_line" reporter:datatype="bool"/>
4474                 </fields>
4475                 <links>
4476                         <link field="runner" reltype="has_a" key="id" map="" class="au"/>
4477                         <link field="report" reltype="has_a" key="id" map="" class="rr"/>
4478                         <link field="folder" reltype="has_a" key="id" map="" class="rof"/>
4479                 </links>
4480         </class>
4481         <class id="rmsr" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::materialized_simple_record" oils_persist:tablename="reporter.materialized_simple_record" reporter:label="Fast Simple Record Extracts">
4482                 <fields oils_persist:primary="id">
4483                         <field reporter:label="Record ID" name="id" reporter:datatype="id" />
4484                         <field reporter:label="Fingerprint" name="fingerprint" reporter:datatype="text"/>
4485                         <field reporter:label="Overall Record Quality" name="quality" reporter:datatype="int"/>
4486                         <field reporter:label="TCN Source" name="tcn_source" reporter:datatype="text"/>
4487                         <field reporter:label="TCN Value" name="tcn_value" reporter:datatype="text"/>
4488                         <field reporter:label="Title Proper (normalized)" name="title" reporter:datatype="text"/>
4489                         <field reporter:label="Author (normalized)" name="author" reporter:datatype="text"/>
4490                         <field reporter:label="Publisher (normalized)" name="publisher" reporter:datatype="text"/>
4491                         <field reporter:label="Publication Year (normalized)" name="pubdate" reporter:datatype="int"/>
4492                         <field reporter:label="ISBN" name="isbn" reporter:datatype="text"/>
4493                         <field reporter:label="ISSN" name="issn" reporter:datatype="text"/>
4494                         <field reporter:label="Full Bibliographic record" name="biblio_record" oils_persist:virtual="true" reporter:datatype="link"/>
4495                 </fields>
4496                 <links>
4497                         <link field="biblio_record" reltype="might_have" key="id" map="" class="bre"/>
4498                 </links>
4499         </class>
4500         <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">
4501                 <fields oils_persist:primary="id">
4502                         <field reporter:label="Record ID" name="id" reporter:datatype="id" />
4503                         <field reporter:label="Fingerprint" name="fingerprint" reporter:datatype="text"/>
4504                         <field reporter:label="Overall Record Quality" name="quality" reporter:datatype="int"/>
4505                         <field reporter:label="TCN Source" name="tcn_source" reporter:datatype="text"/>
4506                         <field reporter:label="TCN Value" name="tcn_value" reporter:datatype="text"/>
4507                         <field reporter:label="Title Proper (normalized)" name="title" reporter:datatype="text"/>
4508                         <field reporter:label="Author (normalized)" name="author" reporter:datatype="text"/>
4509                         <field reporter:label="Publisher (normalized)" name="publisher" reporter:datatype="text"/>
4510                         <field reporter:label="Publication Year (normalized)" name="pubdate" reporter:datatype="int"/>
4511                         <field reporter:label="ISBN" name="isbn" reporter:datatype="text"/>
4512                         <field reporter:label="ISSN" name="issn" reporter:datatype="text"/>
4513                         <field reporter:label="Full Bibliographic record" name="biblio_record" oils_persist:virtual="true" reporter:datatype="link"/>
4514                 </fields>
4515                 <links>
4516                         <link field="biblio_record" reltype="might_have" key="id" map="" class="bre"/>
4517                 </links>
4518         </class>
4519         <class id="rsr" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::simple_record" oils_persist:tablename="reporter.simple_record" reporter:label="Simple Record">
4520                 <fields oils_persist:primary="id">
4521                         <field reporter:label="Record ID" name="id" reporter:datatype="id" />
4522                         <field reporter:label="Metarecord" name="metarecord" reporter:datatype="link"/>
4523                         <field reporter:label="Fingerprint" name="fingerprint" />
4524                         <field reporter:label="Overall Record Quality" name="quality" reporter:datatype="int"/>
4525                         <field reporter:label="TCN Source" name="tcn_source" reporter:datatype="text"/>
4526                         <field reporter:label="TCN Value" name="tcn_value" reporter:datatype="text"/>
4527                         <field reporter:label="Title Proper (normalized)" name="title" reporter:datatype="text"/>
4528                         <field reporter:label="Uniform Title (normalized)" name="uniform_title" reporter:datatype="text"/>
4529                         <field reporter:label="Author (normalized)" name="author" reporter:datatype="text"/>
4530                         <field reporter:label="Publisher (normalized)" name="publisher" reporter:datatype="text"/>
4531                         <field reporter:label="Publication Year (normalized)" name="pubdate" reporter:datatype="int"/>
4532                         <field reporter:label="Series Title (normalized)" name="series_title" reporter:datatype="text"/>
4533                         <field reporter:label="Series Statement (normalized)" name="series_statement" reporter:datatype="text"/>
4534                         <field reporter:label="Summary (normalized)" name="summary" reporter:datatype="text"/>
4535                         <field reporter:label="ISBN" name="isbn" reporter:datatype="text"/>
4536                         <field reporter:label="ISSN" name="issn" reporter:datatype="text"/>
4537                         <field reporter:label="Topic Subjects (normalized)" name="topic_subject" reporter:datatype="text"/>
4538                         <field reporter:label="Geographic Subjects (normalized)" name="geographic_subject" reporter:datatype="text"/>
4539                         <field reporter:label="Genres (normalized)" name="genre" reporter:datatype="text"/>
4540                         <field reporter:label="Personal Name Subjects (normalized)" name="name_subject" reporter:datatype="text"/>
4541                         <field reporter:label="Corporate Name Subjects (normalized)" name="corporate_subject" reporter:datatype="text"/>
4542                         <field reporter:label="External URI List (normalized)" name="external_uri" reporter:datatype="text"/>
4543                         <field reporter:label="Full Bibliographic record" name="biblio_record" oils_persist:virtual="true" reporter:datatype="link"/>
4544                 </fields>
4545                 <links>
4546                         <link field="metarecord" reltype="has_a" key="id" map="" class="mmr"/>
4547                         <link field="biblio_record" reltype="might_have" key="id" map="" class="bre"/>
4548                 </links>
4549         </class>
4550         <class id="rud" controller="open-ils.reporter-store open-ils.cstore" oils_obj:fieldmapper="reporter::user_demographic" oils_persist:tablename="reporter.demographic" reporter:label="User Demographics">
4551                 <fields oils_persist:primary="id">
4552                         <field reporter:label="User ID" name="id" reporter:datatype="id" />
4553                         <field reporter:label="Date of Birth" name="dob" reporter:datatype="timestamp"/>
4554                         <field reporter:label="General Demographic Division" name="general_division" reporter:datatype="text"/>
4555                 </fields>
4556                 <links>
4557                         <link field="id" reltype="might_have" key="id" map="" class="au"/>
4558                 </links>
4559         </class>
4560         <class id="rcirct" controller="open-ils.reporter-store open-ils.cstore" oils_obj:fieldmapper="reporter::circulation_type" oils_persist:tablename="reporter.circ_type" reporter:label="Circulation Type">
4561                 <fields oils_persist:primary="id">
4562                         <field reporter:label="Circulation ID" name="id" reporter:datatype="id" />
4563                         <field reporter:label="Circulation Type" name="type" reporter:datatype="text"/>
4564                 </fields>
4565                 <links>
4566                         <link field="id" reltype="might_have" key="id" map="" class="circ"/>
4567                 </links>
4568         </class>
4569         <class id="rhrr" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::hold_request_record" oils_persist:tablename="reporter.hold_request_record" reporter:label="Hold Request Record">
4570                 <fields oils_persist:primary="id">
4571                         <field reporter:label="Hold ID" name="id" reporter:datatype="id" />
4572                         <field reporter:label="Hold Target" name="target" reporter:datatype="int" />
4573                         <field reporter:label="Hold Request Type" name="hold_type" reporter:datatype="text"/>
4574                         <field reporter:label="Target Bib Record" name="bib_record" reporter:datatype="link"/>
4575                 </fields>
4576                 <links>
4577                         <link field="id" reltype="might_have" key="id" map="" class="ahr"/>
4578                         <link field="bib_record" reltype="has_a" key="id" map="" class="bre"/>
4579                 </links>
4580         </class>
4581         <class id="rxbt" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::xact_billing_totals" oils_persist:tablename="reporter.xact_billing_totals" reporter:label="Transaction Billing Totals">
4582                 <fields oils_persist:primary="xact">
4583                         <field reporter:label="Transaction ID" name="xact" reporter:datatype="int" />
4584                         <field reporter:label="Unvoided Billing Amount" name="unvoided" reporter:datatype="int" />
4585                         <field reporter:label="Voided Billing Amount" name="voided" reporter:datatype="money"/>
4586                         <field reporter:label="Total Billing Amount" name="total" reporter:datatype="money"/>
4587                 </fields>
4588                 <links>
4589                         <link field="xact" reltype="might_have" key="id" map="" class="mbt"/>
4590                 </links>
4591         </class>
4592         <class id="rxpt" controller="open-ils.reporter-store" oils_obj:fieldmapper="reporter::xact_paid_totals" oils_persist:tablename="reporter.xact_paid_totals" reporter:label="Transaction Paid Totals">
4593                 <fields oils_persist:primary="xact">
4594                         <field reporter:label="Transaction ID" name="xact" reporter:datatype="int" />
4595                         <field reporter:label="Unvoided Paid Amount" name="unvoided" reporter:datatype="int" />
4596                         <field reporter:label="Voided (Returned) Paid Amount" name="voided" reporter:datatype="money"/>
4597                         <field reporter:label="Total Paid Amount" name="total" reporter:datatype="money"/>
4598                 </fields>
4599                 <links>
4600                         <link field="xact" reltype="might_have" key="id" map="" class="mbt"/>
4601                 </links>
4602         </class>
4603         <class id="ergbhu" controller="open-ils.reporter-store" oils_obj:fieldmapper="extend_reporter::global_bibs_by_holding_update" oils_persist:tablename="extend_reporter.global_bibs_by_holding_update" reporter:label="Bib IDs by Holding Add/Delete Time (OCLC batch update)">
4604                 <fields oils_persist:primary="id">
4605                         <field reporter:label="Bib ID" name="id" reporter:datatype="id" />
4606                         <field reporter:label="Update Time" name="holding_update" reporter:datatype="timestamp" />
4607                         <field reporter:label="Update Type" name="update_type" reporter:datatype="text" />
4608                 </fields>
4609                 <links>
4610                         <link field="id" reltype="has_a" key="id" map="" class="bre"/>
4611                 </links>
4612         </class>
4613         <class id="erfcc" controller="open-ils.reporter-store" oils_obj:fieldmapper="extend_reporter::full_circ_count" oils_persist:tablename="extend_reporter.full_circ_count" reporter:label="Total Circulation Count, Including Legacy">
4614                 <fields oils_persist:primary="id">
4615                         <field reporter:label="Copy ID" name="id" reporter:datatype="int" />
4616                         <field reporter:label="Total Circulation Count" name="circ_count" reporter:datatype="int" />
4617                 </fields>
4618                 <links>
4619                         <link field="id" reltype="has_a" key="id" map="" class="acp"/>
4620                 </links>
4621         </class>
4622         <class id="acqdf" controller="open-ils.cstore open-ils.pcrud" oils_obj:fieldmapper="acq::distribution_formula" oils_persist:tablename="acq.distribution_formula" reporter:label="Distribution Formula">
4623                 <fields oils_persist:primary="id" oils_persist:sequence="acq.distribution_formula_id_seq">
4624                         <field reporter:label="Formula ID" name="id" reporter:datatype="id"/>
4625                         <field reporter:label="Formula Owner" name="owner" reporter:datatype="org_unit"/>
4626                         <field reporter:label="Formula Name" name="name" reporter:datatype="text"/>
4627                         <field reporter:label="Skip Count" name="skip_count" reporter:datatype="int"/>
4628                         <field reporter:label="Entries" name="entries" oils_persist:virtual="true" reporter:datatype="link"/>
4629                 </fields>
4630                 <links>
4631                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
4632                         <link field="entries" reltype="has_many" key="formula" map="" class="acqdfe"/>
4633                 </links>
4634                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
4635                         <actions>
4636                                 <create permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
4637                                 <retrieve permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
4638                                 <update permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
4639                                 <delete permission="ADMIN_ACQ_DISTRIB_FORMULA" context_field="owner"/>
4640                         </actions>
4641                 </permacrud>
4642         </class>
4643         <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">
4644                 <fields oils_persist:primary="id" oils_persist:sequence="acq.distribution_formula_entry_id_seq">
4645                         <field reporter:label="Entry ID" name="id" reporter:datatype="id"/>
4646                         <field reporter:label="Formula ID" name="formula" reporter:datatype="link"/>
4647                         <field reporter:label="Position" name="position" reporter:datatype="int"/>
4648                         <field reporter:label="Item Count" name="item_count" reporter:datatype="int"/>
4649                         <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4650                         <field reporter:label="Location" name="location" reporter:datatype="link"/>
4651                 </fields>
4652                 <links>
4653                         <link field="formula" reltype="has_a" key="id" map="" class="acqdf"/>
4654                         <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4655                         <link field="location" reltype="has_a" key="id" map="" class="acpl"/>
4656                 </links>
4657                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
4658                         <actions>
4659                                 <create permission="ADMIN_ACQ_DISTRIB_FORMULA">
4660                                         <context link="formula" field="owner"/>
4661                                 </create>
4662                                 <retrieve permission="ADMIN_ACQ_DISTRIB_FORMULA">
4663                                         <context link="formula" field="owner"/>
4664                                 </retrieve>
4665                                 <update permission="ADMIN_ACQ_DISTRIB_FORMULA">
4666                                         <context link="formula" field="owner"/>
4667                                 </update>
4668                                 <delete permission="ADMIN_ACQ_DISTRIB_FORMULA">
4669                                         <context link="formula" field="owner"/>
4670                                 </delete>
4671                         </actions>
4672                 </permacrud>
4673         </class>
4674
4675
4676         <!-- ********************************************************************************************************************* -->
4677         <!-- What follows is a set of example extensions that are useful for PINES.  Comment out or remove if you don't want them. -->
4678         <!-- ********************************************************************************************************************* -->
4679         <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">
4680                 <fields oils_persist:primary="id">
4681                         <field reporter:label="Circulation" name="id" reporter:datatype="id" />
4682                         <field reporter:label="Library Circulation Location Short (Policy) Name" name="circ_lib" reporter:datatype="text"/>
4683                         <field reporter:label="Library Circulation Location Link" name="circ_lib_id" reporter:datatype="org_unit"/>
4684                         <field reporter:label="Circulation Date/Time" name="xact_start" reporter:datatype="timestamp"/>
4685                         <field reporter:label="Circulation Type" name="circ_type" reporter:datatype="text"/>
4686                         <field reporter:label="Copy Link" name="copy_id" reporter:datatype="link"/>
4687                         <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="text"/>
4688                         <field reporter:label="Owning Library Short (Policy) Name" name="owning_lib_name" reporter:datatype="text"/>
4689                         <field reporter:label="Item Language" name="language" reporter:datatype="text"/>
4690                         <field reporter:label="Literary Form" name="lit_form" reporter:datatype="text"/>
4691                         <field reporter:label="MARC Form" name="item_form" reporter:datatype="text"/>
4692                         <field reporter:label="MARC Type" name="item_type" reporter:datatype="text"/>
4693                         <field reporter:label="Shelving Location" name="shelving_location" reporter:datatype="text"/>
4694                         <field reporter:label="Patron Profile Group" name="profile_group" reporter:datatype="text"/>
4695                         <field reporter:label="Patron Age Demographic" name="demographic_general_division" reporter:datatype="text"/>
4696                         <field reporter:label="Call Number Link" name="call_number" reporter:datatype="link"/>
4697                         <field reporter:label="Call Number Label" name="call_number_label" reporter:datatype="text"/>
4698                         <field reporter:label="Call Number Dewey/Prefix" name="dewey" reporter:datatype="text"/>
4699                         <field reporter:label="Patron Link" name="patron_id" reporter:datatype="link"/>
4700                         <field reporter:label="Patron Home Library Link" name="patron_home_lib" reporter:datatype="link"/>
4701                         <field reporter:label="Patron Home Library Short (Policy) Name" name="patron_home_lib_shortname" reporter:datatype="text"/>
4702                         <field reporter:label="Patron County" name="patron_county" reporter:datatype="text"/>
4703                         <field reporter:label="Patron City" name="patron_city" reporter:datatype="text"/>
4704                         <field reporter:label="Patron ZIP Code" name="patron_zip" reporter:datatype="text"/>
4705                         <field reporter:label="Legacy CAT1 Link" name="stat_cat_1" reporter:datatype="link"/>
4706                         <field reporter:label="Legacy CAT2 Link" name="stat_cat_2" reporter:datatype="link"/>
4707                         <field reporter:label="Dewey Range - Tens" name="dewey_range_tens" reporter:datatype="text"/>
4708                         <field reporter:label="Dewey Range - Hundreds" name="dewey_range_hundreds" reporter:datatype="text"/>
4709                         <field reporter:label="Dewey Block - Tens" name="dewey_block_tens" reporter:datatype="text"/>
4710                         <field reporter:label="Dewey Block - Hundreds" name="dewey_block_hundreds" reporter:datatype="text"/>
4711                         <field reporter:label="Legacy CAT1 Value" name="stat_cat_1_value" reporter:datatype="text"/>
4712                         <field reporter:label="Legacy CAT2 Value" name="stat_cat_2_value" reporter:datatype="text"/>
4713                 </fields>
4714                 <links>
4715                         <link field="id" reltype="has_a" key="id" map="" class="circ"/>
4716                         <link field="copy_id" reltype="has_a" key="id" map="" class="acp"/>
4717                         <link field="patron_id" reltype="has_a" key="id" map="" class="au"/>
4718                         <link field="circ_lib_id" reltype="has_a" key="id" map="" class="aou"/>
4719                         <link field="call_number" reltype="has_a" key="id" map="" class="acn"/>
4720                         <link field="patron_home_lib" reltype="has_a" key="id" map="" class="aou"/>
4721                         <link field="stat_cat_1" reltype="has_a" key="id" map="" class="rsce1"/>
4722                         <link field="stat_cat_2" reltype="has_a" key="id" map="" class="rsce2"/>
4723                 </links>
4724         </class>
4725
4726         <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">
4727                 <fields oils_persist:primary="id">
4728                         <field reporter:label="Entry ID" name="id" reporter:selector="value" reporter:datatype="id" />
4729                         <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
4730                         <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
4731                 </fields>
4732                 <links>
4733                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
4734                 </links>
4735         </class>
4736
4737         <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">
4738                 <fields oils_persist:primary="id">
4739                         <field reporter:label="Entry ID" name="id" reporter:selector="value" reporter:datatype="id" />
4740                         <field reporter:label="Entry Owner" name="owner" reporter:datatype="link"/>
4741                         <field reporter:label="Entry Value" name="value" reporter:datatype="text"/>
4742                 </fields>
4743                 <links>
4744                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
4745                 </links>
4746         </class>
4747
4748         <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">
4749                 <fields oils_persist:primary="id">
4750                         <field reporter:label="Transaction ID" name="id" reporter:datatype="id" />
4751
4752                         <field reporter:label="Billing Location Short (Policy) Name" name="billing_location_shortname" reporter:datatype="text"/>
4753                         <field reporter:label="Billing Location Name" name="billing_location_name" reporter:datatype="text"/>
4754                         <field reporter:label="Billing Location Link" name="billing_location" reporter:datatype="org_unit"/>
4755
4756                         <field reporter:label="User Home Library Short (Policy) Name" name="usr_home_ou_shortname" reporter:datatype="text"/>
4757                         <field reporter:label="User Home Library Name" name="usr_home_ou_name" reporter:datatype="text"/>
4758                         <field reporter:label="User Home Library Link" name="usr_home_ou" reporter:datatype="org_unit"/>
4759
4760                         <field reporter:label="User Barcode" name="barcode" reporter:datatype="text"/>
4761                         <field reporter:label="User Link" name="usr" reporter:datatype="link"/>
4762
4763                         <field reporter:label="Transaction Start Date/Time" name="xact_start" reporter:datatype="timestamp"/>
4764                         <field reporter:label="Transaction End Date/Time" name="xact_finish" reporter:datatype="timestamp"/>
4765                         <field reporter:label="Transaction Type" name="xact_type" reporter:datatype="text"/>
4766
4767                         <field reporter:label="Total Paid" name="total_paid" reporter:datatype="money"/>
4768                         <field reporter:label="Total Billed" name="total_owed" reporter:datatype="money"/>
4769
4770                         <field reporter:label="Last Payment Date/Time" name="last_payment_ts" reporter:datatype="timestamp"/>
4771                         <field reporter:label="Last Payment Note" name="last_payment_note" reporter:datatype="text"/>
4772                         <field reporter:label="Last Payment Type" name="last_payment_type" reporter:datatype="text"/>
4773
4774                         <field reporter:label="Last Billing Date/Time" name="last_billing_ts" reporter:datatype="timestamp"/>
4775                         <field reporter:label="Last Billing Note" name="last_billing_note" reporter:datatype="text"/>
4776                         <field reporter:label="Last Billing Type" name="last_billing_type" reporter:datatype="text"/>
4777
4778                         <field reporter:label="User Age Demographic" name="demographic_general_division" reporter:datatype="text"/>
4779                         <field reporter:label="User County" name="patron_county" reporter:datatype="text"/>
4780                         <field reporter:label="User City" name="patron_city" reporter:datatype="text"/>
4781                         <field reporter:label="User ZIP Code" name="patron_zip" reporter:datatype="text"/>
4782
4783                         <field reporter:label="Balance Owed" name="balance_owed" reporter:datatype="money"/>
4784                         <field reporter:label="User Profile Group" name="profile_group" reporter:datatype="text"/>
4785
4786                 </fields>
4787                 <links>
4788                         <link field="id" reltype="has_a" key="id" map="" class="mbt"/>
4789                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
4790                         <link field="billing_location" reltype="has_a" key="id" map="" class="aou"/>
4791                         <link field="usr_home_ou" reltype="has_a" key="id" map="" class="aou"/>
4792                 </links>
4793         </class>
4794
4795         <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">
4796                 <oils_persist:source_definition>
4797
4798                         SELECT  t.*
4799                           FROM  action.transit_copy t
4800                                 JOIN actor.org_unit AS s ON (t.source = s.id)
4801                                 JOIN actor.org_unit AS d ON (t.dest = d.id)
4802                           WHERE s.parent_ou &lt;&gt; d.parent_ou
4803
4804                 </oils_persist:source_definition>
4805                 <fields oils_persist:primary="id" oils_persist:sequence="action.transit_copy_id_seq">
4806                         <field reporter:label="Pretransit Copy Status" name="copy_status" reporter:datatype="bool"/>
4807                         <field reporter:label="Destination" name="dest" reporter:datatype="link"/>
4808                         <field reporter:label="Receive Date/Time" name="dest_recv_time" reporter:datatype="timestamp"/>
4809                         <field reporter:label="Transit ID" name="id" reporter:datatype="id"/>
4810                         <field reporter:label="Is Persistent? (unused)" name="persistant_transfer" reporter:datatype="bool"/>
4811                         <field reporter:label="Previous Hop (unused)" name="prev_hop" reporter:datatype="link"/>
4812                         <field reporter:label="Source" name="source" reporter:datatype="link"/>
4813                         <field reporter:label="Send Date/Time" name="source_send_time" reporter:datatype="timestamp"/>
4814                         <field reporter:label="Transited Copy" name="target_copy" reporter:datatype="link"/>
4815                         <field reporter:label="Hold Transit" name="hold_transit_copy" oils_persist:virtual="true" reporter:datatype="link"/>
4816                 </fields>
4817                 <links>
4818                         <link field="hold_transit_copy" reltype="might_have" key="id" map="" class="ahtc"/>
4819                         <link field="source" reltype="has_a" key="id" map="" class="aou"/>
4820                         <link field="copy_status" reltype="has_a" key="id" map="" class="ccs"/>
4821                         <link field="dest" reltype="has_a" key="id" map="" class="aou"/>
4822                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
4823                 </links>
4824         </class>
4825
4826         <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">
4827                 <fields oils_persist:primary="id" oils_persist:sequence="money.billable_xact_id_seq">
4828                         <field reporter:label="Check In Library" name="checkin_lib" reporter:datatype="org_unit"/>
4829                         <field reporter:label="Check In Staff" name="checkin_staff" reporter:datatype="link"/>
4830                         <field reporter:label="Check In Date/Time" name="checkin_time" reporter:datatype="timestamp"/>
4831                         <field reporter:label="Circulating Library" name="circ_lib"  reporter:datatype="org_unit"/>
4832                         <field reporter:label="Circulating Staff" name="circ_staff" reporter:datatype="link"/>
4833                         <field reporter:label="Desk Renewal" name="desk_renewal" reporter:datatype="bool"/>
4834                         <field reporter:label="Due Date/Time" name="due_date" reporter:datatype="timestamp"/>
4835                         <field reporter:label="Circulation Duration" name="duration" reporter:datatype="interval"/>
4836                         <field reporter:label="Circ Duration Rule" name="duration_rule" reporter:datatype="link"/>
4837                         <field reporter:label="Fine Interval" name="fine_interval" reporter:datatype="interval"/>
4838                         <field reporter:label="Circ ID" name="id" reporter:datatype="id" />
4839                         <field reporter:label="Max Fine Amount" name="max_fine" reporter:datatype="money" />
4840                         <field reporter:label="Max Fine Rule" name="max_fine_rule" reporter:datatype="link"/>
4841                         <field reporter:label="OPAC Renewal" name="opac_renewal" reporter:datatype="bool"/>
4842                         <field reporter:label="Phone Renewal" name="phone_renewal" reporter:datatype="bool"/>
4843                         <field reporter:label="Recurring Fine Amount" name="recuring_fine" reporter:datatype="money" />
4844                         <field reporter:label="Recurring Fine Rule" name="recuring_fine_rule" reporter:datatype="link"/>
4845                         <field reporter:label="Remaining Renewals" name="renewal_remaining" reporter:datatype="int" />
4846                         <field reporter:label="Fine Stop Reason" name="stop_fines" reporter:datatype="text"/>
4847                         <field reporter:label="Fine Stop Date/Time" name="stop_fines_time" reporter:datatype="timestamp"/>
4848                         <field reporter:label="Circulating Item" name="target_copy" reporter:datatype="link"/>
4849                         <field reporter:label="Patron" name="usr" reporter:datatype="link"/>
4850                         <field reporter:label="Transaction Finish Date/Time" name="xact_finish" reporter:datatype="timestamp" />
4851                         <field reporter:label="Check Out Date/Time" name="xact_start" reporter:datatype="timestamp" />
4852                         <field reporter:label="Transaction Billings" name="billings" oils_persist:virtual="true" reporter:datatype="link"/>
4853                         <field reporter:label="Transaction Payments" name="payments" oils_persist:virtual="true" reporter:datatype="link"/>
4854                         <field reporter:label="Base Transaction" name="billable_transaction" oils_persist:virtual="true" reporter:datatype="link"/>
4855                         <field reporter:label="Circulation Type" name="circ_type" oils_persist:virtual="true" reporter:datatype="text"/>
4856                         <field reporter:label="Billing Totals" name="billing_total" oils_persist:virtual="true" reporter:datatype="money"/>
4857                         <field reporter:label="Payment Totals" name="payment_total" oils_persist:virtual="true" reporter:datatype="money"/>
4858                 </fields>
4859                 <links>
4860                         <link field="billable_transaction" reltype="might_have" key="id" map="" class="mbt"/>
4861                         <link field="circ_staff" reltype="has_a" key="id" map="" class="au"/>
4862                         <link field="checkin_lib" reltype="has_a" key="id" map="" class="aou"/>
4863                         <link field="target_copy" reltype="has_a" key="id" map="" class="acp"/>
4864                         <link field="checkin_staff" reltype="has_a" key="id" map="" class="au"/>
4865                         <link field="usr" reltype="has_a" key="id" map="" class="au"/>
4866                         <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
4867                         <link field="payments" reltype="has_many" key="xact" map="" class="mp"/>
4868                         <link field="billings" reltype="has_many" key="xact" map="" class="mb"/>
4869                         <link field="duration_rule" reltype="has_a" key="name" map="" class="crcd"/>
4870                         <link field="max_fine_rule" reltype="has_a" key="name" map="" class="crmf"/>
4871                         <link field="recuring_fine_rule" reltype="has_a" key="name" map="" class="crrf"/>
4872                         <link field="circ_type" reltype="might_have" key="id" map="" class="rcirct"/>
4873                         <link field="billing_total" reltype="might_have" key="xact" map="" class="rxbt"/>
4874                         <link field="payment_total" reltype="might_have" key="xact" map="" class="rxpt"/>
4875                 </links>
4876         </class>
4877
4878     <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">
4879         <fields oils_persist:primary="id">
4880             <field reporter:label="Title" name="title" reporter:datatype="text"/>
4881             <field reporter:label="Author" name="author" reporter:datatype="text"/>
4882             <field reporter:label="Pubdate" name="pubdate" reporter:datatype="text"/>
4883             <field reporter:label="Copy ID" name="id" reporter:datatype="id"/>
4884             <field reporter:label="Price" name="price" reporter:datatype="money"/>
4885             <field reporter:label="Barcode" name="barcode" reporter:datatype="text"/>
4886             <field reporter:label="Callnumber Label" name="call_number_label" reporter:datatype="text"/>
4887             <field reporter:label="Dewy Tens" name="dewey_block_tens" reporter:datatype="text"/>
4888             <field reporter:label="Dewy Hundreds" name="dewey_block_hundreds" reporter:datatype="text"/>
4889             <field reporter:label="Use Count" name="use_count" reporter:datatype="int"/>
4890             <field reporter:label="Circ Modifier" name="circ_modifier" reporter:datatype="text"/>
4891             <field reporter:label="Shelving Location Name" name="shelving_location" reporter:datatype="text"/>
4892             <field reporter:label="Legacy Stat Cat 1" name="stat_cat_1" reporter:datatype="text"/>
4893             <field reporter:label="Legacy Stat Cat 2" name="stat_cat_2" reporter:datatype="text"/>
4894             <field reporter:label="Legacy Stat Cat 1 Value" name="stat_cat_1_value" reporter:datatype="text"/>
4895             <field reporter:label="Legacy Stat Cat 2 Value" name="stat_cat_2_value" reporter:datatype="text"/>
4896             <field reporter:label="Edit Date" name="edit_date" reporter:datatype="timestamp"/>
4897             <field reporter:label="Create Date" name="create_date" reporter:datatype="timestamp"/>
4898             <field reporter:label="Owning Lib Name" name="owning_lib_name" reporter:datatype="text"/>
4899             <field reporter:label="Circ Lib Name" name="circ_lib_name" reporter:datatype="text"/>
4900             <field reporter:label="Owning Lib" name="owning_lib" reporter:datatype="link"/>
4901             <field reporter:label="Circ Lib" name="circ_lib" reporter:datatype="link"/>
4902             <field reporter:label="Creator" name="creator" reporter:datatype="link"/>
4903             <field reporter:label="Age Protection" name="age_protect" reporter:datatype="link"/>
4904             <field reporter:label="OPAC Visible" name="opac_visible" reporter:datatype="bool"/>
4905             <field reporter:label="Reference" name="ref" reporter:datatype="bool"/>
4906             <field reporter:label="Deposit Amount" name="deposit_amount" reporter:datatype="text"/>
4907             <field reporter:label="Deleted" name="deleted" reporter:datatype="bool"/>
4908             <field reporter:label="TCN" name="tcn_value" reporter:datatype="text"/>
4909             <field reporter:label="Status" name="status" reporter:datatype="link"/>
4910             <field reporter:label="Stop Fines Reason" name="stop_fines" reporter:datatype="text"/>
4911             <field reporter:label="Due Date" name="due_date" reporter:datatype="timestamp"/>
4912             <field reporter:label="Patron Barcode" name="patron_barcode" reporter:datatype="text"/>
4913             <field reporter:label="Patron Name" name="patron_name" reporter:datatype="text"/>
4914         </fields>
4915         <links>
4916             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4917             <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
4918             <link field="creator" reltype="has_a" key="id" map="" class="au"/>
4919             <link field="age_protect" reltype="has_a" key="id" map="" class="crahp"/>
4920             <link field="status" reltype="has_a" key="id" map="" class="ccs"/>
4921         </links>
4922     </class>
4923
4924     <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">
4925         <fields oils_persist:primary="id">
4926             <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
4927             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4928             <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
4929             <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
4930         </fields>
4931         <links>
4932             <link field="id" reltype="has_a" key="id" map="" class="circ"/>
4933             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4934         </links>
4935     </class>
4936
4937     <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">
4938         <fields oils_persist:primary="owning_lib">
4939             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4940             <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
4941             <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
4942         </fields>
4943         <links>
4944             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4945         </links>
4946     </class>
4947
4948     <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">
4949         <fields oils_persist:primary="id">
4950             <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
4951             <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="org_unit"/>
4952             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4953             <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
4954             <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
4955         </fields>
4956         <links>
4957             <link field="id" reltype="has_a" key="id" map="" class="circ"/>
4958             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4959             <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
4960         </links>
4961     </class>
4962
4963     <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">
4964         <fields oils_persist:primary="circ_lib">
4965             <field reporter:label="Circulating Library" name="circ_lib" reporter:datatype="org_unit"/>
4966             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4967             <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
4968             <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
4969         </fields>
4970         <links>
4971             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4972             <link field="circ_lib" reltype="has_a" key="id" map="" class="aou"/>
4973         </links>
4974     </class>
4975
4976     <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">
4977         <fields oils_persist:primary="id">
4978             <field reporter:label="Circulation ID" name="id" reporter:datatype="link"/>
4979             <field reporter:label="User Home Library" name="home_ou" reporter:datatype="org_unit"/>
4980             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4981             <field reporter:label="Billing Type" name="billing_type" reporter:datatype="text"/>
4982             <field reporter:label="Total Billed" name="billed" reporter:datatype="money"/>
4983         </fields>
4984         <links>
4985             <link field="id" reltype="has_a" key="id" map="" class="circ"/>
4986             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
4987             <link field="home_ou" reltype="has_a" key="id" map="" class="aou"/>
4988         </links>
4989     </class>
4990
4991     <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">
4992         <fields oils_persist:primary="home_ou">
4993             <field reporter:label="User Home Library" name="home_ou" reporter:datatype="org_unit"/>
4994             <field reporter:label="Owning Library" name="owning_lib" reporter:datatype="org_unit"/>
4995             <field reporter:label="Billing Types" name="billing_types" reporter:datatype="text"/>
4996             <field reporter:label="Balance" name="balance" reporter:datatype="money"/>
4997         </fields>
4998         <links>
4999             <link field="owning_lib" reltype="has_a" key="id" map="" class="aou"/>
5000             <link field="home_ou" reltype="has_a" key="id" map="" class="aou"/>
5001         </links>
5002     </class>
5003         <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">
5004                 <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_tag_id_seq">
5005                         <field reporter:label="Fund Tag ID" name="id" reporter:datatype="id"/>
5006                         <field reporter:label="Fund Tag Owner" name="owner" reporter:datatype="org_unit"/>
5007                         <field reporter:label="Fund Tag Name" name="name" reporter:datatype="text"/>
5008                         <field reporter:label="Map Entries" name="map_entries" oils_persist:virtual="true" reporter:datatype="link"/>
5009                 </fields>
5010                 <links>
5011                         <link field="owner" reltype="has_a" key="id" map="" class="aou"/>
5012                         <link field="map_entries" reltype="has_many" key="fund" map="" class="acqftm"/>
5013                 </links>
5014                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
5015                         <actions>
5016                                 <create permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
5017                                 <retrieve permission="ADMIN_ACQ_FUND_TAG ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND" context_field="owner"/>
5018                                 <update permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
5019                         <delete permission="ADMIN_ACQ_FUND_TAG" context_field="owner"/>
5020                         </actions>
5021                 </permacrud>
5022         </class>
5023         <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">
5024                 <fields oils_persist:primary="id" oils_persist:sequence="acq.fund_tag_map_id_seq">
5025                         <field reporter:label="Map Entry ID" name="id" reporter:datatype="id"/>
5026                         <field reporter:label="Fund ID" name="fund" reporter:datatype="link"/>
5027                         <field reporter:label="Tag ID" name="tag" reporter:datatype="link"/>
5028                 </fields>
5029                 <links>
5030                         <link field="fund" reltype="has_a" key="id" map="" class="acqf"/>
5031                         <link field="tag" reltype="has_a" key="id" map="" class="acqft"/>
5032                         </links>
5033                 <permacrud xmlns="http://open-ils.org/spec/opensrf/IDL/permacrud/v1">
5034                 <actions>
5035                                 <create permission="ADMIN_ACQ_FUND_TAG">
5036                                         <context link="tag" field="owner"/>
5037                                 </create>
5038                                 <retrieve permission="ADMIN_ACQ_FUND_TAG ADMIN_ACQ_FUND VIEW_FUND MANAGE_FUND">
5039                                         <context link="tag" field="owner"/>
5040                                 </retrieve>
5041                                 <update permission="ADMIN_ACQ_FUND_TAG">
5042                                         <context link="tag" field="owner"/>
5043                                 </update>
5044                                 <delete permission="ADMIN_ACQ_FUND_TAG">
5045                                         <context link="tag" field="owner"/>
5046                                 </delete>
5047                         </actions>
5048                 </permacrud>
5049         </class>
5050
5051         <!-- ********************************************************************************************************************* -->
5052
5053 </IDL>
5054
5055 <!--
5056     vim:noet:ts=4:sw=4:
5057 -->