Advertisement
Bedhoel

Untitled

Jul 9th, 2018
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.84 KB | None | 0 0
  1. <?php
  2.  
  3. use yii\helpers\Html;
  4. use kartik\grid\GridView;
  5.  
  6. /* @var $this yii\web\View */
  7. /* @var $searchModel app\models\DataVideoWebSearch */
  8. /* @var $dataProvider yii\data\ActiveDataProvider */
  9.  
  10. $this->title = 'Harian SOR';
  11. $this->params['breadcrumbs'][] = $this->title;
  12.  
  13.  
  14.  
  15. ?>
  16. <style type="text/css">
  17.   .table th {
  18.        text-align: center;  
  19.        font-weight:bold;
  20.     }
  21.     #example>tbody>tr>td
  22.     {
  23.       white-space: nowrap;
  24.     }
  25. </style>
  26. <div id="table_data">
  27.   <table id="example" class="display table table-striped custom-table datatable">
  28.       <thead>
  29.           <tr>
  30.               <th class="text-center">Tanggal</th>
  31.               <th class="text-center">Loket</th>
  32.               <th class="text-center">Group Layanan</th>
  33.               <th class="text-center">Sub Group Layanan</th>
  34.               <th class="text-center">Permohonan</th>
  35.               <th class="text-center">Perihal</th>
  36.               <th class="text-center">Nama</th>
  37.               <th class="text-center">Jenis Kelamin</th>
  38.               <th class="text-center">Intansi / Perusahaan</th>
  39.               <th class="text-center">Provinsi</th>
  40.               <th class="text-center">Kota / Kabupaten</th>
  41.               <th class="text-center">Action</th>
  42.           </tr>
  43.       </thead>
  44.       <tbody>
  45.       </tbody>
  46.       <tfoot>
  47.               <th class="text-center">Tanggal</th>
  48.               <th class="text-center">Loket</th>
  49.               <th class="text-center">Group Layanan</th>
  50.               <th class="text-center">Sub Group Layanan</th>
  51.               <th class="text-center">Permohonan</th>
  52.               <th class="text-center">Perihal</th>
  53.               <th class="text-center">Nama</th>
  54.               <th class="text-center">Jenis Kelamin</th>
  55.               <th class="text-center">Intansi / Perusahaan</th>
  56.               <th class="text-center">Provinsi</th>
  57.               <th class="text-center">Kota / Kabupaten</th>
  58.               <th class="text-center">Action</th>
  59.             </tfoot>
  60.   </table>
  61. </div>
  62.  
  63.  
  64.  
  65. <script type="text/javascript">
  66. $(document).ready(function() {
  67.    $(".content-wrapper").hide();
  68.    $(".content-header").remove();
  69.    $(".main-header").remove();
  70.    $(".main-sidebar").remove();
  71.    $(".main-footer").remove();
  72.    $(".skin-blue .wrapper, .skin-blue .main-sidebar, .skin-blue .left-side").css('background-color','#FFF');
  73.    $('.content-wrapper').css('min-height','0');
  74.    $('.content-wrapper').css('margin-left','0px');
  75.    $('.content-wrapper').css('background-color','#FFFFFF');
  76.    $(".content-wrapper").show();
  77.   var url      = "<?php echo dirname(Yii::$app->homeUrl) ?>/serverside/table.php?jenis=<?php echo $_GET['req'] ?>";
  78.   var id_table = "example";
  79.   <?php
  80.   $coldef = array(
  81.                   '{ "orderable": true, "targets": 0, "searchable": true}',
  82.                   '{ "orderable": true, "targets": 1, "searchable": true}',
  83.                   '{ "orderable": true, "targets": 2, "searchable": true}',
  84.                   '{ "orderable": true, "targets": 3, "searchable": true}',
  85.                   '{ "orderable": true, "targets": 4, "searchable": true}',
  86.                   '{ "orderable": true, "targets": 5, "searchable": true}',
  87.                   '{ "orderable": true, "targets": 6, "searchable": true}',
  88.                   '{ "orderable": true, "targets": 7, "searchable": true}',
  89.                   '{ "orderable": true, "targets": 8, "searchable": true}',
  90.                   '{ "orderable": true, "targets": 9, "searchable": true}',
  91.                   '{ "orderable": true, "targets": 10, "searchable": true}',
  92.                   '{ "orderable": false, "targets": 11, "searchable": false}'
  93.             );
  94.   $list_col = "[".implode("",$coldef)."]";
  95.   ?>
  96.  var coldef   = '<?php echo $list_col; ?>';
  97.  var mycol = coldef.replace(/\s+/g," ");
  98.   getDataTables(url,id_table,mycol);
  99.  
  100.          
  101. });  
  102. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement