<?php 
	include("../../php_crud/my_class.php");
	$obj=new my_class();
	extract($_POST);

	$row_id = $_REQUEST['row_num'];
    $date_id      = "date_$row_id";
    $wl_id        = "wl_$row_id";
    $ww_id        = "ww_$row_id";
    $area_id      = "area_$row_id";
    $discharge_id = "dischrg_$row_id";
    $vmax_id      = "vmax_$row_id";
    $vmean_id     = "vmean_$row_id";
    $note_id      = "note_$row_id";

    $after_note_id="";  
    $next_row_val          = $row_id + 1;
    $after_note_id         = "date_$next_row_val";
    $function_for_nxt_val  = "call_next_val_loader(event,'$note_id',' $after_note_id')";
    $function_for_wl       = "call_save_function(event,'$vmean_id',' $after_note_id ','$row_id')";
    $call_key_up_function = "call_next_val_loader(event,'$date_id','$wl_id')";
	
?>
 <tr>
            <!-- <th><?php echo $sl;?></th> -->
            <th style="text-align:center;">
                <input type="text" class=" td_date" name="date-time" id="<?php echo $date_id;?>" style="text-align: center;font-weight:bold; width:60%; " value="" onkeyup="<?php echo $call_key_up_function;?>">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-mini td_wl" name="water-level" id="<?php echo $wl_id;?>" style="text-align:center;font-weight:bold; "  value=""  onkeyup="call_next_val_loader(event,'<?php echo $wl_id; ?>','<?php echo $ww_id; ?>')" onkeypress="return isDecimalInput(event)">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-small td_ww" name="water-width" id="<?php echo $ww_id;?>" style="text-align:center;font-weight:bold; " value="" onkeyup="call_next_val_loader(event,'<?php echo $ww_id;; ?>','<?php echo $area_id; ?>')" onkeypress="return isNumericInput(event)">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-small td_area" name="area" id="<?php echo $area_id;?>" style="text-align:center;font-weight:bold; " value="" onkeyup="call_next_val_loader(event,'<?php echo $area_id; ?>','<?php echo $discharge_id; ?>')" onkeypress="return isNumericInput(event)">
            </th>
            <th style="text-align:center;"> 
                <input type="text" class="input-mini td_discharge" name="discharge" id="<?php echo $discharge_id;?>" style="text-align:center;font-weight:bold; " value="" onkeyup="call_next_val_loader(event,'<?php echo $discharge_id; ?>','<?php echo $vmax_id; ?>')" onkeypress="return isNumericInput(event)">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-mini td_v_max" name="v-max" id="<?php echo $vmax_id;?>" style="text-align:center;font-weight:bold; " value="" onkeyup="call_next_val_loader(event,'<?php echo $vmax_id; ?>','<?php echo $vmean_id; ?>')" onkeypress="return isNumericInput(event)">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-mini td_v_mean" name="v-mean" id="<?php echo $vmean_id;?>" style="text-align:center;font-weight:bold; " value="" onkeyup="call_next_val_loader(event,'<?php echo $vmean_id; ?>','<?php echo  $note_id; ?>')" onkeypress="return isNumericInput(event)">
            </th>
            <th style="text-align:center;">
                <input type="text" class="input-mini td_note" name="note" id="<?php echo $note_id;?>" style="text-align:center;font-weight:bold; " value=""   onkeyup="<?php echo  $function_for_wl  ; ?>">
            </th>
             <td style="text-align: center;">
                <button class="btn btn-minier btn-purple" type="button" onclick="save_single_td_discharge_info('<?php echo $row_id; ?>','btn_click')"><i class="icon-save"></i> <b style="padding:-1%!important;">Save</b></button>

                <?php
                    if($_SESSION['delete'] == 'Y'){
                        echo '&nbsp;<button class="btn btn-minier btn-danger" type="button" onclick = "delete_tidal_data('.$row_id.')">
                        <i class="icon-trash"></i><b style="font-size: 12px;">Delete</b></button>';
                    }
                ?>
            </td>
        </tr>
    