Bugzilla – Attachment 140097 Details for
Bug 27981
Add option to automatically set the 001 control number to the biblionumber
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27981: (QA follow-up) Unify JavaScript to false/true from 0/1/""
Bug-27981-QA-follow-up-Unify-JavaScript-to-falsetr.patch (text/plain), 2.40 KB, created by
Andrii Nugged
on 2022-09-02 09:44:14 UTC
(
hide
)
Description:
Bug 27981: (QA follow-up) Unify JavaScript to false/true from 0/1/""
Filename:
MIME Type:
Creator:
Andrii Nugged
Created:
2022-09-02 09:44:14 UTC
Size:
2.40 KB
patch
obsolete
>From 3be975c71384b957ef155f1d0a90dbbf0c4466b6 Mon Sep 17 00:00:00 2001 >From: Andrew Nugged <nugged@gmail.com> >Date: Mon, 15 Aug 2022 01:58:29 +0300 >Subject: [PATCH] Bug 27981: (QA follow-up) Unify JavaScript to false/true from > 0/1/"" > >Make remove_control_num var and JS KohaBackend.GetRecord calls to have >only false/true instead of mixed 0,1, and "" in different places. > >Signed-off-by: Andrew Nugged <nugged@gmail.com> >--- > koha-tmpl/intranet-tmpl/prog/en/includes/cateditor-ui.inc | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/cateditor-ui.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/cateditor-ui.inc >index 52f4598888..18cafecbb2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/cateditor-ui.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/cateditor-ui.inc >@@ -251,7 +251,7 @@ require( [ 'koha-backend', 'search', 'macros', 'marc-editor', 'marc-record', 'pr > saveLabel: _("Duplicate"), > get: function( id, callback ) { > if ( !id ) return false; >- var remove_control_num = [% IF Koha.Preference('autoControlNumber') == 'OFF' %] 0 [% ELSE %] 1 [% END %]; >+ var remove_control_num = [% IF Koha.Preference('autoControlNumber') == 'OFF' %] false [% ELSE %] true [% END %]; > > KohaBackend.GetRecord( id, remove_control_num, callback ); > }, >@@ -276,7 +276,7 @@ require( [ 'koha-backend', 'search', 'macros', 'marc-editor', 'marc-record', 'pr > get: function( id, callback ) { > if ( !id ) return false; > >- KohaBackend.GetRecord( id, "", callback ); >+ KohaBackend.GetRecord( id, false, callback ); > }, > save: function( id, record, done ) { > function finishCb( data ) { >@@ -412,7 +412,7 @@ require( [ 'koha-backend', 'search', 'macros', 'marc-editor', 'marc-record', 'pr > > backends[ parts[0] ].get( parts[1], function( record ) { > if ( !record.error ) { >- var remove_control_num = [% IF Koha.Preference('autoControlNumber') == 'OFF' %] 0 [% ELSE %] 1 [% END %]; >+ var remove_control_num = [% IF Koha.Preference('autoControlNumber') == 'OFF' %] false [% ELSE %] true [% END %]; > if( remove_control_num ){ record.removeField("001"); } > editor.displayRecord( record ); > editor.focus(); >-- >2.37.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 27981
:
118461
|
118513
|
119704
|
119705
|
119717
|
121805
|
122280
|
122301
|
122344
|
122356
|
122672
|
122674
|
122675
|
124279
|
124280
|
124281
|
128223
|
128224
|
128225
|
132034
|
132035
|
132036
|
134536
|
134537
|
134538
|
134539
|
136022
|
140092
|
140093
|
140094
|
140095
|
140096
| 140097 |
140502