2016-09-21 13:42:40 +05:30
|
|
|
<?php
|
2019-09-18 04:44:05 +05:30
|
|
|
declare(strict_types=1);
|
|
|
|
|
2016-09-21 13:42:40 +05:30
|
|
|
namespace common\db\mysql;
|
|
|
|
|
2019-09-18 04:44:05 +05:30
|
|
|
use SamIT\Yii2\MariaDb\JsonExpressionBuilder;
|
|
|
|
use SamIT\Yii2\MariaDb\Schema as MysqlSchema;
|
2016-09-21 13:42:40 +05:30
|
|
|
|
|
|
|
class Schema extends MysqlSchema {
|
|
|
|
|
|
|
|
public function createQueryBuilder() {
|
2019-09-18 04:44:05 +05:30
|
|
|
$result = new QueryBuilder($this->db);
|
|
|
|
$result->setExpressionBuilders([
|
|
|
|
'yii\db\JsonExpression' => JsonExpressionBuilder::class,
|
|
|
|
]);
|
|
|
|
|
|
|
|
return $result;
|
2016-09-21 13:42:40 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
}
|