From: dbs Date: Mon, 16 Nov 2009 14:46:19 +0000 (+0000) Subject: Correct long-standing, wide-spread "recurance" and "recuring" typos. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=c1b08233f4e52bcaad00f01ffc30f8d85619f612;p=evergreen%2Fbjwebb.git Correct long-standing, wide-spread "recurance" and "recuring" typos. We'll miss you - *sniff* git-svn-id: svn://svn.open-ils.org/ILS/trunk@14920 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/examples/fm_IDL.xml b/Open-ILS/examples/fm_IDL.xml index f7baeb5c1..4c2ef6854 100644 --- a/Open-ILS/examples/fm_IDL.xml +++ b/Open-ILS/examples/fm_IDL.xml @@ -2151,8 +2151,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + @@ -2184,7 +2184,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + @@ -2211,8 +2211,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + @@ -2247,7 +2247,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + @@ -2275,8 +2275,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + @@ -2315,7 +2315,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + @@ -3268,8 +3268,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + @@ -3283,7 +3283,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + @@ -3298,22 +3298,22 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + - + - + - - + + @@ -4742,7 +4742,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + @@ -5360,8 +5360,8 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - - + + @@ -5388,7 +5388,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA - + diff --git a/Open-ILS/src/cgi-bin/circ-rules.cgi b/Open-ILS/src/cgi-bin/circ-rules.cgi index f67687946..d65c39fb5 100755 --- a/Open-ILS/src/cgi-bin/circ-rules.cgi +++ b/Open-ILS/src/cgi-bin/circ-rules.cgi @@ -82,10 +82,10 @@ my %fine_cols = ( high => "High", normal => "Normal", low => "Low", - recurance_interval => "Interval", + recurrence_interval => "Interval", ); -my @fine_display_order = ( qw/name recurance_interval normal high low/ ); +my @fine_display_order = ( qw/name recurrence_interval normal high low/ ); my %age_cols = ( name => "Name", @@ -120,13 +120,13 @@ if (my $action = $cgi->param('action')) { { map { ($_ => $cgi->param($_)) } keys %dur_cols } ); } - } elsif ($form eq 'recuring_fine') { + } elsif ($form eq 'recurring_fine') { if ($action eq 'Remove Selected') { for my $id ( ($cgi->param('remove_me')) ) { - config::rules::recuring_fine->retrieve($id)->delete; + config::rules::recurring_fine->retrieve($id)->delete; } } elsif ( $action eq 'Add New' ) { - config::rules::recuring_fine->create( + config::rules::recurring_fine->create( { map { ($_ => $cgi->param($_)) } keys %fine_cols } ); } @@ -196,11 +196,11 @@ if (my $action = $cgi->param('action')) { { #----------------------------------------------------------------------- - # Recuring Fine form + # Recurring Fine form #----------------------------------------------------------------------- print "
". - "". - "

Recuring Fine Levels

". + "". + "

Recurring Fine Levels

