This commit is contained in:
as2252258@163.com
2021-07-03 14:16:01 +08:00
parent de475736ba
commit bcf865ff34
+2 -1
View File
@@ -26,6 +26,7 @@ use Exception;
use HttpServer\Http\Context; use HttpServer\Http\Context;
use ReflectionException; use ReflectionException;
use Snowflake\Abstracts\Component; use Snowflake\Abstracts\Component;
use Snowflake\Abstracts\Config;
use Snowflake\Abstracts\TraitApplication; use Snowflake\Abstracts\TraitApplication;
use Snowflake\Event as SEvent; use Snowflake\Event as SEvent;
use Snowflake\Exception\NotFindClassException; use Snowflake\Exception\NotFindClassException;
@@ -1047,7 +1048,7 @@ abstract class BaseActiveRecord extends Component implements IOrm, ArrayAccess
*/ */
public static function getDbName() public static function getDbName()
{ {
return static::$ab_name; return Config::get('databases.connections.' . static::$ab_name . '.database');
} }