芝麻web文件管理V1.00
编辑当前文件:/home/mgatv524/public_html/migrations/20190509113001_add_report_page_migration.php
. */ use Phinx\Migration\AbstractMigration; /** * Class AddReportPageMigration */ class AddReportPageMigration extends AbstractMigration { /** @inheritdoc */ public function change() { $pages = $this->table('pages'); // add report page if (!$this->fetchRow('SELECT * FROM pages WHERE name = \'report\'')) { $pages->insert([ 'name' => 'report', 'title' => 'Report', 'asHome' => 0 ])->save(); } } }