提交 dc26d89d 编写于 作者: T teebbstudios

just simple config

上级 f9b998cd
......@@ -29,7 +29,7 @@ APP_SECRET=1e0a0e96d4ade8189745bcdd2946c25f
# For an SQLite database, use: "sqlite:///%kernel.project_dir%/var/data.db"
# For a PostgreSQL database, use: "postgresql://db_user:db_password@127.0.0.1:5432/db_name?serverVersion=11&charset=utf8"
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml
DATABASE_URL=mysql://root:4713056Qwwdezone!@127.0.0.1:3306/teebb?serverVersion=5.7
DATABASE_URL=mysql://root:4713056Qwwdezone!@127.0.0.1:3306/teebb_%kernel.environment%?serverVersion=5.7
###< doctrine/doctrine-bundle ###
###> nelmio/cors-bundle ###
......
......@@ -14,3 +14,5 @@ framework:
#fragments: true
php_errors:
log: true
ide: phpstorm
\ No newline at end of file
teebb_core:
# mapping:
# directories: ['%kernel.project_dir%/src/Entity']
\ No newline at end of file
mapping:
directories: ['%kernel.project_dir%/src']
\ No newline at end of file
framework:
default_locale: en
default_locale: '%locale%'
translator:
default_path: '%kernel.project_dir%/translations'
fallbacks:
......
......@@ -4,6 +4,7 @@
# Put parameters here that don't need to change on each machine where the app is deployed
# https://symfony.com/doc/current/best_practices/configuration.html#application-related-configuration
parameters:
locale: 'zh_CN'
services:
# default configuration for services in *this* file
......
此差异已折叠。
<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20200602072441 extends AbstractMigration
{
public function getDescription() : string
{
return '';
}
public function up(Schema $schema) : void
{
// this up() migration is auto-generated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('CREATE TABLE teebb_content_type (id INT AUTO_INCREMENT NOT NULL, name VARCHAR(255) NOT NULL, alias VARCHAR(255) NOT NULL, description LONGTEXT NOT NULL, created_at DATETIME NOT NULL, updated_at DATETIME NOT NULL, PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
}
public function down(Schema $schema) : void
{
// this down() migration is auto-generated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('DROP TABLE teebb_content_type');
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册