<?php 

function maintain_students_in_class_cb() {
	?>
	<div class="row">
		<div class="col-md-12">
			<div class="card card-primary">
				<div class="card-header">
					<h3 class="card-title"></h3>
				</div>
				<div class="card-body">

					<form method="post" action="contents/plugins/eedu_portal/ajax.php" id="maintain_students_in_class_form">
						<input type="hidden" name="to_class" id="to_class" value="<?php echo $_GET['class'] ?>">
						<input type="hidden" name="to_category" id="to_category" value="<?php echo $_GET['category'] ?>">
						<input type="hidden" name="to_term" id="to_term" value="<?php echo $_GET['term'] ?>">
						<input type="hidden" name="to_session" id="to_session" value="<?php echo $_GET['session'] ?>">
						<?php 
							do_action("eedu_portal_class_filter", ['required' => 'required', 'hint' => 'Current term: '.get_full_term_name(get_option('current_academic_term'))]);
							
						?>
						<div class="col-md-12">
							<small>By clicking on the submit button, you are pushing the students of the selected class to <?php echo get_class_name($_GET['class'], $_GET['category']) . " " . get_full_term_name($_GET['term']) ?></small><br>
							<?php 
								submit_btn('maintain_students_in_class', 'Submit');
							 ?>
						</div>
					</form>
				</div>
			</div>
		</div>
	</div>
	<?php
	global $post_meta;
	add_page_javascript('app/assets/js/page-scripts/submit.js');
}