Bug 23183: Reindent cataloging.js
authorOwen Leonard <oleonard@myacpl.org>
Fri, 21 Jun 2019 14:07:49 +0000 (14:07 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Fri, 28 Jun 2019 13:37:05 +0000 (14:37 +0100)
This patch makes some very minor corrections to indentation in
cataloging.js, a JavaScript file used by the bibliographic and item
records editors.

To test, apply the patch and perform a diff against master using the
'-w' flag:

git diff -w origin/master

There should be no changes reported.

Signed-off-by: Nadine Pierre <nadine.pierre@inLibro.com>
Signed-off-by: Bin Wen <bin.wen@inlibro.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

koha-tmpl/intranet-tmpl/prog/js/cataloging.js

index b685c2a..b26c45b 100644 (file)
@@ -12,7 +12,7 @@ function getFieldCode(tagDivId){
 
 //returns the field and subfieldcode based upon subfield div id
 function getFieldAndSubfieldCode(subfieldDivId){
- // format : subfield<tagnumber><subfieldnumber>...
+    // format : subfield<tagnumber><subfieldnumber>...
     return subfieldDivId.substr(8,3+1);
 }
 
@@ -76,23 +76,23 @@ function ExpandField(index) {
 }
 
 var Select2Utils = {
-  removeSelect2: function(element) {
-    if ($.fn.select2) {
-      var selects = element.getElementsByTagName('select');
-      for (var i=0; i < selects.length; i++) {
-        $(selects[i]).select2('destroy');
-      }
-    }
-  },
-
-  initSelect2: function(element) {
-    if ($.fn.select2) {
-      var selects = element.getElementsByTagName('select');
-      for (var i=0; i < selects.length; i++) {
-        $(selects[i]).select2();
-      }
+    removeSelect2: function(element) {
+        if ($.fn.select2) {
+            var selects = element.getElementsByTagName('select');
+            for (var i=0; i < selects.length; i++) {
+                $(selects[i]).select2('destroy');
+            }
+        }
+    },
+
+    initSelect2: function(element) {
+        if ($.fn.select2) {
+            var selects = element.getElementsByTagName('select');
+            for (var i=0; i < selects.length; i++) {
+                $(selects[i]).select2();
+            }
+        }
     }
-  }
 };
 
 /**
@@ -221,7 +221,7 @@ function CloneField(index, hideMarc, advancedMARCEditor) {
                                     buttonDotOnClick = buttonDotOnClick.replace(re2,",'"+inputs[1].getAttribute('id')+"')");
 
                                     if(buttonDotOnClick){
-                                            buttonDot.setAttribute('onclick',buttonDotOnClick);
+                                        buttonDot.setAttribute('onclick',buttonDotOnClick);
                                     }
                                 }
                             }
@@ -557,6 +557,6 @@ function CheckMandatorySubfields(p){
     return total;
 }
 
- $(document).ready(function() {
+$(document).ready(function() {
     $("input.input_marceditor, input.indicator").addClass('noEnterSubmit');
 });