addons
This commit is contained in:
parent
b147198b0c
commit
a54e206e00
@ -26,7 +26,7 @@ class Addons extends AdminController
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 插件列表
|
* 插件动态列表
|
||||||
* @return Json
|
* @return Json
|
||||||
*/
|
*/
|
||||||
public function addonsList()
|
public function addonsList()
|
||||||
@ -57,10 +57,10 @@ class Addons extends AdminController
|
|||||||
['field'=> 'version','title'=> '版本', 'templet' => '<div>{{d.version}}</div>', 'width'=> 60],
|
['field'=> 'version','title'=> '版本', 'templet' => '<div>{{d.version}}</div>', 'width'=> 60],
|
||||||
['field' => 'author','title'=> '作者', 'width'=> 80],
|
['field' => 'author','title'=> '作者', 'width'=> 80],
|
||||||
['field' => 'description','title'=> '简介', 'minWidth'=> 200],
|
['field' => 'description','title'=> '简介', 'minWidth'=> 200],
|
||||||
['field' => 'show','title'=> '状态', 'width'=> 100],
|
|
||||||
['field' => 'install','title'=> '安装', 'width'=> 100],
|
['field' => 'install','title'=> '安装', 'width'=> 100],
|
||||||
['field' => 'ctime','title'=> '到期时间', 'width'=> 100],
|
['field' => 'ctime','title'=> '到期时间', 'width'=> 100],
|
||||||
['title' => '操作', 'width'=> 200, 'align'=>'center', 'toolbar'=> '#addons-installed-tool']
|
['field' => 'status','title'=> '状态', 'width'=> 95, 'templet' => '#buttonStatus'],
|
||||||
|
['title' => '操作', 'width'=> 150, 'align'=>'center', 'toolbar'=> '#addons-installed-tool']
|
||||||
];
|
];
|
||||||
} else {
|
} else {
|
||||||
$res = ['code'=>-1,'msg'=>'没有安装任何插件'];
|
$res = ['code'=>-1,'msg'=>'没有安装任何插件'];
|
||||||
@ -119,10 +119,10 @@ class Addons extends AdminController
|
|||||||
['field' => 'title','title'=> '插件', 'width'=> 200],
|
['field' => 'title','title'=> '插件', 'width'=> 200],
|
||||||
['field' => 'description','title'=> '简介', 'minWidth'=> 200],
|
['field' => 'description','title'=> '简介', 'minWidth'=> 200],
|
||||||
['field' => 'author','title'=> '作者', 'width'=> 100],
|
['field' => 'author','title'=> '作者', 'width'=> 100],
|
||||||
['field' => 'price','title'=> '价格(元)','width'=> 80],
|
['field' => 'price','title'=> '价格(元)','width'=> 85],
|
||||||
['field' => 'downloads','title'=> '下载', 'width'=> 70],
|
['field' => 'downloads','title'=> '下载', 'width'=> 70],
|
||||||
['field' => 'version','title'=> '版本', 'templet' => '<div>{{d.version}} {{# if(d.have_newversion == 1){ }}<span class="layui-badge-dot"></span>{{# } }}</div>','width'=> 70],
|
['field' => 'version','title'=> '版本', 'templet' => '<div>{{d.version}} {{# if(d.have_newversion == 1){ }}<span class="layui-badge-dot"></span>{{# } }}</div>','width'=> 75],
|
||||||
['field' => 'status','title'=> '状态', 'width'=> 70],
|
['field' => 'status','title'=> '在线', 'width'=> 70],
|
||||||
['title' => '操作', 'width'=> 150, 'align'=>'center', 'toolbar'=> '#addons-tool']
|
['title' => '操作', 'width'=> 150, 'align'=>'center', 'toolbar'=> '#addons-tool']
|
||||||
];
|
];
|
||||||
} else {
|
} else {
|
||||||
@ -151,34 +151,6 @@ class Addons extends AdminController
|
|||||||
}
|
}
|
||||||
return json($res);
|
return json($res);
|
||||||
}
|
}
|
||||||
|
|
||||||
return View::fetch();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 编辑版本
|
|
||||||
* @param $id
|
|
||||||
* @return string|Json
|
|
||||||
* @throws \think\db\exception\DataNotFoundException
|
|
||||||
* @throws \think\db\exception\DbException
|
|
||||||
* @throws \think\db\exception\ModelNotFoundException
|
|
||||||
*/
|
|
||||||
public function edit($id)
|
|
||||||
{
|
|
||||||
$addons = AddonsModel::find($id);
|
|
||||||
|
|
||||||
if(Request::isAjax()){
|
|
||||||
$data = Request::only(['id','addons_name','addons_version','addons_auther','addons_resume','addons_price','addons_src']);
|
|
||||||
$result = $addons->where('id',$id)->save($data);
|
|
||||||
if($result){
|
|
||||||
$res = ['code'=>0,'msg'=>'编辑成功'];
|
|
||||||
}else{
|
|
||||||
$res = ['code'=>-1,'msg'=>'编辑失败'];
|
|
||||||
}
|
|
||||||
return json($res);
|
|
||||||
}
|
|
||||||
View::assign('addons',$addons);
|
|
||||||
return View::fetch();
|
return View::fetch();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -219,17 +191,22 @@ class Addons extends AdminController
|
|||||||
return $this->uploadFiles($type);
|
return $this->uploadFiles($type);
|
||||||
}
|
}
|
||||||
|
|
||||||
//安装插件
|
/**
|
||||||
|
* 安装插件
|
||||||
|
* @return Json
|
||||||
|
* @throws \Exception
|
||||||
|
*/
|
||||||
public function install()
|
public function install()
|
||||||
{
|
{
|
||||||
$data = Request::param();
|
$data = Request::param();
|
||||||
$url = $this->getSystem()['api_url'].'/v1/getaddons';
|
$url = $this->getSystem()['api_url'].'/v1/getaddons';
|
||||||
$data = ['name'=>$data['name'], 'version'=>$data['version'], 'uid'=>$data['uid'], 'token'=>$data['token']];
|
$data = ['name'=>$data['name'], 'version'=>$data['version'], 'uid'=>$data['uid'], 'token'=>$data['token']];
|
||||||
$addons = Api::urlPost($url,$data);
|
$addons = Api::urlPost($url,$data);
|
||||||
if( $addons->code == -1) {
|
if( $addons->code < 0) {
|
||||||
return json(['code'=>$addons->code,'msg'=>$addons->msg]);
|
return json(['code'=>$addons->code,'msg'=>$addons->msg]);
|
||||||
}
|
}
|
||||||
//是否安装?
|
//$this->pay($name,$extend);
|
||||||
|
//版本判断,是否能够安装?
|
||||||
$addInstalledVersion = get_addons_info($data['name']);
|
$addInstalledVersion = get_addons_info($data['name']);
|
||||||
if(!empty($addInstalledVersion)){
|
if(!empty($addInstalledVersion)){
|
||||||
$verRes = version_compare($data['version'],$addInstalledVersion['version'],'>');
|
$verRes = version_compare($data['version'],$addInstalledVersion['version'],'>');
|
||||||
@ -325,7 +302,6 @@ class Addons extends AdminController
|
|||||||
$menu = get_addons_menu($name);
|
$menu = get_addons_menu($name);
|
||||||
if(!empty($menu)){
|
if(!empty($menu)){
|
||||||
$menu_arr[] = $menu['menu'];
|
$menu_arr[] = $menu['menu'];
|
||||||
// halt( $menu_arr);
|
|
||||||
$this->delAddonMenu($menu_arr);
|
$this->delAddonMenu($menu_arr);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -361,7 +337,11 @@ class Addons extends AdminController
|
|||||||
return json(['code' => 0, 'msg' => '插件卸载成功']);
|
return json(['code' => 0, 'msg' => '插件卸载成功']);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 启用禁用插件
|
/**
|
||||||
|
* 启用禁用插件
|
||||||
|
* @return Json
|
||||||
|
* @throws Exception
|
||||||
|
*/
|
||||||
public function status(){
|
public function status(){
|
||||||
$name = input('name');
|
$name = input('name');
|
||||||
$info = get_addons_info($name);
|
$info = get_addons_info($name);
|
||||||
@ -382,7 +362,12 @@ class Addons extends AdminController
|
|||||||
return json($res);
|
return json($res);
|
||||||
}
|
}
|
||||||
|
|
||||||
//配置插件
|
/**
|
||||||
|
* 配置插件
|
||||||
|
* @param $name
|
||||||
|
* @return string|Json
|
||||||
|
* @throws \Exception
|
||||||
|
*/
|
||||||
public function config($name)
|
public function config($name)
|
||||||
{
|
{
|
||||||
$name = input('name');
|
$name = input('name');
|
||||||
@ -426,6 +411,14 @@ class Addons extends AdminController
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加菜单
|
||||||
|
* @param array $menu
|
||||||
|
* @param int $pid
|
||||||
|
* @param int $type
|
||||||
|
* @return void
|
||||||
|
* @throws \Exception
|
||||||
|
*/
|
||||||
public function addAddonMenu(array $menu,int $pid = 0, int $type = 1)
|
public function addAddonMenu(array $menu,int $pid = 0, int $type = 1)
|
||||||
{
|
{
|
||||||
foreach ($menu as $v){
|
foreach ($menu as $v){
|
||||||
@ -451,7 +444,13 @@ class Addons extends AdminController
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//循环删除菜单
|
/**
|
||||||
|
* 循环删除菜单
|
||||||
|
* @param array $menu
|
||||||
|
* @param string $module
|
||||||
|
* @return void
|
||||||
|
* @throws \Exception
|
||||||
|
*/
|
||||||
public function delAddonMenu(array $menu,string $module = 'addon')
|
public function delAddonMenu(array $menu,string $module = 'addon')
|
||||||
{
|
{
|
||||||
foreach ($menu as $k=>$v){
|
foreach ($menu as $k=>$v){
|
||||||
@ -473,6 +472,10 @@ class Addons extends AdminController
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户登录
|
||||||
|
* @return mixed|Json
|
||||||
|
*/
|
||||||
public function userLogin()
|
public function userLogin()
|
||||||
{
|
{
|
||||||
$data = Request::param();
|
$data = Request::param();
|
||||||
@ -485,4 +488,44 @@ class Addons extends AdminController
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 订单
|
||||||
|
* @return string|Json
|
||||||
|
*/
|
||||||
|
public function pay()
|
||||||
|
{
|
||||||
|
$data = Request::only(['id','name','version','uid','price']);
|
||||||
|
$url = $this->getSystem()['api_url'].'/v1/createOrder';
|
||||||
|
$order = Api::urlPost($url,$data);
|
||||||
|
|
||||||
|
if ($order->code == 0) {
|
||||||
|
$orderData = json_decode(json_encode($order->data),TRUE);
|
||||||
|
View::assign('orderData',$orderData);
|
||||||
|
return View::fetch();
|
||||||
|
} else {
|
||||||
|
return json(['code'=>-1,'msg'=>$order->msg]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 支付查询
|
||||||
|
* @return Json
|
||||||
|
*/
|
||||||
|
public function isPay()
|
||||||
|
{
|
||||||
|
$param = Request::only(['name','userinfo']);
|
||||||
|
//halt($data);
|
||||||
|
$data = [
|
||||||
|
'name'=>$param['name'],
|
||||||
|
'uid'=> $param['userinfo']['uid'],
|
||||||
|
];
|
||||||
|
$url = $this->getSystem()['api_url'].'/v1/ispay';
|
||||||
|
$res = Api::urlPost($url,$data);
|
||||||
|
if($res->code == 0) {
|
||||||
|
return json(['code'=>0,'msg'=>'payed']);
|
||||||
|
} else {
|
||||||
|
return json(['code'=>-1,'msg'=>'no pay']);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -3,30 +3,18 @@
|
|||||||
{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-card-body">
|
<div class="layui-card-body">
|
||||||
<form class="layui-form layui-card-header layuiadmin-card-header-auto">
|
|
||||||
<div class="layui-form-item">
|
|
||||||
<div class="layui-inline">插件分类</div>
|
|
||||||
<div class="layui-inline">
|
|
||||||
<select name="id" lay-filter="LAY-user-adminrole-type">
|
|
||||||
<option value="">全部插件</option>
|
|
||||||
<option value="">支付</option>
|
|
||||||
<option value="">第三方登陆</option>
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<table id="addons-list" lay-filter="addons-list"></table>
|
<table id="addons-list" lay-filter="addons-list"></table>
|
||||||
|
|
||||||
<script type="text/html" id="toolbar">
|
<script type="text/html" id="toolbar">
|
||||||
<div class="layui-btn-group" style="padding-bottom: 10px;">
|
<div class="layui-btn-group" style="padding-bottom: 10px;">
|
||||||
<a href="#denable" type="button" class="layui-btn layui-btn-sm" lay-event="allAddons">全部</a>
|
<a href="#denable" type="button" class="layui-btn layui-btn-sm" lay-event="allAddons">全部</a>
|
||||||
<button type="button" class="layui-btn layui-btn-sm" lay-event="freeAddons">免费</button>
|
<a type="button" class="layui-btn layui-btn-sm" lay-event="freeAddons">免费</a>
|
||||||
<button type="button" class="layui-btn layui-btn-sm" lay-event="payAddons">付费</button>
|
<a type="button" class="layui-btn layui-btn-sm" lay-event="payAddons">付费</a>
|
||||||
<a href="#enable" type="button" class="layui-btn layui-btn-sm" lay-event="installed">已安装</a>
|
<a href="#enable" type="button" class="layui-btn layui-btn-normal layui-btn-sm" lay-event="installed">已安装</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-btn-group" style="padding-bottom: 10px;">
|
<div class="layui-btn-group" style="padding-bottom: 10px;">
|
||||||
<button class="layui-btn layui-btn-sm layuiadmin-btn-admin" data-type="add">离线安装</button>
|
<button class="layui-btn layui-btn-danger layui-btn-sm layuiadmin-btn-admin" data-type="add">离线安装</button>
|
||||||
</div>
|
</div>
|
||||||
</script>
|
</script>
|
||||||
<script type="text/html" id="addons-tool">
|
<script type="text/html" id="addons-tool">
|
||||||
@ -36,7 +24,7 @@
|
|||||||
{{# if(d.isInstall ===1) { }}
|
{{# if(d.isInstall ===1) { }}
|
||||||
<a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="config" data-url="{:url('Addons/config')}"><i class="layui-icon layui-icon-set"></i>设置</a>
|
<a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="config" data-url="{:url('Addons/config')}"><i class="layui-icon layui-icon-set"></i>设置</a>
|
||||||
{{# } else { }}
|
{{# } else { }}
|
||||||
<a class="layui-btn layui-btn-xs" lay-event="install" data-url="{:url('Addons/install')}" data-userlogin="{:url('Addons/userLogin')}"><i class="layui-icon layui-icon-edit"></i>安装</a>
|
<a class="layui-btn layui-btn-xs" lay-event="install" data-url="{:url('Addons/install')}" data-userlogin="{:url('Addons/userLogin')}" data-ispay="{:url('Addons/isPay')}"><i class="layui-icon layui-icon-edit"></i>安装</a>
|
||||||
<select id="vers{{d.name}}" name="sss" class="layui-border" lay-ignore lay-filter="versSelect">
|
<select id="vers{{d.name}}" name="sss" class="layui-border" lay-ignore lay-filter="versSelect">
|
||||||
{{# d.vers.forEach(function(item, index){ }}
|
{{# d.vers.forEach(function(item, index){ }}
|
||||||
<option value="{{ item }}">{{ item }}</option>
|
<option value="{{ item }}">{{ item }}</option>
|
||||||
@ -45,28 +33,22 @@
|
|||||||
{{# } }}
|
{{# } }}
|
||||||
{{# } }}
|
{{# } }}
|
||||||
</script>
|
</script>
|
||||||
|
<script type="text/html" id="buttonStatus">
|
||||||
|
<input type="checkbox" name="{{d.name}}" lay-skin="switch" lay-filter="addonsStatus" lay-text="启动|禁用" {{# if(d.status == 1){ }} checked {{# } }} data-url="{:url('Addons/status')}">
|
||||||
|
</script>
|
||||||
<script type="text/html" id="addons-installed-tool">
|
<script type="text/html" id="addons-installed-tool">
|
||||||
{{# if(d.status == 1){ }}
|
|
||||||
<a class="layui-btn layui-btn-xs" lay-event="status" data-url="{:url('Addons/status')}"><i class="layui-icon layui-icon-pause"></i>禁用</a>
|
|
||||||
{{# } else { }}
|
|
||||||
<a class="layui-btn layui-btn-warm layui-btn-xs" lay-event="status" data-url="{:url('Addons/status')}"><i class="layui-icon layui-icon-play"></i>启动</a>
|
|
||||||
{{# } }}
|
|
||||||
<a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="config" data-url="{:url('Addons/config')}"><i class="layui-icon layui-icon-set"></i>设置</a>
|
<a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="config" data-url="{:url('Addons/config')}"><i class="layui-icon layui-icon-set"></i>设置</a>
|
||||||
<a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="uninstall" data-url="{:url('Addons/uninstall')}"><i class="layui-icon layui-icon-delete"></i>卸载</a>
|
<a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="uninstall" data-url="{:url('Addons/uninstall')}"><i class="layui-icon layui-icon-delete"></i>卸载</a>
|
||||||
</script>
|
</script>
|
||||||
|
</div>
|
||||||
</form>
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
{include file="public/user_login" /}
|
{include file="public/user_login" /}
|
||||||
{/block}
|
{/block}
|
||||||
{block name="js"}
|
{block name="js"}
|
||||||
<script src="/static/notify.js"></script>
|
<script src="/static/notify.js"></script>
|
||||||
<script>
|
<script>
|
||||||
var addonsList = "{:url('Addons/addonsList')}",
|
var addonsList = "{:url('Addons/addonsList')}";
|
||||||
addonsEdit = "{:url('Addons/edit')}";
|
|
||||||
|
|
||||||
layui.config({
|
layui.config({
|
||||||
base: '/static/admin/' //静态资源所在路径
|
base: '/static/admin/' //静态资源所在路径
|
||||||
@ -126,6 +108,22 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 启动禁用
|
||||||
|
form.on('switch(addonsStatus)', function(data){
|
||||||
|
var data = data.elem;
|
||||||
|
var url = $(this).data('url');
|
||||||
|
//执行帖子审核
|
||||||
|
$.post(url,{ name: data.name },function(res){
|
||||||
|
if(res.code == 0){
|
||||||
|
notify.success(res.msg, "topRight");
|
||||||
|
} else {
|
||||||
|
notify.error(res.msg, "topRight");
|
||||||
|
}
|
||||||
|
table.reloadData("addons-list",{},'deep');
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
});
|
||||||
|
|
||||||
$('.layui-btn.layuiadmin-btn-admin').on('click', function(){
|
$('.layui-btn.layuiadmin-btn-admin').on('click', function(){
|
||||||
var type = $(this).data('type');
|
var type = $(this).data('type');
|
||||||
active[type] ? active[type].call(this) : '';
|
active[type] ? active[type].call(this) : '';
|
||||||
|
71
app/admin/view/addons/pay.html
Normal file
71
app/admin/view/addons/pay.html
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
{extend name="public/base" /}
|
||||||
|
|
||||||
|
{block name="body"}
|
||||||
|
<style>
|
||||||
|
.layui-container{background-color: #F9F9F9}
|
||||||
|
.auth-type{margin: 10px 0px;}
|
||||||
|
.order-info{margin:10px 0px; line-height: 30px;}
|
||||||
|
.pay-type{line-height: 50px;}
|
||||||
|
.soft-info{margin: 10px;}
|
||||||
|
.pay-tips{line-height:20px;text-align: center;margin-bottom: 20px;}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<div class="layui-container">
|
||||||
|
|
||||||
|
<div class="layui-row">
|
||||||
|
<div class="auth-type">
|
||||||
|
授权
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="layui-row">
|
||||||
|
<div class="order-info">
|
||||||
|
<p>订单标题:<em>{$orderData.subject}</em></p>
|
||||||
|
<p>订单编号:<em>{$orderData.out_trade_no}</em></p>
|
||||||
|
<p>订单价格:<em class="scanpay-price">¥{$orderData.total_amount}</em> 元</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="layui-row">
|
||||||
|
<div class="layui-col-xs6 layui-col-md6">
|
||||||
|
<div class="pay-type">
|
||||||
|
<div style="padding: 5px;"><a ><img src="/static/res/images/alipay.jpg" style="height:80px;"></a></div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="soft-info">
|
||||||
|
<div>不支持退款</div>
|
||||||
|
<br />
|
||||||
|
<div>软件协议:本软件为原作者拥有版权权限,购买软件可以商用,禁止第三方出售行为。</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="layui-col-xs6 layui-col-md6">
|
||||||
|
<div class="qrcode" data-text="{$orderData.qr_code_img}">
|
||||||
|
<img src="{$orderData.qr_code_img}">
|
||||||
|
</div>
|
||||||
|
<div class="pay-tips">
|
||||||
|
<p>请使用支付宝扫一扫<br>扫描二维码进行支付</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
{/block}
|
||||||
|
{block name="js"}
|
||||||
|
<script type="text/javascript">
|
||||||
|
var $ = layui.jquery;
|
||||||
|
var out_trade_no = "{$orderData.out_trade_no}";
|
||||||
|
var interval = setInterval(function(){
|
||||||
|
var url = 'https://www.aieok.com/pay/checkstatus.html?out_trade_no=' + out_trade_no;
|
||||||
|
$.ajax({
|
||||||
|
type: "get",
|
||||||
|
url: url,
|
||||||
|
data: {out_trade_no:out_trade_no},
|
||||||
|
dataType:"json",
|
||||||
|
success: function (res) {
|
||||||
|
// 等等支付时,一直轮询
|
||||||
|
if(res.code !== 0) {
|
||||||
|
clearInterval(interval);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},2500);
|
||||||
|
</script>
|
||||||
|
{/block}
|
@ -127,7 +127,7 @@ 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;
|
var status = data.checked ? 1 : -1;
|
||||||
//执行回帖审核
|
//执行回帖审核
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type:'post',
|
type:'post',
|
||||||
@ -148,7 +148,6 @@ var forumList = "{:url('Forum/list')}",
|
|||||||
adim:6
|
adim:6
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
table.reload('LAY-app-forumreply-list');
|
table.reload('LAY-app-forumreply-list');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
24
composer.lock
generated
24
composer.lock
generated
@ -2130,16 +2130,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/var-dumper",
|
"name": "symfony/var-dumper",
|
||||||
"version": "v4.4.46",
|
"version": "v4.4.47",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/symfony/var-dumper.git",
|
"url": "https://github.com/symfony/var-dumper.git",
|
||||||
"reference": "90425fd98d1ecad98e4b2dca9f54f62069193b15"
|
"reference": "1069c7a3fca74578022fab6f81643248d02f8e63"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/90425fd98d1ecad98e4b2dca9f54f62069193b15",
|
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/1069c7a3fca74578022fab6f81643248d02f8e63",
|
||||||
"reference": "90425fd98d1ecad98e4b2dca9f54f62069193b15",
|
"reference": "1069c7a3fca74578022fab6f81643248d02f8e63",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -2199,7 +2199,7 @@
|
|||||||
"dump"
|
"dump"
|
||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"source": "https://github.com/symfony/var-dumper/tree/v4.4.46"
|
"source": "https://github.com/symfony/var-dumper/tree/v4.4.47"
|
||||||
},
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
@ -2215,7 +2215,7 @@
|
|||||||
"type": "tidelift"
|
"type": "tidelift"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"time": "2022-09-03T23:07:25+00:00"
|
"time": "2022-10-03T15:15:11+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/var-exporter",
|
"name": "symfony/var-exporter",
|
||||||
@ -2292,16 +2292,16 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "taoser/think-addons",
|
"name": "taoser/think-addons",
|
||||||
"version": "v1.0.6",
|
"version": "v1.0.8",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/taoser/think-addons.git",
|
"url": "https://github.com/taoser/think-addons.git",
|
||||||
"reference": "e6e35bfd8b93dc469ebb5c5530ba350131bd7541"
|
"reference": "570367e8d4904842625427f132d23c93f5edfc68"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/taoser/think-addons/zipball/e6e35bfd8b93dc469ebb5c5530ba350131bd7541",
|
"url": "https://api.github.com/repos/taoser/think-addons/zipball/570367e8d4904842625427f132d23c93f5edfc68",
|
||||||
"reference": "e6e35bfd8b93dc469ebb5c5530ba350131bd7541",
|
"reference": "570367e8d4904842625427f132d23c93f5edfc68",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -2343,9 +2343,9 @@
|
|||||||
"description": "The ThinkPHP6 Addons Package",
|
"description": "The ThinkPHP6 Addons Package",
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/taoser/think-addons/issues",
|
"issues": "https://github.com/taoser/think-addons/issues",
|
||||||
"source": "https://github.com/taoser/think-addons/tree/v1.0.6"
|
"source": "https://github.com/taoser/think-addons/tree/v1.0.8"
|
||||||
},
|
},
|
||||||
"time": "2022-10-06T13:11:38+00:00"
|
"time": "2022-10-15T06:21:17+00:00"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "taoser/think-auth",
|
"name": "taoser/think-auth",
|
||||||
|
@ -16,7 +16,7 @@ return [
|
|||||||
// 应用名,此项不可更改
|
// 应用名,此项不可更改
|
||||||
'appname' => 'TaoLer',
|
'appname' => 'TaoLer',
|
||||||
// 版本配置
|
// 版本配置
|
||||||
'version' => '2.0.4',
|
'version' => '2.0.5',
|
||||||
// 加盐
|
// 加盐
|
||||||
'salt' => 'taoler',
|
'salt' => 'taoler',
|
||||||
// 数据库备份目录
|
// 数据库备份目录
|
||||||
|
@ -73,25 +73,50 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
var event = obj.event;
|
var event = obj.event;
|
||||||
var url = $(this).data('url')
|
var url = $(this).data('url')
|
||||||
|
|
||||||
//安装插件
|
// 安装
|
||||||
if (event === "install") {
|
var install = function (data,url,userLoginUrl,userIsPayUrl){
|
||||||
// 检测权限
|
var userinfo = api.userinfo.get(); // 检测权限
|
||||||
var userinfo = api.userinfo.get();
|
|
||||||
var userLoginUrl = $(this).data('userlogin');
|
|
||||||
if(userinfo) {
|
if(userinfo) {
|
||||||
notify.confirm("确认安装吗?", "vcenter",function(){
|
notify.confirm("确认安装吗?", "vcenter",function(){
|
||||||
var index = layer.load(1);
|
var index = layer.load(1);
|
||||||
$.post(url, { name: data.name, version: data.version, uid: userinfo.uid, token: userinfo.token }, function (res) {
|
$.post(url, { name: data.name, version: data.version, uid: userinfo.uid, token: userinfo.token }, function (res) {
|
||||||
if (res.code == 0) {
|
// 需要支付
|
||||||
|
if (res.code === -2) {
|
||||||
|
layer.close(index);
|
||||||
|
layer.open({
|
||||||
|
type: 2,
|
||||||
|
area: ['700px', '650px'],
|
||||||
|
fixed: false, //不固定
|
||||||
|
maxmin: true,
|
||||||
|
content: 'pay.html'+ "?id=" + data.id+ "&name=" + data.name + "&version=" + data.version + "&uid=" + userinfo.uid + "&price=" + data.price,
|
||||||
|
success: function (layero, index){
|
||||||
|
// 订单沦陷
|
||||||
|
var intervalPay = setInterval(function() {
|
||||||
|
$.post(userIsPayUrl,{name:data.name, userinfo:userinfo},function (res){
|
||||||
|
if(res.code === 0) {
|
||||||
|
layer.close(index);
|
||||||
|
clearInterval(intervalPay);
|
||||||
|
install(data,url,userLoginUrl,userIsPayUrl);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},3000);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
// 安装成功
|
||||||
|
if (res.code === 0) {
|
||||||
|
layer.close(index);
|
||||||
notify.success(res.msg, "topRight");
|
notify.success(res.msg, "topRight");
|
||||||
} else {
|
}
|
||||||
|
// 安装失败
|
||||||
|
if (res.code === -1) {
|
||||||
|
layer.close(index);
|
||||||
notify.error(res.msg, "topRight");
|
notify.error(res.msg, "topRight");
|
||||||
}
|
}
|
||||||
layer.close(index);
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
// 登录
|
// 未登录时
|
||||||
layer.confirm('你当前还未登录TaoLer社区账号,请登录后操作!', {
|
layer.confirm('你当前还未登录TaoLer社区账号,请登录后操作!', {
|
||||||
title : '温馨提示',
|
title : '温馨提示',
|
||||||
btnAlign: 'c',
|
btnAlign: 'c',
|
||||||
@ -146,21 +171,13 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 启用禁用
|
//安装插件
|
||||||
if(event == 'status') {
|
if (event === "install") {
|
||||||
notify.confirm("确认框", "vcenter", function(){
|
var userLoginUrl = $(this).data('userlogin');
|
||||||
$.post(url,{ name: data.name },function(res){
|
var userIsPayUrl = $(this).data('ispay');
|
||||||
if (res.code == 0) {
|
install(data,url,userLoginUrl,userIsPayUrl);
|
||||||
notify.success(res.msg, "topRight");
|
|
||||||
} else {
|
|
||||||
notify.error(res.msg, "topRight");
|
|
||||||
}
|
|
||||||
table.reloadData("addons-list",{},'deep');
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 卸载插件
|
// 卸载插件
|
||||||
@ -168,7 +185,7 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
notify.confirm("确认框", "vcenter",function() {
|
notify.confirm("确认框", "vcenter",function() {
|
||||||
var index = layer.load(1);
|
var index = layer.load(1);
|
||||||
$.post(url, { name: data.name }, function (res) {
|
$.post(url, { name: data.name }, function (res) {
|
||||||
if (res.code == 0) {
|
if (res.code === 0) {
|
||||||
notify.success(res.msg, "topRight");
|
notify.success(res.msg, "topRight");
|
||||||
} else {
|
} else {
|
||||||
notify.error(res.msg, "topRight");
|
notify.error(res.msg, "topRight");
|
||||||
@ -183,7 +200,7 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
if (event === "config") {
|
if (event === "config") {
|
||||||
$.post(url,{name:data.name},function (res){
|
$.post(url,{name:data.name},function (res){
|
||||||
// 无配置项拦截
|
// 无配置项拦截
|
||||||
if (res.code == -1) {
|
if (res.code === -1) {
|
||||||
notify.alert(res.msg);
|
notify.alert(res.msg);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -195,9 +212,7 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
area: ["780px", "90%"],
|
area: ["780px", "90%"],
|
||||||
btn: ["确定", "取消"],
|
btn: ["确定", "取消"],
|
||||||
yes: function (index, layero) {
|
yes: function (index, layero) {
|
||||||
var iframeWindow = window["layui-layer-iframe" + index],
|
var iframeWindow = window["layui-layer-iframe" + index], submitID = "LAY-addons-config-submit", submit = layero.find("iframe").contents().find("#" + submitID);
|
||||||
submitID = "LAY-addons-config-submit",
|
|
||||||
submit = layero.find("iframe").contents().find("#" + submitID);
|
|
||||||
//监听提交
|
//监听提交
|
||||||
iframeWindow.layui.form.on("submit(" + submitID + ")",
|
iframeWindow.layui.form.on("submit(" + submitID + ")",
|
||||||
function (data) {
|
function (data) {
|
||||||
@ -208,7 +223,7 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
data: field,
|
data: field,
|
||||||
daType: "json",
|
daType: "json",
|
||||||
success: function (res) {
|
success: function (res) {
|
||||||
if (res.code == 0) {
|
if (res.code === 0) {
|
||||||
notify.success(res.msg, "topRight");
|
notify.success(res.msg, "topRight");
|
||||||
} else {
|
} else {
|
||||||
notify.error(res.msg, "topRight");
|
notify.error(res.msg, "topRight");
|
||||||
@ -251,60 +266,6 @@ layui.define(["table", "form", "upload","notify","hxNav"], function (exports) {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (event === "edit") {
|
|
||||||
var tr = $(obj.tr);
|
|
||||||
layer.open({
|
|
||||||
type: 2,
|
|
||||||
title: "编辑插件",
|
|
||||||
content: addonsEdit + "?id=" + data.id,
|
|
||||||
maxmin: true,
|
|
||||||
area: ["400px", "620px"],
|
|
||||||
btn: ["确定", "取消"],
|
|
||||||
yes: function (index, layero) {
|
|
||||||
var iframeWindow = window["layui-layer-iframe" + index],
|
|
||||||
submitID = "LAY-addons-submit",
|
|
||||||
submit = layero
|
|
||||||
.find("iframe")
|
|
||||||
.contents()
|
|
||||||
.find("#" + submitID);
|
|
||||||
|
|
||||||
//监听提交
|
|
||||||
iframeWindow.layui.form.on(
|
|
||||||
"submit(" + submitID + ")",
|
|
||||||
function (data) {
|
|
||||||
var field = data.field; //获取提交的字段
|
|
||||||
|
|
||||||
//提交 Ajax 成功后,静态更新表格中的数据
|
|
||||||
$.ajax({
|
|
||||||
type: "post",
|
|
||||||
url: addonsEdit,
|
|
||||||
data: field,
|
|
||||||
daType: "json",
|
|
||||||
success: function (res) {
|
|
||||||
if (res.code == 0) {
|
|
||||||
layer.msg(res.msg, { icon: 6, time: 2000 });
|
|
||||||
} else {
|
|
||||||
layer.open({
|
|
||||||
tiele: "修改失败",
|
|
||||||
content: res.msg,
|
|
||||||
icon: 5,
|
|
||||||
anim: 6,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
table.reload("addons-list"); //数据刷新
|
|
||||||
layer.close(index); //关闭弹层
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
submit.trigger("click");
|
|
||||||
},
|
|
||||||
success: function (layero, index) {},
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
exports("addons", {});
|
exports("addons", {});
|
||||||
|
BIN
public/static/res/images/alipay-logo.png
Normal file
BIN
public/static/res/images/alipay-logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 5.9 KiB |
BIN
public/static/res/images/alipay.jpg
Normal file
BIN
public/static/res/images/alipay.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 11 KiB |
2
vendor/composer/autoload_psr4.php
vendored
2
vendor/composer/autoload_psr4.php
vendored
@ -15,7 +15,7 @@ return array(
|
|||||||
'think\\app\\' => array($vendorDir . '/topthink/think-multi-app/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-orm/src', $vendorDir . '/topthink/think-template/src'),
|
||||||
'taoser\\think\\' => array($vendorDir . '/taoser/think-auth/src'),
|
'taoser\\think\\' => array($vendorDir . '/taoser/think-auth/src'),
|
||||||
'taoser\\' => array($vendorDir . '/taoser/think-addons/src', $vendorDir . '/taoser/think-setarr/src'),
|
'taoser\\' => array($vendorDir . '/taoser/think-setarr/src', $vendorDir . '/taoser/think-addons/src'),
|
||||||
'phpspirit\\databackup\\' => array($vendorDir . '/lotofbadcode/phpspirit_databackup/src'),
|
'phpspirit\\databackup\\' => array($vendorDir . '/lotofbadcode/phpspirit_databackup/src'),
|
||||||
'liliuwei\\social\\' => array($vendorDir . '/liliuwei/thinkphp-social/src'),
|
'liliuwei\\social\\' => array($vendorDir . '/liliuwei/thinkphp-social/src'),
|
||||||
'app\\' => array($baseDir . '/app'),
|
'app\\' => array($baseDir . '/app'),
|
||||||
|
4
vendor/composer/autoload_static.php
vendored
4
vendor/composer/autoload_static.php
vendored
@ -184,8 +184,8 @@ class ComposerStaticInit1b32198725235c8d6500c87262ef30c2
|
|||||||
),
|
),
|
||||||
'taoser\\' =>
|
'taoser\\' =>
|
||||||
array (
|
array (
|
||||||
0 => __DIR__ . '/..' . '/taoser/think-addons/src',
|
0 => __DIR__ . '/..' . '/taoser/think-setarr/src',
|
||||||
1 => __DIR__ . '/..' . '/taoser/think-setarr/src',
|
1 => __DIR__ . '/..' . '/taoser/think-addons/src',
|
||||||
),
|
),
|
||||||
'phpspirit\\databackup\\' =>
|
'phpspirit\\databackup\\' =>
|
||||||
array (
|
array (
|
||||||
|
28
vendor/composer/installed.json
vendored
28
vendor/composer/installed.json
vendored
@ -2264,17 +2264,17 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "symfony/var-dumper",
|
"name": "symfony/var-dumper",
|
||||||
"version": "v4.4.46",
|
"version": "v4.4.47",
|
||||||
"version_normalized": "4.4.46.0",
|
"version_normalized": "4.4.47.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/symfony/var-dumper.git",
|
"url": "https://github.com/symfony/var-dumper.git",
|
||||||
"reference": "90425fd98d1ecad98e4b2dca9f54f62069193b15"
|
"reference": "1069c7a3fca74578022fab6f81643248d02f8e63"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/90425fd98d1ecad98e4b2dca9f54f62069193b15",
|
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/1069c7a3fca74578022fab6f81643248d02f8e63",
|
||||||
"reference": "90425fd98d1ecad98e4b2dca9f54f62069193b15",
|
"reference": "1069c7a3fca74578022fab6f81643248d02f8e63",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -2298,7 +2298,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": "2022-09-03T23:07:25+00:00",
|
"time": "2022-10-03T15:15:11+00:00",
|
||||||
"bin": [
|
"bin": [
|
||||||
"Resources/bin/var-dump-server"
|
"Resources/bin/var-dump-server"
|
||||||
],
|
],
|
||||||
@ -2336,7 +2336,7 @@
|
|||||||
"dump"
|
"dump"
|
||||||
],
|
],
|
||||||
"support": {
|
"support": {
|
||||||
"source": "https://github.com/symfony/var-dumper/tree/v4.4.46"
|
"source": "https://github.com/symfony/var-dumper/tree/v4.4.47"
|
||||||
},
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
@ -2432,17 +2432,17 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "taoser/think-addons",
|
"name": "taoser/think-addons",
|
||||||
"version": "v1.0.6",
|
"version": "v1.0.8",
|
||||||
"version_normalized": "1.0.6.0",
|
"version_normalized": "1.0.8.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/taoser/think-addons.git",
|
"url": "https://github.com/taoser/think-addons.git",
|
||||||
"reference": "e6e35bfd8b93dc469ebb5c5530ba350131bd7541"
|
"reference": "570367e8d4904842625427f132d23c93f5edfc68"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/taoser/think-addons/zipball/e6e35bfd8b93dc469ebb5c5530ba350131bd7541",
|
"url": "https://api.github.com/repos/taoser/think-addons/zipball/570367e8d4904842625427f132d23c93f5edfc68",
|
||||||
"reference": "e6e35bfd8b93dc469ebb5c5530ba350131bd7541",
|
"reference": "570367e8d4904842625427f132d23c93f5edfc68",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
@ -2452,7 +2452,7 @@
|
|||||||
"topthink/think-helper": "^3.0.0",
|
"topthink/think-helper": "^3.0.0",
|
||||||
"topthink/think-view": "^1.0"
|
"topthink/think-view": "^1.0"
|
||||||
},
|
},
|
||||||
"time": "2022-10-06T13:11:38+00:00",
|
"time": "2022-10-15T06:21:17+00:00",
|
||||||
"type": "library",
|
"type": "library",
|
||||||
"extra": {
|
"extra": {
|
||||||
"think": {
|
"think": {
|
||||||
@ -2486,7 +2486,7 @@
|
|||||||
"description": "The ThinkPHP6 Addons Package",
|
"description": "The ThinkPHP6 Addons Package",
|
||||||
"support": {
|
"support": {
|
||||||
"issues": "https://github.com/taoser/think-addons/issues",
|
"issues": "https://github.com/taoser/think-addons/issues",
|
||||||
"source": "https://github.com/taoser/think-addons/tree/v1.0.6"
|
"source": "https://github.com/taoser/think-addons/tree/v1.0.8"
|
||||||
},
|
},
|
||||||
"install-path": "../taoser/think-addons"
|
"install-path": "../taoser/think-addons"
|
||||||
},
|
},
|
||||||
|
16
vendor/composer/installed.php
vendored
16
vendor/composer/installed.php
vendored
@ -3,7 +3,7 @@
|
|||||||
'name' => 'taoser/taoler',
|
'name' => 'taoser/taoler',
|
||||||
'pretty_version' => 'dev-master',
|
'pretty_version' => 'dev-master',
|
||||||
'version' => 'dev-master',
|
'version' => 'dev-master',
|
||||||
'reference' => '0c44db5a5d56d4f62656d0fdad68f82c27235469',
|
'reference' => 'ad4f215470c0da087a55d6ee63199988a4d216bd',
|
||||||
'type' => 'project',
|
'type' => 'project',
|
||||||
'install_path' => __DIR__ . '/../../',
|
'install_path' => __DIR__ . '/../../',
|
||||||
'aliases' => array(),
|
'aliases' => array(),
|
||||||
@ -347,9 +347,9 @@
|
|||||||
'dev_requirement' => false,
|
'dev_requirement' => false,
|
||||||
),
|
),
|
||||||
'symfony/var-dumper' => array(
|
'symfony/var-dumper' => array(
|
||||||
'pretty_version' => 'v4.4.46',
|
'pretty_version' => 'v4.4.47',
|
||||||
'version' => '4.4.46.0',
|
'version' => '4.4.47.0',
|
||||||
'reference' => '90425fd98d1ecad98e4b2dca9f54f62069193b15',
|
'reference' => '1069c7a3fca74578022fab6f81643248d02f8e63',
|
||||||
'type' => 'library',
|
'type' => 'library',
|
||||||
'install_path' => __DIR__ . '/../symfony/var-dumper',
|
'install_path' => __DIR__ . '/../symfony/var-dumper',
|
||||||
'aliases' => array(),
|
'aliases' => array(),
|
||||||
@ -367,16 +367,16 @@
|
|||||||
'taoser/taoler' => array(
|
'taoser/taoler' => array(
|
||||||
'pretty_version' => 'dev-master',
|
'pretty_version' => 'dev-master',
|
||||||
'version' => 'dev-master',
|
'version' => 'dev-master',
|
||||||
'reference' => '0c44db5a5d56d4f62656d0fdad68f82c27235469',
|
'reference' => 'ad4f215470c0da087a55d6ee63199988a4d216bd',
|
||||||
'type' => 'project',
|
'type' => 'project',
|
||||||
'install_path' => __DIR__ . '/../../',
|
'install_path' => __DIR__ . '/../../',
|
||||||
'aliases' => array(),
|
'aliases' => array(),
|
||||||
'dev_requirement' => false,
|
'dev_requirement' => false,
|
||||||
),
|
),
|
||||||
'taoser/think-addons' => array(
|
'taoser/think-addons' => array(
|
||||||
'pretty_version' => 'v1.0.6',
|
'pretty_version' => 'v1.0.8',
|
||||||
'version' => '1.0.6.0',
|
'version' => '1.0.8.0',
|
||||||
'reference' => 'e6e35bfd8b93dc469ebb5c5530ba350131bd7541',
|
'reference' => '570367e8d4904842625427f132d23c93f5edfc68',
|
||||||
'type' => 'library',
|
'type' => 'library',
|
||||||
'install_path' => __DIR__ . '/../taoser/think-addons',
|
'install_path' => __DIR__ . '/../taoser/think-addons',
|
||||||
'aliases' => array(),
|
'aliases' => array(),
|
||||||
|
2
vendor/services.php
vendored
2
vendor/services.php
vendored
@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
// This file is automatically generated at:2022-10-10 16:42:53
|
// This file is automatically generated at:2022-10-15 14:22:33
|
||||||
declare (strict_types = 1);
|
declare (strict_types = 1);
|
||||||
return array (
|
return array (
|
||||||
0 => 'taoser\\addons\\Service',
|
0 => 'taoser\\addons\\Service',
|
||||||
|
@ -10,6 +10,10 @@
|
|||||||
* file that was distributed with this source code.
|
* file that was distributed with this source code.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
if ('cli' !== PHP_SAPI) {
|
||||||
|
throw new Exception('This script must be run from the command line.');
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Starts a dump server to collect and output dumps on a single place with multiple formats support.
|
* Starts a dump server to collect and output dumps on a single place with multiple formats support.
|
||||||
*
|
*
|
||||||
|
3
vendor/taoser/think-addons/src/helper.php
vendored
3
vendor/taoser/think-addons/src/helper.php
vendored
@ -317,7 +317,4 @@ if (!function_exists('get_addons_list')) {
|
|||||||
return $list;
|
return $list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{extend name="public/base" /}
|
{extend name="public/base" /}
|
||||||
{block name="title"}发表帖子{/block}
|
{block name="title"}发表帖子{/block}
|
||||||
{block name="link"}<link rel="stylesheet" href="{$Request.domain}/static/res/css/plyr.css" charset="utf-8"/>{/block}
|
{block name="link"} {/block}
|
||||||
{block name="column"}{/block}
|
{block name="column"}{/block}
|
||||||
{block name="content"}
|
{block name="content"}
|
||||||
<div class="layui-container fly-marginTop">
|
<div class="layui-container fly-marginTop">
|
||||||
@ -149,13 +149,12 @@
|
|||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
<script src="/static/xm-select.js"></script>
|
<script src="/static/xm-select.js"></script>
|
||||||
<script>
|
<script>
|
||||||
layui.use(["fly", "plyr"], function () {
|
layui.use(["fly"], function () {
|
||||||
var $ = layui.jquery,
|
var $ = layui.jquery,
|
||||||
fly = layui.fly,
|
fly = layui.fly,
|
||||||
form = layui.form,
|
form = layui.form,
|
||||||
colorpicker = layui.colorpicker,
|
colorpicker = layui.colorpicker,
|
||||||
upload = layui.upload,
|
upload = layui.upload;
|
||||||
plyr = layui.plyr;
|
|
||||||
|
|
||||||
//获取百度标签标志,tag或者word;
|
//获取百度标签标志,tag或者word;
|
||||||
var flag = 'word';
|
var flag = 'word';
|
||||||
@ -323,12 +322,12 @@
|
|||||||
dataType: "json",
|
dataType: "json",
|
||||||
success: function (data) {
|
success: function (data) {
|
||||||
if (data.code == 0) {
|
if (data.code == 0) {
|
||||||
layer.msg(data.msg, { icon: 6, time: 2000 }, function () {
|
notify.success(data.msg, function () {
|
||||||
location.href = data.url;
|
location.href = data.url;
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
layer.open({ title: "发布失败", content: data.msg, icon: 5, anim: 6 });
|
notify.error(data.msg);
|
||||||
l$("#captcha").attr("src", "{:captcha_src()}?" + Math.random());
|
$("#captcha").attr("src", "{:captcha_src()}?" + Math.random());
|
||||||
}
|
}
|
||||||
layer.close(index);
|
layer.close(index);
|
||||||
},
|
},
|
||||||
@ -364,9 +363,6 @@
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
//加载播放器
|
|
||||||
plyr.setup();
|
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
<meta property="bytedance:lrDate_time" content="{$lrDate_time|date='c'}" />
|
<meta property="bytedance:lrDate_time" content="{$lrDate_time|date='c'}" />
|
||||||
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
||||||
{/block}
|
{/block}
|
||||||
{block name="link"}<link rel="stylesheet" href="{$Request.domain}/static/res/css/plyr.css" charset="utf-8"/>{/block}
|
{block name="link"} {/block}
|
||||||
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
||||||
{block name="content"}
|
{block name="content"}
|
||||||
<div class="layui-container">
|
<div class="layui-container">
|
||||||
@ -183,8 +183,11 @@
|
|||||||
</div>
|
</div>
|
||||||
{include file="public/menu" /}
|
{include file="public/menu" /}
|
||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
{block name="script"}
|
{block name="script"}
|
||||||
|
|
||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var collectionFind = "{:url('Collection/find')}",
|
var collectionFind = "{:url('Collection/find')}",
|
||||||
collection = "{:url('collection/')}",
|
collection = "{:url('collection/')}",
|
||||||
@ -198,12 +201,11 @@
|
|||||||
langCollection = "{:lang('collection')}",
|
langCollection = "{:lang('collection')}",
|
||||||
langCancelCollection = "{:lang('cancel collection')}";
|
langCancelCollection = "{:lang('cancel collection')}";
|
||||||
|
|
||||||
layui.use(["fly", "face", "colorpicker", "plyr", "laypage"], function () {
|
layui.use(["fly", "face", "colorpicker", "laypage"], function () {
|
||||||
var $ = layui.jquery,
|
var $ = layui.jquery,
|
||||||
form = layui.form,
|
form = layui.form,
|
||||||
fly = layui.fly,
|
fly = layui.fly,
|
||||||
colorpicker = layui.colorpicker,
|
colorpicker = layui.colorpicker,
|
||||||
plyr = layui.plyr,
|
|
||||||
laytpl = layui.laytpl,
|
laytpl = layui.laytpl,
|
||||||
uid = layui.cache.user.uid,
|
uid = layui.cache.user.uid,
|
||||||
laypage = layui.laypage;
|
laypage = layui.laypage;
|
||||||
@ -334,11 +336,11 @@
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
//加载播放器
|
|
||||||
plyr.setup();
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
{:hook('taoplyr')}
|
||||||
|
|
||||||
{//图片点击放大}
|
{//图片点击放大}
|
||||||
{include file="/public/images-click" /}
|
{include file="/public/images-click" /}
|
||||||
{:hook('markdownhook')}
|
{:hook('markdownhook')}
|
||||||
|
@ -15,7 +15,6 @@
|
|||||||
<meta name="mobile-agent" content="format=html5;url={$Request.domain}{$Request.url}">
|
<meta name="mobile-agent" content="format=html5;url={$Request.domain}{$Request.url}">
|
||||||
{/block}
|
{/block}
|
||||||
{block name="link"}
|
{block name="link"}
|
||||||
<link rel="stylesheet" href="{$Request.domain}/static/res/css/plyr.css" charset="utf-8">
|
|
||||||
<!-- 谷歌JavaScript结构化 -->
|
<!-- 谷歌JavaScript结构化 -->
|
||||||
<script type="application/ld+json">{"@context": "https://schema.org","@type": "NewsArticle","headline": "{$article.title}","image" : "{:getOnepic($article.content)}","datePublished" : "{$article.create_time|date='c'}","dateModified": "{$article.update_time|date='c'}","author" : {"@type" : "Person","name" : "用户投稿","url": "{$Request.domain}"}},</script>
|
<script type="application/ld+json">{"@context": "https://schema.org","@type": "NewsArticle","headline": "{$article.title}","image" : "{:getOnepic($article.content)}","datePublished" : "{$article.create_time|date='c'}","dateModified": "{$article.update_time|date='c'}","author" : {"@type" : "Person","name" : "用户投稿","url": "{$Request.domain}"}},</script>
|
||||||
<!-- 百度JavaScript结构化 -->
|
<!-- 百度JavaScript结构化 -->
|
||||||
@ -287,7 +286,9 @@
|
|||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
{block name="script"}
|
{block name="script"}
|
||||||
|
|
||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
|
|
||||||
<script type='text/javascript' src="{$Request.domain}/view/common/blog/js/theme.js"></script>
|
<script type='text/javascript' src="{$Request.domain}/view/common/blog/js/theme.js"></script>
|
||||||
<script>
|
<script>
|
||||||
var collectionFind = "{:url('Collection/find')}",
|
var collectionFind = "{:url('Collection/find')}",
|
||||||
@ -302,12 +303,11 @@ var collectionFind = "{:url('Collection/find')}",
|
|||||||
langCollection = "{:lang('collection')}",
|
langCollection = "{:lang('collection')}",
|
||||||
langCancelCollection = "{:lang('cancel collection')}";
|
langCancelCollection = "{:lang('cancel collection')}";
|
||||||
|
|
||||||
layui.use(['fly', 'face','colorpicker','plyr', 'laypage'], function(){
|
layui.use(['fly', 'face','colorpicker', 'laypage'], function(){
|
||||||
var $ = layui.jquery
|
var $ = layui.jquery
|
||||||
,form = layui.form
|
,form = layui.form
|
||||||
,fly = layui.fly
|
,fly = layui.fly
|
||||||
,colorpicker = layui.colorpicker
|
,colorpicker = layui.colorpicker
|
||||||
,plyr = layui.plyr
|
|
||||||
,laytpl = layui.laytpl
|
,laytpl = layui.laytpl
|
||||||
,uid = layui.cache.user.uid
|
,uid = layui.cache.user.uid
|
||||||
,laypage = layui.laypage;
|
,laypage = layui.laypage;
|
||||||
@ -445,14 +445,13 @@ layui.use(['fly', 'face','colorpicker','plyr', 'laypage'], function(){
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
//加载播放器
|
|
||||||
plyr.setup();
|
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
{:hook('taoplyr')}
|
||||||
|
|
||||||
{:hook('markdownhook')}
|
{:hook('markdownhook')}
|
||||||
|
|
||||||
{include file="/public/qr-read" /}
|
{include file="/public/qr-read" /}
|
||||||
|
|
||||||
{volist name="push_js" id="vo"}
|
{volist name="push_js" id="vo"}
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{extend name="public/base" /}
|
{extend name="public/base" /}
|
||||||
|
|
||||||
{block name="title"}编辑帖子{/block}
|
{block name="title"}编辑帖子{/block}
|
||||||
{block name="link"}<link rel="stylesheet" href="/static/res/css/plyr.css" charset="utf-8">{/block}
|
{block name="link"} {/block}
|
||||||
{block name="column"}{/block}
|
{block name="column"}{/block}
|
||||||
{block name="content"}
|
{block name="content"}
|
||||||
<div class="layui-container fly-marginTop">
|
<div class="layui-container fly-marginTop">
|
||||||
@ -140,7 +140,9 @@
|
|||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
{block name="script"}
|
{block name="script"}
|
||||||
|
|
||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
|
|
||||||
<script src="/static/xm-select.js"></script>
|
<script src="/static/xm-select.js"></script>
|
||||||
<script>
|
<script>
|
||||||
var cateId = "{$article.cate.id}";
|
var cateId = "{$article.cate.id}";
|
||||||
@ -211,13 +213,12 @@ $(function(){
|
|||||||
|
|
||||||
</script>
|
</script>
|
||||||
<script>
|
<script>
|
||||||
layui.use(['fly','plyr'], function(){
|
layui.use(['fly'], function(){
|
||||||
var $ = layui.jquery
|
var $ = layui.jquery
|
||||||
,fly = layui.fly
|
,fly = layui.fly
|
||||||
,colorpicker = layui.colorpicker
|
,colorpicker = layui.colorpicker
|
||||||
,form = layui.form
|
,form = layui.form
|
||||||
,upload = layui.upload
|
,upload = layui.upload;
|
||||||
,plyr = layui.plyr;
|
|
||||||
|
|
||||||
//获取百度标签标志,tag或者word;
|
//获取百度标签标志,tag或者word;
|
||||||
var flag = 'word';
|
var flag = 'word';
|
||||||
@ -258,15 +259,14 @@ $(function(){
|
|||||||
|
|
||||||
// 获取百度分词接口的关键词
|
// 获取百度分词接口的关键词
|
||||||
function getBdiduWords(flag,title,content) {
|
function getBdiduWords(flag,title,content) {
|
||||||
console.log(flag,title,content)
|
$.post("{:url('article/keywords')}",{ keywords: title, content:content, flag: flag }, function (res) {
|
||||||
$.post("{:url('article/keywords')}",{ keywords: title, content:content, flag: flag }, function (res) {
|
if (res.code == 0) {
|
||||||
if (res.code == 0) {
|
console.log(res.data)
|
||||||
console.log(res.data)
|
$("input[name='keywords']").val(res.data.join(','));
|
||||||
$("input[name='keywords']").val(res.data.join(','));
|
}
|
||||||
}
|
},
|
||||||
},
|
)
|
||||||
)
|
}
|
||||||
}
|
|
||||||
|
|
||||||
// 百度词条
|
// 百度词条
|
||||||
(function(){
|
(function(){
|
||||||
@ -326,13 +326,13 @@ $(function(){
|
|||||||
daType:"json",
|
daType:"json",
|
||||||
success:function (data){
|
success:function (data){
|
||||||
if (data.code == 0) {
|
if (data.code == 0) {
|
||||||
layer.msg(data.msg,{icon:6,time:2000}, function(){
|
notify.success(data.msg, function(){
|
||||||
location.href = data.url;
|
location.href = data.url;
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
layer.open({title:'编辑失败',content:data.msg,icon:5,anim:6});
|
notify.error(data.msg);
|
||||||
layui.jquery('#captcha').attr('src', '{:captcha_src()}?'+Math.random());
|
layui.jquery('#captcha').attr('src', '{:captcha_src()}?'+Math.random());
|
||||||
};
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return false;
|
return false;
|
||||||
@ -344,7 +344,6 @@ $(function(){
|
|||||||
,color: "{$article.title_color ?? '#333'}"
|
,color: "{$article.title_color ?? '#333'}"
|
||||||
,predefine: true // 开启预定义颜色
|
,predefine: true // 开启预定义颜色
|
||||||
,done: function(color){
|
,done: function(color){
|
||||||
//console.log(color);
|
|
||||||
//譬如你可以在回调中把得到的 color 赋值给表单
|
//譬如你可以在回调中把得到的 color 赋值给表单
|
||||||
$('#L_title_color').val(color);
|
$('#L_title_color').val(color);
|
||||||
//改变标题颜色
|
//改变标题颜色
|
||||||
@ -354,22 +353,19 @@ $(function(){
|
|||||||
|
|
||||||
//指定允许上传的文件类型
|
//指定允许上传的文件类型
|
||||||
upload.render({
|
upload.render({
|
||||||
elem: '#zip-button'
|
elem: '#zip-button'
|
||||||
,url: "{:url('article/uploads')}" //改成您自己的上传接口
|
,url: "{:url('article/uploads')}" //改成您自己的上传接口
|
||||||
,data: {type:'zip'}
|
,data: {type:'zip'}
|
||||||
,accept: 'file' //普通文件
|
,accept: 'file' //普通文件
|
||||||
,done: function(res){
|
,done: function(res){
|
||||||
if(res.status == 0){
|
if(res.status == 0){
|
||||||
$('input[name="upzip"]').val(res.url);
|
$('input[name="upzip"]').val(res.url);
|
||||||
layer.msg('上传成功');
|
notify.success(res.msg);
|
||||||
} else {
|
} else {
|
||||||
layer.msg(res.msg);
|
notify.error(res.msg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
//加载播放器
|
|
||||||
plyr.setup();
|
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
<meta property="bytedance:published_time" content="{$article.create_time|date='c'}" />
|
<meta property="bytedance:published_time" content="{$article.create_time|date='c'}" />
|
||||||
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
||||||
{/block}
|
{/block}
|
||||||
{block name="link"}<link rel="stylesheet" href="{$Request.domain}/static/res/css/plyr.css" charset="utf-8">{/block}
|
{block name="link"} {/block}
|
||||||
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
||||||
{block name="content"}
|
{block name="content"}
|
||||||
<div class="layui-container">
|
<div class="layui-container">
|
||||||
@ -64,7 +64,9 @@
|
|||||||
{/block}
|
{/block}
|
||||||
|
|
||||||
{block name="script"}
|
{block name="script"}
|
||||||
|
|
||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var collectionFind = "{:url('Collection/find')}",
|
var collectionFind = "{:url('Collection/find')}",
|
||||||
collection = "{:url('collection/')}",
|
collection = "{:url('collection/')}",
|
||||||
@ -78,13 +80,12 @@
|
|||||||
langCollection = "{:lang('collection')}",
|
langCollection = "{:lang('collection')}",
|
||||||
langCancelCollection = "{:lang('cancel collection')}";
|
langCancelCollection = "{:lang('cancel collection')}";
|
||||||
|
|
||||||
layui.use(['fly', 'face','colorpicker','plyr', 'laypage'], function(){
|
layui.use(['fly', 'face','colorpicker', 'laypage'], function(){
|
||||||
var $ = layui.jquery
|
var $ = layui.jquery
|
||||||
,form = layui.form
|
,form = layui.form
|
||||||
,fly = layui.fly
|
,fly = layui.fly
|
||||||
,colorpicker = layui.colorpicker
|
,colorpicker = layui.colorpicker
|
||||||
,plyr = layui.plyr
|
,laytpl = layui.laytpl
|
||||||
,laytpl = layui.laytpl
|
|
||||||
,uid = layui.cache.user.uid
|
,uid = layui.cache.user.uid
|
||||||
,laypage = layui.laypage;
|
,laypage = layui.laypage;
|
||||||
|
|
||||||
@ -201,12 +202,11 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
});
|
||||||
plyr.setup();
|
|
||||||
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
{:hook('taoplyr')}
|
||||||
|
|
||||||
{//图片点击放大}
|
{//图片点击放大}
|
||||||
{include file="/public/images-click" /}
|
{include file="/public/images-click" /}
|
||||||
{:hook('markdownhook')}
|
{:hook('markdownhook')}
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
<meta property="bytedance:lrDate_time" content="{$lrDate_time|date='c'}" />
|
<meta property="bytedance:lrDate_time" content="{$lrDate_time|date='c'}" />
|
||||||
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
<meta property="bytedance:updated_time" content="{$article.update_time|date='c'}" />
|
||||||
{/block}
|
{/block}
|
||||||
{block name="link"}<link rel="stylesheet" href="{$Request.domain}/static/res/css/plyr.css" charset="utf-8">{/block}
|
{block name="link"} {/block}
|
||||||
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
{block name="column"}<div class="layui-hide-xs">{include file="/public/column" /}</div>{/block}
|
||||||
{block name="content"}
|
{block name="content"}
|
||||||
<div class="layui-container">
|
<div class="layui-container">
|
||||||
@ -203,7 +203,11 @@
|
|||||||
{include file="public/menu" /}
|
{include file="public/menu" /}
|
||||||
{/block}
|
{/block}
|
||||||
{block name="script"}
|
{block name="script"}
|
||||||
|
|
||||||
{:hook('taonyeditor')}
|
{:hook('taonyeditor')}
|
||||||
|
|
||||||
|
{:hook('taoplayer')}
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
var collectionFind = "{:url('Collection/find')}",
|
var collectionFind = "{:url('Collection/find')}",
|
||||||
collection = "{:url('collection/')}",
|
collection = "{:url('collection/')}",
|
||||||
@ -217,12 +221,11 @@ var collectionFind = "{:url('Collection/find')}",
|
|||||||
langCollection = "{:lang('collection')}",
|
langCollection = "{:lang('collection')}",
|
||||||
langCancelCollection = "{:lang('cancel collection')}";
|
langCancelCollection = "{:lang('cancel collection')}";
|
||||||
|
|
||||||
layui.use(['fly', 'face','colorpicker','plyr', 'laypage'], function(){
|
layui.use(['fly', 'face','colorpicker', 'laypage'], function(){
|
||||||
var $ = layui.jquery
|
var $ = layui.jquery
|
||||||
,form = layui.form
|
,form = layui.form
|
||||||
,fly = layui.fly
|
,fly = layui.fly
|
||||||
,colorpicker = layui.colorpicker
|
,colorpicker = layui.colorpicker
|
||||||
,plyr = layui.plyr
|
|
||||||
,laytpl = layui.laytpl
|
,laytpl = layui.laytpl
|
||||||
,uid = layui.cache.user.uid
|
,uid = layui.cache.user.uid
|
||||||
,laypage = layui.laypage;
|
,laypage = layui.laypage;
|
||||||
@ -354,13 +357,11 @@ layui.use(['fly', 'face','colorpicker','plyr', 'laypage'], function(){
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
//加载播放器
|
|
||||||
plyr.setup();
|
|
||||||
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
{:hook('taoplyr')}
|
||||||
|
|
||||||
{//图片点击放大}
|
{//图片点击放大}
|
||||||
{include file="/public/images-click" /}
|
{include file="/public/images-click" /}
|
||||||
{:hook('markdownhook')}
|
{:hook('markdownhook')}
|
||||||
|
@ -81,11 +81,11 @@
|
|||||||
daType:"json",
|
daType:"json",
|
||||||
success:function (data){
|
success:function (data){
|
||||||
if (data.code == 0) {
|
if (data.code == 0) {
|
||||||
layer.msg(data.msg,{icon:6,time:2000}, function(){
|
notify.success(data.msg,function(){
|
||||||
location.href = data.url;
|
location.href = data.url;
|
||||||
});
|
})
|
||||||
} else {
|
} else {
|
||||||
layer.open({title:'登陆失败',content:data.msg,icon:5,anim:6});
|
notify.error(data.msg);
|
||||||
layui.jquery('#captcha').attr('src', '{:captcha_src()}?'+Math.random());
|
layui.jquery('#captcha').attr('src', '{:captcha_src()}?'+Math.random());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
{block name="meta"}{/block}
|
{block name="meta"}{/block}
|
||||||
<script src="/static/jquery-3.6.0.min.js"></script>
|
<script src="/static/jquery-3.6.0.min.js"></script>
|
||||||
<script src="{$Request.domain}/static/layui/layui.js" charset="utf-8"></script>
|
<script src="{$Request.domain}/static/layui/layui.js" charset="utf-8"></script>
|
||||||
|
<script src="/static/notify.js"></script>
|
||||||
<!-- 样式 -->
|
<!-- 样式 -->
|
||||||
<link rel="canonical" href="{$Request.domain}{$Request.url}">
|
<link rel="canonical" href="{$Request.domain}{$Request.url}">
|
||||||
<link rel="stylesheet" href="https://at.alicdn.com/t/font_24081_qs69ykjbea.css" />
|
<link rel="stylesheet" href="https://at.alicdn.com/t/font_24081_qs69ykjbea.css" />
|
||||||
@ -53,6 +54,8 @@
|
|||||||
{include file="public/footer" /}
|
{include file="public/footer" /}
|
||||||
{include file="public/js" /}
|
{include file="public/js" /}
|
||||||
<script>
|
<script>
|
||||||
|
var element = layui.element;
|
||||||
|
var notify = layui.notify;
|
||||||
layui.cache.page = "{$jspage}";
|
layui.cache.page = "{$jspage}";
|
||||||
layui.cache.user = {
|
layui.cache.user = {
|
||||||
username: "{$user.name ?? '游客'}"
|
username: "{$user.name ?? '游客'}"
|
||||||
@ -67,7 +70,6 @@
|
|||||||
}).extend({
|
}).extend({
|
||||||
fly: 'index'
|
fly: 'index'
|
||||||
}).use('fly');
|
}).use('fly');
|
||||||
var element = layui.element;
|
|
||||||
</script>
|
</script>
|
||||||
{block name="script"}{/block}
|
{block name="script"}{/block}
|
||||||
</body>
|
</body>
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
<link rel="stylesheet" href="{$Request.domain}/static/res/css/global.css">
|
<link rel="stylesheet" href="{$Request.domain}/static/res/css/global.css">
|
||||||
{block name="css"}{/block}
|
{block name="css"}{/block}
|
||||||
<script src="{$Request.domain}/static/layui/layui.js" charset="utf-8"></script>
|
<script src="{$Request.domain}/static/layui/layui.js" charset="utf-8"></script>
|
||||||
|
<script src="/static/notify.js"></script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
{include file="public/header" /}
|
{include file="public/header" /}
|
||||||
@ -32,6 +33,7 @@
|
|||||||
</div>
|
</div>
|
||||||
{include file="public/footer" /}
|
{include file="public/footer" /}
|
||||||
<script>
|
<script>
|
||||||
|
var notify = layui.notify;
|
||||||
layui.cache.page = 'user';
|
layui.cache.page = 'user';
|
||||||
layui.cache.user = {
|
layui.cache.user = {
|
||||||
username: "{$user.name ??'游客'}"
|
username: "{$user.name ??'游客'}"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user