Skip to content

Commit

Permalink
Merge branch 'tags/rel_3_0_1' into iish_master_rel_3_0_1
Browse files Browse the repository at this point in the history
# Conflicts:
#	ChangeLog
#	Open-ILS/src/perlmods/lib/OpenILS.pm
#	Open-ILS/src/perlmods/lib/OpenILS/Application.pm
#	Open-ILS/src/sql/Pg/002.schema.config.sql
#	Open-ILS/xul/staff_client/chrome/content/main/about.html
#	Open-ILS/xul/staff_client/defaults/preferences/prefs.js
#	README
#	configure.ac
#	docs/installation/server_upgrade.adoc
  • Loading branch information
Lucien van Wouw committed Oct 20, 2017
2 parents b06b957 + 34947b8 commit d687ece
Show file tree
Hide file tree
Showing 56 changed files with 1,467 additions and 11,320 deletions.
11,432 changes: 313 additions & 11,119 deletions ChangeLog

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion Open-ILS/src/perlmods/lib/OpenILS.pm
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ OpenILS - Client and server support for the Evergreen open source library system
=cut

our $VERSION = '3.0000';
our $VERSION = '3.0001';

1;
2 changes: 1 addition & 1 deletion Open-ILS/src/perlmods/lib/OpenILS/Application.pm
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use OpenILS::Utils::Fieldmapper;
sub ils_version {
# version format is "x-y-z", for example "2-0-0" for Evergreen 2.0.0
# For branches, format is "x-y"
return "3-0-0";
return "3-0-1";
}

