示例#1
0
/**
 * Created by PhpStorm.
 * User: ekobudisusilo
 * Date: 26 /06 /15
 * Time: 23.37
 */
include_once '/Applications/MAMP/htdocs/isias/configs/functions.php';
if (isset($_POST['pageId']) && !empty($_POST['pageId'])) {
    $id = $_POST['pageId'];
} else {
    $id = '1';
}
$pageLimit = PAGE_PER_NO * $id;
$list = new Akuns();
$stmt = $list->GetListAkuns($pageLimit, PAGE_PER_NO);
$num = $stmt->rowCount();
if ($num > 0) {
    while ($row = $stmt->fetchAll(PDO::FETCH_ASSOC)) {
        extract($row);
        $HTML .= "<tr>";
        $HTML .= "<td>{$acc_no}</td>";
        $HTML .= "<td>{$acc_name}</td>";
        $HTML .= "<td>{$sub_acc_no}</td>";
        $HTML .= "<td>{$typeakun}</td>";
        $HTML .= "<td style='text-align:center;'>\n                <a class='btn btn-warning btn-sm' href='' role='button'><span class='glyphicon glyphicon-pencil' aria-hidden='true'></span></a>\n                <a class='btn btn-danger btn-sm' href='' role='button'><span class='glyphicon glyphicon-trash' aria-hidden='true'></span></a>\n                  </td>\n            </td>";
        $HTML .= "</tr>";
    }
} else {
    $HTML .= "<tr rowspan=5> No Data Found! </tr>";
}
示例#2
0
 * User: ekobudisusilo
 * Date: 14 /07 /15
 * Time: 23.41
 */
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(-1);
include_once '/Applications/MAMP/htdocs/isias/classes/class.Siswa.php';
include_once '/Applications/MAMP/htdocs/isias/classes/paginator.class.php';
$coa = new Akuns();
$stmt = $coa->countAll();
$num_rows = $stmt->rowCount();
$pages = new Paginator($num_rows, 19);
if (isset($_POST['cari'])) {
    $cari = $_POST['cari'];
    $stmt = $coa->GetListAkuns($cari, $pages->limit_start, $pages->limit_end);
} else {
    $stmt = $coa->GetListAkuns('', $pages->limit_start, $pages->limit_end);
}
?>

<div class="container">
    <div class="row">
        <a href="#myModal" role="button" class="btn btn-primary" data-toggle="modal" data-target="#add-Data">Akun Baru</a>
        <div class="input-prepend pull-right">
            <span class="add-on"><i class="icon-search"></i></span>
            <input class="span2" id="prependedInput" type="text" name="cari" placeholder="Pencarian..">

        </div>
    </div>
</div>
示例#3
0
<?php

ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(-1);
include_once 'classes/class.Akuns.php';
$page = isset($_GET['page']) ? $_GET['page'] : 1;
$records_per_page = 25;
$from_record_num = $records_per_page * $page - $records_per_page;
$list = new Akuns();
$stmt = $list->GetListAkuns($page, $from_record_num, $records_per_page);
$num = $stmt->rowCount();
?>


<a href="#myModal" role="button" class="btn btn-primary" data-toggle="modal">Akun Baru</a><br>
<!--define the table using the proper table tags, leaving the tbody tag empty -->
<table class="table table-condensed table-bordered table-hover" cellpadding="0" cellspacing="0">
    <thead>
        <tr>
            <th style="width:60px">No Akun</th>
            <th style="width:180px">Nama Akun</th>
            <th style="width:60px">Sub Akun</th>
            <th style="width:120px">Tipe Akun</th>
            <th style="width:60px">Status Akun</th>
            <th style="width:40px"></th>
        </tr>
    </thead>
    <tbody>
    <?php 
while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {