Beispiel #1
0
<?php

require_once "model/Ptype.php";
$model = new Ptype();
$link = "index.php?mod=project_type&act=list";
if (isset($_GET['status']) && $_GET['status'] > 0) {
    $lang_id = (int) $_GET['status'];
    $status .= "&status={$status}";
} else {
    $status = -1;
}
$listTotal = $model->getListPtypeByStatus($status, -1, -1);
$total_record = mysql_num_rows($listTotal);
$total_page = ceil($total_record / LIMIT);
$page = isset($_GET['page']) ? (int) $_GET['page'] : 1;
$offset = LIMIT * ($page - 1);
$list = $model->getListPtypeByStatus($status, $offset, LIMIT);
?>
<div class="row">
    <div class="col-md-12">
    <button class="btn btn-primary btn-sm right" onclick="location.href='index.php?mod=project_type&act=form'">Tạo mới</button>
         <div class="box-header">
                <h3 class="box-title">Danh sách loại dự án</h3>
            </div><!-- /.box-header -->
        <div class="box">

            <div class="box-body">
                <table class="table table-bordered table-striped">
                    <tbody><tr>
                        <th style="width: 10px">No.</th>
                        <th>Name</th>