Example #1
0
function gmgt_measurement_view()
{
    $obj_workout = new Gmgtworkout();
    $curr_user_id = get_current_user_id();
    $obj_gym = new Gym_management($curr_user_id);
    $user_id = $_REQUEST['user_id'];
    $measurement_data = $obj_workout->get_all_measurement_by_userid($user_id);
    ?>
		<div class="form-group"> 	<a href="#" class="close-btn badge badge-success pull-right">X</a>
			<h4 class="modal-title" id="myLargeModalLabel">
				<?php 
    echo gym_get_display_name($user_id) . __(' MediciĆ³n', 'gym_mgt');
    ?>
			</h4>
		</div>
		<hr>
		<div class="panel-body">
			<div class="table-responsive box-scroll">
        		<table id="measurement_list" class="display table" cellspacing="0" width="100%">
		        	 <thead>
		            	<tr>						
						<th><?php 
    _e('Measurement', 'gym_mgt');
    ?>
</th>
						<th><?php 
    _e('Result', 'gym_mgt');
    ?>
</th>			
					    <th><?php 
    _e('Record Date', 'gym_mgt');
    ?>
</th>		
					     <th><?php 
    _e('Action Date', 'gym_mgt');
    ?>
</th>				            
		            	</tr>		            	 
		        	</thead>
		        	<tbody>
		        	<?php 
    if (!empty($measurement_data)) {
        foreach ($measurement_data as $retrieved_data) {
            ?>
			        		<tr id="row_<?php 
            echo $retrieved_data->measurment_id;
            ?>
">
			        			<td class="recorddate"><?php 
            echo $retrieved_data->result_measurment;
            ?>
</td>
								<td class="duration"><?php 
            echo $retrieved_data->result;
            ?>
</td>
								<td class="result"><?php 
            echo $retrieved_data->result_date;
            ?>
</td>
								<td class="result">
								<?php 
            if ($obj_gym->role == 'Administrator') {
                ?>
								<a href="?page=gmgt_workout&tab=addmeasurement&action=edit&measurment_id=<?php 
                echo $retrieved_data->measurment_id;
                ?>
" class="btn btn-info">
								<?php 
            } else {
                ?>
								<a href="?dashboard=user&page=workouts&tab=addmeasurement&action=edit&measurment_id=<?php 
                echo $retrieved_data->measurment_id;
                ?>
" class="btn btn-info">
								<?php 
            }
            _e('Edit', 'gym_mgt');
            ?>
</a>
								 <a href="#" class="btn btn-danger measurement_delete" data-val="<?php 
            echo $retrieved_data->measurment_id;
            ?>
"><?php 
            _e('Delete', 'gym_mgt');
            ?>
</a>
								</td>
			        		</tr>
		        		<?php 
        }
    } else {
        ?>
		        		<tr>
		        		<td colspan=3> <?php 
        _e('No Record Found', 'gym_mgt');
        ?>
</td>
		        		</tr>
		        	<?php 
    }
    ?>
		        	</tbody>
		        	
		        </table>
		</div>
		<?php 
    die;
}
Example #2
0
<?php

$curr_user_id = get_current_user_id();
$obj_gym = new Gym_management($curr_user_id);
$obj_workouttype = new Gmgtworkouttype();
$obj_workout = new Gmgtworkout();
$active_tab = isset($_REQUEST['tab']) ? $_REQUEST['tab'] : 'workoutlist';
?>
<script type="text/javascript">
$(document).ready(function() {
	jQuery('#workout_list').DataTable({
		"responsive": true,
		 "order": [[ 1, "asc" ]],
		 "aoColumns":[
					  {"bSortable": false},
	                  {"bSortable": true},
	                  {"bSortable": true},
	                  {"bSortable": true},
					 {"bSortable": false}]
		});
} );
</script>
<!-- POP up code -->
<div class="popup-bg">
    <div class="overlay-content">
    <div class="modal-content">
    <div class="invoice_data">
     </div>
     
    </div>
    </div> 
Example #3
0
<?php

$obj_workouttype = new Gmgtworkouttype();
$obj_workout = new Gmgtworkout();
$active_tab = isset($_GET['tab']) ? $_GET['tab'] : 'workoutlist';
?>
<!-- POP up code -->
<div class="popup-bg">
    <div class="overlay-content">
    <div class="modal-content">
    <div class="invoice_data">
     </div>
     
    </div>
    </div> 
    
</div>
<!-- End POP-UP Code -->

<div class="page-inner" style="min-height:1631px !important">
<div class="page-title">
		<h3><img src="<?php 
echo get_option('gmgt_system_logo');
?>
" class="img-circle head_logo" width="40" height="40" /><?php 
echo get_option('gmgt_system_name');
?>
</h3>
	</div>
	<?php 
if (isset($_POST['save_workout'])) {