mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-01 12:42:48 +08:00
修正traits引入
This commit is contained in:
@@ -11,13 +11,13 @@
|
||||
|
||||
namespace think;
|
||||
|
||||
T('controller/view');
|
||||
T('controller/jump');
|
||||
T('controller/View');
|
||||
T('controller/Jump');
|
||||
|
||||
class Controller
|
||||
{
|
||||
use \traits\controller\jump;
|
||||
use \traits\controller\view;
|
||||
use \traits\controller\Jump;
|
||||
use \traits\controller\View;
|
||||
|
||||
/**
|
||||
* 前置操作方法列表
|
||||
|
||||
@@ -11,11 +11,11 @@
|
||||
|
||||
namespace think\model;
|
||||
|
||||
T('model/adv');
|
||||
T('model/query');
|
||||
T('model/Adv');
|
||||
T('model/Query');
|
||||
|
||||
class Adv extends \think\model
|
||||
class Adv extends \think\Model
|
||||
{
|
||||
use \traits\model\adv;
|
||||
use \traits\model\query;
|
||||
use \traits\model\Adv;
|
||||
use \traits\model\Query;
|
||||
}
|
||||
|
||||
@@ -13,15 +13,15 @@ namespace think\model;
|
||||
use think\Lang;
|
||||
use think\Loader;
|
||||
|
||||
T('modle/adv');
|
||||
T('modle/Adv');
|
||||
|
||||
/**
|
||||
* MongoModel模型类
|
||||
* 实现了ODM和ActiveRecords模式
|
||||
*/
|
||||
class Mongo extends \Think\Model
|
||||
class Mongo extends \think\Model
|
||||
{
|
||||
use \traits\model\adv;
|
||||
use \traits\model\Adv;
|
||||
|
||||
// 主键类型
|
||||
const TYPE_OBJECT = 1;
|
||||
@@ -243,7 +243,7 @@ class Mongo extends \Think\Model
|
||||
if (true !== $sepa) {
|
||||
// 当sepa指定为true的时候 返回所有数据
|
||||
$options['limit'] = is_numeric($sepa) ? $sepa : 1;
|
||||
}
|
||||
}
|
||||
// 查找一条记录
|
||||
$result = $this->db->find($options);
|
||||
if (!empty($result)) {
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
|
||||
namespace think\model;
|
||||
|
||||
T('model/relation');
|
||||
class Relation extends \think\model
|
||||
T('model/Relation');
|
||||
class Relation extends \think\Model
|
||||
{
|
||||
use \traits\model\relation;
|
||||
use \traits\model\Relation;
|
||||
}
|
||||
|
||||
@@ -11,8 +11,8 @@
|
||||
|
||||
namespace think\model;
|
||||
|
||||
T('model/view');
|
||||
class View extends \think\model
|
||||
T('model/View');
|
||||
class View extends \think\Model
|
||||
{
|
||||
use \traits\model\view;
|
||||
use \traits\model\View;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user