diff options
Diffstat (limited to 'template/allotter/apply.html')
-rw-r--r-- | template/allotter/apply.html | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/template/allotter/apply.html b/template/allotter/apply.html index 37249ec..7fe61cf 100644 --- a/template/allotter/apply.html +++ b/template/allotter/apply.html @@ -16,15 +16,17 @@ $(document).ready(function(){ <script> $(document).ready(function(){ $("select").change(function () { - var $this = $(this); - var prevVal = $this.data("prev"); - var otherSelects = $("select").not(this); - otherSelects.find("option[value=" + $(this).val() + "]").attr('disabled', true); - if (prevVal) { - otherSelects.find("option[value=" + prevVal + "]").attr('disabled', false); - } - - $this.data("prev", $this.val()); + if ($("select").val() !="0"){ + var $this = $(this); + var prevVal = $this.data("prev"); + var otherSelects = $("select").not(this); + otherSelects.find("option[value=" + $(this).val() + "]").attr('disabled', true); + if (prevVal) { + otherSelects.find("option[value=" + prevVal + "]").attr('disabled', false); + } + + $this.data("prev", $this.val()); + } }); }); </script> |