Bug 10753: Any library is represented by an empty string

And not with "__ANY__"

Test plan:
0/ Don't apply this patch
1/ Create a suggestion for "any library"
2/ Verify suggestions.branchcode contain "__ANY__"
3/ Apply this patch and execute the updatedb entry
4/ Create a suggestion for "any library"
5/ Verify suggestions.branchcode contain "" (for both suggestions).

Signed-off-by: Paola Rossi <paola.rossi@cineca.it>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
This commit is contained in:
Jonathan Druart 2014-12-11 12:07:17 +01:00 committed by Tomas Cohen Arazi
parent 6114c5fd6f
commit 67c3217238
2 changed files with 10 additions and 1 deletions

View file

@ -9599,6 +9599,15 @@ if ( CheckVersion($DBversion) ) {
SetVersion ($DBversion);
}
$DBversion = "3.19.00.XXX";
if ( CheckVersion($DBversion) ) {
$dbh->do(q|
UPDATE suggestions SET branchcode="" WHERE branchcode="__ANY__"
|);
print "upgrade to $DBversion done (Bug 10753: replace __ANY__ with empty string in suggestions.branchcode)\n";
SetVersion ($DBversion);
}
=head1 FUNCTIONS
=head2 TableExists($table)

View file

@ -419,7 +419,7 @@ h4.local_collapse a { font-size : 80%; text-decoration: none; } fieldset.brief o
<fieldset class="rows"> <legend>Acquisition information</legend><ol>
<li><label for="branchcode">Library:</label>
<select name="branchcode" id="branchcode">
<option value="__ANY__">Any</option>[% FOREACH branchloo IN branchloop %]
<option value="">Any</option>[% FOREACH branchloo IN branchloop %]
[% IF ( branchloo.selected ) %]<option value="[% branchloo.value %]" selected="selected">[% branchloo.branchname %]</option>[% ELSE %]<option value="[% branchloo.value %]">[% branchloo.branchname %]</option>[% END %][% END %]
</select>
</li>