penambahan phpdoc dan perubahan semua class mengacu hanya pada $app

This commit is contained in:
2026-08-27 12:01:54 +07:00
parent 64e9c02c38
commit a2978ae927
17 changed files with 264 additions and 59 deletions
+16 -3
View File
@@ -3,7 +3,6 @@
/*******************************************************************
Module : /DB/CheckSQL.php
Desc. : Class Check SQL / Repair Database
Created By : Siau Pheng ([email protected]).
Created Date : May 11th, 2011.
Last Modified : August 21st, 2026.
@@ -20,14 +19,28 @@ use \Exception;
use \flight\Engine;
use \flight\database\SimplePdo;
/**
* Class CheckSQL
*
* Check Database Mysql/MariaDB dan Repair.
*
* @license MIT, https://www.3fonia.com
* @copyright Copyright (c) 2008-2026, Siau Pheng <[email protected]>
*
* @package Webapp\DB
*/
final class CheckSQL {
private Array $__atabel = [];
protected Engine $app;
protected SimplePdo $db;
public function __construct(Engine $app, SimplePdo $db) {
/**
* @param Engine $app
*/
public function __construct(Engine $app) {
$this->app = $app;
$this->db = $db;
$this->db = $app->db();
$nama_db = $this->db->fetchField('SELECT DATABASE()');
$arow = $this->db->fetchAll("SELECT TABLE_NAME,ENGINE,TABLE_ROWS FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA='".$nama_db."' AND TABLE_TYPE='BASE TABLE'");
foreach ($arow as $row) {