| Server IP : 172.67.187.206 / Your IP : 162.159.115.41 Web Server : Apache/2.4.25 (Win32) OpenSSL/1.0.2j PHP/5.6.30 System : Windows NT WIN-ECQAAA40806 6.2 build 9200 (Windows Server 2012 Standard Edition) i586 User : SYSTEM ( 0) PHP Version : 5.6.30 Disable Function : NONE MySQL : ON | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : E:/Inetpub/www/news/csr/admin/pages/ |
Upload File : |
<?php
if(isset($ugroup)){
?>
<div class="row">
<div class="col-xl-12">
<div class="breadcrumb-holder">
<h1 class="main-title float-left"><?php if($ugroup=="donate"){}else{ echo "<i class='fa fa-university'></i>";}?> <?php if($ugroup=="school"){ echo "โรงเรียน"; }?><?=$fullname;?></h1>
<ol class="breadcrumb float-right">
<li class="breadcrumb-item">Home</li>
<li class="breadcrumb-item active"><?=$ugroup;?></li>
</ol>
<div class="clearfix"></div>
</div>
</div>
</div>
<?php
// Msg แจ้งเตือนการทำงาน
if(isset($_GET['msg'])){ ?>
<script type="text/javascript">
$(window).on('load',function(){
$('#msgAlert').modal('show');
});
</script>
<?php } else {} ?>
<?php include ("pages/modals/modal_msg.php");?>
<!-- end row -->
<link rel="stylesheet" type="text/css" href="<?php echo ADMIN_URL;?>/assets/plugins/datatables/dataTables.bootstrap4.min.css"/>
<script type="text/javascript" src="<?php echo ADMIN_URL;?>/assets/plugins/datatables/jquery.dataTables.min.js"></script>
<script type="text/javascript" src="<?php echo ADMIN_URL;?>/assets/plugins/datatables/dataTables.bootstrap4.min.js"></script>
<link rel="stylesheet" href="<?php echo ADMIN_URL;?>/assets/css/bootstrap-select.css">
<script src="<?php echo ADMIN_URL;?>/assets/js/bootstrap-select.js"></script>
<script>
// START CODE FOR BASIC DATA TABLE
$(document).ready(function() {
$('#example1').DataTable();
} );
$(document).ready(function() {
$('#table1').DataTable();
} );
// END CODE FOR BASIC DATA TABLE
</script>
<style type="text/css">
table.dataTable tbody th, table.dataTable tbody td {
padding: 3px 2px;
}
</style>
<div class="row">
<div class="col-lg-12">
<div class="card mb-3">
<div class="card-header">
<span class="pull-right">
<a href="account.php?page=addrequirements&op31=1"><button class="btn btn-primary btn-sm"><i class="fa fa-user-plus" aria-hidden="true"></i> เพิ่มข้อมูล</button></a>
<a href="Export/Export_student.php"><button class="btn btn-success m-l-5 btn-sm"><i class="fa fa-file-excel-o" aria-hidden="true"></i> ส่งออก</button></a>
<a href="account.php?page=studentreport&op4=1"><button class="btn btn-secondary m-l-5 btn-sm"><i class="fa fa-print" aria-hidden="true"></i> พิมพ์ข้อมูล</button></a>
</span>
<h3><i class="fa fa-table"></i> ความต้องการขอรับบริจาค</h3>
</div>
<div class="card-body">
<!-- ส่วนของฟอร์มข้อมูล-->
<?php
//เผื่อไว้แสดงข้อมูลปีปัจจุบัน
$setyear=date("Y")+543;
?>
<table id="example1" data-page-length="10" class="table table-bordered table-hover display" cellspacing="0" width="100%">
<thead>
<tr>
<th><center>ที่</center></th>
<th><center>รายการ</center></th>
<th><center>จำนวน</center></th>
<th><center>งบประมาณ</center></th>
<th><center>ราคากลาง</center></th>
<th><center>วันที่ขอ</center></th>
<th><center>สถานะ</center></th>
<th><center>ดำเนินการ</center></th>
</tr>
</thead>
<tbody>
<?php
$table ="requirements";
$sql= $mysqli->query("SELECT
*
FROM
`tb_requirements`
INNER JOIN `tb_category_detail` ON `tb_requirements`.`r_type` =
`tb_category_detail`.`Did` where rcode='$user' AND r_status='$ugroup' AND `r_donate` IS NULL ORDER BY Id DESC");
$i = 0;
while($row=mysqli_fetch_array($sql)) {
$i++;
?>
<tr>
<td align="center" width="10"><?php echo "$i"; ?></td>
<td> <?=$row['d_title'];?> <font color="#608FFE"><?=$row['r_detail'];?></font></td>
<td align="center"><?=$row['r_max'];?></td>
<td align="center" width="120"><?=number_format($row['r_sarary'],2);?></td>
<td align="center" width="120"><?=number_format($row['d_price'],2);?></td>
<td align="center"><?=$row['r_date'];?></td>
<td align="center"><?php if($row['r_donate']<1){ ?>
<a href="#" data-toggle="modal" data-target="#modal_doclose<?=$row['Id'];?>"><font color="#477CF9"><i class="fa fa-pencil-square-o" aria-hidden="true"></i></font></a>
รอบริจาค
<?php }else{ echo "<font color='#33cc33'>บริจาคแล้ว</font>";}?></td>
<td align="center">
<a href="#" data-toggle="modal" data-target="#modal_price<?=$row['Id'];?>"><font color="#477CF9"><i class="fa fa-pencil-square-o" aria-hidden="true"></i></font></a>
<a href="#" data-toggle="modal" data-target="#modal_delete<?=$row['Id'];?>"><font color="red"><i class="fa fa-trash-o" aria-hidden="true"></i></font></a>
<?php include ("modals/modal_delete.php");?>
<?php include ("modals/modal_price.php");?>
<?php include ("modals/modal_doclose.php");?>
</td>
</tr>
<?php } ?>
</tbody>
</table>
<!-- สจบ่วนของฟอร์มข้อมูล-->
</div>
</div><!-- end card-->
</div>
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-6 col-xl-12">
<div class="card mb-3">
<div class="card-header">
<span class="pull-right">
<a href="Export/Export_student.php"><button class="btn btn-success m-l-5 btn-sm"><i class="fa fa-file-excel-o" aria-hidden="true"></i> ส่งออก</button></a>
<a href="account.php?page=studentreport&op4=1"><button class="btn btn-secondary m-l-5 btn-sm"><i class="fa fa-print" aria-hidden="true"></i> พิมพ์ข้อมูล</button></a>
</span>
<h3><i class="fa fa-table"></i> ประวัติการประกาศรับบริจาค</h3>
</div>
<div class="card-body">
<div class="table-responsive">
<!-- ส่วนของฟอร์มข้อมูล-->
<table id="table1" data-page-length="10" class="table table-bordered table-hover display" cellspacing="0" width="100%">
<thead>
<tr>
<th><center>ที่</center></th>
<th><center>รายการ</center></th>
<th><center>จำนวน</center></th>
<th><center>งบประมาณ</center></th>
<th><center>ราคากลาง</center></th>
<th><center>วันที่ขอ</center></th>
</tr>
</thead>
<tbody>
<?php
$table ="requirements";
$sql= $mysqli->query("SELECT
*
FROM
`tb_requirements`
INNER JOIN `tb_category_detail` ON `tb_requirements`.`r_type` =
`tb_category_detail`.`Did` where rcode='$user' AND r_status='$ugroup' AND `r_donate`='Close' ORDER BY Id DESC");
$i = 0;
while($row=mysqli_fetch_array($sql)) {
$i++;
?>
<tr>
<td align="center" width="10"><?php echo "$i"; ?></td>
<td> <?=$row['d_title'];?> <font color="#608FFE"><?=$row['r_detail'];?></font></td>
<td align="center"><?=$row['r_max'];?></td>
<td align="center" width="120"><?=number_format($row['r_sarary'],2);?></td>
<td align="center" width="120"><?=number_format($row['d_price'],2);?></td>
<td align="center"><?=$row['r_date'];?></td>
</tr>
<?php } ?>
</tbody>
</table>
<!-- สจบ่วนของฟอร์มข้อมูล-->
</div>
</div>
</div><!-- end card-->
</div>
</div>
<?php }else{
header("Location: ../index.php?msg=error");
exit;
} ?>