From 579290e787301eb77a4e7209b424b56ef95237c2 Mon Sep 17 00:00:00 2001 From: Elijah Madden Date: Thu, 1 Mar 2018 08:55:41 +0900 Subject: [PATCH] Success/Danger classes reversed --- administrator/templates/isis/js/template.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/administrator/templates/isis/js/template.js b/administrator/templates/isis/js/template.js index 699615d719950..33df4512245be 100644 --- a/administrator/templates/isis/js/template.js +++ b/administrator/templates/isis/js/template.js @@ -34,9 +34,9 @@ jQuery(function($) if (input.val() == '') { label.addClass('active btn-primary'); } else if (input.val() == 0) { - label.addClass('active btn-' + (reversed ? 'danger' : 'success')); - } else { label.addClass('active btn-' + (reversed ? 'success' : 'danger')); + } else { + label.addClass('active btn-' + (reversed ? 'danger' : 'success')); } input.prop('checked', true); @@ -51,9 +51,9 @@ jQuery(function($) if ($self.val() == '') { $label.addClass('active btn-primary'); } else if ($self.val() == 0) { - $label.addClass('active btn-' + (reversed ? 'danger' : 'success')); - } else { $label.addClass('active btn-' + (reversed ? 'success' : 'danger')); + } else { + $label.addClass('active btn-' + (reversed ? 'danger' : 'success')); } }); // add color classes to chosen field based on value