<?php

use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class RenameArticleToCmsHelp extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        if (\ModStart\Core\Dao\ModelManageUtil::hasTable('article')) {
            Schema::rename('article', 'cms_help');
        }
        if (\ModStart\Core\Dao\ModelManageUtil::hasTable('article_category')) {
            Schema::rename('article_category', 'cms_help_category');
        }
        if (\ModStart\Core\Dao\ModelManageUtil::hasTable('quick_nav')) {
            Schema::rename('quick_nav', 'cms_help_quick_nav');
        }
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {

    }
}