". "\n"; for my $col ( @fine_display_order ) { @@ -209,7 +209,7 @@ if (my $action = $cgi->param('action')) { print "\n"; for my $col ( @fine_display_order ) { print td($row->$col); diff --git a/Open-ILS/src/extras/ils_events.xml b/Open-ILS/src/extras/ils_events.xml index 4f189fb18..898afcb87 100644 --- a/Open-ILS/src/extras/ils_events.xml +++ b/Open-ILS/src/extras/ils_events.xml @@ -464,8 +464,8 @@ The requested metabib_subject_field_entry was not found - - The requested config_rules_recuring_fine was not found + + The requested config_rules_recurring_fine was not found The requested money_check_payment was not found diff --git a/Open-ILS/src/perlmods/OpenILS/Application/AppUtils.pm b/Open-ILS/src/perlmods/OpenILS/Application/AppUtils.pm index 082b3d2b6..f3b7a7ce4 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/AppUtils.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/AppUtils.pm @@ -812,9 +812,9 @@ sub fetch_recurring_fine_by_name { my( $obj, $evt ); $obj = $self->simplereq( 'open-ils.cstore', - 'open-ils.cstore.direct.config.rules.recuring_fine.search.atomic', { name => $name } ); + 'open-ils.cstore.direct.config.rules.recurring_fine.search.atomic', { name => $name } ); $obj = $obj->[0]; - $evt = OpenILS::Event->new('CONFIG_RULES_RECURING_FINE_NOT_FOUND') unless $obj; + $evt = OpenILS::Event->new('CONFIG_RULES_RECURRING_FINE_NOT_FOUND') unless $obj; return ($obj, $evt); } diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm b/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm index 163ce377b..10be02cd5 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Circ.pm @@ -897,7 +897,7 @@ sub copy_details { 'checkin_workstation', 'duration_rule', 'max_fine_rule', - 'recuring_fine_rule' + 'recurring_fine_rule' ] }, order_by => { circ => 'xact_start desc' }, diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm index 4c906603f..a228cb011 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm @@ -984,7 +984,7 @@ sub get_circ_policy { recurring_fine_rule => $recurring_fine_rule->name, max_fine_rule => $max_fine_rule->name, max_fine => $self->get_max_fine_amount($max_fine_rule), - fine_interval => $recurring_fine_rule->recurance_interval, + fine_interval => $recurring_fine_rule->recurrance_interval, renewal_remaining => $duration_rule->max_renewals }; @@ -1540,19 +1540,19 @@ sub build_checkout_circ_object { "with duration=$dname, maxfine=$mname, recurring=$rname"); $circ->duration($policy->{duration}); - $circ->recuring_fine($policy->{recurring_fine}); + $circ->recurring_fine($policy->{recurring_fine}); $circ->duration_rule($duration->name); - $circ->recuring_fine_rule($recurring->name); + $circ->recurring_fine_rule($recurring->name); $circ->max_fine_rule($max->name); $circ->max_fine($policy->{max_fine}); - $circ->fine_interval($recurring->recurance_interval); + $circ->fine_interval($recurring->recurrance_interval); $circ->renewal_remaining($duration->max_renewals); } else { $logger->info("circulator: copy found with an unlimited circ duration"); $circ->duration_rule(OILS_UNLIMITED_CIRC_DURATION); - $circ->recuring_fine_rule(OILS_UNLIMITED_CIRC_DURATION); + $circ->recurring_fine_rule(OILS_UNLIMITED_CIRC_DURATION); $circ->max_fine_rule(OILS_UNLIMITED_CIRC_DURATION); $circ->renewal_remaining(0); } diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/action.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/action.pm index 3cbfc7ba0..8802e5781 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/action.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/action.pm @@ -64,7 +64,7 @@ __PACKAGE__->table('action_circulation'); __PACKAGE__->columns(Primary => 'id'); __PACKAGE__->columns(Essential => qw/xact_start usr target_copy circ_lib duration duration_rule renewal_remaining - recuring_fine_rule recuring_fine stop_fines + recurring_fine_rule recurring_fine stop_fines max_fine max_fine_rule fine_interval stop_fines xact_finish due_date opac_renewal checkin_staff circ_staff circ_lib checkin_lib @@ -79,7 +79,7 @@ __PACKAGE__->table('action_open_circulation'); __PACKAGE__->columns(Primary => 'id'); __PACKAGE__->columns(Essential => qw/xact_start usr target_copy circ_lib duration duration_rule renewal_remaining - recuring_fine_rule recuring_fine stop_fines + recurring_fine_rule recurring_fine stop_fines max_fine max_fine_rule fine_interval stop_fines xact_finish due_date opac_renewal checkin_staff circ_staff circ_lib checkin_lib diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/config.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/config.pm index 5e8845523..bde437298 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/config.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/CDBI/config.pm @@ -55,11 +55,11 @@ __PACKAGE__->columns(Primary => 'id'); __PACKAGE__->columns(Essential => qw/name amount is_percent/); #------------------------------------------------------------------------------- -package config::rules::recuring_fine; +package config::rules::recurring_fine; use base qw/config/; -__PACKAGE__->table('config_rule_recuring_fine'); +__PACKAGE__->table('config_rule_recurring_fine'); __PACKAGE__->columns(Primary => 'id'); -__PACKAGE__->columns(Essential => qw/name high normal low recurance_interval/); +__PACKAGE__->columns(Essential => qw/name high normal low recurrence_interval/); #------------------------------------------------------------------------------- package config::rules::age_hold_protect; diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Driver/Pg/dbi.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Driver/Pg/dbi.pm index 2da5d7c94..0620bd7fa 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Driver/Pg/dbi.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Driver/Pg/dbi.pm @@ -238,10 +238,10 @@ config::rules::max_fine->sequence( 'config.rule_max_fine_id_seq' ); #--------------------------------------------------------------------- - package config::rules::recuring_fine; + package config::rules::recurring_fine; - config::rules::recuring_fine->table( 'config.rule_recuring_fine' ); - config::rules::recuring_fine->sequence( 'config.rule_recuring_fine_id_seq' ); + config::rules::recurring_fine->table( 'config.rule_recurring_fine' ); + config::rules::recurring_fine->sequence( 'config.rule_recurring_fine_id_seq' ); #--------------------------------------------------------------------- package config::net_access_level; diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm index f58ff7b07..82eb65e32 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm @@ -755,7 +755,7 @@ sub generate_fines { $client->respond( "\t$pending_fine_count pending fine(s)\n" ); - my $recuring_fine = int($c->recuring_fine * 100); + my $recurring_fine = int($c->recurring_fine * 100); my $max_fine = int($c->max_fine * 100); my ($latest_billing_ts, $latest_amount) = ('',0); @@ -788,8 +788,8 @@ sub generate_fines { ); next if (@cl); - $current_fine_total += $recuring_fine; - $latest_amount += $recuring_fine; + $current_fine_total += $recurring_fine; + $latest_amount += $recurring_fine; $latest_billing_ts = $timestamptz; money::billing->create( @@ -797,7 +797,7 @@ sub generate_fines { note => "System Generated Overdue Fine", billing_type => "Overdue materials", btype => 1, - amount => sprintf('%0.2f', $recuring_fine/100), + amount => sprintf('%0.2f', $recurring_fine/100), billing_ts => $timestamptz, } ); diff --git a/Open-ILS/src/reporter/clark-kent.pl b/Open-ILS/src/reporter/clark-kent.pl index 5e87cb247..9800a9ce7 100755 --- a/Open-ILS/src/reporter/clark-kent.pl +++ b/Open-ILS/src/reporter/clark-kent.pl @@ -284,7 +284,7 @@ for my $r ( @reports ) { $r->{folder}, $r->{runner}, $r->{run_time}, - $r->{report}->{recurance}, + $r->{report}->{recurrence}, $r->{email}, $r->{csv_format}, $r->{excel_format}, diff --git a/Open-ILS/src/sql/Pg/002.schema.config.sql b/Open-ILS/src/sql/Pg/002.schema.config.sql index 2475548f7..22099db0c 100644 --- a/Open-ILS/src/sql/Pg/002.schema.config.sql +++ b/Open-ILS/src/sql/Pg/002.schema.config.sql @@ -51,7 +51,7 @@ CREATE TABLE config.upgrade_log ( install_date TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW() ); -INSERT INTO config.upgrade_log (version) VALUES ('0084'); -- senator +INSERT INTO config.upgrade_log (version) VALUES ('0085'); -- dbs CREATE TABLE config.bib_source ( id SERIAL PRIMARY KEY, @@ -309,15 +309,15 @@ COMMENT ON TABLE config.rule_max_fine IS $$ */ $$; -CREATE TABLE config.rule_recuring_fine ( +CREATE TABLE config.rule_recurring_fine ( id SERIAL PRIMARY KEY, name TEXT NOT NULL UNIQUE CHECK ( name ~ E'^\\w+$' ), high NUMERIC(6,2) NOT NULL, normal NUMERIC(6,2) NOT NULL, low NUMERIC(6,2) NOT NULL, - recurance_interval INTERVAL NOT NULL DEFAULT '1 day'::INTERVAL + recurrence_interval INTERVAL NOT NULL DEFAULT '1 day'::INTERVAL ); -COMMENT ON TABLE config.rule_recuring_fine IS $$ +COMMENT ON TABLE config.rule_recurring_fine IS $$ /* * Copyright (C) 2005 Georgia Public Library Service * Mike Rylander @@ -325,7 +325,7 @@ COMMENT ON TABLE config.rule_recuring_fine IS $$ * Circulation Recurring Fine rules * * Each circulation is given a recurring fine amount based on one of - * these rules. The recurance_interval should not be any shorter + * these rules. The recurrence_interval should not be any shorter * than the interval between runs of the fine_processor.pl script * (which is run from CRON), or you could miss fines. * diff --git a/Open-ILS/src/sql/Pg/090.schema.action.sql b/Open-ILS/src/sql/Pg/090.schema.action.sql index 315118814..302fdedce 100644 --- a/Open-ILS/src/sql/Pg/090.schema.action.sql +++ b/Open-ILS/src/sql/Pg/090.schema.action.sql @@ -115,13 +115,13 @@ CREATE TABLE action.circulation ( create_time TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT NOW(), duration INTERVAL, -- derived from "circ duration" rule fine_interval INTERVAL NOT NULL DEFAULT '1 day'::INTERVAL, -- derived from "circ fine" rule - recuring_fine NUMERIC(6,2), -- derived from "circ fine" rule + recurring_fine NUMERIC(6,2), -- derived from "circ fine" rule max_fine NUMERIC(6,2), -- derived from "max fine" rule phone_renewal BOOL NOT NULL DEFAULT FALSE, desk_renewal BOOL NOT NULL DEFAULT FALSE, opac_renewal BOOL NOT NULL DEFAULT FALSE, duration_rule TEXT NOT NULL, -- name of "circ duration" rule - recuring_fine_rule TEXT NOT NULL, -- name of "circ fine" rule + recurring_fine_rule TEXT NOT NULL, -- name of "circ fine" rule max_fine_rule TEXT NOT NULL, -- name of "max fine" rule stop_fines TEXT CHECK (stop_fines IN ( 'CHECKIN','CLAIMSRETURNED','LOST','MAXFINES','RENEW','LONGOVERDUE','CLAIMSNEVERCHECKEDOUT')), @@ -190,8 +190,8 @@ CREATE OR REPLACE VIEW action.all_circulation AS SELECT id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, - stop_fines_time, checkin_time, create_time, duration, fine_interval, recuring_fine, - max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recuring_fine_rule, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ FROM action.aged_circulation UNION ALL @@ -199,8 +199,8 @@ CREATE OR REPLACE VIEW action.all_circulation AS cp.call_number AS copy_call_number, cp.location AS copy_location, cn.owning_lib AS copy_owning_lib, cp.circ_lib AS copy_circ_lib, cn.record AS copy_bib_record, circ.xact_start, circ.xact_finish, circ.target_copy, circ.circ_lib, circ.circ_staff, circ.checkin_staff, circ.checkin_lib, circ.renewal_remaining, circ.due_date, circ.stop_fines_time, circ.checkin_time, circ.create_time, circ.duration, - circ.fine_interval, circ.recuring_fine, circ.max_fine, circ.phone_renewal, circ.desk_renewal, circ.opac_renewal, circ.duration_rule, - circ.recuring_fine_rule, circ.max_fine_rule, circ.stop_fines, circ.workstation, circ.checkin_workstation, circ.checkin_scan_time, + circ.fine_interval, circ.recurring_fine, circ.max_fine, circ.phone_renewal, circ.desk_renewal, circ.opac_renewal, circ.duration_rule, + circ.recurring_fine_rule, circ.max_fine_rule, circ.stop_fines, circ.workstation, circ.checkin_workstation, circ.checkin_scan_time, circ.parent_circ FROM action.circulation circ JOIN asset.copy cp ON (circ.target_copy = cp.id) @@ -232,15 +232,15 @@ BEGIN (id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, - stop_fines_time, checkin_time, create_time, duration, fine_interval, recuring_fine, - max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recuring_fine_rule, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ) SELECT id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, - stop_fines_time, checkin_time, create_time, duration, fine_interval, recuring_fine, - max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recuring_fine_rule, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ FROM action.all_circulation WHERE id = OLD.id; diff --git a/Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql b/Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql index a0c618358..82726048a 100644 --- a/Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql +++ b/Open-ILS/src/sql/Pg/1.4.0.5-1.6.0.0-upgrade-db.sql @@ -1124,7 +1124,7 @@ ALTER TABLE action.hold_request ADD COLUMN cancel_note TEXT; ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN juvenile_flag BOOL; ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN circulate BOOL NOT NULL DEFAULT TRUE; ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN duration_rule INT REFERENCES config.rule_circ_duration (id) DEFERRABLE INITIALLY DEFERRED; -ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN recurring_fine_rule INT REFERENCES config.rule_recuring_fine (id) DEFERRABLE INITIALLY DEFERRED; +ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN recurring_fine_rule INT REFERENCES config.rule_recurring_fine (id) DEFERRABLE INITIALLY DEFERRED; ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN max_fine_rule INT REFERENCES config.rule_max_fine (id) DEFERRABLE INITIALLY DEFERRED; ALTER TABLE config.circ_matrix_matchpoint ADD COLUMN script_test TEXT; diff --git a/Open-ILS/src/sql/Pg/100.circ_matrix.sql b/Open-ILS/src/sql/Pg/100.circ_matrix.sql index 08abe3932..2e79c9829 100644 --- a/Open-ILS/src/sql/Pg/100.circ_matrix.sql +++ b/Open-ILS/src/sql/Pg/100.circ_matrix.sql @@ -111,7 +111,7 @@ CREATE TABLE config.circ_matrix_matchpoint ( usr_age_upper_bound INTERVAL, circulate BOOL NOT NULL DEFAULT TRUE, -- Hard "can't circ" flag requiring an override duration_rule INT NOT NULL REFERENCES config.rule_circ_duration (id) DEFERRABLE INITIALLY DEFERRED, - recurring_fine_rule INT NOT NULL REFERENCES config.rule_recuring_fine (id) DEFERRABLE INITIALLY DEFERRED, + recurring_fine_rule INT NOT NULL REFERENCES config.rule_recurring_fine (id) DEFERRABLE INITIALLY DEFERRED, max_fine_rule INT NOT NULL REFERENCES config.rule_max_fine (id) DEFERRABLE INITIALLY DEFERRED, script_test TEXT, -- javascript source total_copy_hold_ratio FLOAT, diff --git a/Open-ILS/src/sql/Pg/950.data.seed-values.sql b/Open-ILS/src/sql/Pg/950.data.seed-values.sql index a0752f0eb..6c9abf2f9 100644 --- a/Open-ILS/src/sql/Pg/950.data.seed-values.sql +++ b/Open-ILS/src/sql/Pg/950.data.seed-values.sql @@ -97,13 +97,13 @@ INSERT INTO config.rule_max_fine VALUES (7, oils_i18n_gettext(7, 'overdue_equip_max', 'crmf', 'name'), 100.00); SELECT SETVAL('config.rule_max_fine_id_seq'::TEXT, 100); -INSERT INTO config.rule_recuring_fine VALUES +INSERT INTO config.rule_recurring_fine VALUES (1, oils_i18n_gettext(1, 'default', 'crrf', 'name'), 0.50, 0.10, 0.05, '1 day'); -INSERT INTO config.rule_recuring_fine VALUES +INSERT INTO config.rule_recurring_fine VALUES (2, oils_i18n_gettext(2, '10_cent_per_day', 'crrf', 'name'), 0.50, 0.10, 0.10, '1 day'); -INSERT INTO config.rule_recuring_fine VALUES +INSERT INTO config.rule_recurring_fine VALUES (3, oils_i18n_gettext(3, '50_cent_per_day', 'crrf', 'name'), 0.50, 0.50, 0.50, '1 day'); -SELECT SETVAL('config.rule_recuring_fine_id_seq'::TEXT, 100); +SELECT SETVAL('config.rule_recurring_fine_id_seq'::TEXT, 100); INSERT INTO config.rule_age_hold_protect VALUES (1, oils_i18n_gettext(1, '3month', 'crahp', 'name'), '3 months', 0); diff --git a/Open-ILS/src/sql/Pg/reporter-schema.sql b/Open-ILS/src/sql/Pg/reporter-schema.sql index 2790e02b6..5e16c2c59 100644 --- a/Open-ILS/src/sql/Pg/reporter-schema.sql +++ b/Open-ILS/src/sql/Pg/reporter-schema.sql @@ -84,7 +84,7 @@ CREATE TABLE reporter.report ( data TEXT NOT NULL, folder INT NOT NULL REFERENCES reporter.report_folder (id) DEFERRABLE INITIALLY DEFERRED, recur BOOL NOT NULL DEFAULT FALSE, - recurance INTERVAL + recurrence INTERVAL ); CREATE INDEX rpt_rpt_owner_idx ON reporter.report (owner); CREATE INDEX rpt_rpt_fldr_idx ON reporter.report (folder); diff --git a/Open-ILS/src/sql/Pg/stats/circ_stats.sql b/Open-ILS/src/sql/Pg/stats/circ_stats.sql index 0948dabde..a0764ab3a 100644 --- a/Open-ILS/src/sql/Pg/stats/circ_stats.sql +++ b/Open-ILS/src/sql/Pg/stats/circ_stats.sql @@ -20,13 +20,13 @@ CREATE TABLE circ_stats.circulation ( checkin_time TIMESTAMP WITH TIME ZONE, duration INTERVAL NOT NULL, fine_interval INTERVAL NOT NULL, - recuring_fine NUMERIC(6,2) NOT NULL, + recurring_fine NUMERIC(6,2) NOT NULL, max_fine NUMERIC(6,2) NOT NULL, opac_renewal BOOL NOT NULL, phone_renewal BOOL NOT NULL, desk_renewal BOOL NOT NULL, duration_rule TEXT NOT NULL, - recuring_fine_rule TEXT NOT NULL, + recurring_fine_rule TEXT NOT NULL, max_fine_rule TEXT NOT NULL, stop_fines TEXT ) WITHOUT OIDS; @@ -101,13 +101,13 @@ CREATE TABLE circ_stats.circ_dim ( circ_desk_renewal BOOL, circ_phone_renewal BOOL, circ_self_checkout BOOL, - circ_recuring_fine NUMERIC(6,2) NOT NULL, + circ_recurring_fine NUMERIC(6,2) NOT NULL, circ_max_fine NUMERIC(6,2) NOT NULL, circ_fine_interval INTERVAL NOT NULL, circ_duration INTERVAL NOT NULL, circ_due_date TIMESTAMP WITH TIME ZONE NOT NULL, circ_duration_rule TEXT NOT NULL, - circ_recuring_fine_rule TEXT NOT NULL, + circ_recurring_fine_rule TEXT NOT NULL, circ_max_fine_rule TEXT NOT NULL, circ_stop_fines TEXT ) WITHOUT OIDS; @@ -194,13 +194,13 @@ CREATE OR REPLACE VIEW circ_stats.checkout_full_view AS circ_staff, circ_opac_renewal, circ_self_checkout, - circ_recuring_fine, + circ_recurring_fine, circ_max_fine, circ_fine_interval, circ_duration, circ_due_date, circ_duration_rule, - circ_recuring_fine_rule, + circ_recurring_fine_rule, circ_max_fine_rule, circ_stop_fines, @@ -250,13 +250,13 @@ CREATE OR REPLACE VIEW circ_stats.checkin_full_view AS circ_staff, circ_opac_renewal, circ_self_checkout, - circ_recuring_fine, + circ_recurring_fine, circ_max_fine, circ_fine_interval, circ_duration, circ_due_date, circ_duration_rule, - circ_recuring_fine_rule, + circ_recurring_fine_rule, circ_max_fine_rule, circ_stop_fines, @@ -306,13 +306,13 @@ CREATE OR REPLACE VIEW circ_stats.renewal_full_view AS circ_staff, circ_opac_renewal, circ_self_checkout, - circ_recuring_fine, + circ_recurring_fine, circ_max_fine, circ_fine_interval, circ_duration, circ_due_date, circ_duration_rule, - circ_recuring_fine_rule, + circ_recurring_fine_rule, circ_max_fine_rule, circ_stop_fines, diff --git a/Open-ILS/src/sql/Pg/upgrade/0085.schema.config.recuring_fine.sql b/Open-ILS/src/sql/Pg/upgrade/0085.schema.config.recuring_fine.sql new file mode 100644 index 000000000..5e5a7ffa0 --- /dev/null +++ b/Open-ILS/src/sql/Pg/upgrade/0085.schema.config.recuring_fine.sql @@ -0,0 +1,121 @@ +-- Correct the long-standing "recuring" (recurring) and "recurance" (recurrence) typos + +BEGIN; + +INSERT INTO config.upgrade_log (version) VALUES ('0085'); -- dbs + +ALTER TABLE config.rule_recuring_fine RENAME TO rule_recurring_fine; +ALTER TABLE config.rule_recurring_fine RENAME COLUMN recurance_interval TO recurrence_interval; + +ALTER TABLE action.circulation RENAME COLUMN recuring_fine TO recurring_fine; +ALTER TABLE action.circulation RENAME COLUMN recuring_fine_rule TO recurring_fine_rule; + +ALTER TABLE action.aged_circulation RENAME COLUMN recuring_fine TO recurring_fine; +ALTER TABLE action.aged_circulation RENAME COLUMN recuring_fine_rule TO recurring_fine_rule; + +-- Might as well keep the comment in sync as well +COMMENT ON TABLE config.rule_recurring_fine IS $$ +/* + * Copyright (C) 2005 Georgia Public Library Service + * Mike Rylander + * + * Circulation Recurring Fine rules + * + * Each circulation is given a recurring fine amount based on one of + * these rules. The recurrence_interval should not be any shorter + * than the interval between runs of the fine_processor.pl script + * (which is run from CRON), or you could miss fines. + * + * + * **** + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ +$$; + +ALTER TABLE reporter.report RENAME COLUMN recurance TO recurrence; + +-- You would think that CREATE OR REPLACE would be enough, but in testing +-- PostgreSQL complained about renaming the columns in the view. So we +-- drop the view first. +DROP VIEW action.all_circulation; + +-- Now we can recreate the view successfully +CREATE OR REPLACE VIEW action.all_circulation AS + SELECT id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, + copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, + circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, + max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ + FROM action.aged_circulation + UNION ALL + SELECT DISTINCT circ.id,COALESCE(a.post_code,b.post_code) AS usr_post_code, p.home_ou AS usr_home_ou, p.profile AS usr_profile, EXTRACT(YEAR FROM p.dob)::INT AS usr_birth_year, + cp.call_number AS copy_call_number, cp.location AS copy_location, cn.owning_lib AS copy_owning_lib, cp.circ_lib AS copy_circ_lib, + cn.record AS copy_bib_record, circ.xact_start, circ.xact_finish, circ.target_copy, circ.circ_lib, circ.circ_staff, circ.checkin_staff, + circ.checkin_lib, circ.renewal_remaining, circ.due_date, circ.stop_fines_time, circ.checkin_time, circ.create_time, circ.duration, + circ.fine_interval, circ.recurring_fine, circ.max_fine, circ.phone_renewal, circ.desk_renewal, circ.opac_renewal, circ.duration_rule, + circ.recurring_fine_rule, circ.max_fine_rule, circ.stop_fines, circ.workstation, circ.checkin_workstation, circ.checkin_scan_time, + circ.parent_circ + FROM action.circulation circ + JOIN asset.copy cp ON (circ.target_copy = cp.id) + JOIN asset.call_number cn ON (cp.call_number = cn.id) + JOIN actor.usr p ON (circ.usr = p.id) + LEFT JOIN actor.usr_address a ON (p.mailing_address = a.id) + LEFT JOIN actor.usr_address b ON (p.billing_address = a.id); + +CREATE OR REPLACE FUNCTION action.age_circ_on_delete () RETURNS TRIGGER AS $$ +DECLARE +found char := 'N'; +BEGIN + + -- If there are any renewals for this circulation, don't archive or delete + -- it yet. We'll do so later, when we archive and delete the renewals. + + SELECT 'Y' INTO found + FROM action.circulation + WHERE parent_circ = OLD.id + LIMIT 1; + + IF found = 'Y' THEN + RETURN NULL; -- don't delete + END IF; + + -- Archive a copy of the old row to action.aged_circulation + + INSERT INTO action.aged_circulation + (id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, + copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, + circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, + max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ) + SELECT + id,usr_post_code, usr_home_ou, usr_profile, usr_birth_year, copy_call_number, copy_location, + copy_owning_lib, copy_circ_lib, copy_bib_record, xact_start, xact_finish, target_copy, + circ_lib, circ_staff, checkin_staff, checkin_lib, renewal_remaining, due_date, + stop_fines_time, checkin_time, create_time, duration, fine_interval, recurring_fine, + max_fine, phone_renewal, desk_renewal, opac_renewal, duration_rule, recurring_fine_rule, + max_fine_rule, stop_fines, workstation, checkin_workstation, checkin_scan_time, parent_circ + FROM action.all_circulation WHERE id = OLD.id; + + RETURN OLD; +END; +$$ LANGUAGE 'plpgsql'; + +-- Get the permissions right +UPDATE permission.perm_list SET code = 'ADMIN_RECURRING_FINE_RULE' WHERE code = 'ADMIN_RECURING_FINE_RULE'; + +-- Let's not break existing reports +UPDATE reporter.template SET data = REGEXP_REPLACE(data, E'^(.*)recuring(.*)$', E'\\1recurring\\2') WHERE data LIKE '%recuring%'; +UPDATE reporter.template SET data = REGEXP_REPLACE(data, E'^(.*)recurance(.*)$', E'\\1recurrence\\2') WHERE data LIKE '%recurance%'; + +COMMIT; diff --git a/Open-ILS/src/support-scripts/test-scripts/indb_circ.pl b/Open-ILS/src/support-scripts/test-scripts/indb_circ.pl index ae1b8d676..55bc54669 100755 --- a/Open-ILS/src/support-scripts/test-scripts/indb_circ.pl +++ b/Open-ILS/src/support-scripts/test-scripts/indb_circ.pl @@ -78,7 +78,7 @@ if($cp->fine_level == 1) { print "Duration [".$rule_set->duration_rule->name."] = $dur\n"; print "Recurring fines [".$rule_set->recurring_fine_rule->name."; interval='". - $rule_set->recurring_fine_rule->recurance_interval."'] = \$$recf\n"; + $rule_set->recurring_fine_rule->recurrence_interval."'] = \$$recf\n"; print "Max fine [".$rule_set->max_fine_rule->name."] = \$".$rule_set->max_fine_rule->amount."\n"; print "took: $rundur\n"; diff --git a/Open-ILS/web/opac/common/js/fm_table_conf.js b/Open-ILS/web/opac/common/js/fm_table_conf.js index 9153b5ac6..646d48555 100644 --- a/Open-ILS/web/opac/common/js/fm_table_conf.js +++ b/Open-ILS/web/opac/common/js/fm_table_conf.js @@ -96,7 +96,7 @@ var FM_TABLE_DISPLAY = { 'template', 'create_time', 'recur', - 'recurance', + 'recurrence', 'owner', ] }, diff --git a/Open-ILS/web/reports/oils_rpt_report_editor.js b/Open-ILS/web/reports/oils_rpt_report_editor.js index b613e29a8..ed9d56478 100644 --- a/Open-ILS/web/reports/oils_rpt_report_editor.js +++ b/Open-ILS/web/reports/oils_rpt_report_editor.js @@ -120,7 +120,7 @@ oilsRptReportEditor.prototype.save = function() { report.name( DOM.oils_rpt_report_editor_name.value ); report.description( DOM.oils_rpt_report_editor_desc.value ); report.recur(this.paramEditor.recur()); - report.recurance(this.paramEditor.recurInterval()); + report.recurrence(this.paramEditor.recurInterval()); /* collect the param data */ diff --git a/Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.js b/Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.js index d6ba72a36..2b4f29a29 100644 --- a/Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.js +++ b/Open-ILS/xul/staff_client/server/circ/alternate_copy_summary.js @@ -279,8 +279,8 @@ function load_item() { set("max_fine_rule", ''); set("opac_renewal", ''); set("phone_renewal", ''); - set("recuring_fine", ''); - set("recuring_fine_rule", ''); + set("recurring_fine", ''); + set("recurring_fine_rule", ''); set("renewal_remaining", ''); set("stop_fines", ''); set("stop_fines_time", ''); @@ -320,8 +320,8 @@ function load_item() { set("opac_renewal", details.circ.opac_renewal()); set("phone_renewal", details.circ.phone_renewal()); set("renewal_type", renewal_composite_kludge(details.circ)); - set("recuring_fine", details.circ.recuring_fine()); - set("recuring_fine_rule", details.circ.recuring_fine_rule()); + set("recurring_fine", details.circ.recurring_fine()); + set("recurring_fine_rule", details.circ.recurring_fine_rule()); set("renewal_remaining", details.circ.renewal_remaining()); set("stop_fines", details.circ.stop_fines()); set("stop_fines_time", details.circ.stop_fines_time()); diff --git a/build/i18n/tests/data/testidl.ent b/build/i18n/tests/data/testidl.ent index 6094c58b9..d1cfb57ac 100644 --- a/build/i18n/tests/data/testidl.ent +++ b/build/i18n/tests/data/testidl.ent @@ -9,7 +9,7 @@ - + @@ -28,7 +28,7 @@ - + diff --git a/build/i18n/tests/data/testidl.xml b/build/i18n/tests/data/testidl.xml index b8c9c83ca..6f50931c7 100644 --- a/build/i18n/tests/data/testidl.xml +++ b/build/i18n/tests/data/testidl.xml @@ -69,8 +69,8 @@ - - + + @@ -97,7 +97,7 @@ - + diff --git a/build/i18n/tests/data/testidlent.xml b/build/i18n/tests/data/testidlent.xml index edc676466..6de18932f 100644 --- a/build/i18n/tests/data/testidlent.xml +++ b/build/i18n/tests/data/testidlent.xml @@ -73,8 +73,8 @@ - - + + @@ -101,10 +101,10 @@ - + - \ No newline at end of file +
\n"; - for my $row ( config::rules::recuring_fine->retrieve_all ) { + for my $row ( config::rules::recurring_fine->retrieve_all ) { print "