where方法支持null和notnull表达式查询 model类db方法改为protected

This commit is contained in:
thinkphp
2016-04-07 11:26:44 +08:00
parent 3691114bef
commit f8a35a1be4
2 changed files with 35 additions and 33 deletions

View File

@@ -617,10 +617,10 @@ abstract class Model implements \JsonSerializable, \ArrayAccess
/**
* 初始化数据库对象
* @access private
* @access protected
* @return object
*/
private static function db()
protected static function db()
{
$model = get_called_class();
$name = basename(str_replace('\\', '/', $model));