mirror of
https://gitee.com/koogua/course-tencent-cloud.git
synced 2025-06-29 13:51:37 +08:00
Merge branch 'koogua/v1.6.9'
This commit is contained in:
commit
d1eb11e399
11
CHANGELOG.md
11
CHANGELOG.md
@ -1,3 +1,14 @@
|
||||
### [v1.7.0](https://gitee.com/koogua/course-tencent-cloud/releases/v1.7.0)(2024-05-15)
|
||||
|
||||
- 升级layui-2.9.8
|
||||
- 调整html编辑器属性
|
||||
- 增加代码块内容复制
|
||||
- 清理无用的Captcha配置
|
||||
- 联系人QQ改为上传二维码图片
|
||||
- 修正logo,favicon上传路径
|
||||
- 登录后台同时登录前台
|
||||
- 移动端修正评论发表
|
||||
|
||||
### [v1.6.9](https://gitee.com/koogua/course-tencent-cloud/releases/v1.6.9)(2024-04-15)
|
||||
|
||||
- 增加用户删除和还原功能
|
||||
|
@ -15,6 +15,8 @@ class SyncAppInfoTask extends Task
|
||||
|
||||
public function mainAction()
|
||||
{
|
||||
echo '------ start sync app info ------' . PHP_EOL;
|
||||
|
||||
$url = 'https://www.koogua.com/api/instance/collect';
|
||||
|
||||
$site = $this->getSettings('site');
|
||||
@ -37,6 +39,8 @@ class SyncAppInfoTask extends Task
|
||||
$client = new Client();
|
||||
|
||||
$client->request('POST', $url, ['form_params' => $params]);
|
||||
|
||||
echo '------ end sync app info ------' . PHP_EOL;
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -8,6 +8,7 @@
|
||||
namespace App\Http\Admin\Services;
|
||||
|
||||
use App\Services\Auth\Admin as AdminAuth;
|
||||
use App\Services\Auth\Home as HomeAuth;
|
||||
use App\Validators\Account as AccountValidator;
|
||||
|
||||
class Session extends Service
|
||||
@ -35,6 +36,8 @@ class Session extends Service
|
||||
|
||||
$this->auth->saveAuthInfo($user);
|
||||
|
||||
$this->loginHome($user);
|
||||
|
||||
$this->eventsManager->fire('Account:afterLogin', $this, $user);
|
||||
}
|
||||
|
||||
@ -47,4 +50,11 @@ class Session extends Service
|
||||
$this->eventsManager->fire('Account:afterLogout', $this, $user);
|
||||
}
|
||||
|
||||
protected function loginHome($user)
|
||||
{
|
||||
$auth = new HomeAuth();
|
||||
|
||||
$auth->saveAuthInfo($user);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ class AppInfo
|
||||
|
||||
protected $link = 'https://www.koogua.com';
|
||||
|
||||
protected $version = '1.6.9';
|
||||
protected $version = '1.7.0';
|
||||
|
||||
public function __get($name)
|
||||
{
|
||||
|
@ -42,7 +42,7 @@ class XunSearch extends PaginatorAdapter
|
||||
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!isset($config['xs']) || ($config['xs'] instanceof \XS) == false) {
|
||||
if (!isset($config['xs']) || !($config['xs'] instanceof \XS)) {
|
||||
throw new PaginatorException('Invalid xs parameter');
|
||||
}
|
||||
|
||||
|
@ -6,18 +6,31 @@ layui.use(['jquery'], function () {
|
||||
|
||||
var options = {
|
||||
uploadJson: '/admin/upload/content/img',
|
||||
cssPath: '/static/lib/kindeditor/content.css',
|
||||
cssPath: '/static/home/css/content.css',
|
||||
width: '100%',
|
||||
height: '300px',
|
||||
items: [
|
||||
'selectall', '|',
|
||||
'undo', 'redo', '|',
|
||||
'copy', 'plainpaste', 'wordpaste', '|',
|
||||
'formatblock', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline', 'removeformat', '|',
|
||||
'insertorderedlist', 'insertunorderedlist', 'table', '|',
|
||||
'superscript', 'subscript', '|', 'image', 'link', 'unlink', '|',
|
||||
'formatblock', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline', 'strikethrough', 'removeformat', '|',
|
||||
'insertorderedlist', 'insertunorderedlist', 'table', 'code', '|',
|
||||
'image', 'link', 'unlink', '|',
|
||||
'source', 'about'
|
||||
],
|
||||
htmlTags: {
|
||||
span: ['.color', '.background-color'],
|
||||
a: ['id', 'class', 'href', 'target', 'name'],
|
||||
img: ['id', 'class', 'src', 'width', 'height', 'alt', 'title'],
|
||||
table: ['id', 'class'],
|
||||
div: ['id', 'class'],
|
||||
pre: ['id', 'class'],
|
||||
hr: ['id', 'class'],
|
||||
embed: ['id', 'class', 'src', 'width', 'height', 'type', 'loop', 'autostart', 'quality', 'align', 'wmode'],
|
||||
iframe: ['id', 'class', 'src', 'width', 'height'],
|
||||
'td,th': ['id', 'class'],
|
||||
'p,ol,ul,li,blockquote,h1,h2,h3,h4,h5,h6': ['id', 'class'],
|
||||
'br,tbody,tr,strong,b,sub,sup,em,i,u,strike,s,del': ['id', 'class'],
|
||||
},
|
||||
extraFileUploadParams: {
|
||||
csrf_token: $('meta[name="csrf-token"]').attr('content')
|
||||
}
|
||||
|
@ -178,7 +178,8 @@
|
||||
font-family: Consolas, Monaco, Andale Mono, monospace;
|
||||
line-height: 1.7em;
|
||||
overflow: auto;
|
||||
padding: 6px 10px;
|
||||
padding: 15px 10px;
|
||||
margin-bottom: 15px;
|
||||
border-left: 5px solid #6CE26C;
|
||||
}
|
||||
|
||||
@ -218,4 +219,25 @@
|
||||
|
||||
.ke-content blockquote p {
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.ke-content pre {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.ke-content pre > span.kg-copy {
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
right: 10px;
|
||||
padding: 0 10px;
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
border-radius: 3px;
|
||||
background: rgba(0, 0, 0, 0.5);
|
||||
cursor: pointer;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.ke-content pre:hover > span.kg-copy {
|
||||
display: block;
|
||||
}
|
@ -12,12 +12,23 @@ layui.use(['jquery'], function () {
|
||||
items: [
|
||||
'selectall', '|',
|
||||
'undo', 'redo', '|',
|
||||
'copy', 'plainpaste', 'wordpaste', '|',
|
||||
'formatblock', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline', 'removeformat', '|',
|
||||
'insertorderedlist', 'insertunorderedlist', 'table', '|',
|
||||
'superscript', 'subscript', '|', 'image', 'link', 'unlink', '|',
|
||||
'formatblock', 'formatblock', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline', 'strikethrough', 'removeformat', '|',
|
||||
'insertorderedlist', 'insertunorderedlist', 'table', 'code', '|',
|
||||
'image', 'link', 'unlink', '|',
|
||||
'source', 'about'
|
||||
],
|
||||
htmlTags: {
|
||||
span: ['.color', '.background-color'],
|
||||
a: ['id', 'class', 'href', 'target', 'name'],
|
||||
img: ['id', 'class', 'src', 'width', 'height', 'alt', 'title'],
|
||||
table: ['id', 'class'],
|
||||
div: ['id', 'class'],
|
||||
pre: ['id', 'class'],
|
||||
hr: ['id', 'class'],
|
||||
'td,th': ['id', 'class'],
|
||||
'p,ol,ul,li,blockquote,h1,h2,h3,h4,h5,h6': ['id', 'class'],
|
||||
'br,tbody,tr,strong,b,sub,sup,em,i,u,strike,s,del': ['id', 'class'],
|
||||
},
|
||||
extraFileUploadParams: {
|
||||
csrf_token: $('meta[name="csrf-token"]').attr('content')
|
||||
}
|
||||
|
@ -1,9 +1,22 @@
|
||||
layui.use(['layer'], function () {
|
||||
layui.use(['jquery','layer'], function () {
|
||||
|
||||
var $ = layui.jquery;
|
||||
var layer = layui.layer;
|
||||
|
||||
if ($('.ke-content').length > 0) {
|
||||
var kePres = $('pre');
|
||||
if (kePres.length > 0) {
|
||||
kePres.each(function () {
|
||||
var text = $(this).text();
|
||||
var btn = $('<span class="kg-copy">复制</span>').attr('data-clipboard-text', text);
|
||||
$(this).prepend(btn);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
var clipboard = new ClipboardJS('.kg-copy');
|
||||
|
||||
clipboard.on('success', function (e) {
|
||||
clipboard.on('success', function () {
|
||||
layer.msg('内容已经复制到剪贴板');
|
||||
});
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user