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


Current Path : /proc/thread-self/root/var/www/html/gsc/js/nitte/
Upload File :
Current File : //proc/thread-self/root/var/www/html/gsc/js/nitte/ExamnoDetailsPopup.js

var $g_ref_data_arr='';

$host_url= getCookie('host_url');
$image_path= getCookie('image_path');

function POpupExamnohtml($degree_code,$exam_no)
{
	$('#dialog').dialog('open');	
	$(".ui-dialog").data("height.dialog", 175);
	$(".ui-dialog").css({width:450});
	$("#dialog").css({height:176});
	$('#ui-dialog-title-dialog').html("Examno Details");	
	
	document.getElementById('dialog').style.display = '';
	$main="<table id='exam_grid' class='scroll' ondblclick='selectMarkEntrySubExamCode();'></table> <div  id='sub_grid_div3' class='scroll' style='text-align:center;'></div>";
	document.getElementById('dialog').innerHTML=$main;

	var exam =jQuery("#exam_grid").jqGrid(
	{
	url:$host_url+'ExamnoDetailsPopup.demo&DegCode='+$degree_code+'&Examno='+$exam_no+"'",
	//url:+$host_url+'ExamnoDetailsPopup.demo&DegCode='+trim($degcode)+'&searchField='+trim($Examno)+,
	datatype: 'json',
	colNames:['ExamNo','Exam Name'],
	colModel:[{name:'fexamno',index:'fexamno', width:75 },
	{name:'fexamname',index:'fexamname', width:115 }],
	rowNum:10,rowList:[5,10,15,20,25,30],
	pager: jQuery('#sub_grid_div3'),
	sortname: 'id',
	imgpath:$image_path,
	height:'100',width:'445',viewrecords: true, sortorder: 'asc',multiselect: false,cellEdit: true,
	addCaption: 'Add Record'
	}).navGrid('#sub_grid_div3',{edit:false,add:false,del:false,search:false},{},{},{},{multipleSearch:true}).
	navButtonAdd('#sub_grid_div3',{caption:"",
	buttonicon :'ui-icon-search', onClickButton:function(){exam[0].toggleToolbar() } }). 
	navButtonAdd('#sub_grid_div3',{caption:"Select", onClickButton:function()
		{
			selectMarkEntrySubExamCode();
		}
		});
	exam.filterToolbar();
	$("#gs_fexamno").focus();
			   $('.ui-search-toolbar').bind('keydown',function(evt) 
				{
					var kC  = (evt.which) ? evt.which : evt.keyCode;
				 	if(kC==40)
					jQuery('#exam_grid').editCell(0,0,false);	
				/* 	if(kC==39) 
					 $('#'+evt.target.id).focusNextInputField();
					 if(kC==37) 
					 $('#'+evt.target.id).focusPreviousInputField();	 */					
				} );
}

function selectMarkEntrySubExamCode()
{
	var id=jQuery("#exam_grid").getGridParam('selrow'); 
	if( id!=null  )   
	{  
		$.ajax({
	       type: "POST",
			async:false,
	       data: "ExamNo="+id+"&degree="+window.location.g_popup_degree_code,
	       url: $host_url+"getExamNo.demo",
 	       success: PopulateExamNoResponse
	    });
	  $('#dialog').dialog("close");
	} 
	else
	{ 
		alert("Please select row");  
	} 
	return;
}

