]> git.evergreen-ils.org Git - Evergreen.git/blob - Open-ILS/src/perlmods/OpenILS/Application/Storage/Driver/Pg/dbi.pm
adding circulation rule config stuff
[Evergreen.git] / Open-ILS / src / perlmods / OpenILS / Application / Storage / Driver / Pg / dbi.pm
1 {
2         #---------------------------------------------------------------------
3         package action::survey;
4         
5         action::survey->table( 'action.survey' );
6         action::survey->sequence( 'action.survey_id_seq' );
7         
8         #---------------------------------------------------------------------
9         package action::survey_question;
10         
11         action::survey_question->table( 'action.survey_question' );
12         action::survey_question->sequence( 'action.survey_question_id_seq' );
13         
14         #---------------------------------------------------------------------
15         package action::survey_answer;
16         
17         action::survey_answer->table( 'action.survey_answer' );
18         action::survey_answer->sequence( 'action.survey_answer_id_seq' );
19         
20         #---------------------------------------------------------------------
21         package action::survey_response;
22         
23         action::survey_response->table( 'action.survey_response' );
24         action::survey_response->sequence( 'action.survey_response_id_seq' );
25         
26         #---------------------------------------------------------------------
27         package config::copy_status;
28         
29         config::standing->table( 'config.copy_status' );
30         config::standing->sequence( 'config.copy_status_id_seq' );
31
32         #---------------------------------------------------------------------
33         package config::rules::circ_duration;
34         
35         config::rules::circ_duration->table( 'config.rule_circ_duration' );
36         config::rules::circ_duration->sequence( 'config.rule_circ_duration_id_seq' );
37         
38         #---------------------------------------------------------------------
39         package config::rules::age_hold_protect;
40         
41         config::rules::age_hold_protect->table( 'config.rule_age_hold_protect' );
42         config::rules::age_hold_protect->sequence( 'config.rule_age_hold_protect_id_seq' );
43         
44         #---------------------------------------------------------------------
45         package config::rules::max_fine;
46         
47         config::rules::max_fine->table( 'config.rule_max_fine' );
48         config::rules::max_fine->sequence( 'config.rule_max_fine_id_seq' );
49         
50         #---------------------------------------------------------------------
51         package config::rules::recuring_fine;
52         
53         config::rules::recuring_fine->table( 'config.rule_recuring_fine' );
54         config::rules::recuring_fine->sequence( 'config.rule_recuring_fine_id_seq' );
55         
56         #---------------------------------------------------------------------
57         package config::net_access_level;
58         
59         config::standing->table( 'config.net_access_level' );
60         config::standing->sequence( 'config.net_access_level_id_seq' );
61         
62         #---------------------------------------------------------------------
63         package config::standing;
64         
65         config::standing->table( 'config.standing' );
66         config::standing->sequence( 'config.standing_id_seq' );
67         
68         #---------------------------------------------------------------------
69         package config::metabib_field;
70         
71         config::metabib_field->table( 'config.metabib_field' );
72         config::metabib_field->sequence( 'config.metabib_field_id_seq' );
73         
74         #---------------------------------------------------------------------
75         package config::bib_source;
76         
77         config::bib_source->table( 'config.bib_source' );
78         config::bib_source->sequence( 'config.bib_source_id_seq' );
79         
80         #---------------------------------------------------------------------
81         package config::identification_type;
82         
83         config::identification_type->table( 'config.identification_type' );
84         config::identification_type->sequence( 'config.identification_type_id_seq' );
85         
86         #---------------------------------------------------------------------
87         package asset::call_number_note;
88         
89         asset::call_number->table( 'asset.call_number_note' );
90         asset::call_number->sequence( 'asset.call_number_note_id_seq' );
91         
92         #---------------------------------------------------------------------
93         package asset::copy_note;
94         
95         asset::copy->table( 'asset.copy_note' );
96         asset::copy->sequence( 'asset.copy_note_id_seq' );
97
98         #---------------------------------------------------------------------
99         package asset::call_number;
100         
101         asset::call_number->table( 'asset.call_number' );
102         asset::call_number->sequence( 'asset.call_number_id_seq' );
103         
104         #---------------------------------------------------------------------
105         package asset::copy_location;
106         
107         asset::copy->table( 'asset.copy_location' );
108         asset::copy->sequence( 'asset.copy_location_id_seq' );
109
110         #---------------------------------------------------------------------
111         package asset::copy;
112         
113         asset::copy->table( 'asset.copy' );
114         asset::copy->sequence( 'asset.copy_id_seq' );
115
116         #---------------------------------------------------------------------
117         package asset::stat_cat;
118         
119         asset::stat_cat->table( 'asset.stat_cat' );
120         asset::stat_cat->sequence( 'asset.stat_cat_id_seq' );
121         
122         #---------------------------------------------------------------------
123         package asset::stat_cat_entry;
124         
125         asset::stat_cat_entry->table( 'asset.stat_cat_entry' );
126         asset::stat_cat_entry->sequence( 'asset.stat_cat_entry_id_seq' );
127         
128         #---------------------------------------------------------------------
129         package asset::stat_cat_entry_copy_map;
130         
131         asset::stat_cat_entry_copy_map->table( 'asset.stat_cat_entry_copy_map' );
132         asset::stat_cat_entry_copy_map->sequence( 'asset.stat_cat_entry_copy_map_id_seq' );
133         
134         #---------------------------------------------------------------------
135         package biblio::record_entry;
136         
137         biblio::record_entry->table( 'biblio.record_entry' );
138         biblio::record_entry->sequence( 'biblio.record_entry_id_seq' );
139
140         #---------------------------------------------------------------------
141         #package biblio::record_marc;
142         #
143         #biblio::record_marc->table( 'biblio.record_marc' );
144         #biblio::record_marc->sequence( 'biblio.record_marc_id_seq' );
145         #
146         #---------------------------------------------------------------------
147         package biblio::record_note;
148         
149         biblio::record_note->table( 'biblio.record_note' );
150         biblio::record_note->sequence( 'biblio.record_note_id_seq' );
151         
152         #---------------------------------------------------------------------
153         package actor::user;
154         
155         actor::user->table( 'actor.usr' );
156         actor::user->sequence( 'actor.usr_id_seq' );
157
158         #---------------------------------------------------------------------
159         package actor::user_address;
160         
161         actor::user_address->table( 'actor.usr_address' );
162         actor::user_address->sequence( 'actor.usr_address_id_seq' );
163
164         #---------------------------------------------------------------------
165         package actor::org_address;
166         
167         actor::org_address->table( 'actor.org_address' );
168         actor::org_address->sequence( 'actor.org_address_id_seq' );
169         
170         #---------------------------------------------------------------------
171         package actor::profile;
172         
173         actor::profile->table( 'actor.profile' );
174         actor::profile->sequence( 'actor.profile_id_seq' );
175         
176         #---------------------------------------------------------------------
177         package actor::org_unit_type;
178         
179         actor::org_unit_type->table( 'actor.org_unit_type' );
180         actor::org_unit_type->sequence( 'actor.org_unit_type_id_seq' );
181
182         #---------------------------------------------------------------------
183         package actor::org_unit;
184         
185         actor::org_unit->table( 'actor.org_unit' );
186         actor::org_unit->sequence( 'actor.org_unit_id_seq' );
187
188         #---------------------------------------------------------------------
189         package actor::stat_cat;
190         
191         actor::stat_cat->table( 'actor.stat_cat' );
192         actor::stat_cat->sequence( 'actor.stat_cat_id_seq' );
193         
194         #---------------------------------------------------------------------
195         package actor::stat_cat_entry;
196         
197         actor::stat_cat_entry->table( 'actor.stat_cat_entry' );
198         actor::stat_cat_entry->sequence( 'actor.stat_cat_entry_id_seq' );
199         
200         #---------------------------------------------------------------------
201         package actor::stat_cat_entry_user_map;
202         
203         actor::stat_cat_entry_user_map->table( 'actor.stat_cat_entry_copy_map' );
204         actor::stat_cat_entry_user_map->sequence( 'actor.stat_cat_entry_usr_map_id_seq' );
205         
206         #---------------------------------------------------------------------
207         package actor::card;
208         
209         actor::card->table( 'actor.card' );
210         actor::card->sequence( 'actor.card_id_seq' );
211
212         #---------------------------------------------------------------------
213
214         #-------------------------------------------------------------------------------
215         package metabib::metarecord;
216
217         metabib::metarecord->table( 'metabib.metarecord' );
218         metabib::metarecord->sequence( 'metabib.metarecord_id_seq' );
219
220         OpenILS::Application::Storage->register_method(
221                 api_name        => 'open-ils.storage.direct.metabib.metarecord.batch.create',
222                 method          => 'copy_create',
223                 api_level       => 1,
224                 'package'       => 'OpenILS::Application::Storage',
225                 cdbi            => 'metabib::metarecord',
226         );
227
228
229         #-------------------------------------------------------------------------------
230
231         #-------------------------------------------------------------------------------
232         package metabib::title_field_entry;
233
234         metabib::title_field_entry->table( 'metabib.title_field_entry' );
235         metabib::title_field_entry->sequence( 'metabib.title_field_entry_id_seq' );
236         metabib::title_field_entry->columns( 'FTS' => 'index_vector' );
237
238 #       metabib::title_field_entry->add_trigger(
239 #               before_create => \&OpenILS::Application::Storage::Driver::Pg::tsearch2_trigger
240 #       );
241 #       metabib::title_field_entry->add_trigger(
242 #               before_update => \&OpenILS::Application::Storage::Driver::Pg::tsearch2_trigger
243 #       );
244
245         OpenILS::Application::Storage->register_method(
246                 api_name        => 'open-ils.storage.direct.metabib.title_field_entry.batch.create',
247                 method          => 'copy_create',
248                 api_level       => 1,
249                 'package'       => 'OpenILS::Application::Storage',
250                 cdbi            => 'metabib::title_field_entry',
251         );
252
253         #-------------------------------------------------------------------------------
254
255         #-------------------------------------------------------------------------------
256         package metabib::author_field_entry;
257
258         metabib::author_field_entry->table( 'metabib.author_field_entry' );
259         metabib::author_field_entry->sequence( 'metabib.author_field_entry_id_seq' );
260         metabib::author_field_entry->columns( 'FTS' => 'index_vector' );
261
262         OpenILS::Application::Storage->register_method(
263                 api_name        => 'open-ils.storage.direct.metabib.author_field_entry.batch.create',
264                 method          => 'copy_create',
265                 api_level       => 1,
266                 'package'       => 'OpenILS::Application::Storage',
267                 cdbi            => 'metabib::author_field_entry',
268         );
269
270         #-------------------------------------------------------------------------------
271
272         #-------------------------------------------------------------------------------
273         package metabib::subject_field_entry;
274
275         metabib::subject_field_entry->table( 'metabib.subject_field_entry' );
276         metabib::subject_field_entry->sequence( 'metabib.subject_field_entry_id_seq' );
277         metabib::subject_field_entry->columns( 'FTS' => 'index_vector' );
278
279         OpenILS::Application::Storage->register_method(
280                 api_name        => 'open-ils.storage.direct.metabib.subject_field_entry.batch.create',
281                 method          => 'copy_create',
282                 api_level       => 1,
283                 'package'       => 'OpenILS::Application::Storage',
284                 cdbi            => 'metabib::subject_field_entry',
285         );
286
287         #-------------------------------------------------------------------------------
288
289         #-------------------------------------------------------------------------------
290         package metabib::keyword_field_entry;
291
292         metabib::keyword_field_entry->table( 'metabib.keyword_field_entry' );
293         metabib::keyword_field_entry->sequence( 'metabib.keyword_field_entry_id_seq' );
294         metabib::keyword_field_entry->columns( 'FTS' => 'index_vector' );
295
296         OpenILS::Application::Storage->register_method(
297                 api_name        => 'open-ils.storage.direct.metabib.keyword_field_entry.batch.create',
298                 method          => 'copy_create',
299                 api_level       => 1,
300                 'package'       => 'OpenILS::Application::Storage',
301                 cdbi            => 'metabib::keyword_field_entry',
302         );
303
304         #-------------------------------------------------------------------------------
305
306         #-------------------------------------------------------------------------------
307         #package metabib::title_field_entry_source_map;
308
309         #metabib::title_field_entry_source_map->table( 'metabib.title_field_entry_source_map' );
310
311         #-------------------------------------------------------------------------------
312
313         #-------------------------------------------------------------------------------
314         #package metabib::author_field_entry_source_map;
315
316         #metabib::author_field_entry_source_map->table( 'metabib.author_field_entry_source_map' );
317
318         #-------------------------------------------------------------------------------
319
320         #-------------------------------------------------------------------------------
321         #package metabib::subject_field_entry_source_map;
322
323         #metabib::subject_field_entry_source_map->table( 'metabib.subject_field_entry_source_map' );
324
325         #-------------------------------------------------------------------------------
326
327         #-------------------------------------------------------------------------------
328         #package metabib::keyword_field_entry_source_map;
329
330         #metabib::keyword_field_entry_source_map->table( 'metabib.keyword_field_entry_source_map' );
331
332         #-------------------------------------------------------------------------------
333
334         #-------------------------------------------------------------------------------
335         package metabib::metarecord_source_map;
336
337         metabib::metarecord_source_map->table( 'metabib.metarecord_source_map' );
338         OpenILS::Application::Storage->register_method(
339                 api_name        => 'open-ils.storage.direct.metabib.metarecord_source_map.batch.create',
340                 method          => 'copy_create',
341                 api_level       => 1,
342                 'package'       => 'OpenILS::Application::Storage',
343                 cdbi            => 'metabib::metarecord_source_map',
344         );
345
346
347         #-------------------------------------------------------------------------------
348         package metabib::record_descriptor;
349
350         metabib::record_descriptor->table( 'metabib.rec_descriptor' );
351         metabib::record_descriptor->sequence( 'metabib.rec_descriptor_id_seq' );
352
353         OpenILS::Application::Storage->register_method(
354                 api_name        => 'open-ils.storage.direct.metabib.record_descriptor.batch.create',
355                 method          => 'copy_create',
356                 api_level       => 1,
357                 'package'       => 'OpenILS::Application::Storage',
358                 cdbi            => 'metabib::record_descriptor',
359         );
360
361         #-------------------------------------------------------------------------------
362
363
364         #-------------------------------------------------------------------------------
365         package metabib::full_rec;
366
367         metabib::full_rec->table( 'metabib.full_rec' );
368         metabib::full_rec->sequence( 'metabib.full_rec_id_seq' );
369         metabib::full_rec->columns( 'FTS' => 'index_vector' );
370
371         OpenILS::Application::Storage->register_method(
372                 api_name        => 'open-ils.storage.direct.metabib.full_rec.batch.create',
373                 method          => 'copy_create',
374                 api_level       => 1,
375                 'package'       => 'OpenILS::Application::Storage',
376                 cdbi            => 'metabib::full_rec',
377         );
378
379
380         #-------------------------------------------------------------------------------
381 }
382
383 1;