1、更新内核

2、修复模型bug
3、修复后台部分操作的bug
4、清除多余文件
This commit is contained in:
2016-07-07 08:58:01 +08:00
parent f3fff63632
commit 2d3e41037d
43 changed files with 499 additions and 752 deletions

View File

@@ -82,11 +82,16 @@ class Addons extends \app\common\model\Base {
public function install($data){
if ($data) {
$result = $this->save($data);
if ($result) {
model('Hooks')->addHooks($data['name']);
return true;
$info = $this->where('name', $data['name'])->find();
if (null == $info) {
$result = $this->save($data);
if ($result) {
return model('Hooks')->addHooks($data['name']);
}else{
return false;
}
}else{
$this->error = "已安装!";
return false;
}
}else{