function PopulateExamNoResponse($responce)
{
	$responce = eval('(' + $responce + ')'); 
 
	if($responce.error_code == 0)
	{
		//alert(document.getElementById('module_name_for_save').value);
		switch(document.getElementById('module_name_for_save').value)
		{
			case 'SaveMarkEntrySubjectwise':
			document.getElementById('markentry_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('markentry_sub_Exam_name').value = $responce.data['fexamname']; 
			document.getElementById('markentry_sub_final_subcode').focus();
			document.getElementById('markentry_sub_Examno').focus();
			break;
			case 'SaveMarkEntryStudentwise':
			document.getElementById('markentry_stu_Examno').value = $responce.data['fexamno'];
			document.getElementById('markentry_stu_Exam_name').value = $responce.data['fexamname'];
		    document.getElementById('markentry_stu_Examno').focus(); 
			break;
			
			case 'SaveAbsentEntrySubjectwise':
			document.getElementById('abs_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('abs_sub_Exam_name').value = $responce.data['fexamname']; 
			document.getElementById('abs_sub_Examno').focus();
			break;
			
			case 'freezeModuleAtAdminCollegeSubject':
			document.getElementById('fmacas_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('fmacas_sub_Exam_name').value = $responce.data['fexamname'];	
			document.getElementById('fmacas_category_name').focus();
			break;	
			
			case 'SavePracticalEntryFreezing':
			document.getElementById('fmacas_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('fmacas_sub_Exam_name').value = $responce.data['fexamname'];	
			document.getElementById('fmacas_sub_Examno').focus();
			break;		
			case 'saveSubjectListGeneral':
			document.getElementById('report_sublist_general_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_sublist_general_Exam_name').value = $responce.data['fexamname'];			
			document.getElementById('report_sublist_general_Examno').focus();
			break;
			case 'saveMarklistSubjectWise':
			document.getElementById('report_marklist_subject_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_subject_Exam_name').value = $responce.data['fexamname'];			
			document.getElementById('report_marklist_subject_Examno').focus();
			break;
			case 'saveMarklistStudentWise':
			document.getElementById('report_marklist_student_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_student_Examno_name').value = $responce.data['fexamname'];			
			document.getElementById('report_marklist_student_Examno').focus();
			break;
			case 'saveDatewar':
			document.getElementById('report_marklist_subject_wise_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_subject_wise_Exam_name').value = $responce.data['fexamname'];			
			document.getElementById('report_marklist_subject_wise_Examno').focus();
			break;
			
			case 'saveDispatchAnswersScript':
			if($g_dispatch_popup==2)
			{
			$Textbox = document.getElementsByName("dispatch_ans_degree");
			$NumTextBox = $Textbox.length;			
			$("#dispatch_exam_"+$NumTextBox).val($responce.data.fexamno);		
			document.getElementById('dispatch_exam_'+$NumTextBox).focus();
			}
			else
			{
			$("#dispatch_exam_1").val($responce.data.fexamno);					
			document.getElementById('dispatch_exam_1').focus();
			}
			break;
			case 'saveDailyReport':
			$id = window.location.g_daliy_id;
			document.getElementById($id).value = $responce.data['fexamno'];
			
			break;	
			case 'ReportAdmissionList':
			document.getElementById('report_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_Exam_name').value = $responce.data['fexamname'];									
			document.getElementById('report_Examno').focus();
			break;	
			case 'SaveBatchSetup':
			document.getElementById('batch_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('batch_sub_Exam_name').value = $responce.data['fexamname'];		
			document.getElementById('batch_sub_Examno').focus();			
			break;
			case 'IdentifySubjFreshEx':
			document.getElementById('fresh_Examno').value = $responce.data['fexamno'];
			document.getElementById('fresh_Exam_name').value = $responce.data['fexamname'];		
			document.getElementById('fresh_Examno').focus();
			break;
			case 'SaveAttendanceEntry':
			document.getElementById('markentry_sub_Examno').value = $responce.data['fexamno'];
			document.getElementById('markentry_sub_Exam_name').value = $responce.data['fexamname']; 
			document.getElementById('markentry_sub_Examno').focus();
			break;
			case 'saveAttendanceSummary':
			document.getElementById('report_marklist_subject_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_subject_Exam_name').value = $responce.data['fexamname']; 
			document.getElementById('report_marklist_subject_Examno').focus();
			break;
			case 'Update Section':
			document.getElementById('stud_section_Examno').value = $responce.data['fexamno'];
			document.getElementById('stud_section_Examno_name').value = $responce.data['fexamname']; 
			document.getElementById('stud_section_Examno').focus();
			break;
			case 'Marks List (Elements)':
			document.getElementById('report_marklist_subject_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_subject_Exam_name').value = $responce.data['fexamname'];			
			document.getElementById('report_marklist_subject_Examno').focus();
			break;
			case 'batch preparation Dairy':
			document.getElementById('report_batch_prepation_examno_code').value = $responce.data['fexamno'];
			document.getElementById('report_batch_prepation_examno_name').value = $responce.data['fexamname'];			
			document.getElementById('report_batch_prepation_examno_code').focus();
			break;
			case 'I.A Marks Pending':
			document.getElementById('report_marklist_student_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_marklist_student_Examno_name').value = $responce.data['fexamname'];			
			document.getElementById('report_marklist_student_Examno').focus();
			break;
			case 'Practical Daily Report':
			document.getElementById('report_topsheet_Examno').value = $responce.data['fexamno'];
			document.getElementById('report_topsheet_Examno_name').value = $responce.data['fexamname'];			
			document.getElementById('report_topsheet_Examno').focus();
			break;
		}	
			
	}
	
}