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



Your IP : 3.147.126.199


Current Path : /var/www/html/vskub/js/
Upload File :
Current File : /var/www/html/vskub/js/ack_chalentries.js

function CallEnableAdmChallanEntries()
{
    $("#page_main_div").load('html_modules/challan_adm_entry.html',function(){
		document.getElementById('display_module_name').innerHTML = 'Acknowledge Challan';
		document.getElementById('module_name_for_save').value = 'Challan Entries';
		getDefaultHeadFooterLinks('Acknowledge Admission Challan'); 
		 $(".ui-tabs .ui-tabs-panel").css("padding","0px");
		$(".ui-tabs .ui-tabs-panel").css("padding-top","21px");
		DisplayChallanEntryDetails();
	}); 		
}
function DisplayChallanEntryDetails()
{
	$.ajax({
        type: "POST",
		data:"",
	   	url: $host_url+"DisplayAdmChallanEntryDetails",
		success:DisplayChallanEntryDetailsResponce
  });
} 
function DisplayChallanEntryDetailsResponce(responce)
{
	responce = eval('(' + responce + ')');
	$("#challan_entry").html("");
	$("#challan_entry").html(responce.data['html']);
		
}
function DeleteChallanDetails(FDOCNO)
{
	var flag=confirm("Do you want to Delete Application");
	if(flag)
	{
		$.ajax({
	        type: "POST",
			data:"&FDOCNO="+FDOCNO,
		   	url: $host_url+"DeleteAdmChallanDetails",
			success: function DeleteChallanDetailsResponce(responce)
			{
				responce = eval('(' + responce + ')');
				if(responce.error_code == 0 )
				{
					alert(responce.data);
					DisplayChallanEntryDetails();
				}
				else
				{
					alert(responce.data);
				}
			}
		});
	}
}

function DeleteDocNoFromChallanDetails(FDOCNO,APPNO)
{
	var flag=confirm("Do you want to Delete Challan");
	if(flag)
	{
		$.ajax({
	        type: "POST",
			data:"&APPNO="+APPNO+"&FDOCNO="+FDOCNO,
		   	url: $host_url+"DeleteAdmDocNoFromChallanDetails",
			success: function DeleteDocNoFromChallanDetailsResponce(responce)
			{
				responce = eval('(' + responce + ')');
				ShowAdmApplicationsForDocNo(FDOCNO)
			}
		});
	}
}
function EnableAdmChallanUpdateScreen(FDOCNO)
{
	$("#challan_entry").html("");
	$("#challan_entry").load('html_modules/adm_challan_entry_update.html',function(){
		$("#doc_id").html("Challan Reference Number: "+FDOCNO);
		ShowAdmApplicationsForDocNo(FDOCNO);
		$("#challan_details_update").bind( "click", function() {
			UpdateChallanDetailsForDoc(FDOCNO);
		});
	}); 
}

function UpdateChallanDetailsForDoc(FDOCNO)
{
	 var challan_no=$("#challan_no").val();
	 var challan_date=date_format($("#challan_date").val());
	 var challan_amt=$("#challan_amt").val();
	 if(empty(challan_no))
	 {
		 alert("Please Enter Challan No");
		 $("#challan_no").focus();
		 return false;
	 }
	 else if(empty(challan_amt))
	 {
		 alert("Please Enter Challan No");
		 $("#challan_amt").focus();
		 return false;
	 }
	 var lst_str="&challan_no="+challan_no;
	 lst_str+="&challan_date="+challan_date;
	 lst_str+="&challan_amt="+challan_amt;
	 
	$.ajax({
        type: "POST",
		data:"&FDOCNO="+FDOCNO+lst_str,
	   	url: $host_url+"UpdateAdmChallanDetailsForDoc",
		success: function UpdateChallanDetailsForDocResponce(responce)
		{
			responce = eval('(' + responce + ')');
			if(responce.error_code==0)
			{
				alert(responce.data);
				CallEnableAdmChallanEntries();
			}
			else
			{
				alert(responce.data);
			}
		}					
	}); 
}

function ShowAdmApplicationsForDocNo(FDOCNO)
{
	$.ajax({
        type: "POST",
		data:"&FDOCNO="+FDOCNO,
	   	url: $host_url+"ShowAdmApplicationsForDocNo",
		success: function ShowApplicationsForDocNoResponce(responce)
		{
			responce = eval('(' + responce + ')');
			$("#challan_update_applications").html('');
			$("#challan_update_applications").html(responce.data['html']);
			var data_obj=responce.data['data'];
			$("#challan_no").val(data_obj['chalno']);
			$("#challan_date").val(data_obj['fchaldate']);
			$("#challan_amt").val(data_obj['fchalamt']);
			$("#td_challan_tot").val(data_obj['fchalamt']);
		}
	}); 
}
function PrintAdmChallanEntryDetails(doc_no)
{
	window.location.href=$host_url+"PrintAdmChallanEntryDetails&doc_no="+doc_no+'&print_type=College';
}