1
0
mirror of https://gitee.com/koogua/course-tencent-cloud.git synced 2025-06-22 03:32:47 +08:00

v.1.4.7 release

This commit is contained in:
koogua 2021-10-28 16:10:16 +08:00
parent 4628a272c8
commit 5cc94b0c01
5 changed files with 33 additions and 23 deletions

View File

@ -1,11 +1,11 @@
### [v1.4.6](https://gitee.com/koogua/course-tencent-cloud/releases/v1.4.6)(2021-10-18)
### [v1.4.7](https://gitee.com/koogua/course-tencent-cloud/releases/v1.4.7)(2021-10-28)
- 更新README.md
- 优化分页查询参数过滤
- 优化分页查询参数过滤
- 优化后台学员添加和搜索
- 优化后台学员课程过期管理
- 增加后台会员特权过期管理
- 增加编辑会员特权功能
- 增加清空用户头像功能
- 增加编辑器内站外图片自动保存到本地
- 增加CSRF放行白名单
- 完善订单|交易|退款序号

View File

@ -2,15 +2,14 @@
![酷瓜云网课GPL协议开源](https://portal-1255691183.file.myqcloud.com/img/content/60e7aea40966f.png)
### 项目介绍
### 系统介绍
酷瓜云课堂依托腾讯云基础服务架构采用C扩展框架Phalcon开发GPL-2.0开源协议,致力开源网课系统,开源网校系统,开源知识付费系统,开源在线教育系统。
[![Gitee star](https://gitee.com/koogua/course-tencent-cloud/badge/star.svg?theme=gitee)](https://gitee.com/koogua/course-tencent-cloud)
[![Gitee fork](https://gitee.com/koogua/course-tencent-cloud/badge/fork.svg?theme=gitee)](https://gitee.com/koogua/course-tencent-cloud)
[![Github stars](https://img.shields.io/github/stars/xiaochong0302/course-tencent-cloud?logo=github)](https://github.com/xiaochong0302/course-tencent-cloud)
[![Github forks](https://img.shields.io/github/forks/xiaochong0302/course-tencent-cloud?logo=github)](https://github.com/xiaochong0302/course-tencent-cloud)
![GPL-2.0](https://img.shields.io/static/v1?label=license&message=GPL-2.0&color=blue)
![star](https://svg.hamm.cn/gitee.svg?user=koogua&project=course-tencent-cloud&type=star)
![fork](https://svg.hamm.cn/gitee.svg?user=koogua&project=course-tencent-cloud&type=fork)
![license](https://svg.hamm.cn/gitee.svg?user=koogua&project=course-tencent-cloud&type=license)
![release](https://svg.hamm.cn/gitee.svg?user=koogua&project=course-tencent-cloud&type=release)
### 系统功能
@ -79,16 +78,3 @@ Tips: 请用手机注册一个新账号,用户中心 -> 关注订阅,扫码
- [码云平台](https://gitee.com/koogua/course-tencent-cloud/issues)
- [官方社区](https://koogua.com/community)
- QQ交流群: 787363898
### 有阿里云版吗?
阿里云版规划中,之前阿里云服务过期未续费,所以腾讯云版本先出。
### 代码有加密吗?
所有代码都公开授权代码除外例如layim没有所谓的商业版和付费插件。
### 开源助力
毫无保留的真开源不容易,不要吝啬您的赞许和鼓励,请给我们 **STAR**

View File

@ -90,6 +90,8 @@ class UserController extends Controller
$account = $userService->getAccount($id);
$adminRoles = $userService->getAdminRoles();
$defaultAvatar = kg_cos_user_avatar_url(null);
if ($user->admin_role == RoleModel::ROLE_ROOT) {
return $this->response->redirect(['for' => 'admin.user.list']);
}
@ -97,6 +99,7 @@ class UserController extends Controller
$this->view->setVar('user', $user);
$this->view->setVar('account', $account);
$this->view->setVar('admin_roles', $adminRoles);
$this->view->setVar('default_avatar', $defaultAvatar);
}
/**

View File

@ -162,6 +162,10 @@ class User extends Service
$data = [];
if (isset($post['avatar'])) {
$data['avatar'] = $validator->checkAvatar($post['avatar']);
}
if (isset($post['name'])) {
$data['name'] = $validator->checkName($post['name']);
if ($post['name'] != $user->name) {

View File

@ -10,7 +10,18 @@
<legend>编辑用户</legend>
</fieldset>
<div class="layui-form-item">
<label class="layui-form-label">用户名</label>
<label class="layui-form-label" style="padding-top:40px;">头像</label>
<div class="layui-input-inline" style="width:120px;">
<img id="avatar" class="kg-avatar" src="{{ user.avatar }}">
<input type="hidden" name="avatar" value="{{ user.avatar }}">
<input type="hidden" name="default_avatar" value="{{ default_avatar }}">
</div>
<div class="layui-input-inline" style="padding-top:35px;">
<button id="clear-avatar" class="layui-btn layui-btn-sm" type="button">清空</button>
</div>
</div>
<div class="layui-form-item">
<label class="layui-form-label">昵称</label>
<div class="layui-input-block">
<input class="layui-input" type="text" name="name" value="{{ user.name }}">
</div>
@ -141,6 +152,12 @@
var form = layui.form;
var laydate = layui.laydate;
$('#clear-avatar').on('click', function () {
var defaultAvatar = $('input[name=default_avatar]').val();
$('input[name=avatar]').val(defaultAvatar);
$('#avatar').attr('src', defaultAvatar);
});
laydate.render({
elem: 'input[name=vip_expiry_time]',
type: 'datetime'