| Current Path : /home2/wtmwscom/www/member/ |
| Current File : /home2/wtmwscom/www/member/daily_virtual_growth_child.php |
<?php
$title= "Daily Virtual Growth";
include 'header_plain.php';
$uid = $_SESSION['userid'];
if (!isset($_GET['commit_id'])){
redirect("./index.php");
die();
}
?>
<h1>Daily Virtual Growth</h1>
<?php echo getMessage();?>
<section>
<table style="width: 100%;">
<thead>
<tr>
<th>Day</th>
<th>Growth ID</th>
<!--<th>Commitment ID.</th>-->
<th>Date</th>
<!--<th>Package</th>-->
<th>Daily Growth</th>
<th>Growth Amount</th>
</tr>
</thead>
<tbody>
<?php
$commit_id = $_GET['commit_id'];
$query = "SELECT g.recid AS recid, g.commit_id AS commit_id, g.datetime AS datetime, g.amount AS amount, g.balance_amount AS growth_balance_amount, c.package AS package, c.amount AS commit_amount, c.vertual_amount AS vertual_amount, c.balance_amount AS balance_amount, c.is_partial_growth AS is_partial_growth, c.remaining_amount AS remaining_amount "
. "FROM `growth` g inner join commit c ON g.commit_id = c.commit_id WHERE c.commit_id='".$commit_id."' ORDER BY g.`datetime` ASC";
// if(!isset($_GET['page'])){$i=1; }else{$i=(($_GET['page']-1)*30)+1;}
// $pager = new PS_Pagination($link, $query, 30, 5);
// $pager->setDebug(true);
// $result = $pager->paginate();
//
$result = mysqli_query($connection,$query);
//echo $query;
$i=1;
$commit = mysqli_fetch_object(mysqli_query($connection,"SELECT commit_id, package, amount, vertual_amount, balance_amount, datetime FROM `commit` WHERE `commit_id`='".$commit_id."'"));
?>
<tr class="light">
<td>0</td>
<td>-</td>
<!--<td><?php echo $commit->commit_id; ?></td>-->
<td><?php echo date("d M, Y", strtotime($commit->datetime));?></td>
<td>0</td>
<td><?php echo $commit->amount ;?></td>
</tr>
<?php
if(mysqli_num_rows($result) >0) {
while ($row = mysqli_fetch_object($result)){
?>
<tr <?php if($i%2){echo "class='light'";}else{echo "class='dark'";}?>>
<td><?php echo $i; ?></td>
<td><?php echo $row->recid; ?></td>
<!--<td><?php echo $row->commit_id; ?></td>-->
<td><?php echo date("d M, Y", strtotime($row->datetime));?></td>
<?php /*<td><?php if($commit->package==1){echo '10 Days';}elseif($commit->package==2){echo '20 Days';}
elseif($commit->package==3){echo '30 Days';}?></td>*/?>
<td><?php echo $row->amount;?></td>
<td><?php echo $row->growth_balance_amount;?></td>
</tr>
<?php
$i++;} }
?>
</tbody>
</table>
<?php //echo $pager->renderFullNav();?>
</section>
<?php include 'footer_plain.php';?>