__PACKAGE__->register_method(
Expand Down
36 changes: 32 additions & 4 deletions Open-ILS/src/perlmods/lib/OpenILS/Application/Circ.pm
Original file line number Diff line number Diff line change
Expand Up @@ -1269,10 +1269,15 @@ __PACKAGE__->register_method(

sub mark_item {
my( $self, $conn, $auth, $copy_id, $args ) = @_;
my $e = new_editor(authtoken=>$auth, xact =>1);
return $e->die_event unless $e->checkauth;
$args ||= {};

# Items must be checked in before any attempt is made to mark damaged
my $evt = try_checkin($auth, $copy_id) if
($self->api_name=~ /damaged/ && $args->{handle_checkin});
return $evt if $evt;

my $e = new_editor(authtoken=>$auth, xact =>1);
return $e->die_event unless $e->checkauth;
my $copy = $e->retrieve_asset_copy([
$copy_id,
{flesh => 1, flesh_fields => {'acp' => ['call_number']}}])
Expand Down Expand Up @@ -1342,6 +1347,31 @@ sub mark_item {
return 1;
}

sub try_checkin {
my($auth, $copy_id) = @_;

my $checkin = $U->simplereq(
'open-ils.circ',
'open-ils.circ.checkin.override',
$auth, {
copy_id => $copy_id,
noop => 1
}
);
if(ref $checkin ne 'ARRAY') { $checkin = [$checkin]; }

my $evt_code = $checkin->[0]->{textcode};
$logger->info("try_checkin() received event: $evt_code");

if($evt_code eq 'SUCCESS' || $evt_code eq 'NO_CHANGE') {
$logger->info('try_checkin() successful checkin');
return undef;
} else {
$logger->warn('try_checkin() un-successful checkin');
return $checkin;
}
}

sub handle_mark_damaged {
my($e, $copy, $owning_lib, $args) = @_;

Expand Down Expand Up @@ -1422,8 +1452,6 @@ sub handle_mark_damaged {
my $evt2 = OpenILS::Utils::Penalty->calculate_penalties($e, $circ->usr->id, $e->requestor->ws_ou);
return $evt2 if $evt2;

return undef;

} else {
return OpenILS::Event->new('DAMAGE_CHARGE',
payload => {
Expand Down
4 changes: 2 additions & 2 deletions Open-ILS/src/sql/Pg/002.schema.config.sql
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ CREATE TRIGGER no_overlapping_deps
BEFORE INSERT OR UPDATE ON config.db_patch_dependencies
FOR EACH ROW EXECUTE PROCEDURE evergreen.array_overlap_check ('deprecates');

INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1077', :eg_version); -- csharp/gmcharlt
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('3.0.0', :eg_version);
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('1078', :eg_version); -- csharp/bshum/gmcharlt
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('3.0.1', :eg_version);

CREATE TABLE config.bib_source (
id SERIAL PRIMARY KEY,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
BEGIN;

SELECT evergreen.upgrade_deps_block_check('1078', :eg_version); -- csharp/bshum/gmcharlt

-- The following billing types would not have been automatically added
-- in upgrade scripts between versions 1.2 and 1.4 (early 2009). We
-- add them here. It's okay if they fail, so this should probably be
-- run outside a transaction if added to the version-upgrade scripts.

INSERT INTO config.billing_type (id, name, owner)
SELECT 7, 'Damaged Item', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item');

INSERT INTO config.billing_type (id, name, owner)
SELECT 8, 'Damaged Item Processing Fee', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item Processing Fee');

INSERT INTO config.billing_type (id, name, owner)
SELECT 9, 'Notification Fee', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Notification Fee');

COMMIT;
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ COMMIT;
\set ON_ERROR_STOP off

BEGIN;
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('3.0-beta1', :eg_version);
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('3.0.0', :eg_version);

SELECT evergreen.upgrade_deps_block_check('1032', :eg_version); -- Bmagic/csharp/gmcharlt

Expand Down
28 changes: 28 additions & 0 deletions Open-ILS/src/sql/Pg/version-upgrade/3.0.0-3.0.1-upgrade-db.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
--Upgrade Script for 3.0.0 to 3.0.1
\set eg_version '''3.0.1'''
BEGIN;
INSERT INTO config.upgrade_log (version, applied_to) VALUES ('3.0.1', :eg_version);

-- 3.0.0 release log fixup
UPDATE config.upgrade_log SET version = '3.0.0' where applied_to = '3.0.0' and version = '3.0-beta1';

SELECT evergreen.upgrade_deps_block_check('1078', :eg_version); -- csharp/bshum/gmcharlt

-- The following billing types would not have been automatically added
-- in upgrade scripts between versions 1.2 and 1.4 (early 2009). We
-- add them here. It's okay if they fail, so this should probably be
-- run outside a transaction if added to the version-upgrade scripts.

INSERT INTO config.billing_type (id, name, owner)
SELECT 7, 'Damaged Item', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item');

INSERT INTO config.billing_type (id, name, owner)
SELECT 8, 'Damaged Item Processing Fee', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Damaged Item Processing Fee');

INSERT INTO config.billing_type (id, name, owner)
SELECT 9, 'Notification Fee', 1
WHERE NOT EXISTS (SELECT 1 FROM config.billing_type WHERE name = 'Notification Fee');

COMMIT;
2 changes: 1 addition & 1 deletion Open-ILS/src/templates/opac/parts/record/copy_table.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ END; # FOREACH bib
[% FOREACH tag IN copy_info.tags; %]
<tr class="copy_tag_row">
<td>&nbsp;</td>
<td class="copy_tag" colspan="4"</td>
<td class="copy_tag" colspan="4">
<span class="copy_tag_value">[% tag.value | html %]</span>
</td>
<tr>
Expand Down
1 change: 1 addition & 0 deletions Open-ILS/src/templates/staff/base_js.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ UpUp.start({
s.CONFIRM_CLEAR_PENDING = "[% l('Clear pending transactions') %]";
s.CONFIRM_CLEAR_PENDING_BODY = "[% l('Are you certain you want to clear these pending offline transactions? This action is irreversible. Transactions cannot be recovered after clearing!') %]";
s.LOCATION_NAME_OU_QUALIFIED = "[% l('{{location_name}} ({{owning_lib_shortname}})') %]";
s.CONFIRM_IN_HOUSE_NUM_USES_COUNT_TITLE = "[% l('Are you sure you want to record {{num_uses}} uses for this?') %]";
}]);
</script>

1 change: 1 addition & 0 deletions Open-ILS/src/templates/staff/cat/catalog/index.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
[% INCLUDE 'staff/cat/share/marcedit_strings.tt2' %]
<script src="[% ctx.media_prefix %]/js/ui/default/staff/cat/services/marcedit.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/circ.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/billing.js"></script>
[% INCLUDE 'staff/circ/share/circ_strings.tt2' %]
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/holds.js"></script>
[% INCLUDE 'staff/circ/share/hold_strings.tt2' %]
Expand Down
34 changes: 28 additions & 6 deletions Open-ILS/src/templates/staff/cat/volcopy/t_attr_edit.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@
<b>[% l('Status') %]</b>
</div>
<div class="col-md-4">
<b>[% l('Statistical Categories') %]</b>
<b>[% l('Copy Alert') %]</b>
</div>
</div>

Expand Down Expand Up @@ -138,6 +138,7 @@
<div class="col-md-6">
<b>[% l('Reference?') %]</b>
</div>

</div>

<div class="row">
Expand Down Expand Up @@ -414,13 +415,33 @@
</div>

<div class="col-md-4">

<div class="row" >
<div class="col-xs-12">
<div class="row">
<div class="nullable col-xs-12">
<input class="form-control" type="text" ng-model="working.alert_message"
ng-disabled="!defaults.attributes.alert_message" placeholder="Alert message" />
</div>
</div>
</div>
</div>

<div class="row pad-vert"></div>
<div class="row">
<div class="col-xs-12">
<select class="form-control" ng-disabled="!defaults.statcats"
ng-model="working.statcat_filter"
ng-options="o.id() as o.shortname() for o in statcat_filter_list">
<option value="">[% l('Filter by Library') %]</option>
</select>
<div class="row bg-info">
<div class="col-xs-12">
<b>Statistical Categories</b>
</div>
</div>
<div class="row">
<select class="form-control" ng-disabled="!defaults.statcats"
ng-model="working.statcat_filter"
ng-options="o.id() as o.shortname() for o in statcat_filter_list">
<option value="">[% l('Filter by Library') %]</option>
</select>
</div>
</div>
</div>

Expand All @@ -446,6 +467,7 @@
</div>
</div>
</div>

</div>

</div>
Expand Down
5 changes: 3 additions & 2 deletions Open-ILS/src/templates/staff/cat/volcopy/t_defaults.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,9 @@
</div>
<div class="col-xs-6">
<label>
<input type="checkbox" ng-change="saveDefaults()" ng-model="defaults.attributes.alerts"/>
[% l('Alerts') %]
<input type="checkbox" ng-change="saveDefaults()" ng-model="defaults.attributes.alert_message"/>
<!-- <input type="checkbox" ng-change="saveDefaults()" ng-model="defaults.attributes.alerts"/> -->
[% l('Alert Message') %]
</label>
</div>
</div>
Expand Down
1 change: 1 addition & 0 deletions Open-ILS/src/templates/staff/circ/checkin/index.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/grid.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/ui.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/user.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/billing.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/circ.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/item.js"></script>
<script>
Expand Down
1 change: 1 addition & 0 deletions Open-ILS/src/templates/staff/circ/holds/index.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/grid.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/ui.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/services/user.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/billing.js"></script>
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/circ.js"></script>
[% INCLUDE 'staff/circ/share/circ_strings.tt2' %]
<script src="[% ctx.media_prefix %]/js/ui/default/staff/circ/services/holds.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion Open-ILS/src/templates/staff/circ/in_house_use/index.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
</label>
<input type="number" min="1" max="{{countMax}}"
class="form-control" focus-me="useFocus"
id="in-house-num-uses" ng-model="args.num_uses"/>
id="in-house-num-uses" ng-model="args.num_uses" ng-change="onNumUsesChanged()" />
</div>
</div>

Expand Down
40 changes: 34 additions & 6 deletions Open-ILS/src/templates/staff/circ/patron/t_checkout.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,48 @@
<div class="col-md-6">
<div class="flex-row">
<div class="flex-cell"></div>
<div class="checkbox pad-horiz">

<div class="input-group">
<div class="input-group-btn" uib-dropdown>
<button type="button" class="btn btn-default" uib-dropdown-toggle>
[% l('Date Options') %]
<span class="caret"></span>
</button>
<ul class="pull-right" uib-dropdown-menu>
<li>
<a href
ng-click="toggle_opt('has_sticky_date')">
<span ng-if="date_options.has_sticky_date"
class="label label-success">&#x2713;</span>
<span ng-if="!date_options.has_sticky_date"
class="label label-warning">&#x2717;</span>
<span>[% l('Specific Due Date') %]</span>
</a>
</li>
<li>
<a href
ng-click="toggle_opt('is_until_logout')">
<span ng-if="date_options.is_until_logout"
class="label label-success">&#x2713;</span>
<span ng-if="!date_options.is_until_logout"
class="label label-warning">&#x2717;</span>
<span>[% l('Use Specific Due Date Until Logout') %]</span>
</a>
</li>
</ul>
</div>

<!-- <div class="checkbox pad-horiz">
<label>
<input type="checkbox" ng-model="checkoutArgs.sticky_date"/>
[% l('Specific Due Date') %]
</label>
</div>
<!--
<div><input type="checkbox" class="checkbox" ng-model="checkoutArgs.sticky_date"/></div>
<div class="pad-horiz">[% l('Specific Due Date') %]</div>
-->
</div> -->
<!-- FIXME: This needs a time component as well, but type="datetime"
is not yet supported by any browsers -->
<div><eg-date-input ng-model="checkoutArgs.due_date"></eg-date-input>
</div>
</div>
</div>
</div>
</div>
Expand Down
3 changes: 2 additions & 1 deletion Open-ILS/src/templates/staff/circ/patron/t_edit.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,8 @@ within the "form" by name for validation.
<div class="row reg-field-row" ng-show="show_field('au.dob')">
[% draw_field_label('au', 'dob') %]
<div class="col-md-3 reg-field-input">
<eg-date-input
<eg-date-input
ng-required="field_required('au', 'dob')"
ng-model="patron.dob"
ng-blur="handle_field_changed(patron, 'dob')">
</eg-date-input>
Expand Down
6 changes: 4 additions & 2 deletions Open-ILS/src/templates/staff/circ/patron/t_messages.tt2
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
<eg-grid
idl-class="ausp"
grid-controls="activeGridControls"
dateformat="{{$root.egDateAndTimeFormat}}">
dateformat="{{$root.egDateAndTimeFormat}}"
persist-key="circ.patron.staff_messages">

<eg-grid-menu-item handler="createPenalty"
label="[% l('Apply Penalty / Message') %]"></eg-grid-menu-item>
Expand Down Expand Up @@ -44,7 +45,8 @@
<eg-grid
idl-class="ausp"
grid-controls="archiveGridControls"
dateformat="{{$root.egDateAndTimeFormat}}">
dateformat="{{$root.egDateAndTimeFormat}}"
persist-key="circ.patron.archived_messages">

<eg-grid-field path="set_date" label="[% l('Applied On') %]" datatype="timestamp"></eg-grid-field>
<eg-grid-field path="standing_penalty.label"></eg-grid-field>
Expand Down
Loading

0 comments on commit d687ece

Please sign in to comment.