mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-09-02 05:31:36 +08:00
Connection类getAttribute方法 改成 getConfig 增加setConfig方法 Model类类型转换支持格式定义
This commit is contained in:
@@ -167,11 +167,23 @@ abstract class Connection
|
||||
* @param string $config 配置名称
|
||||
* @return mixed
|
||||
*/
|
||||
public function getAttribute($config)
|
||||
public function getConfig($config)
|
||||
{
|
||||
return $this->config[$config];
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置数据库的配置参数
|
||||
* @access public
|
||||
* @param string $config 配置名称
|
||||
* @param mixed $value 配置值
|
||||
* @return void
|
||||
*/
|
||||
public function setConfig($config, $value)
|
||||
{
|
||||
$this->config[$config] = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* 连接数据库方法
|
||||
* @access public
|
||||
|
||||
Reference in New Issue
Block a user