2.2.5
This commit is contained in:
parent
12ad13a7f8
commit
53303f2650
@ -309,9 +309,9 @@ class Addons extends AdminController
|
||||
//$pid = AuthRule::where('name','addons')->value('id');
|
||||
return json(['code'=>-1,'msg'=> 'is_nav菜单项目设置错误']);
|
||||
}
|
||||
// 开启关闭的父ID状态
|
||||
// 父ID状态为0时打开
|
||||
$pidStatus = AuthRule::where('id', $pid)->value('status');
|
||||
if(!$pidStatus) {
|
||||
if($pidStatus < 1) {
|
||||
AuthRule::update(['status' => 1, 'id' => $pid]);
|
||||
}
|
||||
// 安装菜单
|
||||
|
@ -39,7 +39,7 @@
|
||||
|
||||
<div class="layui-form-item layui-form-text">
|
||||
<div class="layui-input-block">
|
||||
<textarea id="L_content" name="content" required lay-verify="required" placeholder="{:lang('please input the content')}" class="layui-textarea fly-editor" style="height: 260px"> </textarea>
|
||||
<textarea id="L_content" name="content" required lay-verify="" placeholder="{:lang('please input the content')}" class="layui-textarea"> </textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item layui-inline">
|
||||
@ -85,12 +85,14 @@
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<script src="/static/component/layui/layui.js"></script>
|
||||
<script src="/static/component/pear/pear.js"></script>
|
||||
<script src="/static/addons/taonyeditor/tinymce/tinymce.min.js"></script>
|
||||
<script src="/static/xm-select.js"></script>
|
||||
|
||||
<script>
|
||||
|
||||
layui.extend({
|
||||
editor: '{/}/static/addons/taonyeditor/js/taonyeditor'
|
||||
}).use(["form", "colorpicker", "upload",'editor','xmSelect'], function () {
|
||||
@ -227,6 +229,7 @@
|
||||
});
|
||||
|
||||
form.on('submit(forum-save)', function(data) {
|
||||
console.log(data)
|
||||
$.ajax({
|
||||
url: "{:url('content.forum/add')}",
|
||||
data: JSON.stringify(data.field),
|
||||
|
@ -37,7 +37,7 @@
|
||||
</div>
|
||||
<div class="layui-form-item layui-form-text">
|
||||
<div class="layui-input-block">
|
||||
<textarea id="L_content" name="content" required lay-verify="required" placeholder="详细内容" class="layui-textarea fly-editor" style="height: 260px;">{$article.content}</textarea>
|
||||
<textarea id="L_content" name="content" required lay-verify="required" placeholder="详细内容" class="layui-textarea">{$article.content}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
@ -93,6 +93,7 @@
|
||||
<script src="/static/xm-select.js"></script>
|
||||
|
||||
<script>
|
||||
|
||||
layui.extend({
|
||||
editor: '{/}/static/addons/taonyeditor/js/taonyeditor'
|
||||
}).use(['colorpicker','form','upload', 'editor'], function(){
|
||||
|
@ -13,7 +13,7 @@
|
||||
<title>{block name="title"}TaoLerCMS后台管理系统{/block}</title>
|
||||
<link rel="stylesheet" href="/static/component/pear/css/pear.css" />
|
||||
</head>
|
||||
<body>
|
||||
<body class="pear-container">
|
||||
{block name="body"}内容{/block}
|
||||
<script src="/static/component/layui/layui.js"></script>
|
||||
<script src="/static/component/pear/pear.js"></script>
|
||||
|
@ -5,7 +5,7 @@
|
||||
<title>{block name="title"}TaoLerCMS后台管理系统{/block}</title>
|
||||
<link rel="stylesheet" href="/static/component/pear/css/pear.css" />
|
||||
</head>
|
||||
<body class="pear-container">
|
||||
<body>
|
||||
{block name="body"}内容{/block}
|
||||
<script src="/static/component/layui/layui.js"></script>
|
||||
<script src="/static/component/pear/pear.js"></script>
|
||||
|
@ -73,7 +73,7 @@ class Article extends Model
|
||||
$data['status'] = $superAdmin ? 1 : Config::get('taoler.config.posts_check');
|
||||
$msg = $data['status'] ? '发布成功' : '发布成功,请等待审核';
|
||||
$result = $this->save($data);
|
||||
if($result == true) {
|
||||
if($result) {
|
||||
return ['code' => 1, 'msg' => $msg, 'data' => ['status' => $data['status'], 'id'=> $this->id]];
|
||||
} else {
|
||||
return ['code' => -1, 'msg'=> '添加文章失败'];
|
||||
|
12
composer.lock
generated
12
composer.lock
generated
@ -3031,16 +3031,16 @@
|
||||
},
|
||||
{
|
||||
"name": "topthink/think-orm",
|
||||
"version": "v2.0.59",
|
||||
"version": "v2.0.60",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/top-think/think-orm.git",
|
||||
"reference": "ac0f18bc3063ca924ed5b4af6e405d74f44d2870"
|
||||
"reference": "8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/top-think/think-orm/zipball/ac0f18bc3063ca924ed5b4af6e405d74f44d2870",
|
||||
"reference": "ac0f18bc3063ca924ed5b4af6e405d74f44d2870",
|
||||
"url": "https://api.github.com/repos/top-think/think-orm/zipball/8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46",
|
||||
"reference": "8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46",
|
||||
"shasum": "",
|
||||
"mirrors": [
|
||||
{
|
||||
@ -3086,9 +3086,9 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/top-think/think-orm/issues",
|
||||
"source": "https://github.com/top-think/think-orm/tree/v2.0.59"
|
||||
"source": "https://github.com/top-think/think-orm/tree/v2.0.60"
|
||||
},
|
||||
"time": "2023-03-06T10:12:41+00:00"
|
||||
"time": "2023-03-19T04:51:56+00:00"
|
||||
},
|
||||
{
|
||||
"name": "topthink/think-template",
|
||||
|
@ -16,7 +16,7 @@ return [
|
||||
// 应用名,此项不可更改
|
||||
'appname' => 'TaoLer',
|
||||
// 版本配置
|
||||
'version' => '2.2.4',
|
||||
'version' => '2.2.5',
|
||||
// 加盐
|
||||
'salt' => 'taoler',
|
||||
// 数据库备份目录
|
||||
|
2
vendor/composer/autoload_psr4.php
vendored
2
vendor/composer/autoload_psr4.php
vendored
@ -14,7 +14,7 @@ return array(
|
||||
'think\\composer\\' => array($vendorDir . '/topthink/think-installer/src'),
|
||||
'think\\captcha\\' => array($vendorDir . '/topthink/think-captcha/src'),
|
||||
'think\\app\\' => array($vendorDir . '/topthink/think-multi-app/src'),
|
||||
'think\\' => array($vendorDir . '/topthink/framework/src/think', $vendorDir . '/topthink/think-helper/src', $vendorDir . '/topthink/think-orm/src', $vendorDir . '/topthink/think-template/src'),
|
||||
'think\\' => array($vendorDir . '/topthink/framework/src/think', $vendorDir . '/topthink/think-helper/src', $vendorDir . '/topthink/think-template/src', $vendorDir . '/topthink/think-orm/src'),
|
||||
'taoser\\think\\' => array($vendorDir . '/taoser/think-auth/src'),
|
||||
'taoser\\' => array($vendorDir . '/taoser/think-addons/src', $vendorDir . '/taoser/think-setarr/src'),
|
||||
'phpspirit\\databackup\\' => array($vendorDir . '/lotofbadcode/phpspirit_databackup/src'),
|
||||
|
4
vendor/composer/autoload_static.php
vendored
4
vendor/composer/autoload_static.php
vendored
@ -182,8 +182,8 @@ class ComposerStaticInit1b32198725235c8d6500c87262ef30c2
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/topthink/framework/src/think',
|
||||
1 => __DIR__ . '/..' . '/topthink/think-helper/src',
|
||||
2 => __DIR__ . '/..' . '/topthink/think-orm/src',
|
||||
3 => __DIR__ . '/..' . '/topthink/think-template/src',
|
||||
2 => __DIR__ . '/..' . '/topthink/think-template/src',
|
||||
3 => __DIR__ . '/..' . '/topthink/think-orm/src',
|
||||
),
|
||||
'taoser\\think\\' =>
|
||||
array (
|
||||
|
14
vendor/composer/installed.json
vendored
14
vendor/composer/installed.json
vendored
@ -3028,17 +3028,17 @@
|
||||
},
|
||||
{
|
||||
"name": "topthink/think-orm",
|
||||
"version": "v2.0.59",
|
||||
"version_normalized": "2.0.59.0",
|
||||
"version": "v2.0.60",
|
||||
"version_normalized": "2.0.60.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/top-think/think-orm.git",
|
||||
"reference": "ac0f18bc3063ca924ed5b4af6e405d74f44d2870"
|
||||
"reference": "8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/top-think/think-orm/zipball/ac0f18bc3063ca924ed5b4af6e405d74f44d2870",
|
||||
"reference": "ac0f18bc3063ca924ed5b4af6e405d74f44d2870",
|
||||
"url": "https://api.github.com/repos/top-think/think-orm/zipball/8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46",
|
||||
"reference": "8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46",
|
||||
"shasum": "",
|
||||
"mirrors": [
|
||||
{
|
||||
@ -3058,7 +3058,7 @@
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^7|^8|^9.5"
|
||||
},
|
||||
"time": "2023-03-06T10:12:41+00:00",
|
||||
"time": "2023-03-19T04:51:56+00:00",
|
||||
"type": "library",
|
||||
"installation-source": "dist",
|
||||
"autoload": {
|
||||
@ -3086,7 +3086,7 @@
|
||||
],
|
||||
"support": {
|
||||
"issues": "https://github.com/top-think/think-orm/issues",
|
||||
"source": "https://github.com/top-think/think-orm/tree/v2.0.59"
|
||||
"source": "https://github.com/top-think/think-orm/tree/v2.0.60"
|
||||
},
|
||||
"install-path": "../topthink/think-orm"
|
||||
},
|
||||
|
10
vendor/composer/installed.php
vendored
10
vendor/composer/installed.php
vendored
@ -3,7 +3,7 @@
|
||||
'name' => 'taoser/taoler',
|
||||
'pretty_version' => 'dev-master',
|
||||
'version' => 'dev-master',
|
||||
'reference' => '9c2eddaed601bdb6e510f417c528a79129611a4b',
|
||||
'reference' => 'dcfb9c2a8181fb002fee01a04843002e53a68e20',
|
||||
'type' => 'project',
|
||||
'install_path' => __DIR__ . '/../../',
|
||||
'aliases' => array(),
|
||||
@ -358,7 +358,7 @@
|
||||
'taoser/taoler' => array(
|
||||
'pretty_version' => 'dev-master',
|
||||
'version' => 'dev-master',
|
||||
'reference' => '9c2eddaed601bdb6e510f417c528a79129611a4b',
|
||||
'reference' => 'dcfb9c2a8181fb002fee01a04843002e53a68e20',
|
||||
'type' => 'project',
|
||||
'install_path' => __DIR__ . '/../../',
|
||||
'aliases' => array(),
|
||||
@ -455,9 +455,9 @@
|
||||
'dev_requirement' => false,
|
||||
),
|
||||
'topthink/think-orm' => array(
|
||||
'pretty_version' => 'v2.0.59',
|
||||
'version' => '2.0.59.0',
|
||||
'reference' => 'ac0f18bc3063ca924ed5b4af6e405d74f44d2870',
|
||||
'pretty_version' => 'v2.0.60',
|
||||
'version' => '2.0.60.0',
|
||||
'reference' => '8bc34a4307fa27186c0e96a9b3de3cb23aa1ed46',
|
||||
'type' => 'library',
|
||||
'install_path' => __DIR__ . '/../topthink/think-orm',
|
||||
'aliases' => array(),
|
||||
|
2
vendor/services.php
vendored
2
vendor/services.php
vendored
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
// This file is automatically generated at:2023-03-17 15:50:41
|
||||
// This file is automatically generated at:2023-03-20 11:45:35
|
||||
declare (strict_types = 1);
|
||||
return array (
|
||||
0 => 'taoser\\addons\\Service',
|
||||
|
@ -354,15 +354,13 @@ abstract class PDOConnection extends Connection
|
||||
if (!isset($this->info[$schema]) || $force) {
|
||||
// 读取字段缓存
|
||||
$cacheKey = $this->getSchemaCacheKey($schema);
|
||||
$cacheField = $this->config['fields_cache'] && !empty($this->cache);
|
||||
|
||||
if ($cacheField && !$force) {
|
||||
if ($this->config['fields_cache'] && !empty($this->cache) && !$force) {
|
||||
$info = $this->cache->get($cacheKey);
|
||||
}
|
||||
|
||||
if (empty($info)) {
|
||||
$info = $this->getTableFieldsInfo($tableName);
|
||||
if ($cacheField) {
|
||||
if (!empty($this->cache) && ($this->config['fields_cache'] || $force)) {
|
||||
$this->cache->set($cacheKey, $info);
|
||||
}
|
||||
}
|
||||
|
@ -735,7 +735,9 @@ trait RelationShip
|
||||
protected function getRelationData(Relation $modelRelation)
|
||||
{
|
||||
if ($this->parent && !$modelRelation->isSelfRelation()
|
||||
&& get_class($this->parent) == get_class($modelRelation->getModel())) {
|
||||
&& get_class($this->parent) == get_class($modelRelation->getModel())
|
||||
&& $modelRelation instanceof OneToOne
|
||||
) {
|
||||
return $this->parent;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user