优化帖子和评论审核,更新依赖组件

This commit is contained in:
taoser 2021-06-09 14:48:38 +08:00
parent 03f780ff88
commit ace6ee5e21
34 changed files with 501 additions and 298 deletions

View File

@ -37,6 +37,9 @@ class Forum extends AdminController
$data['is_reply'] = 0; $data['is_reply'] = 0;
break; break;
case '5': case '5':
$data['a.status'] = -1;
break;
case '6':
$data['a.status'] = 0; $data['a.status'] = 0;
break; break;
} }
@ -120,7 +123,7 @@ class Forum extends AdminController
//审核帖子 //审核帖子
public function check() public function check()
{ {
$data = Request::param(); $data = Request::only(['id','status']);
//获取状态 //获取状态
$res = Db::name('article')->where('id',$data['id'])->save(['status' => $data['status']]); $res = Db::name('article')->where('id',$data['id'])->save(['status' => $data['status']]);
@ -211,13 +214,17 @@ class Forum extends AdminController
public function replys() public function replys()
{ {
if(Request::isAjax()) { if(Request::isAjax()) {
$data = Request::only(['name','content']); $data = Request::only(['name','content','status']);
$map = array_filter($data); $map = array_filter($data);
$where = array(); $where = array();
if(!empty($map['content'])){ if(!empty($map['content'])){
$where[] = ['a.content','like','%'.$map['content'].'%']; $where[] = ['a.content','like','%'.$map['content'].'%'];
unset($map['content']); unset($map['content']);
} }
if(isset($data['status'])){
$where[] = ['a.status','=',(int)$data['status']];
unset($map['status']);
}
/* /*
$replys = Comment::field('id,article_id,user_id,content,create_time')->with([ $replys = Comment::field('id,article_id,user_id,content,create_time')->with([
@ -252,7 +259,7 @@ class Forum extends AdminController
$res = ['code'=>-1,'msg'=>'没有查询结果!']; $res = ['code'=>-1,'msg'=>'没有查询结果!'];
} }
return json($res); return json($res);
} }
return View::fetch(); return View::fetch();
} }

View File

@ -67,6 +67,11 @@ class Index extends AdminController
} else { } else {
$versions ='当前无可更新版本'; $versions ='当前无可更新版本';
} }
//评论、帖子状态
$comm = Db::name('comment')->field('id')->where(['delete_time'=>0,'status'=>0])->select();
$forum = Db::name('article')->field('id')->where(['delete_time'=>0,'status'=>0])->select();
$comms = count($comm);
$forums = count($forum);
//运行时间 //运行时间
$now = time(); $now = time();
$count = $now-$this->sys['create_time']; $count = $now-$this->sys['create_time'];
@ -79,7 +84,7 @@ class Index extends AdminController
} }
$runTime = $years ? "{$years}{$days}{$hos}{$mins}" : "{$days}{$hos}{$mins}"; $runTime = $years ? "{$years}{$days}{$hos}{$mins}" : "{$days}{$hos}{$mins}";
View::assign(['runTime'=>$runTime,'versions'=>$versions]); View::assign(['runTime'=>$runTime,'versions'=>$versions,'comms'=>$comms,'forums'=>$forums]);
return View::fetch(); return View::fetch();
} }

View File

@ -6,7 +6,7 @@
<div class="layui-form layui-card-header layuiadmin-card-header-auto"> <div class="layui-form layui-card-header layuiadmin-card-header-auto">
<div class="layui-form-item"> <div class="layui-form-item">
<div class="layui-inline"> <div class="layui-inline">
<label class="layui-form-label">ID</label> <label class="layui-form-label">帖子ID</label>
<div class="layui-input-block"> <div class="layui-input-block">
<input type="text" name="id" placeholder="请输入" autocomplete="off" class="layui-input"> <input type="text" name="id" placeholder="请输入" autocomplete="off" class="layui-input">
</div> </div>
@ -18,21 +18,22 @@
</div> </div>
</div> </div>
<div class="layui-inline"> <div class="layui-inline">
<label class="layui-form-label">发帖名称</label> <label class="layui-form-label">标题</label>
<div class="layui-input-block"> <div class="layui-input-block">
<input type="text" name="title" placeholder="请输入" autocomplete="off" class="layui-input"> <input type="text" name="title" placeholder="请输入" autocomplete="off" class="layui-input">
</div> </div>
</div> </div>
<div class="layui-inline"> <div class="layui-inline">
<label class="layui-form-label">帖子状态</label> <label class="layui-form-label">状态</label>
<div class="layui-input-block"> <div class="layui-input-block">
<select name="sec"> <select name="sec">
<option value="">选择状态</option> <option value="">选择状态</option>
<option value="1">正常</option> <option value="1">正常</option>
<option value="5">禁止</option>
<option value="6">待审</option>
<option value="2">置顶</option> <option value="2">置顶</option>
<option value="3">热门</option> <option value="3">加精</option>
<option value="4">禁评</option> <option value="4">禁评</option>
<option value="5">封禁</option>
</select> </select>
</div> </div>
</div> </div>
@ -64,7 +65,7 @@
</script> </script>
<script type="text/html" id="buttonHot"> <script type="text/html" id="buttonHot">
{{# if(d.hot == 1){ }} {{# if(d.hot == 1){ }}
<button class="layui-btn layui-btn-xs"></button> <button class="layui-btn layui-btn-xs"></button>
{{# } else { }} {{# } else { }}
<button class="layui-btn layui-btn-primary layui-btn-xs">正常</button> <button class="layui-btn layui-btn-primary layui-btn-xs">正常</button>
{{# } }} {{# } }}
@ -78,7 +79,7 @@
</script> </script>
<script type="text/html" id="buttonCheck"> <script type="text/html" id="buttonCheck">
{if condition="checkRuleButton('admin/forum/check')"} {if condition="checkRuleButton('admin/forum/check')"}
<input type="checkbox" name="check" lay-skin="switch" lay-filter="forumcheck" lay-text="通过|禁止" {{# if(d.check == 1){ }} checked {{# } }} id="{{d.id}}" > <input type="checkbox" name="check" lay-skin="switch" lay-filter="forumcheck" lay-text="通过|{{# if(d.check == -1){ }}禁止{{# } }} {{# if(d.check == 0){ }}待审{{# } }}" {{# if(d.check == 1){ }} checked {{# } }} id="{{d.id}}" >
{else /}<button class="layui-btn layui-btn-xs layui-btn-radius layui-btn-disabled">无权限</button>{/if} {else /}<button class="layui-btn layui-btn-xs layui-btn-radius layui-btn-disabled">无权限</button>{/if}
</script> </script>
<script type="text/html" id="table-forum-list"> <script type="text/html" id="table-forum-list">
@ -116,24 +117,7 @@ var forumList = "{:url('Forum/list')}",
//监听搜索 //监听搜索
form.on('submit(LAY-app-forumlist-search)', function(data){ form.on('submit(LAY-app-forumlist-search)', function(data){
var field = data.field; var field = data.field;
$.ajax({ $.post("{:url('admin/Forum/list')}",field);
type:"post",
url:"{:url('admin/Forum/list')}",
data:{field},
daType:"json",
success:function (data){
if (data.code == 0) {
} else {
layer.open({
content:data.msg,
icon:5,
anim:6
});
}
}
});
//执行重载 //执行重载
table.reload('LAY-app-forum-list', { table.reload('LAY-app-forum-list', {
where: field where: field
@ -168,26 +152,19 @@ var forumList = "{:url('Forum/list')}",
//监听帖子审核 //监听帖子审核
form.on('switch(forumcheck)', function(data){ form.on('switch(forumcheck)', function(data){
var data= data.elem; var data= data.elem;
status = data.checked ? 1 : -1;
if(data.checked == true){
data.value = 1;
}else{
data.value = 0;
}
//执行帖子审核 //执行帖子审核
$.ajax({ $.ajax({
type:'post', type:'post',
url:"{:url('admin/Forum/check')}", url:"{:url('admin/Forum/check')}",
data:{id:data.id,status:data.value,}, data:{id:data.id,status:status},
dataType:'json', dataType:'json',
success:function(res){ success:function(res){
if(res.code == 0){ if(res.code == 0){
layer.msg(res.msg,{ layer.msg(res.msg,{
icon:res.icon, icon:res.icon,
time:2000 time:2000
} });
//,function(){location.reload();}
);
} else { } else {
layer.open({ layer.open({
title:'审核失败', title:'审核失败',
@ -196,6 +173,7 @@ var forumList = "{:url('Forum/list')}",
adim:6 adim:6
}) })
} }
table.reload('LAY-app-forum-list');
} }
}); });
return false; return false;

View File

@ -1,7 +1,6 @@
{extend name="public:base" /} {extend name="public:base" /}
{block name="body"} {block name="body"}
<div class="layui-fluid"> <div class="layui-fluid">
<div class="layui-card"> <div class="layui-card">
<div class="layui-form layui-card-header layuiadmin-card-header-auto"> <div class="layui-form layui-card-header layuiadmin-card-header-auto">
@ -13,10 +12,21 @@
</div> </div>
</div> </div>
<div class="layui-inline"> <div class="layui-inline">
<label class="layui-form-label">回帖内容</label> <label class="layui-form-label">内容</label>
<div class="layui-input-block"> <div class="layui-input-block">
<input type="text" name="content" placeholder="请输入" autocomplete="off" class="layui-input"> <input type="text" name="content" placeholder="请输入" autocomplete="off" class="layui-input">
</div> </div>
</div>
<div class="layui-inline">
<label class="layui-form-label">状态</label>
<div class="layui-input-block">
<select name="status" lay-filter="fourm-check">
<option value="">全部</option>
<option value="0">待审</option>
<option value="-1">禁止</option>
<option value="1">通过</option>
</select>
</div>
</div> </div>
<div class="layui-inline"> <div class="layui-inline">
<button class="layui-btn layuiadmin-btn-replys" data-type="reload" lay-submit lay-filter="LAY-app-forumreply-search"> <button class="layui-btn layuiadmin-btn-replys" data-type="reload" lay-submit lay-filter="LAY-app-forumreply-search">
@ -37,7 +47,7 @@
<a href="{$domain}/jie/{{d.cid}}.html" target="_blank">{{d.cardid}}</a> <a href="{$domain}/jie/{{d.cid}}.html" target="_blank">{{d.cardid}}</a>
</script> </script>
<script type="text/html" id="buttonCheck"> <script type="text/html" id="buttonCheck">
{if condition="checkRuleButton('admin/forum/recheck')"}<input type="checkbox" name="check" lay-skin="switch" lay-filter="recheck" lay-text="通过|禁止" {{# if(d.check == 1){ }} checked {{# } }} id="{{d.id}}" > {if condition="checkRuleButton('admin/forum/recheck')"}<input type="checkbox" name="check" lay-skin="switch" lay-filter="recheck" lay-text="通过|{{# if(d.check == -1){ }}禁止{{# } }} {{# if(d.check == 0){ }}待审{{# } }}" {{# if(d.check == 1){ }} checked {{# } }} id="{{d.id}}" >
{else /}<button class="layui-btn layui-btn-xs layui-btn-radius layui-btn-disabled">无权限</button>{/if} {else /}<button class="layui-btn layui-btn-xs layui-btn-radius layui-btn-disabled">无权限</button>{/if}
</script> </script>
<script type="text/html" id="table-forum-replys"> <script type="text/html" id="table-forum-replys">
@ -75,30 +85,24 @@ var forumList = "{:url('Forum/list')}",
//监听搜索 //监听搜索
form.on('submit(LAY-app-forumreply-search)', function(data){ form.on('submit(LAY-app-forumreply-search)', function(data){
var field = data.field; var field = data.field;
$.ajax({ $.post("{:url('admin/Forum/replys')}",field);
type:"post",
url:"{:url('admin/Forum/replys')}",
data:{field},
daType:"json",
success:function (data){
if (data.code == 0) {
} else {
layer.open({
content:data.msg,
icon:5,
anim:6
});
}
}
});
//执行重载 //执行重载
table.reload('LAY-app-forumreply-list', { table.reload('LAY-app-forumreply-list', {
where: field where: field
}); });
}); });
//状态选择
form.on('select(fourm-check)',function(data){
$.post("{:url('admin/Forum/replys')}",{"status":data.value});
//执行重载
table.reload('LAY-app-forumreply-list', {
where: {
status: data.value
}
});
});
var active = { var active = {
batchdel: function(){ batchdel: function(){
var checkStatus = table.checkStatus('LAY-app-forumreply-list') var checkStatus = table.checkStatus('LAY-app-forumreply-list')
@ -126,26 +130,19 @@ var forumList = "{:url('Forum/list')}",
//监听回贴审核 //监听回贴审核
form.on('switch(recheck)', function(data){ form.on('switch(recheck)', function(data){
var data= data.elem; var data= data.elem;
status = data.checked ? 1 : -1;
if(data.checked == true){
data.value = 1;
}else{
data.value = 0;
}
//执行回帖审核 //执行回帖审核
$.ajax({ $.ajax({
type:'post', type:'post',
url:"{:url('admin/Forum/recheck')}", url:"{:url('admin/Forum/recheck')}",
data:{id:data.id,status:data.value,}, data:{id:data.id,status:status},
dataType:'json', dataType:'json',
success:function(res){ success:function(res){
if(res.code == 0){ if(res.code == 0){
layer.msg(res.msg,{ layer.msg(res.msg,{
icon:res.icon, icon:res.icon,
time:2000 time:2000
} });
//,function(){location.reload();}
);
} else { } else {
layer.open({ layer.open({
title:'审核失败', title:'审核失败',
@ -154,6 +151,8 @@ var forumList = "{:url('Forum/list')}",
adim:6 adim:6
}) })
} }
table.reload('LAY-app-forumreply-list');
} }
}); });
return false; return false;

View File

@ -83,19 +83,19 @@
<div carousel-item> <div carousel-item>
<ul class="layui-row layui-col-space10"> <ul class="layui-row layui-col-space10">
<li class="layui-col-xs6"> <li class="layui-col-xs6">
<a lay-href="app/content/comment.html" class="layadmin-backlog-body"> <a lay-href="{:url('admin/Forum/replys')}" class="layadmin-backlog-body">
<h3>待审评论</h3> <h3>待审评论</h3>
<p><cite>66</cite></p> <p><cite>{$comms}</cite></p>
</a> </a>
</li> </li>
<li class="layui-col-xs6"> <li class="layui-col-xs6">
<a lay-href="app/forum/list.html" class="layadmin-backlog-body"> <a lay-href="{:url('admin/Forum/list')}" class="layadmin-backlog-body">
<h3>待审帖子</h3> <h3>待审帖子</h3>
<p><cite>12</cite></p> <p><cite>{$forums}</cite></p>
</a> </a>
</li> </li>
<li class="layui-col-xs6"> <li class="layui-col-xs6">
<a lay-href="template/goodslist.html" class="layadmin-backlog-body"> <a lay-href="javascript:;" class="layadmin-backlog-body">
<h3>待审商品</h3> <h3>待审商品</h3>
<p><cite>99</cite></p> <p><cite>99</cite></p>
</a> </a>

View File

@ -52,7 +52,7 @@ CREATE TABLE `tao_article` (
`id` int(11) NOT NULL AUTO_INCREMENT COMMENT '用户ID', `id` int(11) NOT NULL AUTO_INCREMENT COMMENT '用户ID',
`title` varchar(50) NOT NULL COMMENT '标题', `title` varchar(50) NOT NULL COMMENT '标题',
`content` text NOT NULL COMMENT '内容', `content` text NOT NULL COMMENT '内容',
`status` enum('0','1') NOT NULL DEFAULT '1' COMMENT '状态1显示0隐藏', `status` enum('0','-1','1') NOT NULL DEFAULT '1' COMMENT '状态1显示0待审-1禁止',
`cate_id` int(11) NOT NULL COMMENT '分类id', `cate_id` int(11) NOT NULL COMMENT '分类id',
`user_id` int(11) NOT NULL COMMENT '用户id', `user_id` int(11) NOT NULL COMMENT '用户id',
`is_top` enum('0','1') NOT NULL DEFAULT '0' COMMENT '置顶1否0', `is_top` enum('0','1') NOT NULL DEFAULT '0' COMMENT '置顶1否0',
@ -323,7 +323,7 @@ CREATE TABLE `tao_comment` (
`user_id` int(11) NOT NULL COMMENT '评论用户', `user_id` int(11) NOT NULL COMMENT '评论用户',
`zan` tinyint(4) NOT NULL DEFAULT '0' COMMENT '', `zan` tinyint(4) NOT NULL DEFAULT '0' COMMENT '',
`cai` enum('1','0') NOT NULL DEFAULT '0' COMMENT '0求解1采纳', `cai` enum('1','0') NOT NULL DEFAULT '0' COMMENT '0求解1采纳',
`status` enum('0','1') NOT NULL DEFAULT '1' COMMENT '1通过0禁止', `status` enum('0','-1','1') NOT NULL DEFAULT '1' COMMENT '1通过0待审-1禁止',
`create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间', `create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
`update_time` int(11) NOT NULL DEFAULT '0' COMMENT '更新时间', `update_time` int(11) NOT NULL DEFAULT '0' COMMENT '更新时间',
`delete_time` int(11) NOT NULL DEFAULT '0' COMMENT '删除时间', `delete_time` int(11) NOT NULL DEFAULT '0' COMMENT '删除时间',
@ -503,7 +503,7 @@ CREATE TABLE `tao_system` (
-- ---------------------------- -- ----------------------------
-- Records of tao_system -- Records of tao_system
-- ---------------------------- -- ----------------------------
INSERT INTO `tao_system` VALUES ('1', 'TaoLer社区演示站', '轻论坛系统', 'http://www.xxx.com', 'taoler', '/storage/logo/logo.png', '10', '2048', 'png|gif|jpg|jpeg|zip|rarr', '<a href=\"http://www.aieok.com\" target=\"_blank\">aieok.com 版权所有</a>', 'TaoLer,轻社区系统,bbs,论坛,Thinkphp6,layui,fly模板,', '这是一个Taoler轻社区论坛系统', '1', '1', '1', '0.0.0.0', '管理员|admin|审核员|超级|垃圾', '1.6.3', '', 'http://api.aieok.com', 'http://api.aieok.com/v1/cy', 'http://api.aieok.com/v1/upload/check', 'http://api.aieok.com/v1/upload/api', '1581221008', '1577419197'); INSERT INTO `tao_system` VALUES ('1', 'TaoLer社区演示站', '轻论坛系统', 'http://www.xxx.com', 'taoler', '/storage/logo/logo.png', '10', '2048', 'png|gif|jpg|jpeg|zip|rarr', '<a href="https://www.aieok.com" target="_blank">TaoLer</a>', 'TaoLer,轻社区系统,bbs,论坛,Thinkphp6,layui,fly模板,', '这是一个Taoler轻社区论坛系统', '1', '1', '1', '0.0.0.0', '管理员|admin|审核员|超级|垃圾', '1.6.3', '', 'http://api.aieok.com', 'http://api.aieok.com/v1/cy', 'http://api.aieok.com/v1/upload/check', 'http://api.aieok.com/v1/upload/api', '1581221008', '1577419197');
-- ---------------------------- -- ----------------------------
-- Table structure for tao_user -- Table structure for tao_user

66
composer.lock generated
View File

@ -8,16 +8,16 @@
"packages": [ "packages": [
{ {
"name": "firebase/php-jwt", "name": "firebase/php-jwt",
"version": "v5.2.1", "version": "v5.3.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/firebase/php-jwt.git", "url": "https://github.com/firebase/php-jwt.git",
"reference": "f42c9110abe98dd6cfe9053c49bc86acc70b2d23" "reference": "3c2d70f2e64e2922345e89f2ceae47d2463faae1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/firebase/php-jwt/zipball/f42c9110abe98dd6cfe9053c49bc86acc70b2d23", "url": "https://api.github.com/repos/firebase/php-jwt/zipball/3c2d70f2e64e2922345e89f2ceae47d2463faae1",
"reference": "f42c9110abe98dd6cfe9053c49bc86acc70b2d23", "reference": "3c2d70f2e64e2922345e89f2ceae47d2463faae1",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -62,9 +62,9 @@
], ],
"support": { "support": {
"issues": "https://github.com/firebase/php-jwt/issues", "issues": "https://github.com/firebase/php-jwt/issues",
"source": "https://github.com/firebase/php-jwt/tree/v5.2.1" "source": "https://github.com/firebase/php-jwt/tree/v5.3.0"
}, },
"time": "2021-02-12T00:02:00+00:00" "time": "2021-05-20T17:37:02+00:00"
}, },
{ {
"name": "league/flysystem", "name": "league/flysystem",
@ -1204,16 +1204,16 @@
"packages-dev": [ "packages-dev": [
{ {
"name": "symfony/polyfill-mbstring", "name": "symfony/polyfill-mbstring",
"version": "v1.22.1", "version": "v1.23.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git", "url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "5232de97ee3b75b0360528dae24e73db49566ab1" "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/5232de97ee3b75b0360528dae24e73db49566ab1", "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2df51500adbaebdc4c38dea4c89a2e131c45c8a1",
"reference": "5232de97ee3b75b0360528dae24e73db49566ab1", "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -1231,7 +1231,7 @@
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -1270,7 +1270,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -1286,20 +1286,20 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2021-01-22T09:19:47+00:00" "time": "2021-05-27T09:27:20+00:00"
}, },
{ {
"name": "symfony/polyfill-php72", "name": "symfony/polyfill-php72",
"version": "v1.22.1", "version": "v1.23.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-php72.git", "url": "https://github.com/symfony/polyfill-php72.git",
"reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9" "reference": "9a142215a36a3888e30d0a9eeea9766764e96976"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9a142215a36a3888e30d0a9eeea9766764e96976",
"reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", "reference": "9a142215a36a3888e30d0a9eeea9766764e96976",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -1314,7 +1314,7 @@
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -1352,7 +1352,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-php72/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-php72/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -1368,20 +1368,20 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2021-01-07T16:49:33+00:00" "time": "2021-05-27T09:17:38+00:00"
}, },
{ {
"name": "symfony/polyfill-php80", "name": "symfony/polyfill-php80",
"version": "v1.22.1", "version": "v1.23.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-php80.git", "url": "https://github.com/symfony/polyfill-php80.git",
"reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/eca0bf41ed421bed1b57c4958bab16aa86b757d0",
"reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -1396,7 +1396,7 @@
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -1441,7 +1441,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-php80/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -1457,20 +1457,20 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2021-01-07T16:49:33+00:00" "time": "2021-02-19T12:13:01+00:00"
}, },
{ {
"name": "symfony/var-dumper", "name": "symfony/var-dumper",
"version": "v4.4.22", "version": "v4.4.25",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/var-dumper.git", "url": "https://github.com/symfony/var-dumper.git",
"reference": "c194bcedde6295f3ec3e9eba1f5d484ea97c41a7" "reference": "31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/c194bcedde6295f3ec3e9eba1f5d484ea97c41a7", "url": "https://api.github.com/repos/symfony/var-dumper/zipball/31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0",
"reference": "c194bcedde6295f3ec3e9eba1f5d484ea97c41a7", "reference": "31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -1536,7 +1536,7 @@
"dump" "dump"
], ],
"support": { "support": {
"source": "https://github.com/symfony/var-dumper/tree/v4.4.22" "source": "https://github.com/symfony/var-dumper/tree/v4.4.25"
}, },
"funding": [ "funding": [
{ {
@ -1552,7 +1552,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2021-04-19T13:36:17+00:00" "time": "2021-05-27T09:48:32+00:00"
}, },
{ {
"name": "topthink/think-trace", "name": "topthink/think-trace",

View File

@ -7,7 +7,7 @@ return [
//应用名,此项不可更改 //应用名,此项不可更改
'appname' => 'TaoLer', 'appname' => 'TaoLer',
//版本配置 //版本配置
'version' => '1.7.8', 'version' => '1.7.9',
//加盐 //加盐
'salt' => 'taoler', 'salt' => 'taoler',
//数据库备份目录 //数据库备份目录

View File

@ -18,17 +18,17 @@ layui.define(['table', 'form'], function(exports){
elem: '#LAY-app-forum-list' elem: '#LAY-app-forum-list'
,url: forumList //帖子数据接口 ,url: forumList //帖子数据接口
,cols: [[ ,cols: [[
{type: 'checkbox', fixed: 'left'} {type: 'checkbox'}
,{field: 'id', width: 55, title: 'ID', sort: true} ,{field: 'id', width: 60, title: 'ID', sort: true}
,{field: 'poster', title: '贴主'} ,{field: 'poster', title: '贴主',width: 80}
,{field: 'avatar', title: '头像', width: 100, templet: '#imgTpl', align: 'center'} ,{field: 'avatar', title: '头像', width: 80, templet: '#imgTpl'}
,{field: 'content', title: '标题', width: 200,templet: '#title'} ,{field: 'content', title: '标题', width: 200,templet: '#title'}
,{field: 'posttime', title: '时间', sort: true} ,{field: 'posttime', title: '时间',width: 120, sort: true}
,{field: 'top', title: '置顶', templet: '#buttonTpl', minWidth: 80, align: 'center'} ,{field: 'top', title: '置顶', templet: '#buttonTpl', width: 80, align: 'center'}
,{field: 'hot', title: '精贴', templet: '#buttonHot', minWidth: 80, align: 'center'} ,{field: 'hot', title: '精贴', templet: '#buttonHot', width: 80, align: 'center'}
,{field: 'reply', title: '评论状态', templet: '#buttonReply', minWidth: 80, align: 'center'} ,{field: 'reply', title: '评论状态', templet: '#buttonReply', width: 80, align: 'center'}
,{field: 'check', title: '审帖', templet: '#buttonCheck', minWidth: 80, align: 'center'} ,{field: 'check', title: '审帖', templet: '#buttonCheck', width: 100, align: 'center'}
,{title: '操作', width: 80, align: 'center', fixed: 'right', toolbar: '#table-forum-list'} ,{title: '操作', width: 85, align: 'center', toolbar: '#table-forum-list'}
]] ]]
,page: true ,page: true
,limit: 15 ,limit: 15
@ -134,15 +134,15 @@ layui.define(['table', 'form'], function(exports){
elem: '#LAY-app-forumreply-list' elem: '#LAY-app-forumreply-list'
,url: forumReplys ,url: forumReplys
,cols: [[ ,cols: [[
{type: 'checkbox', fixed: 'left'} {type: 'checkbox'}
,{field: 'id', width: 100, title: 'ID', sort: true} ,{field: 'id', width: 80, title: 'ID', sort: true}
,{field: 'replyer', title: '回帖人'} ,{field: 'replyer', title: '回帖人', width: 80}
,{field: 'cardid', title: '帖ID',templet: '#title'} ,{field: 'cardid', title: '帖ID',templet: '#title'}
,{field: 'avatar', title: '头像', width: 100, templet: '#imgTpl'} ,{field: 'avatar', title: '头像', width: 80, templet: '#imgTpl'}
,{field: 'content', title: '回帖内容', width: 200} ,{field: 'content', title: '评论', minWidth: 200}
,{field: 'replytime', title: '回帖时间', sort: true} ,{field: 'replytime', title: '回复时间', width: 120, sort: true}
,{field: 'check', title: '审核', templet: '#buttonCheck'} ,{field: 'check', title: '审核', templet: '#buttonCheck', width: 100}
,{title: '操作', width: 80, align: 'center', fixed: 'right', toolbar: '#table-forum-replys'} ,{title: '操作', width: 85, align: 'center', toolbar: '#table-forum-replys'}
]] ]]
,page: true ,page: true
,limit: 15 ,limit: 15

View File

@ -18,20 +18,21 @@ layui.define(['table', 'form'], function(exports){
elem: '#LAY-user-manage' elem: '#LAY-user-manage'
,url: userList //模拟接口 ,url: userList //模拟接口
,cols: [[ ,cols: [[
{type: 'checkbox', fixed: 'left'} {type: 'checkbox'}
,{field: 'id', width: 50, title: 'ID', sort: true} ,{field: 'id', width: 60, title: 'ID', sort: true}
,{field: 'username', title: '用户名', minWidth: 80} ,{field: 'username', title: '用户名', minWidth: 100}
,{field: 'avatar', title: '头像', width: 100, templet: '#imgTpl'} ,{field: 'nick', title: '昵称',minWidth: 100}
,{field: 'phone', title: '手机',width: 150} ,{field: 'avatar', title: '头像', width: 80, templet: '#imgTpl'}
//,{field: 'phone', title: '手机',width: 80}
,{field: 'email', title: '邮箱'} ,{field: 'email', title: '邮箱'}
,{field: 'sex', width: 60, title: '性别',templet: '#sex'} ,{field: 'sex', width: 60, title: '性别',templet: '#sex'}
,{field: 'ip', title: '登录IP'} ,{field: 'ip', title: '登录IP'}
,{field: 'city', title: '城市'} ,{field: 'city', title: '城市'}
,{field: 'logintime', title: '最后登录', sort: true} ,{field: 'logintime', title: '最后登录',minWidth: 150, sort: true}
,{field: 'jointime', title: '注册时间', sort: true} ,{field: 'jointime', title: '注册时间',minWidth: 120, sort: true}
,{field: 'check', title: '状态', templet: '#buttonCheck', minWidth: 80, align: 'center'} ,{field: 'check', title: '状态', templet: '#buttonCheck', minWidth: 80, align: 'center'}
,{field: 'auth', title: '超级管理员', templet: '#buttonAuth', minWidth: 80, align: 'center'} ,{field: 'auth', title: '超级管理员', templet: '#buttonAuth', width: 60, align: 'center'}
,{title: '操作', width: 150, align:'center', fixed: 'right', toolbar: '#table-useradmin-webuser'} ,{title: '操作', width: 150, align:'center', toolbar: '#table-useradmin-webuser'}
]] ]]
,page: true ,page: true
,limit: 30 ,limit: 30

View File

@ -26,12 +26,12 @@ private static $installed = array (
array ( array (
'firebase/php-jwt' => 'firebase/php-jwt' =>
array ( array (
'pretty_version' => 'v5.2.1', 'pretty_version' => 'v5.3.0',
'version' => '5.2.1.0', 'version' => '5.3.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'f42c9110abe98dd6cfe9053c49bc86acc70b2d23', 'reference' => '3c2d70f2e64e2922345e89f2ceae47d2463faae1',
), ),
'league/flysystem' => 'league/flysystem' =>
array ( array (
@ -116,39 +116,39 @@ private static $installed = array (
), ),
'symfony/polyfill-mbstring' => 'symfony/polyfill-mbstring' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => '5232de97ee3b75b0360528dae24e73db49566ab1', 'reference' => '2df51500adbaebdc4c38dea4c89a2e131c45c8a1',
), ),
'symfony/polyfill-php72' => 'symfony/polyfill-php72' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9', 'reference' => '9a142215a36a3888e30d0a9eeea9766764e96976',
), ),
'symfony/polyfill-php80' => 'symfony/polyfill-php80' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'dc3063ba22c2a1fd2f45ed856374d79114998f91', 'reference' => 'eca0bf41ed421bed1b57c4958bab16aa86b757d0',
), ),
'symfony/var-dumper' => 'symfony/var-dumper' =>
array ( array (
'pretty_version' => 'v4.4.22', 'pretty_version' => 'v4.4.25',
'version' => '4.4.22.0', 'version' => '4.4.25.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'c194bcedde6295f3ec3e9eba1f5d484ea97c41a7', 'reference' => '31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0',
), ),
'taoser/taoler' => 'taoser/taoler' =>
array ( array (

View File

@ -2,17 +2,17 @@
"packages": [ "packages": [
{ {
"name": "firebase/php-jwt", "name": "firebase/php-jwt",
"version": "v5.2.1", "version": "v5.3.0",
"version_normalized": "5.2.1.0", "version_normalized": "5.3.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/firebase/php-jwt.git", "url": "https://github.com/firebase/php-jwt.git",
"reference": "f42c9110abe98dd6cfe9053c49bc86acc70b2d23" "reference": "3c2d70f2e64e2922345e89f2ceae47d2463faae1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/firebase/php-jwt/zipball/f42c9110abe98dd6cfe9053c49bc86acc70b2d23", "url": "https://api.github.com/repos/firebase/php-jwt/zipball/3c2d70f2e64e2922345e89f2ceae47d2463faae1",
"reference": "f42c9110abe98dd6cfe9053c49bc86acc70b2d23", "reference": "3c2d70f2e64e2922345e89f2ceae47d2463faae1",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -27,7 +27,7 @@
"require-dev": { "require-dev": {
"phpunit/phpunit": ">=4.8 <=9" "phpunit/phpunit": ">=4.8 <=9"
}, },
"time": "2021-02-12T00:02:00+00:00", "time": "2021-05-20T17:37:02+00:00",
"type": "library", "type": "library",
"installation-source": "dist", "installation-source": "dist",
"autoload": { "autoload": {
@ -59,7 +59,7 @@
], ],
"support": { "support": {
"issues": "https://github.com/firebase/php-jwt/issues", "issues": "https://github.com/firebase/php-jwt/issues",
"source": "https://github.com/firebase/php-jwt/tree/v5.2.1" "source": "https://github.com/firebase/php-jwt/tree/v5.3.0"
}, },
"install-path": "../firebase/php-jwt" "install-path": "../firebase/php-jwt"
}, },
@ -646,17 +646,17 @@
}, },
{ {
"name": "symfony/polyfill-mbstring", "name": "symfony/polyfill-mbstring",
"version": "v1.22.1", "version": "v1.23.0",
"version_normalized": "1.22.1.0", "version_normalized": "1.23.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git", "url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "5232de97ee3b75b0360528dae24e73db49566ab1" "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/5232de97ee3b75b0360528dae24e73db49566ab1", "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2df51500adbaebdc4c38dea4c89a2e131c45c8a1",
"reference": "5232de97ee3b75b0360528dae24e73db49566ab1", "reference": "2df51500adbaebdc4c38dea4c89a2e131c45c8a1",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -671,11 +671,11 @@
"suggest": { "suggest": {
"ext-mbstring": "For best performance" "ext-mbstring": "For best performance"
}, },
"time": "2021-01-22T09:19:47+00:00", "time": "2021-05-27T09:27:20+00:00",
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -715,7 +715,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -735,17 +735,17 @@
}, },
{ {
"name": "symfony/polyfill-php72", "name": "symfony/polyfill-php72",
"version": "v1.22.1", "version": "v1.23.0",
"version_normalized": "1.22.1.0", "version_normalized": "1.23.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-php72.git", "url": "https://github.com/symfony/polyfill-php72.git",
"reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9" "reference": "9a142215a36a3888e30d0a9eeea9766764e96976"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/9a142215a36a3888e30d0a9eeea9766764e96976",
"reference": "cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9", "reference": "9a142215a36a3888e30d0a9eeea9766764e96976",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -757,11 +757,11 @@
"require": { "require": {
"php": ">=7.1" "php": ">=7.1"
}, },
"time": "2021-01-07T16:49:33+00:00", "time": "2021-05-27T09:17:38+00:00",
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -800,7 +800,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-php72/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-php72/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -820,17 +820,17 @@
}, },
{ {
"name": "symfony/polyfill-php80", "name": "symfony/polyfill-php80",
"version": "v1.22.1", "version": "v1.23.0",
"version_normalized": "1.22.1.0", "version_normalized": "1.23.0.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/polyfill-php80.git", "url": "https://github.com/symfony/polyfill-php80.git",
"reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/eca0bf41ed421bed1b57c4958bab16aa86b757d0",
"reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", "reference": "eca0bf41ed421bed1b57c4958bab16aa86b757d0",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -842,11 +842,11 @@
"require": { "require": {
"php": ">=7.1" "php": ">=7.1"
}, },
"time": "2021-01-07T16:49:33+00:00", "time": "2021-02-19T12:13:01+00:00",
"type": "library", "type": "library",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",
@ -892,7 +892,7 @@
"shim" "shim"
], ],
"support": { "support": {
"source": "https://github.com/symfony/polyfill-php80/tree/v1.22.1" "source": "https://github.com/symfony/polyfill-php80/tree/v1.23.0"
}, },
"funding": [ "funding": [
{ {
@ -912,17 +912,17 @@
}, },
{ {
"name": "symfony/var-dumper", "name": "symfony/var-dumper",
"version": "v4.4.22", "version": "v4.4.25",
"version_normalized": "4.4.22.0", "version_normalized": "4.4.25.0",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/symfony/var-dumper.git", "url": "https://github.com/symfony/var-dumper.git",
"reference": "c194bcedde6295f3ec3e9eba1f5d484ea97c41a7" "reference": "31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/c194bcedde6295f3ec3e9eba1f5d484ea97c41a7", "url": "https://api.github.com/repos/symfony/var-dumper/zipball/31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0",
"reference": "c194bcedde6295f3ec3e9eba1f5d484ea97c41a7", "reference": "31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0",
"shasum": "", "shasum": "",
"mirrors": [ "mirrors": [
{ {
@ -952,7 +952,7 @@
"ext-intl": "To show region name in time zone dump", "ext-intl": "To show region name in time zone dump",
"symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script" "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script"
}, },
"time": "2021-04-19T13:36:17+00:00", "time": "2021-05-27T09:48:32+00:00",
"bin": [ "bin": [
"Resources/bin/var-dump-server" "Resources/bin/var-dump-server"
], ],
@ -990,7 +990,7 @@
"dump" "dump"
], ],
"support": { "support": {
"source": "https://github.com/symfony/var-dumper/tree/v4.4.22" "source": "https://github.com/symfony/var-dumper/tree/v4.4.25"
}, },
"funding": [ "funding": [
{ {

View File

@ -13,12 +13,12 @@
array ( array (
'firebase/php-jwt' => 'firebase/php-jwt' =>
array ( array (
'pretty_version' => 'v5.2.1', 'pretty_version' => 'v5.3.0',
'version' => '5.2.1.0', 'version' => '5.3.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'f42c9110abe98dd6cfe9053c49bc86acc70b2d23', 'reference' => '3c2d70f2e64e2922345e89f2ceae47d2463faae1',
), ),
'league/flysystem' => 'league/flysystem' =>
array ( array (
@ -103,39 +103,39 @@
), ),
'symfony/polyfill-mbstring' => 'symfony/polyfill-mbstring' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => '5232de97ee3b75b0360528dae24e73db49566ab1', 'reference' => '2df51500adbaebdc4c38dea4c89a2e131c45c8a1',
), ),
'symfony/polyfill-php72' => 'symfony/polyfill-php72' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'cc6e6f9b39fe8075b3dabfbaf5b5f645ae1340c9', 'reference' => '9a142215a36a3888e30d0a9eeea9766764e96976',
), ),
'symfony/polyfill-php80' => 'symfony/polyfill-php80' =>
array ( array (
'pretty_version' => 'v1.22.1', 'pretty_version' => 'v1.23.0',
'version' => '1.22.1.0', 'version' => '1.23.0.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'dc3063ba22c2a1fd2f45ed856374d79114998f91', 'reference' => 'eca0bf41ed421bed1b57c4958bab16aa86b757d0',
), ),
'symfony/var-dumper' => 'symfony/var-dumper' =>
array ( array (
'pretty_version' => 'v4.4.22', 'pretty_version' => 'v4.4.25',
'version' => '4.4.22.0', 'version' => '4.4.25.0',
'aliases' => 'aliases' =>
array ( array (
), ),
'reference' => 'c194bcedde6295f3ec3e9eba1f5d484ea97c41a7', 'reference' => '31ea689a8e7d2410016b0d25fc15a1ba05a6e2e0',
), ),
'taoser/taoler' => 'taoser/taoler' =>
array ( array (

View File

@ -0,0 +1,18 @@
#!/bin/sh -l
apt-get update && \
apt-get install -y --no-install-recommends \
git \
zip \
curl \
unzip \
wget
curl --silent --show-error https://getcomposer.org/installer | php
php composer.phar self-update
echo "---Installing dependencies ---"
php composer.phar update
echo "---Running unit tests ---"
vendor/bin/phpunit

View File

@ -0,0 +1,77 @@
name: Test Suite
on:
push:
branches:
- master
pull_request:
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
php: [ "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0" ]
name: PHP ${{matrix.php }} Unit Test
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
- name: Install Dependencies
uses: nick-invision/retry@v1
with:
timeout_minutes: 10
max_attempts: 3
command: composer install
- name: Run Script
run: vendor/bin/phpunit
# use dockerfiles for old versions of php (setup-php times out for those).
test_php55:
name: "PHP 5.5 Unit Test"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Run Unit Tests
uses: docker://php:5.5-cli
with:
entrypoint: ./.github/actions/entrypoint.sh
test_php54:
name: "PHP 5.4 Unit Test"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Run Unit Tests
uses: docker://php:5.4-cli
with:
entrypoint: ./.github/actions/entrypoint.sh
test_php53:
name: "PHP 5.3 Unit Test"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Run Unit Tests
uses: docker://tomsowerby/php-5.3:cli
with:
entrypoint: ./.github/actions/entrypoint.sh
style:
runs-on: ubuntu-latest
name: PHP Style Check
steps:
- uses: actions/checkout@v2
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "7.0"
- name: Run Script
run: |
composer require friendsofphp/php-cs-fixer
vendor/bin/php-cs-fixer fix --diff --dry-run .
vendor/bin/php-cs-fixer fix --rules=native_function_invocation --allow-risky=yes --diff src

View File

@ -13,7 +13,7 @@ modification, are permitted provided that the following conditions are met:
disclaimer in the documentation and/or other materials provided disclaimer in the documentation and/or other materials provided
with the distribution. with the distribution.
* Neither the name of Neuman Vong nor the names of other * Neither the name of the copyright holder nor the names of other
contributors may be used to endorse or promote products derived contributors may be used to endorse or promote products derived
from this software without specific prior written permission. from this software without specific prior written permission.

View File

@ -19,8 +19,7 @@ composer require firebase/php-jwt
Example Example
------- -------
```php ```php
<?php use Firebase\JWT\JWT;
use \Firebase\JWT\JWT;
$key = "example_key"; $key = "example_key";
$payload = array( $payload = array(
@ -57,14 +56,11 @@ $decoded_array = (array) $decoded;
*/ */
JWT::$leeway = 60; // $leeway in seconds JWT::$leeway = 60; // $leeway in seconds
$decoded = JWT::decode($jwt, $key, array('HS256')); $decoded = JWT::decode($jwt, $key, array('HS256'));
?>
``` ```
Example with RS256 (openssl) Example with RS256 (openssl)
---------------------------- ----------------------------
```php ```php
<?php use Firebase\JWT\JWT;
use \Firebase\JWT\JWT;
$privateKey = <<<EOD $privateKey = <<<EOD
-----BEGIN RSA PRIVATE KEY----- -----BEGIN RSA PRIVATE KEY-----
@ -112,13 +108,49 @@ $decoded = JWT::decode($jwt, $publicKey, array('RS256'));
$decoded_array = (array) $decoded; $decoded_array = (array) $decoded;
echo "Decode:\n" . print_r($decoded_array, true) . "\n"; echo "Decode:\n" . print_r($decoded_array, true) . "\n";
?> ```
Example with a passphrase
-------------------------
```php
// Your passphrase
$passphrase = '[YOUR_PASSPHRASE]';
// Your private key file with passphrase
// Can be generated with "ssh-keygen -t rsa -m pem"
$privateKeyFile = '/path/to/key-with-passphrase.pem';
// Create a private key of type "resource"
$privateKey = openssl_pkey_get_private(
file_get_contents($privateKeyFile),
$passphrase
);
$payload = array(
"iss" => "example.org",
"aud" => "example.com",
"iat" => 1356999524,
"nbf" => 1357000000
);
$jwt = JWT::encode($payload, $privateKey, 'RS256');
echo "Encode:\n" . print_r($jwt, true) . "\n";
// Get public key from the private key, or pull from from a file.
$publicKey = openssl_pkey_get_details($privateKey)['key'];
$decoded = JWT::decode($jwt, $publicKey, array('RS256'));
echo "Decode:\n" . print_r((array) $decoded, true) . "\n";
``` ```
Using JWKs Using JWKs
---------- ----------
```php ```php
use Firebase\JWT\JWK;
use Firebase\JWT\JWT;
// Set of keys. The "keys" key is required. For example, the JSON response to // Set of keys. The "keys" key is required. For example, the JSON response to
// this endpoint: https://www.gstatic.com/iap/verify/public_key-jwk // this endpoint: https://www.gstatic.com/iap/verify/public_key-jwk
$jwks = ['keys' => []]; $jwks = ['keys' => []];

View File

@ -1,4 +1,5 @@
<?php <?php
namespace Firebase\JWT; namespace Firebase\JWT;
class BeforeValidException extends \UnexpectedValueException class BeforeValidException extends \UnexpectedValueException

View File

@ -1,4 +1,5 @@
<?php <?php
namespace Firebase\JWT; namespace Firebase\JWT;
class ExpiredException extends \UnexpectedValueException class ExpiredException extends \UnexpectedValueException

View File

@ -82,7 +82,7 @@ class JWK
switch ($jwk['kty']) { switch ($jwk['kty']) {
case 'RSA': case 'RSA':
if (\array_key_exists('d', $jwk)) { if (!empty($jwk['d'])) {
throw new UnexpectedValueException('RSA private keys are not supported'); throw new UnexpectedValueException('RSA private keys are not supported');
} }
if (!isset($jwk['n']) || !isset($jwk['e'])) { if (!isset($jwk['n']) || !isset($jwk['e'])) {

View File

@ -2,10 +2,10 @@
namespace Firebase\JWT; namespace Firebase\JWT;
use \DomainException; use DomainException;
use \InvalidArgumentException; use InvalidArgumentException;
use \UnexpectedValueException; use UnexpectedValueException;
use \DateTime; use DateTime;
/** /**
* JSON Web Token implementation, based on this spec: * JSON Web Token implementation, based on this spec:
@ -42,6 +42,7 @@ class JWT
public static $timestamp = null; public static $timestamp = null;
public static $supported_algs = array( public static $supported_algs = array(
'ES384' => array('openssl', 'SHA384'),
'ES256' => array('openssl', 'SHA256'), 'ES256' => array('openssl', 'SHA256'),
'HS256' => array('hash_hmac', 'SHA256'), 'HS256' => array('hash_hmac', 'SHA256'),
'HS384' => array('hash_hmac', 'SHA384'), 'HS384' => array('hash_hmac', 'SHA384'),
@ -58,10 +59,12 @@ class JWT
* @param string|array|resource $key The key, or map of keys. * @param string|array|resource $key The key, or map of keys.
* If the algorithm used is asymmetric, this is the public key * If the algorithm used is asymmetric, this is the public key
* @param array $allowed_algs List of supported verification algorithms * @param array $allowed_algs List of supported verification algorithms
* Supported algorithms are 'ES256', 'HS256', 'HS384', 'HS512', 'RS256', 'RS384', and 'RS512' * Supported algorithms are 'ES384','ES256', 'HS256', 'HS384',
* 'HS512', 'RS256', 'RS384', and 'RS512'
* *
* @return object The JWT's payload as a PHP object * @return object The JWT's payload as a PHP object
* *
* @throws InvalidArgumentException Provided JWT was empty
* @throws UnexpectedValueException Provided JWT was invalid * @throws UnexpectedValueException Provided JWT was invalid
* @throws SignatureInvalidException Provided JWT was invalid because the signature verification failed * @throws SignatureInvalidException Provided JWT was invalid because the signature verification failed
* @throws BeforeValidException Provided JWT is trying to be used before it's eligible as defined by 'nbf' * @throws BeforeValidException Provided JWT is trying to be used before it's eligible as defined by 'nbf'
@ -101,8 +104,8 @@ class JWT
if (!\in_array($header->alg, $allowed_algs)) { if (!\in_array($header->alg, $allowed_algs)) {
throw new UnexpectedValueException('Algorithm not allowed'); throw new UnexpectedValueException('Algorithm not allowed');
} }
if ($header->alg === 'ES256') { if ($header->alg === 'ES256' || $header->alg === 'ES384') {
// OpenSSL expects an ASN.1 DER sequence for ES256 signatures // OpenSSL expects an ASN.1 DER sequence for ES256/ES384 signatures
$sig = self::signatureToDER($sig); $sig = self::signatureToDER($sig);
} }
@ -150,13 +153,14 @@ class JWT
/** /**
* Converts and signs a PHP object or array into a JWT string. * Converts and signs a PHP object or array into a JWT string.
* *
* @param object|array $payload PHP object or array * @param object|array $payload PHP object or array
* @param string $key The secret key. * @param string|resource $key The secret key.
* If the algorithm used is asymmetric, this is the private key * If the algorithm used is asymmetric, this is the private key
* @param string $alg The signing algorithm. * @param string $alg The signing algorithm.
* Supported algorithms are 'ES256', 'HS256', 'HS384', 'HS512', 'RS256', 'RS384', and 'RS512' * Supported algorithms are 'ES384','ES256', 'HS256', 'HS384',
* @param mixed $keyId * 'HS512', 'RS256', 'RS384', and 'RS512'
* @param array $head An array with header elements to attach * @param mixed $keyId
* @param array $head An array with header elements to attach
* *
* @return string A signed JWT * @return string A signed JWT
* *
@ -189,7 +193,8 @@ class JWT
* @param string $msg The message to sign * @param string $msg The message to sign
* @param string|resource $key The secret key * @param string|resource $key The secret key
* @param string $alg The signing algorithm. * @param string $alg The signing algorithm.
* Supported algorithms are 'ES256', 'HS256', 'HS384', 'HS512', 'RS256', 'RS384', and 'RS512' * Supported algorithms are 'ES384','ES256', 'HS256', 'HS384',
* 'HS512', 'RS256', 'RS384', and 'RS512'
* *
* @return string An encrypted message * @return string An encrypted message
* *
@ -213,6 +218,9 @@ class JWT
if ($alg === 'ES256') { if ($alg === 'ES256') {
$signature = self::signatureFromDER($signature, 256); $signature = self::signatureFromDER($signature, 256);
} }
if ($alg === 'ES384') {
$signature = self::signatureFromDER($signature, 384);
}
return $signature; return $signature;
} }
} }

View File

@ -1,4 +1,5 @@
<?php <?php
namespace Firebase\JWT; namespace Firebase\JWT;
class SignatureInvalidException extends \UnexpectedValueException class SignatureInvalidException extends \UnexpectedValueException

2
vendor/services.php vendored
View File

@ -1,5 +1,5 @@
<?php <?php
// This file is automatically generated at:2021-05-10 13:56:23 // This file is automatically generated at:2021-06-09 14:46:43
declare (strict_types = 1); declare (strict_types = 1);
return array ( return array (
0 => 'think\\captcha\\CaptchaService', 0 => 'think\\captcha\\CaptchaService',

View File

@ -101,7 +101,7 @@ final class Mbstring
$fromEncoding = 'Windows-1252'; $fromEncoding = 'Windows-1252';
} }
if ('UTF-8' !== $fromEncoding) { if ('UTF-8' !== $fromEncoding) {
$s = iconv($fromEncoding, 'UTF-8//IGNORE', $s); $s = \iconv($fromEncoding, 'UTF-8//IGNORE', $s);
} }
return preg_replace_callback('/[\x80-\xFF]+/', [__CLASS__, 'html_encoding_callback'], $s); return preg_replace_callback('/[\x80-\xFF]+/', [__CLASS__, 'html_encoding_callback'], $s);
@ -112,7 +112,7 @@ final class Mbstring
$fromEncoding = 'UTF-8'; $fromEncoding = 'UTF-8';
} }
return iconv($fromEncoding, $toEncoding.'//IGNORE', $s); return \iconv($fromEncoding, $toEncoding.'//IGNORE', $s);
} }
public static function mb_convert_variables($toEncoding, $fromEncoding, &...$vars) public static function mb_convert_variables($toEncoding, $fromEncoding, &...$vars)
@ -129,7 +129,7 @@ final class Mbstring
public static function mb_decode_mimeheader($s) public static function mb_decode_mimeheader($s)
{ {
return iconv_mime_decode($s, 2, self::$internalEncoding); return \iconv_mime_decode($s, 2, self::$internalEncoding);
} }
public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null) public static function mb_encode_mimeheader($s, $charset = null, $transferEncoding = null, $linefeed = null, $indent = null)
@ -165,10 +165,10 @@ final class Mbstring
if ('UTF-8' === $encoding) { if ('UTF-8' === $encoding) {
$encoding = null; $encoding = null;
if (!preg_match('//u', $s)) { if (!preg_match('//u', $s)) {
$s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
} }
} else { } else {
$s = iconv($encoding, 'UTF-8//IGNORE', $s); $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
} }
$cnt = floor(\count($convmap) / 4) * 4; $cnt = floor(\count($convmap) / 4) * 4;
@ -194,7 +194,7 @@ final class Mbstring
return $s; return $s;
} }
return iconv('UTF-8', $encoding.'//IGNORE', $s); return \iconv('UTF-8', $encoding.'//IGNORE', $s);
} }
public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = false) public static function mb_encode_numericentity($s, $convmap, $encoding = null, $is_hex = false)
@ -231,10 +231,10 @@ final class Mbstring
if ('UTF-8' === $encoding) { if ('UTF-8' === $encoding) {
$encoding = null; $encoding = null;
if (!preg_match('//u', $s)) { if (!preg_match('//u', $s)) {
$s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
} }
} else { } else {
$s = iconv($encoding, 'UTF-8//IGNORE', $s); $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
} }
static $ulenMask = ["\xC0" => 2, "\xD0" => 2, "\xE0" => 3, "\xF0" => 4]; static $ulenMask = ["\xC0" => 2, "\xD0" => 2, "\xE0" => 3, "\xF0" => 4];
@ -264,7 +264,7 @@ final class Mbstring
return $result; return $result;
} }
return iconv('UTF-8', $encoding.'//IGNORE', $result); return \iconv('UTF-8', $encoding.'//IGNORE', $result);
} }
public static function mb_convert_case($s, $mode, $encoding = null) public static function mb_convert_case($s, $mode, $encoding = null)
@ -279,10 +279,10 @@ final class Mbstring
if ('UTF-8' === $encoding) { if ('UTF-8' === $encoding) {
$encoding = null; $encoding = null;
if (!preg_match('//u', $s)) { if (!preg_match('//u', $s)) {
$s = @iconv('UTF-8', 'UTF-8//IGNORE', $s); $s = @\iconv('UTF-8', 'UTF-8//IGNORE', $s);
} }
} else { } else {
$s = iconv($encoding, 'UTF-8//IGNORE', $s); $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
} }
if (\MB_CASE_TITLE == $mode) { if (\MB_CASE_TITLE == $mode) {
@ -342,7 +342,7 @@ final class Mbstring
return $s; return $s;
} }
return iconv('UTF-8', $encoding.'//IGNORE', $s); return \iconv('UTF-8', $encoding.'//IGNORE', $s);
} }
public static function mb_internal_encoding($encoding = null) public static function mb_internal_encoding($encoding = null)
@ -353,7 +353,7 @@ final class Mbstring
$normalizedEncoding = self::getEncoding($encoding); $normalizedEncoding = self::getEncoding($encoding);
if ('UTF-8' === $normalizedEncoding || false !== @iconv($normalizedEncoding, $normalizedEncoding, ' ')) { if ('UTF-8' === $normalizedEncoding || false !== @\iconv($normalizedEncoding, $normalizedEncoding, ' ')) {
self::$internalEncoding = $normalizedEncoding; self::$internalEncoding = $normalizedEncoding;
return true; return true;
@ -412,7 +412,7 @@ final class Mbstring
$encoding = self::$internalEncoding; $encoding = self::$internalEncoding;
} }
return self::mb_detect_encoding($var, [$encoding]) || false !== @iconv($encoding, $encoding, $var); return self::mb_detect_encoding($var, [$encoding]) || false !== @\iconv($encoding, $encoding, $var);
} }
public static function mb_detect_encoding($str, $encodingList = null, $strict = false) public static function mb_detect_encoding($str, $encodingList = null, $strict = false)
@ -487,7 +487,7 @@ final class Mbstring
return \strlen($s); return \strlen($s);
} }
return @iconv_strlen($s, $encoding); return @\iconv_strlen($s, $encoding);
} }
public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null) public static function mb_strpos($haystack, $needle, $offset = 0, $encoding = null)
@ -508,7 +508,7 @@ final class Mbstring
return 0; return 0;
} }
return iconv_strpos($haystack, $needle, $offset, $encoding); return \iconv_strpos($haystack, $needle, $offset, $encoding);
} }
public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null) public static function mb_strrpos($haystack, $needle, $offset = 0, $encoding = null)
@ -532,7 +532,7 @@ final class Mbstring
} }
$pos = '' !== $needle || 80000 > \PHP_VERSION_ID $pos = '' !== $needle || 80000 > \PHP_VERSION_ID
? iconv_strrpos($haystack, $needle, $encoding) ? \iconv_strrpos($haystack, $needle, $encoding)
: self::mb_strlen($haystack, $encoding); : self::mb_strlen($haystack, $encoding);
return false !== $pos ? $offset + $pos : false; return false !== $pos ? $offset + $pos : false;
@ -613,7 +613,7 @@ final class Mbstring
} }
if ($start < 0) { if ($start < 0) {
$start = iconv_strlen($s, $encoding) + $start; $start = \iconv_strlen($s, $encoding) + $start;
if ($start < 0) { if ($start < 0) {
$start = 0; $start = 0;
} }
@ -622,13 +622,13 @@ final class Mbstring
if (null === $length) { if (null === $length) {
$length = 2147483647; $length = 2147483647;
} elseif ($length < 0) { } elseif ($length < 0) {
$length = iconv_strlen($s, $encoding) + $length - $start; $length = \iconv_strlen($s, $encoding) + $length - $start;
if ($length < 0) { if ($length < 0) {
return ''; return '';
} }
} }
return (string) iconv_substr($s, $start, $length, $encoding); return (string) \iconv_substr($s, $start, $length, $encoding);
} }
public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null) public static function mb_stripos($haystack, $needle, $offset = 0, $encoding = null)
@ -653,7 +653,7 @@ final class Mbstring
$pos = strrpos($haystack, $needle); $pos = strrpos($haystack, $needle);
} else { } else {
$needle = self::mb_substr($needle, 0, 1, $encoding); $needle = self::mb_substr($needle, 0, 1, $encoding);
$pos = iconv_strrpos($haystack, $needle, $encoding); $pos = \iconv_strrpos($haystack, $needle, $encoding);
} }
return self::getSubpart($pos, $part, $haystack, $encoding); return self::getSubpart($pos, $part, $haystack, $encoding);
@ -732,12 +732,12 @@ final class Mbstring
$encoding = self::getEncoding($encoding); $encoding = self::getEncoding($encoding);
if ('UTF-8' !== $encoding) { if ('UTF-8' !== $encoding) {
$s = iconv($encoding, 'UTF-8//IGNORE', $s); $s = \iconv($encoding, 'UTF-8//IGNORE', $s);
} }
$s = preg_replace('/[\x{1100}-\x{115F}\x{2329}\x{232A}\x{2E80}-\x{303E}\x{3040}-\x{A4CF}\x{AC00}-\x{D7A3}\x{F900}-\x{FAFF}\x{FE10}-\x{FE19}\x{FE30}-\x{FE6F}\x{FF00}-\x{FF60}\x{FFE0}-\x{FFE6}\x{20000}-\x{2FFFD}\x{30000}-\x{3FFFD}]/u', '', $s, -1, $wide); $s = preg_replace('/[\x{1100}-\x{115F}\x{2329}\x{232A}\x{2E80}-\x{303E}\x{3040}-\x{A4CF}\x{AC00}-\x{D7A3}\x{F900}-\x{FAFF}\x{FE10}-\x{FE19}\x{FE30}-\x{FE6F}\x{FF00}-\x{FF60}\x{FFE0}-\x{FFE6}\x{20000}-\x{2FFFD}\x{30000}-\x{3FFFD}]/u', '', $s, -1, $wide);
return ($wide << 1) + iconv_strlen($s, 'UTF-8'); return ($wide << 1) + \iconv_strlen($s, 'UTF-8');
} }
public static function mb_substr_count($haystack, $needle, $encoding = null) public static function mb_substr_count($haystack, $needle, $encoding = null)

View File

@ -81,7 +81,7 @@ return array (
'Ī' => 'ī', 'Ī' => 'ī',
'Ĭ' => 'ĭ', 'Ĭ' => 'ĭ',
'Į' => 'į', 'Į' => 'į',
'İ' => 'i', 'İ' => 'i̇',
'IJ' => 'ij', 'IJ' => 'ij',
'Ĵ' => 'ĵ', 'Ĵ' => 'ĵ',
'Ķ' => 'ķ', 'Ķ' => 'ķ',

View File

@ -746,41 +746,41 @@ return array (
'ύ' => 'Ύ', 'ύ' => 'Ύ',
'ὼ' => 'Ὼ', 'ὼ' => 'Ὼ',
'ώ' => 'Ώ', 'ώ' => 'Ώ',
'ᾀ' => '', 'ᾀ' => 'ἈΙ',
'ᾁ' => '', 'ᾁ' => 'ἉΙ',
'ᾂ' => '', 'ᾂ' => 'ἊΙ',
'ᾃ' => '', 'ᾃ' => 'ἋΙ',
'ᾄ' => '', 'ᾄ' => 'ἌΙ',
'ᾅ' => '', 'ᾅ' => 'ἍΙ',
'ᾆ' => '', 'ᾆ' => 'ἎΙ',
'ᾇ' => '', 'ᾇ' => 'ἏΙ',
'ᾐ' => '', 'ᾐ' => 'ἨΙ',
'ᾑ' => '', 'ᾑ' => 'ἩΙ',
'ᾒ' => '', 'ᾒ' => 'ἪΙ',
'ᾓ' => '', 'ᾓ' => 'ἫΙ',
'ᾔ' => '', 'ᾔ' => 'ἬΙ',
'ᾕ' => '', 'ᾕ' => 'ἭΙ',
'ᾖ' => '', 'ᾖ' => 'ἮΙ',
'ᾗ' => '', 'ᾗ' => 'ἯΙ',
'ᾠ' => '', 'ᾠ' => 'ὨΙ',
'ᾡ' => '', 'ᾡ' => 'ὩΙ',
'ᾢ' => '', 'ᾢ' => 'ὪΙ',
'ᾣ' => '', 'ᾣ' => 'ὫΙ',
'ᾤ' => '', 'ᾤ' => 'ὬΙ',
'ᾥ' => '', 'ᾥ' => 'ὭΙ',
'ᾦ' => '', 'ᾦ' => 'ὮΙ',
'ᾧ' => '', 'ᾧ' => 'ὯΙ',
'ᾰ' => 'Ᾰ', 'ᾰ' => 'Ᾰ',
'ᾱ' => 'Ᾱ', 'ᾱ' => 'Ᾱ',
'ᾳ' => '', 'ᾳ' => 'ΑΙ',
'' => 'Ι', '' => 'Ι',
'ῃ' => '', 'ῃ' => 'ΗΙ',
'ῐ' => 'Ῐ', 'ῐ' => 'Ῐ',
'ῑ' => 'Ῑ', 'ῑ' => 'Ῑ',
'ῠ' => 'Ῠ', 'ῠ' => 'Ῠ',
'ῡ' => 'Ῡ', 'ῡ' => 'Ῡ',
'ῥ' => 'Ῥ', 'ῥ' => 'Ῥ',
'ῳ' => '', 'ῳ' => 'ΩΙ',
'ⅎ' => 'Ⅎ', 'ⅎ' => 'Ⅎ',
'' => '', '' => '',
'ⅱ' => 'Ⅱ', 'ⅱ' => 'Ⅱ',
@ -1411,4 +1411,79 @@ return array (
'𞥁' => '𞤟', '𞥁' => '𞤟',
'𞥂' => '𞤠', '𞥂' => '𞤠',
'𞥃' => '𞤡', '𞥃' => '𞤡',
'ß' => 'SS',
'ff' => 'FF',
'fi' => 'FI',
'fl' => 'FL',
'ffi' => 'FFI',
'ffl' => 'FFL',
'ſt' => 'ST',
'st' => 'ST',
'և' => 'ԵՒ',
'ﬓ' => 'ՄՆ',
'ﬔ' => 'ՄԵ',
'ﬕ' => 'ՄԻ',
'ﬖ' => 'ՎՆ',
'ﬗ' => 'ՄԽ',
'ʼn' => 'ʼN',
'ΐ' => 'Ϊ́',
'ΰ' => 'Ϋ́',
'ǰ' => 'J̌',
'ẖ' => 'H̱',
'ẗ' => 'T̈',
'ẘ' => 'W̊',
'ẙ' => 'Y̊',
'ẚ' => 'Aʾ',
'ὐ' => 'Υ̓',
'ὒ' => 'Υ̓̀',
'ὔ' => 'Υ̓́',
'ὖ' => 'Υ̓͂',
'ᾶ' => 'Α͂',
'ῆ' => 'Η͂',
'ῒ' => 'Ϊ̀',
'ΐ' => 'Ϊ́',
'ῖ' => 'Ι͂',
'ῗ' => 'Ϊ͂',
'ῢ' => 'Ϋ̀',
'ΰ' => 'Ϋ́',
'ῤ' => 'Ρ̓',
'ῦ' => 'Υ͂',
'ῧ' => 'Ϋ͂',
'ῶ' => 'Ω͂',
'ᾈ' => 'ἈΙ',
'ᾉ' => 'ἉΙ',
'ᾊ' => 'ἊΙ',
'ᾋ' => 'ἋΙ',
'ᾌ' => 'ἌΙ',
'ᾍ' => 'ἍΙ',
'ᾎ' => 'ἎΙ',
'ᾏ' => 'ἏΙ',
'ᾘ' => 'ἨΙ',
'ᾙ' => 'ἩΙ',
'ᾚ' => 'ἪΙ',
'ᾛ' => 'ἫΙ',
'ᾜ' => 'ἬΙ',
'ᾝ' => 'ἭΙ',
'ᾞ' => 'ἮΙ',
'ᾟ' => 'ἯΙ',
'ᾨ' => 'ὨΙ',
'ᾩ' => 'ὩΙ',
'ᾪ' => 'ὪΙ',
'ᾫ' => 'ὫΙ',
'ᾬ' => 'ὬΙ',
'ᾭ' => 'ὭΙ',
'ᾮ' => 'ὮΙ',
'ᾯ' => 'ὯΙ',
'ᾼ' => 'ΑΙ',
'ῌ' => 'ΗΙ',
'ῼ' => 'ΩΙ',
'ᾲ' => 'ᾺΙ',
'ᾴ' => 'ΆΙ',
'ῂ' => 'ῊΙ',
'ῄ' => 'ΉΙ',
'ῲ' => 'ῺΙ',
'ῴ' => 'ΏΙ',
'ᾷ' => 'Α͂Ι',
'ῇ' => 'Η͂Ι',
'ῷ' => 'Ω͂Ι',
); );

View File

@ -55,7 +55,7 @@ if (!function_exists('mb_detect_order')) {
function mb_detect_order($encoding = null) { return p\Mbstring::mb_detect_order($encoding); } function mb_detect_order($encoding = null) { return p\Mbstring::mb_detect_order($encoding); }
} }
if (!function_exists('mb_parse_str')) { if (!function_exists('mb_parse_str')) {
function mb_parse_str($string, &$result = []) { parse_str($string, $result); } function mb_parse_str($string, &$result = []) { parse_str($string, $result); return (bool) $result; }
} }
if (!function_exists('mb_strlen')) { if (!function_exists('mb_strlen')) {
function mb_strlen($string, $encoding = null) { return p\Mbstring::mb_strlen($string, $encoding); } function mb_strlen($string, $encoding = null) { return p\Mbstring::mb_strlen($string, $encoding); }

View File

@ -48,10 +48,10 @@ if (!function_exists('mb_detect_encoding')) {
function mb_detect_encoding(?string $string, array|string|null $encodings = null, ?bool $strict = false): string|false { return p\Mbstring::mb_detect_encoding((string) $string, $encodings, (bool) $strict); } function mb_detect_encoding(?string $string, array|string|null $encodings = null, ?bool $strict = false): string|false { return p\Mbstring::mb_detect_encoding((string) $string, $encodings, (bool) $strict); }
} }
if (!function_exists('mb_detect_order')) { if (!function_exists('mb_detect_order')) {
function mb_detect_order(array|string|null $encoding = null): array|bool { return p\Mbstring::mb_detect_order((string) $encoding); } function mb_detect_order(array|string|null $encoding = null): array|bool { return p\Mbstring::mb_detect_order($encoding); }
} }
if (!function_exists('mb_parse_str')) { if (!function_exists('mb_parse_str')) {
function mb_parse_str(?string $string, &$result = []): bool { parse_str((string) $string, $result); } function mb_parse_str(?string $string, &$result = []): bool { parse_str((string) $string, $result); return (bool) $result; }
} }
if (!function_exists('mb_strlen')) { if (!function_exists('mb_strlen')) {
function mb_strlen(?string $string, ?string $encoding = null): int { return p\Mbstring::mb_strlen((string) $string, $encoding); } function mb_strlen(?string $string, ?string $encoding = null): int { return p\Mbstring::mb_strlen((string) $string, $encoding); }
@ -78,7 +78,7 @@ if (!function_exists('mb_stristr')) {
function mb_stristr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_stristr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); } function mb_stristr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_stristr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); }
} }
if (!function_exists('mb_strrchr')) { if (!function_exists('mb_strrchr')) {
function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrchr((string) $haystack, (string) $needle, $before_needle, (bool) $encoding); } function mb_strrchr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrchr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); }
} }
if (!function_exists('mb_strrichr')) { if (!function_exists('mb_strrichr')) {
function mb_strrichr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrichr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); } function mb_strrichr(?string $haystack, ?string $needle, ?bool $before_needle = false, ?string $encoding = null): string|false { return p\Mbstring::mb_strrichr((string) $haystack, (string) $needle, (bool) $before_needle, $encoding); }

View File

@ -28,7 +28,7 @@
"minimum-stability": "dev", "minimum-stability": "dev",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",

View File

@ -182,7 +182,7 @@ final class Php72
$s = \chr(0xF0 | $code >> 18).\chr(0x80 | $code >> 12 & 0x3F).\chr(0x80 | $code >> 6 & 0x3F).\chr(0x80 | $code & 0x3F); $s = \chr(0xF0 | $code >> 18).\chr(0x80 | $code >> 12 & 0x3F).\chr(0x80 | $code >> 6 & 0x3F).\chr(0x80 | $code & 0x3F);
} }
if ('UTF-8' !== $encoding) { if ('UTF-8' !== $encoding = $encoding ?? mb_internal_encoding()) {
$s = mb_convert_encoding($s, $encoding, 'UTF-8'); $s = mb_convert_encoding($s, $encoding, 'UTF-8');
} }

View File

@ -25,7 +25,7 @@
"minimum-stability": "dev", "minimum-stability": "dev",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",

View File

@ -30,7 +30,7 @@
"minimum-stability": "dev", "minimum-stability": "dev",
"extra": { "extra": {
"branch-alias": { "branch-alias": {
"dev-main": "1.22-dev" "dev-main": "1.23-dev"
}, },
"thanks": { "thanks": {
"name": "symfony/polyfill", "name": "symfony/polyfill",

View File

@ -8,8 +8,8 @@ of `var_dump`.
Resources Resources
--------- ---------
* [Documentation](https://symfony.com/doc/current/components/var_dumper/introduction.html) * [Documentation](https://symfony.com/doc/current/components/var_dumper/introduction.html)
* [Contributing](https://symfony.com/doc/current/contributing/index.html) * [Contributing](https://symfony.com/doc/current/contributing/index.html)
* [Report issues](https://github.com/symfony/symfony/issues) and * [Report issues](https://github.com/symfony/symfony/issues) and
[send Pull Requests](https://github.com/symfony/symfony/pulls) [send Pull Requests](https://github.com/symfony/symfony/pulls)
in the [main Symfony repository](https://github.com/symfony/symfony) in the [main Symfony repository](https://github.com/symfony/symfony)

View File

@ -1,5 +1,5 @@
<div class="fly-footer html5plus-hide"> <div class="fly-footer html5plus-hide">
<p> Copyright &copy; {:date('Y')}{$sysInfo.copyright|raw}v{:config('taoler.version')}</p> <p> Copyright &copy; {:date('Y')} {$sysInfo.copyright|raw}v{:config('taoler.version')}</p>
<p> <p>
<a href="#" target="_blank">站务反馈</a> <a href="#" target="_blank">站务反馈</a>
<a href="#" target="_blank">获取本站源码</a> <a href="#" target="_blank">获取本站源码</a>