<%@ Page Language="C#" AutoEventWireup="true" CodeFile="presidentgroupwise.aspx.cs" MasterPageFile="~/module/presidentdash.master" Inherits="module_presidentgroupwise" %>

<asp:Content ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
      <script type="text/javascript">
          var cashamt = "";
          var vrno = "";
          var fullname = ""; var fullname1 = "";var fullname2 = "";
          var expenes = "";
          var cash = "";  var cash1 = "";var cash2 = "";var cash3 = 0;
          var totalcash = 0;var totalonlines = 0;var totalcash1 = 0;var totalonlines1 = 0;var totalonlines2 = 0;
          var totalcash3 = 0;var totalonlines3 = 0;
          var online = "";var appendss = "";
          var developcash = 0; var online2 = "";var online3 = "";var narrationss = "";
          var tscash = 0;var tsonline = 0;
          var developonline = 0;var online1 = "";var totalcash2 = 0;var narrationss = "";var cashexp = "";var online3 = 0;
          var closingbal = 0;
          var totalcashonline = 0;  var totalcashonlineexpense = 0;
          var tocash  = 0;
          $(document).ready(function () {
          
              let today2 = new Date().toISOString().substr(0, 10);
                     
              document.querySelector("#paydt").value = today2;
              let today3 = new Date().toISOString().substr(0, 10);
                     
              document.querySelector("#paydt1").value = today3;
              let today4 = new Date().toISOString().substr(0, 10);
                     
              document.querySelector("#paydt2").value = today4;
              let today5 = new Date().toISOString().substr(0, 10);
                     
              document.querySelector("#paydt3").value = today5;
              $("#lblcashes").html("0");
              $("#lblcareditcash").html("0");
              $("#lblcareditcash1").html("0");  $("#lblexpenses").html("0");
              $("#lblclosingcash").html(0);
              //  $("#lblhcash").html(totalcashonline);

              $.ajax({
                  type: "POST",
                  contentType: "application/json; charset=utf-8",
                  url: "presidentgroupwise.aspx/PopulateDropDownList4",
                  data: "",
                  dataType: "json",
                  success: function (result) {
                      $('select[id$=ddlclass]').empty();
                      $('select[id$=ddlclass]').append("<option value='0'>Select class</option>");
                      $.each(result.d, function (key, value) {
                          var dd = value.DeptName;


                          $('select[id$=ddlclass]').append($("<option data-toggle='tooltip' data-placement='top' title='" + dd + "'></option>").val(value.DeptId).html(dd));
                          //console.log(value.DeptName);
                      });
                      $('select[id$=ddlclass]').val('0').change();
                      //$('select[id$=cat] option:eq(0)').attr("selected", true);
                      //  $('select[id$=ddlclassty]').selectpicker('refresh');
                      //  hdndoc=$('select[id$=cat] option:eq(1)').val();
                  },
                  error: function ajaxError(result) {
                      console.log(result.status + ' : ' + result.statusText);
                  }

              }); 
              $.ajax({
                  type: "POST",
                  contentType: "application/json; charset=utf-8",
                  url: "presidentgroupwise.aspx/PopulateDropDownList5",
                  data: "",
                  dataType: "json",
                  success: function (result) {
                      $('select[id$=ddlexp]').empty();
                      $('select[id$=ddlexp]').append("<option value='0'>Select Expenses</option>");
                      $.each(result.d, function (key, value) {
                          var dd = value.DeptName;


                          $('select[id$=ddlexp]').append($("<option data-toggle='tooltip' data-placement='top' title='" + dd + "'></option>").val(value.DeptId).html(dd));
                          //console.log(value.DeptName);
                      });
                      $('select[id$=ddlexp]').val('0').change();
                      //$('select[id$=cat] option:eq(0)').attr("selected", true);
                      //  $('select[id$=ddlclassty]').selectpicker('refresh');
                      //  hdndoc=$('select[id$=cat] option:eq(1)').val();
                  },
                  error: function ajaxError(result) {
                      console.log(result.status + ' : ' + result.statusText);
                  }

              });
          });
          //function GetData() {
          //    $.ajax({
          //        url: "cashbook.aspx/Getdata",
          //        method: "post",
          //        contentType: "application/json; charset=utf-8",
          //        data: "{paydate :'" + $('#paydt').val() + "'}",
          //        dataType: "json",
          //        success: function (data) {



          //            //$("#dataemp").find("tbody").empty();
          //             $("#dataemp").find("tbody").empty();

               
          //            if (data.d != "") {
          //                data = JSON.parse(data.d);
          //            }
                

                  
          //            for (var i = 0; i < data.length ; i++) {
          //                if(data[i].baltutionfees != "0"){
                     
          //                    if(data[i].paymode == "cash")
          //                    {
                           
          //                        online = "";
          //                        cash = parseFloat( data[i].baltutionfees);
          //                        fullname = data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname;
                       
          //                        appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
          //                        totalcash = totalcash + cash;
          //                        $("#dataemp").find("tbody").append(appendss);
          //                    }
                        
          //                    if(data[i].paymode == "cheque"){
                           
          //                        online = parseFloat(data[i].baltutionfees);
          //                        cash = "";
          //                        fullname = data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname;
          //                        totalonlines = totalonlines + online;
          //                        appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
          //                        $("#dataemp").find("tbody").append(appendss);
          //                    }
                        
          //                } 
          //                if(data[i].baldevelopemntfee != "0"){
                     
          //                    if(data[i].paymode == "cash")
          //                    {
                           
          //                        online = "";
          //                        developcash = parseFloat(data[i].baldevelopemntfee);
          //                        fullname = data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname;
                       
          //                        appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
          //                        totalcash = totalcash + developcash;
          //                        $("#dataemp").find("tbody").append(appendss);
          //                    }
                        
          //                    if(data[i].paymode == "cheque"){
                           
          //                        developonline = parseFloat(data[i].baldevelopemntfee);
          //                        developcash = "";
          //                        fullname = data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname;
          //                        totalonlines = totalonlines + developonline;
          //                        appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
          //                        $("#dataemp").find("tbody").append(appendss);
          //                    }
                        
          //                } 
          //            }
          //            //$("#dataemp").find("tbody").append("<tr><td  style='text-align:right'>Total Cash<td><td style='text-align:right'>"+ totalcash +"<td><td colspan='1' style='text-align:right'>Online</td><td style='text-align:right'>"+ totalonlines +"</td></tr>");
          //        },
          //        error: function () {
          //            //alert("Error in display");
          //            noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
          //            setTimeout(function () { $.noty.closeAll(); }, 3000);
          //        }

          //    });
          //}
          //192.168.137.119 192.168.137.97
          function GetData(){
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnm = $("select[id$=ddlclass]").val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Getdata',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          totalcash = 0;
                          totalonlines = 0;
                          table = $('#dataemp').DataTable();
                          table.destroy();
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          } 
                          var table = $('#dataemp').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              //"dom": 'lBfrtip',
                          
                              //responsive: true,
                              "columns": [
                     { "width": "5%" },
                     { "width": "8%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "7%" },
                     { "width": "6%" },
                     { "width": "10%" },
                    
                              ]
                          });

                          $('#dataemp').DataTable().clear().draw();
                          for (var i = 0; i < data.length; i++) {
                          
                              fullname1 = "";
                              if(data[i].paymode == "cash")
                              {
                           
                                  online = "";
                                  cash = parseFloat(data[i].paidamt);
                                  fullname1 = "Tution Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                                  totalcash = totalcash + cash;
                                  
                              }
                        
                              if(data[i].paymode == "cheque"){
                           
                                  online = parseFloat(data[i].paidamt);
                                  cash = "";
                                  fullname1 = "Tution Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                                  totalonlines = totalonlines + online;
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
                                  
                              }
                        
                            
                              //if(data[i].baldevelopemntfee != "0"){
                              //    fullname1 = "";
                              //    if(data[i].paymode == "cash")
                              //    {
                           
                              //        online = "";
                              //        developcash = parseFloat(data[i].baldevelopemntfee);
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+"";
                       
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                              //        totalcash = totalcash + developcash;
                                 
                              //    }
                        
                              //    if(data[i].paymode == "cheque"){
                           
                              //        developonline = parseFloat(data[i].baldevelopemntfee);
                              //        developcash = "";
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                              //        totalonlines = totalonlines + developonline;
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
                                  
                              //    }
                        
                              //}
                              table.row.add([

                                                data[i].ppaymentdate, fullname1,vrno, data[i].receiptnos, cash, expenes, cash, online



                              ]).draw(false);
                          
                          } 
                      
                          $("#totalamt").html(totalcash);
                          $("#totalheadscash").html(totalcash);
                          $("#totalonline").html(totalonlines);
                          $("#lblheadsonlinecash").html(totalonlines);
                          var totalsum = parseFloat(totalcash) + parseFloat(totalonlines);
                          $("#lblcashes").html(totalsum);
                      

                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
        

          } 
          function GetData1(){
       
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnms = $("select[id$=ddlclass]").val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Getdataincome',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#dataemp1').DataTable();
                          table.destroy();
                          totalcash1 = 0;
                          totalonlines1 = 0;
                          tocash =0;
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          } 
                          var table = $('#dataemp1').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              //"dom": 'lBfrtip',
                          
                              //responsive: true,
                              "columns": [
                     { "width": "5%" },
                     { "width": "8%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "7%" },
                     { "width": "6%" },
                     { "width": "10%" },
                    
                              ]
                          });

                          $('#dataemp1').DataTable().clear().draw();
                          for (var i = 0; i < data.length; i++) {
                          
                              fullname2 = "";
                              if(data[i].paymodes == "cash")
                              {
                           
                                  online1 = "";
                                  cash1 = parseFloat(data[i].amount); 
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                                  totalcash1 = totalcash1 + cash1;
                                  
                              }
                        
                              if(data[i].paymodes == "online"){
                           
                                  online1 = parseFloat(data[i].amount);
                                  cash1 = "";
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].utrnos +"";
                                  totalonlines1 = totalonlines1 + online1;
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
                                  
                              }
                        
                            
                              //if(data[i].baldevelopemntfee != "0"){
                              //    fullname1 = "";
                              //    if(data[i].paymode == "cash")
                              //    {
                           
                              //        online = "";
                              //        developcash = parseFloat(data[i].baldevelopemntfee);
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+"";
                       
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                              //        totalcash = totalcash + developcash;
                                 
                              //    }
                        
                              //    if(data[i].paymode == "cheque"){
                           
                              //        developonline = parseFloat(data[i].baldevelopemntfee);
                              //        developcash = "";
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                              //        totalonlines = totalonlines + developonline;
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
                                  
                              //    }
                        
                              //}
                              table.row.add([
                                                data[i].incpdate, fullname2,vrno, data[i].recptnos, cash1, expenes, cash1, online1
                              ]).draw(false);
                          
                          } 
                          //  var tscash = 0;var tsonline = 0;
                          $("#lblinccash").html(totalcash1);
                          $("#lblonlinecash").html(totalonlines1);
                          tscash = parseFloat($("#totalheadscash").html());
                    
                          //if(tscash > 0){
                          //    tscash = tscash + parseFloat(totalcash1);   $("#totalheadscash").html(tscash);
                          //} 
                          //else {
                          //    tscash =parseFloat(totalcash1);  $("#totalheadscash").html(tscash);
                          //}
                          //tsonline = parseFloat($("#lblheadsonlinecash").html());
                          //if(tsonline > 0){
                          //    tsonline = tsonline + parseFloat(totalonlines1); $("#lblheadsonlinecash").html(tsonline);
                          //}else{
                          //    tsonline = parseFloat(totalonlines1); $("#lblheadsonlinecash").html(tsonline);
                          //}
                          tocash = parseFloat(totalcash1) + parseFloat(totalonlines1); 
                          $("#lblcareditcash").html(tocash);
                          //totalcashonline = parseFloat( $("#lblhcash").html());
                          //if(totalcashonline > 0){
                          //    totalcashonline = totalcashonline + parseFloat( tocash);
                          //    $("#lblhcash").html(totalcashonline);
                          //}else{
                          //    totalcashonline = 0;
                          //}

                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
        

          } 
          function GetDataExam(){
       
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnms = $("select[id$=ddlclass]").val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Getdataexam',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#tblexamfee').DataTable();
                          table.destroy();
                          totalcash3 = 0;
                          totalonlines3 = 0;

                          tocash = 0;
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          } 
                          var table = $('#tblexamfee').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              //"dom": 'lBfrtip',
                          
                              //responsive: true,
                              "columns": [
                     { "width": "5%" },
                     { "width": "8%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "10%" },
                     { "width": "7%" },
                     { "width": "6%" },
                     { "width": "10%" },
                    
                              ]
                          });

                          $('#tblexamfee').DataTable().clear().draw();
                          for (var i = 0; i < data.length; i++) {
                          
                              fullname2 = "";
                              if(data[i].paymode == "cash")
                              {
                           
                                  online3 = 0;
                                  cash3 = parseFloat(data[i].tamount); 
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                                  totalcash3 = totalcash3 + cash3;
                                  
                              }
                        
                              if(data[i].paymode == "online"){
                           
                                  online3 = parseFloat(data[i].tamount);
                                  cash3 = 0;
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].utrnos +"";
                                  totalonlines3 = totalonlines3 + online3;
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
                                  
                              }
                        
                            
                              //if(data[i].baldevelopemntfee != "0"){
                              //    fullname1 = "";
                              //    if(data[i].paymode == "cash")
                              //    {
                           
                              //        online = "";
                              //        developcash = parseFloat(data[i].baldevelopemntfee);
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+"";
                       
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                              //        totalcash = totalcash + developcash;
                                 
                              //    }
                        
                              //    if(data[i].paymode == "cheque"){
                           
                              //        developonline = parseFloat(data[i].baldevelopemntfee);
                              //        developcash = "";
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                              //        totalonlines = totalonlines + developonline;
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
                                  
                              //    }
                        
                              //}
                              table.row.add([

                                                data[i].payexamdate, fullname2,vrno, data[i].examrecpt, cash3, expenes, cash3, online3



                              ]).draw(false);
                          
                          } 
                      
                      
                          $("#lblexamcash").html(totalcash3);
                          $("#lblonlineexamcash").html(totalonlines3);
                          tscash = parseFloat($("#totalheadscash").html());
                    
                          //if(tscash > 0){
                          //    tscash = tscash + parseFloat(totalcash3);   $("#totalheadscash").html(tscash);
                          //} 
                          //else {
                          //    tscash =parseFloat(totalcash3);  $("#totalheadscash").html(tscash);
                          //}
                          //tsonline = parseFloat($("#lblheadsonlinecash").html());
                          //if(tsonline > 0){
                          //    tsonline = tsonline + parseFloat(totalonlines3); $("#lblheadsonlinecash").html(tsonline);
                          //}else{
                          //    tsonline = parseFloat(totalonlines3); $("#lblheadsonlinecash").html(tsonline);
                          //}
                          tocash = parseFloat(totalcash3) + parseFloat(totalonlines3); 
                          $("#lblcareditcash1").html(tocash);
                          //totalcashonline = parseFloat( $("#lblhcash").html());
                          //if(totalcashonline > 0 ){
                          //    totalcashonline = totalcashonline + parseFloat(tocash); $("#lblhcash").html(totalcashonline);
                          //}else{
                          //    totalcashonline = 0;
                          //}

                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
        

          } 
          function ExportDataExam(){
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnm = $("select[id$=ddlclass]").val(); alert($("select[id$=ddlclass]").val());
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Exportsexamfee',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#tblexamfee').DataTable();
                          table.destroy();
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          }
                          var table = $('#tblexamfee').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              "dom": 'lBfrtip',
                          
                              //responsive: true,
                              //select: {
                              //    style: 'single'
                              //},
                              buttons: [
                              {
                                  extend: 'excelHtml5',
                                  text: 'Export to Excel',
                                  title: 'Exam Fee',
                                  download: 'open',
                                  orientation: 'landscape',
                                  exportOptions: {
                                      columns: ':visible'
                                  }
                              }],
                              "columns": [
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                    
                              ]
                          });

                          $('#tblexamfee').DataTable().clear().draw();

                          for (var i = 0; i < data.length; i++) {
                              fullname2 = "";
                              if(data[i].paymode == "cash")
                              {
                           
                                  online3 = 0;
                                  cash3 = parseFloat(data[i].tamount); 
                                  fullname2 = "Exam Fee"+ data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                                  totalcash3 = totalcash3 + cash3;
                                  
                              }
                        
                              if(data[i].paymode == "online"){
                           
                                  online3 = parseFloat(data[i].tamount);
                                  cash3 = 0;
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].utrnos +"";
                                  totalonlines3 = totalonlines3 + online3;
                                  //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
                                  
                              }
                        
                            
                              //if(data[i].baldevelopemntfee != "0"){
                              //    fullname1 = "";
                              //    if(data[i].paymode == "cash")
                              //    {
                           
                              //        online = "";
                              //        developcash = parseFloat(data[i].baldevelopemntfee);
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+"";
                       
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                              //        totalcash = totalcash + developcash;
                                 
                              //    }
                        
                              //    if(data[i].paymode == "cheque"){
                           
                              //        developonline = parseFloat(data[i].baldevelopemntfee);
                              //        developcash = "";
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                              //        totalonlines = totalonlines + developonline;
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
                                  
                              //    }
                        
                              //}
                              table.row.add([

                                                data[i].payexamdate, fullname2,vrno, data[i].examrecpt, cash3, expenes, cash3, online3



                              ]).draw(false);
                          
                          }
                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
          }
          function GetData2(){
       
              var obj = {};
           
          
              obj.paydate = $("#paydt2").val();
              obj.paydate1 = $("#paydt3").val();
              //  obj.expid =  $('select[id$=ddlexp]').val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Getdataexpenses',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#dataemp2').DataTable();
                          table.destroy();
                          totalcash2 = 0;
                          totalonlines2 = 0;
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                      
                              var table = $('#dataemp2').DataTable({

                                  "order": [[0, "asc"]],
                                  "ordering": false,
                                  "pageLength": 10,
                                  //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                                  //"dom": 'lBfrtip',
                          
                                  //responsive: true,
                                  "columns": [
                         { "width": "5%" },
                         { "width": "8%" },
                         { "width": "10%" },
                         { "width": "10%" },
                         { "width": "10%" },
                         { "width": "7%" },
                         { "width": "6%" },
                         { "width": "10%" },
                    
                                  ]
                              });

                              $('#dataemp2').DataTable().clear().draw();
                              for (var i = 0; i < data.length; i++) {
                          
                                  narrationss = ""; 
                                  if(data[i].pymodes == "cash")
                                  {
                           
                                      online2 = "";
                                      cash2 = parseFloat(data[i].amounts);  
                                      narrationss = data[i].exnsmr+"("+ data[i].narrations+")";
                       
                             
                                      totalcash2 = totalcash2 + cash2;
                                  
                                  }
                        
                                  if(data[i].pymodes == "online"){
                           
                                      online2 = parseFloat(data[i].amounts);
                                      cash2 = "";
                                      narrationss = data[i].exnsmr+" "+ data[i].narrations+ " " + data[i].utrnos;
                                      totalonlines2 = totalonlines2 + online2;
                           
                                  
                                  }
                        
                            
                        
                                  table.row.add([

                                                    data[i].expaydt, narrationss,vrno, data[i].rectpsnos, cash2, expenes, cash2, online2



                                  ]).draw(false);
                          
                              } 
                              var tscash1 = 0;var tsonline1 = 0; 
                              $("#lblexpesecash").html(totalcash2);

                              $("#lblexpenseonlnecash").html(totalonlines2);
                              tscash1 = parseFloat($("#totalonline").html());

                              if(tscash1 > 0){
                                  tscash1 = tscash1 + parseFloat(totalcash2);   $("#totalheadscash").html(tscash1);
                              } 
                              else {
                                  tscash1 =parseFloat(totalcash2);  $("#totalheadscash").html(tscash1);
                              }
                              tsonline1 = parseFloat($("#lblheadsonlinecash").html());
                              if(tsonline1 > 0){
                                  tsonline1 = tsonline1 + parseFloat(totalonlines2); $("#lblheadsonlinecash").html(tsonline1);
                              }else{
                                  tsonline1 = parseFloat(totalonlines2); $("#lblheadsonlinecash").html(tsonline1);
                              }
                              var totalcashexp = parseFloat(totalcash2) + parseFloat(totalonlines2);
                      
                              if(totalcashexp > 0){
                                  $("#lbltotalexpense").html(totalcashexp); $("lblexpenses").html(totalcashexp);
                              }
                              else{
                                  $("#lbltotalexpense").html("0");$("lblexpenses").html(0);
                              }
                          }
                          else{
                              noty({ text: 'No Record Found!!', layout: 'topRight', type: 'information' });
                              setTimeout(function () { $.noty.closeAll(); }, 3000);
                              $("#lbltotalexpense").html("0");
                              $("#lblexpesecash").html(0);

                              $("#lblexpenseonlnecash").html(0);
                          }
                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
        

          }
          function ExportData() {
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnm = $("select[id$=ddlclass]").val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Exports',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#dataemp').DataTable();
                          table.destroy();
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          }
                          var table = $('#dataemp').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              "dom": 'lBfrtip',
                          
                              //responsive: true,
                              //select: {
                              //    style: 'single'
                              //},
                              buttons: [
                              {
                                  extend: 'excelHtml5',
                                  text: 'Export to Excel',
                                  title: 'Cash Book',
                                  download: 'open',
                                  orientation: 'landscape',
                                  exportOptions: {
                                      columns: ':visible'
                                  }
                              }],
                              "columns": [
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                    
                              ]
                          });

                          $('#dataemp').DataTable().clear().draw();

                          for (var i = 0; i < data.length; i++) {
                              if(data[i].baltutionfees != "0"){
                                  fullname1 = "";
                                  if(data[i].paymode == "cash")
                                  {
                           
                                      online = "";
                                      cash = parseFloat(data[i].paidamt);
                                      fullname1 = "Tution Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                                      //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                                      totalcash = totalcash + cash;
                                  
                                  }
                        
                                  if(data[i].paymode == "cheque"){
                           
                                      online = parseFloat(data[i].paidamt);
                                      cash = "";
                                      fullname1 = "Tution Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                                      totalonlines = totalonlines + online;
                                      //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ cash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ online +"</td></tr>";
                                  
                                  }
                        
                              } 
                              //if(data[i].baldevelopemntfee != "0"){
                              //    fullname1 = "";
                              //    if(data[i].paymode == "cash")
                              //    {
                           
                              //        online = "";
                              //        developcash = parseFloat(data[i].baldevelopemntfee);
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+"";
                       
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Tution Fee <br/>"+ fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ online +"</td></tr>";
                              //        totalcash = totalcash + developcash;
                                 
                              //    }
                        
                              //    if(data[i].paymode == "cheque"){
                           
                              //        developonline = parseFloat(data[i].baldevelopemntfee);
                              //        developcash = "";
                              //        fullname1 = "Development Fee "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"";
                              //        totalonlines = totalonlines + developonline;
                              //        //appendss ="<tr><td style='text-align:center'>"+ data[i].ppaymentdate +"</td><td style='text-align:center'>Deveopment Fee <br/>"+fullname +"<br/>"+data[i].clsname+"<br/>"+data[i].divsname +"<br/>Cheque No."+ data[i].chequenos +"&"+ data[i].bankname +"</td><td style='text-align:center'>"+ vrno +"</td><td style='text-align:center'>"+ data[i].receiptnos +"</td><td style='text-align:center'>"+ developcash +"</td><td style='text-align:center'>"+ expenes +"</td><td style='text-align:center'></td><td style='text-align:center'>"+ developonline +"</td></tr>";
                                  
                              //    }
                        
                              //}
                              table.row.add([

                                                data[i].ppaymentdate, fullname1,vrno, data[i].receiptnos, cash, expenes, cash, online



                              ]).draw(false);
                              //table.row.add([

                              //               "<tr><td colspan='3' style='text-align:right'>Total Cash<td><td style='text-align:right'>"+ totalcash +"<td><td colspan='1' style='text-align:right'>Online</td><td style='text-align:right'>"+ totalonlines +"</td></tr>"



                              //]).draw(false);
                          } 
                      
                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
          } 
          function ExportData1(){
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              obj.clsnms = $("select[id$=ddlclass]").val();
              if ($("#paydt").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Exports1',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#dataemp1').DataTable();
                          table.destroy();
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          }
                          var table = $('#dataemp1').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              "dom": 'lBfrtip',
                          
                              //responsive: true,
                              //select: {
                              //    style: 'single'
                              //},
                              buttons: [
                              {
                                  extend: 'excelHtml5',
                                  text: 'Export to Excel',
                                  title: 'Cash Book(INCOME)',
                                  download: 'open',
                                  orientation: 'landscape',
                                  exportOptions: {
                                      columns: ':visible'
                                  }
                              }],
                              "columns": [
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                    
                              ]
                          });

                          $('#dataemp1').DataTable().clear().draw();
                          for (var i = 0; i < data.length; i++) {
                          
                              fullname2 = "";
                              if(data[i].paymodes == "cash")
                              {
                           
                                  online1 = "";
                                  cash1 = parseFloat(data[i].amount); 
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" ";
                       
                            
                                  totalcash1 = totalcash1 + cash1;
                                  
                              }
                        
                              if(data[i].paymodes == "online"){
                           
                                  online1 = parseFloat(data[i].amount);
                                  cash1 = "";
                                  fullname2 = data[i].incname + " "+ data[i].title+"."+ data[i].fname +" "+data[i].mname+" "+data[i].lname+" "+ data[i].clsname +" "+data[i].divsname+" Cheque No."+ data[i].utrnos +"";
                                  totalonlines1 = totalonlines1 + online1;
                             
                                  
                              }
                        
                            
                         
                              table.row.add([

                                                data[i].incpdate, fullname2,vrno, data[i].recptnos, cash1, expenes, cash1, online1



                              ]).draw(false);
                          
                          } 
                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
            
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
          } 
          function ExportData2(){
              var obj = {};
           
          
              obj.paydate = $("#paydt").val();
              obj.paydate1 = $("#paydt1").val();
              //obj.expid =  $('select[id$=ddlexp]').val();
              if ($("#paydt2").val() != "") {
                  $.ajax({
                      url: 'presidentgroupwise.aspx/Exports2',
                      method: 'post',
                      contentType: 'application/json;charset=utf-8',
                      data: JSON.stringify(obj),
                      dataType: 'json',
                      success: function (data) {
                          table = $('#dataemp2').DataTable();
                          table.destroy();
                          if (data.d != "") {
                              data = JSON.parse(data.d);
                          }
                          var table = $('#dataemp2').DataTable({

                              "order": [[0, "asc"]],
                              "ordering": false,
                              "pageLength": 10,
                              //"lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]],
                              "dom": 'lBfrtip',
                          
                              //responsive: true,
                              //select: {
                              //    style: 'single'
                              //},
                              buttons: [
                              {
                                  extend: 'excelHtml5',
                                  text: 'Export to Excel',
                                  title: 'Cash Book(EXPENSE)',
                                  download: 'open',
                                  orientation: 'landscape',
                                  exportOptions: {
                                      columns: ':visible'
                                  }
                              }],
                              "columns": [
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                       { "width": "10%" },
                    
                              ]
                          });

                          $('#dataemp2').DataTable().clear().draw();
                     
                          for (var i = 0; i < data.length; i++) {
                          
                              narrationss = ""; 
                              if(data[i].pymodes == "cash")
                              {
                           
                                  online2 = "";
                                  cash2 = parseFloat(data[i].amounts);  
                                  narrationss = data[i].exnsmr+"("+ data[i].narrations+")";
                       
                             
                                  totalcash2 = totalcash2 + cash2;
                                  
                              }
                        
                              if(data[i].pymodes == "online"){
                           
                                  online2 = parseFloat(data[i].amounts);
                                  cash2 = "";
                                  narrationss = data[i].exnsmr+" "+ data[i].narrations+ " " + data[i].utrnos;
                                  totalonlines2 = totalonlines2 + online2;
                           
                                  
                              }
                        
                            
                        
                              table.row.add([

                                                data[i].expaydt, narrationss,vrno, data[i].rectpsnos, cash2, expenes, cash2, online2



                              ]).draw(false);
                          
                          } 
                      },
                      error: function () {


                          noty({ text: 'Get Error', layout: 'topRight', type: 'error' });
                          setTimeout(function () { $.noty.closeAll(); }, 3000);
                      }
                  });
            
              }
              else {
                  noty({ text: 'Please Select Payment Date', layout: 'topRight', type: 'information' });
                  setTimeout(function () { $.noty.closeAll(); }, 3000);
                       
              } 
          }
          function Getsumaccount(){
              if( $("#lblcashes").html() != "0" && $("#lblcareditcash").html() != "0" && $("#lblcareditcash1").html() != "0"){
                  totalcashonline = parseFloat($("#lblcashes").html()) + parseFloat($("#lblcareditcash").html()) + parseFloat($("#lblcareditcash1").html()); 
                  $("#lblhcash").html(totalcashonline);
                  totalcashonlineexpense = $("#lblexpenses").html(); 
                  closingbal = totalcashonline - parseFloat(totalcashonlineexpense);
                  $("#lblclosingcash").html(closingbal);

              }else{
                  $("#lblhcash").html(totalcashonline);

              }

          }
    </script>
     <div class="page-wrapper">
			<div class="page-content">
				<div class="row">
					<div class="col-md-12 mx-auto" >
					
				<div class="card">
					<div class="card-body">
						<div class="card-title d-flex align-items-center">

							<h6>Cash Book</h6>
						</div>
						<hr />
						
						
						
						 <div class="col-md-12">
                           
                                 <form class="row">
                            <div class="col-md-2">
							<label> Payment Date From :</label>
							<input class="form-control mb-3" id="paydt" type="date"
								aria-label="default input example" />

						</div>
                               <div class="col-md-2">
							<label>To :</label>
							<input class="form-control mb-3" id="paydt1" type="date"
								aria-label="default input example" />

						</div>
							<div class="col-md-2" style="">
								<label>Class </label>
								<select id="ddlclass" class="form-select mb-3" aria-label="Default select example">
									
								</select>
							</div>
								<div class="col-md-3" style="display:none">
								<label>Payment Type </label>
								<select id="Select1" class="form-select mb-3" aria-label="Default select example">
									<option value="0">Select Type</option>
									<option value="cash">Cash</option>
									<option value="online">Online</option>
								</select>
                                    </div>
								<div class="col-md-3" style="display:none">
								<label>Payment  Heads</label>
								<select id="ddlheads" class="form-select mb-3" aria-label="Default select example">
									<option value="0">Select Heads</option>
									<option value="TutionFee">Tution Fee</option>
												
								</select>
							</div>
                           
                                
                                    
					       <div class="col-md-2" style="margin-top: 3.5vh;">
							<button type="button" class="btn btn-primary" onclick="GetData();"><i class='bx bx-search'></i>Search</button>
											
						   </div>
						  
                         
                          
                         <div class="col-md-2" style="margin-top: 3.5vh;">
                              <button class="btn btn-primary" type="button" style=""  onclick="ExportData();"> Export Data</button>
                             </div>
                                       </form>
					</div>
					
                         
                       </div>
                   </div>
				   
				  
						
				<!-- <div class="row row-cols-auto g-2">

				<div class="col">
					<button style="height:35px; width: 35px; padding-left:7px;"  data-bs-toggle="modal" data-bs-target="#exampleLargeModal" type="button" class="btn btn-secondary"6><i class="fadeIn animated bx bx-user-plus"></i>
					</button>
				</div>
				<div class="col">
					<button  style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-success"><i class='bx bx-message-square-edit'></i>
					</button>
				</div>
				<div class="col">
					<button  style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-danger"><i class="fadeIn animated bx bx-trash-alt"></i>
					</button>
				</div>
				<div class="col">
					<button  style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-warning"><i class="lni lni-share"></i>
					</button>
				</div>
				
				<div class="col">
					<button  style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-dark"><i class="fadeIn animated bx bx-printer"></i>
					</button>
				</div>
				</div>
				</div>
				</div>
				 -->

				   <div class="overlay toggle-icon"></div>
				   <hr/>
				   <div class="col-md-12 mx-auto">
				   <div class="card">
					   <div class="card-body">
                          
						   <div class="table-responsive">
							   <table id="dataemp" class="table table-striped table-bordered" style="overflow-y:scroll">
								   <thead>
									   <tr>
										   <th>Payment Date</th>	
										   <th>Particulars</th>
										   <th>V.R</th>  
										   <th>Receipt No.</th>
										   <th>Credit Cash</th>
										   <th>Debit Expenses</th>
										   <th>Total Cash</th>
                                           <th>Online</th>
									   </tr>
								   </thead>
								   <tbody>
								<%--	<tr>
										<td><input class="form-control mb-3" type="text" placeholder=""
											aria-label="default input example"></td>
											<td><input class="form-control mb-3" type="text" placeholder=""
												aria-label="default input example"></td>
												<td><input class="form-control mb-3" type="text" placeholder=""
													aria-label="default input example"></td>
													<td><input class="form-control mb-3" type="text" placeholder=""
														aria-label="default input example"></td>
														<td><input class="form-control mb-3" type="text" placeholder=""
															aria-label="default input example"></td>
															<td><input class="form-control mb-3" type="text" placeholder=""
																aria-label="default input example"></td>
																<td style="background-color: white;">
																	<%--<button style="height:35px; width: 35px; padding-left:7px;" data-bs-toggle="modal" data-bs-target="#exampleLargeModal4" type="button" class="btn btn-secondary"><i class="fadeIn animated bx bx-user-plus"></i>
																	</button>						
																	<button style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-success"  data-bs-toggle="modal" data-bs-target="#exampleLargeModal4"><i class='bx bx-message-square-edit'></i>
																	</button>&nbsp;<button style="height:35px; width: 35px; padding-left:7px;" type="button" class="btn btn-danger"><i class="fadeIn animated bx bx-trash-alt"></i>
																	</button>
																	</td>
									</tr>--%>
								
									   </tbody>
							   </table>
                               <hr />
                                   <div class="col-md-12">
                                <div class ="row">
                                     <div class="col-md-3" style="margin-top:35px">
                       <b> <label>Cash Credit :</label> &nbsp; <label id="lblcashes" ></label></b>
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                               <div class="col-md-3" style="margin-top:35px">
                       <b> <label>Total Cash :</label> &nbsp; <label id="totalamt"></label></b>
                        </div>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                            &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;   <div class="col-md-3" style="margin-top:35px">
                      <b>  <label>Online Cash :</label> &nbsp; <label id="totalonline"></label></b>
                        </div>
                                    </div>
                                       </div>
						   </div>
					   </div>
				   </div>
			   </div>
                        <hr />
                           <div class="card">
					   <div class="card-body">
                         <div class="card-title d-flex align-items-center">

							<h6>Cash Book(Income)</h6>
						</div>
						<hr />
                           <div class="col-md-12">
                               <div class="row">
                          <div class="col-md-2" style="margin-top: 1.5vh;">
							<button type="button" class="btn btn-primary" onclick="GetData1();"><i class='bx bx-search'></i>Search</button>
											
						   </div>
                           
                                    
                         <div class="col-md-2" style="margin-top: 1.5vh;">
                              <button class="btn btn-primary" type="button" style="float :right"  onclick="ExportData1();"> Export Data</button>
                             </div>
                                   </div>
					</div>
                           </div> 
                               </div>
                          <hr/>
				   <div class="col-md-12 mx-auto">
				   <div class="card">
					   <div class="card-body">
						   <div class="table-responsive">
							   <table id="dataemp1" class="table table-striped table-bordered" style="overflow-y:scroll">
								   <thead>
									   <tr>
										   <th>Payment Date</th>	
										   <th>Particulars</th>
										   <th>V.R</th>  
										   <th>Receipt No.</th>
										   <th>Credit Cash</th>
										   <th>Debit Expenses</th>
										   <th>Total Cash</th>
                                           <th>Online</th>
									   </tr>
								   </thead>
								   <tbody>
						
								
									   </tbody>
							   </table> 
                               <hr />
                                  <div class="col-md-12">
                               <div class="row">
                                   <div class="col-md-3" style="margin-top:35px">
                     <b>  <label>Credit Cash :</label> &nbsp; <label id="lblcareditcash"></label></b> 
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                    &nbsp;<div class="col-md-3" style="margin-top:35px">
                       <b> <label>Total Cash :</label> &nbsp; <label id="lblinccash"></label></b>
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                <div class="col-md-3" style="margin-top:35px">
                      <b>  <label>Online Cash :</label> &nbsp; <label id="lblonlinecash"></label></b>
                        </div>
                           
                                   </div>
                                      </div>
						   </div>
					   </div>
				   </div>
			   </div>
                            <div class="card">
					   <div class="card-body">
                         <div class="card-title d-flex align-items-center">

							<h6>Cash Book(Exam Fee)</h6>
						</div>
						<hr />
                           <div class="col-md-12">
                               <div class="row">
                          <div class="col-md-2" style="margin-top: 1.5vh;">
							<button type="button" class="btn btn-primary" onclick="GetDataExam();"><i class='bx bx-search'></i>Search</button>
											
						   </div>
                           
                                    
                         <div class="col-md-2" style="margin-top: 1.5vh;">
                              <button class="btn btn-primary" type="button" style="float :right"  onclick="ExportDataExam();"> Export Data</button>
                             </div>
                                   </div>
					</div>
                           </div> 
                               </div>
                          <hr/>
				   <div class="col-md-12 mx-auto">
				   <div class="card">
					   <div class="card-body">
						   <div class="table-responsive">
							   <table id="tblexamfee" class="table table-striped table-bordered" style="overflow-y:scroll">
								   <thead>
									   <tr>
										   <th>Payment Date</th>	
										   <th>Particulars</th>
										   <th>V.R</th>  
										   <th>Receipt No.</th>
										   <th>Credit Cash</th>
										   <th>Debit Expenses</th>
										   <th>Total Cash</th>
                                           <th>Online</th>
									   </tr>
								   </thead>
								   <tbody>
						
								
									   </tbody>
							   </table> 
                               <hr />
                                  <div class="col-md-12">
                               <div class="row">
                                   <div class="col-md-3" style="margin-top:35px">
                     <b>  <label>Credit Cash :</label> &nbsp; <label id="lblcareditcash1"></label></b> 
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                    &nbsp;<div class="col-md-3" style="margin-top:35px">
                       <b> <label>Total Cash :</label> &nbsp; <label id="lblexamcash"></label></b>
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                <div class="col-md-3" style="margin-top:35px">
                      <b>  <label>Online Cash :</label> &nbsp; <label id="lblonlineexamcash"></label></b>
                        </div>
                           
                                   </div>
                                      </div>
						   </div>
					   </div>
				   </div>
			   </div>
                          <hr />
                         <div class="card">
					   <div class="card-body">
                             <div class="card-title d-flex align-items-center">

							<h6>Cash Book(Expenses)</h6>
						</div>
                           <hr />
                         <div class="col-md-12">
                               <div class="row">
                                       <div class="col-md-3" style="display:none">
							<label> Payment Date From :</label>
							<input class="form-control mb-3" id="paydt2" type="date"
								aria-label="default input example" />

						</div>
                               <div class="col-md-3" style="display:none">
							<label>To :</label>
							<input class="form-control mb-3" id="paydt3" type="date"
								aria-label="default input example" />

						</div>
                                   	<div class="col-md-3"  style="display:none">
								<label>Expenses </label>
								<select id="ddlexp" class="form-select mb-3" aria-label="Default select example">
									
								</select>
							</div>
                          <div class="col-md-2" style="margin-top: 1.5vh;">
							<button type="button" class="btn btn-primary" onclick="GetData2();"><i class='bx bx-search'></i>Search</button>
											
						   </div>
                           
                                  
                         <div class="col-md-2" style="margin-top: 1.5vh;">
                              <button class="btn btn-primary" type="button" style=""  onclick="ExportData2();"> Export Data</button>
                             </div>
                                   </div>
					</div>
                           </div></div>
                        <hr />
                          <div class="col-md-12 mx-auto">
				   <div class="card">
					   <div class="card-body">
						   <div class="table-responsive">
							   <table id="dataemp2" class="table table-striped table-bordered" style="overflow-y:scroll">
								   <thead>
									   <tr>
										   <th>Payment Date</th>	
										   <th>Particulars</th>
										   <th>V.R</th>  
										   <th>Receipt No.</th>
										   <th>Credit Cash</th>
										   <th>Debit Expenses</th>
										   <th>Total Cash</th>
                                           <th>Online</th>
									   </tr>
								   </thead>
								   <tbody>
						
								
									   </tbody>
							   </table>
                                 <div class="col-md-12">
                               <div class="row">
                                     <div class="col-md-3" style="margin-top:35px">
                      <b> <label>Credit Cash :</label> &nbsp; <label id="lbltotalexpense"></label></b> 
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                    &nbsp;
                                      <div class="col-md-3" style="margin-top:35px">
                     <b>   <label>Total Cash :</label> &nbsp; <label id="lblexpesecash"></label></b>
                        </div>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                <div class="col-md-3" style="margin-top:35px">
                       <b> <label>Online Cash :</label> &nbsp; <label id="lblexpenseonlnecash"></label></b>
                        </div>
                      
                                   </div> 
                                     </div>
						   </div>
					   </div>
				   </div>
			   </div>
                           <div class="card">
					   <div class="card-body">
                           <div class="col-md-12">
                               (Cash -&nbsp;<label id="totalheadscash"></label> &nbsp;&nbsp;&nbsp;&nbsp;Online - &nbsp;<label id="lblheadsonlinecash"></label>) 
                           </div>
                           <div class="col-md-12">
                               <div class="row">
                                     <div class="col-md-2" style="margin-top: 4.7vh;float:right">
							<button type="button" class="btn btn-primary" onclick="Getsumaccount();">Calculate</button>
											
						   </div>
                               </div>
                           </div>
  <div class="col-md-12">
                               <div class="row">

                                     <div class="col-md-3" style="margin-top:35px">
                      <b> <label>Credit Cash :</label> &nbsp; <label id="lblhcash"></label></b> 
                        </div> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                    &nbsp;
                                      <div class="col-md-3" style="margin-top:35px">
                     <b>   <label>Total Expenses :</label> &nbsp; <label id="lblexpenses"></label></b>
                        </div>  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                         &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                <div class="col-md-3" style="margin-top:35px">
                       <b> <label>Closing Cash :</label> &nbsp; <label id="lblclosingcash"></label></b>
                        </div>
                      
                                   </div> 
                                     </div>
			   </div>
		   </div>			
   
				  </div>
                    </div> 
		   <div class="col">
		   <!-- Button trigger modal -->
		   <!-- Modal -->
		   <div class="modal fade" id="exampleLargeModal4" tabindex="-1" aria-hidden="true">
			   <div class="modal-dialog modal-lg">
				   <div class="modal-content">
					   <div class="modal-header">
						   <h5 class="modal-title">Academic Year Setup</h5>
						   <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
					   </div>
					   <div class="modal-body">
                           <form class="row g-2">
                           								
						<div class="col-md-3">
							<label>From date</label>
							<input class="form-control mb-3" id="dp-5" type="date"
								aria-label="default input example" />

						</div>
                           
						<div class="col-md-3">
							<label>To date</label>
							<input class="form-control mb-3" id="dp-6" type="date"
								aria-label="default input example" />
						</div>
						<div class="col-md-3">
							<label>Academic Year</label>
							<input class="form-control mb-3" id="txtyear" type="text" placeholder="Academic Year"
								aria-label="default input example" />
						</div>
						<div class="col-md-2">
						<button type="button" id="btnsave" value="Submit" class="btn btn-primary" style="margin-top:3vh;">Save</button>
						</div>	

					</form>

                           
					   <!-- <div class="modal-footer"> -->
						
						   
					   </div>
				   </div>
			   </div>
		   </div>
	   </div>
			   <div class="col">
		   <!-- Button trigger modal -->
		   <!-- Modal -->
		   <div class="modal fade" id="exampleLargeModal5" tabindex="-1" aria-hidden="true">
			   <div class="modal-dialog modal-lg">
				   <div class="modal-content">
					   <div class="modal-header">
						   <h5 class="modal-title">Academic Year Setup</h5>
						   <button type="button" class="btn-close" id="mclose" data-bs-dismiss="modal" aria-label="Close"></button>
					   </div>
					   <div class="modal-body"><form class="row g-2">
                           								
						<div class="col-md-3">
							<label>From date</label>
							<input class="form-control mb-3" id="ddlfromyear" type="date"
								aria-label="default input example" />

						</div>
                           
						<div class="col-md-3">
							<label>To date</label>
							<input class="form-control mb-3" id="ddltoyear" type="date"
								aria-label="default input example" />
						</div>
						<div class="col-md-3">
							<label>Academic Year</label>
							<input class="form-control mb-3" id="txtacdyear" type="text" placeholder="Academic Year"
								aria-label="default input example" />
						</div>
						<div class="col-md-2">
						<button type="button" id="Button1" value="Submit" class="btn btn-primary" onclick="updatedata()" style="margin-top:3vh;">Update</button>
						</div>	

					</form>

                           
					   <!-- <div class="modal-footer"> -->
						
						   
					   </div>
				   </div>
			   </div>
		   </div>
	   </div>	


				
				<!--end page wrapper -->
				<!--start overlay-->
				
		<!--end page wrapper -->
		<!--start overlay-->
		<div class="overlay toggle-icon"></div>
		<!--end overlay-->
		<!--Start Back To Top Button--> <a href="javaScript:;" class="back-to-top"><i class='bx bxs-up-arrow-alt'></i></a>
		<!--End Back To Top Button-->
		
	</div>
            </div>
</asp:Content>