0xV3NOMx
Linux ip-172-26-7-228 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 23 20:04:10 UTC 2023 x86_64



Your IP : 18.221.161.43


Current Path : /proc/thread-self/root/var/www/oasis/js/
Upload File :
Current File : //proc/thread-self/root/var/www/oasis/js/studentreport.js

function callStdReport() {
  $("#page_main_div").load("../html_modules/studentreport.html", function () {
    document.getElementById("display_module_name").innerHTML = "Student Report";
    document.getElementById("module_name_for_save").value = "Student Report";
    getDefaultHeadFooterLinks("Student Report");
  });
  getyears();
  // getmulti();
}

function getyears() {
  $.ajax({
    type: "GET",
    url: $host_url + "getyears",
    success: function (res) {
      var response = JSON.parse(res);
      console.log(response);
      if (response.error_code == 0) {
        var year = "";
        var degree = "";
        year += `<option value="All">ALL</option>`;
        degree += `<option value="All">ALL</option>`;

        for (var i = 0; i < response.data.length; i++) {
          year += `<option value="${response.data[i].fadyear}">${response.data[i].fadyear} </option>`;
        }
        $("#year").html(year);
        $("#degree").html(degree);
      } else {
        alert(response.data.msg);
        return;
      }
    },
  });
}

function getmulti() {
  var opt = `<option>United Kingdom</option>
              <option>United States</option>
              <option>France</option>
              <option>Germany</option>
              <option>Italy</option>`;
  $("#demo-multiple-select").append(opt);
}

function getstdreport() {
  var year = document.getElementById("year").value;
  var degree = document.getElementById("degree").value;
  var clgRangeFrom = document.getElementById("clgrangeFrom").value;
  var clgRangeTo = document.getElementById("clgrangeTo").value;
  var semRangeFrom = document.getElementById("semrangeFrom").value;
  var semRangeTo = document.getElementById("semrangeTo").value;
  // var multi = document.getElementById("demo-multiple-select-input").value;

  if (year == " ") {
    alert("Please Select the Year of Addmission");
    return;
  }
  if (degree == " ") {
    alert("Please Select the Degree");
    return;
  }

  window.open(
    $host_url +
      "getstdreport" +
      "&year=" +
      year +
      "&degree=" +
      degree +
      "&clgrangeFrom=" +
      clgRangeFrom +
      "&clgrangeTo=" +
      clgRangeTo +
      "&semrangeFrom=" +
      semRangeFrom +
      "&semrangeTo=" +
      semRangeTo
  );
}