diff options
Diffstat (limited to 'website/static')
-rw-r--r-- | website/static/website/js/cloud.js | 29 | ||||
-rw-r--r-- | website/static/website/templates/index.html | 2 |
2 files changed, 1 insertions, 30 deletions
diff --git a/website/static/website/js/cloud.js b/website/static/website/js/cloud.js index de5d9f3..a34f359 100644 --- a/website/static/website/js/cloud.js +++ b/website/static/website/js/cloud.js @@ -146,35 +146,6 @@ $(document.body).ready(function() { $("#diff-wrapper").hide(); $("#contributor").hide(); $("#databox-wrapper").hide(); - }else{ - $.ajax({ - url: 'get_subcategories/', - dataType: 'JSON', - type: 'GET', - data: { - maincat_id: $("#main_categories").val(), - }, - success: function(data) { - ajax_loader("clear"); - $("#categories").html( - ''); - $("#categories").html( - ' <option value="">Select Subcategory</option>' - ); - var j = 1; - for (var i = 0; i < - data.length; i++) { - $('#categories').append( - '<option value="' + - data[i].subcategory_id + - '">' + j + ' - ' + - data[i].subcategory + - '</option>' - ); - j++; - } - } - }); } if ($("#categories").val() == 0) { $("#books-wrapper").hide(); diff --git a/website/static/website/templates/index.html b/website/static/website/templates/index.html index 4b24827..fe31f5b 100644 --- a/website/static/website/templates/index.html +++ b/website/static/website/templates/index.html @@ -94,7 +94,7 @@ <div class="container small"> <form class="col-12"> <div id="main-category-wrapper" class="form-row form-group"> - <label class="col-sm-2 col-form-label font-weight-bold">{{ maincat_id }} Main Category :</label> + <label class="col-sm-2 col-form-label font-weight-bold">Main Category :</label> <select id="main_categories" class="form-control-sm col-sm-10"> <option value="0">Select Main Category</option> {% for category in catg %} {% if maincat_id == category.category_id or maincat_id == 0 %} |