Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
飞鱼0526
ShopXO
提交
5bef77ee
ShopXO
项目概览
飞鱼0526
/
ShopXO
与 Fork 源项目一致
Fork自
纵之格 / ShopXO
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
ShopXO
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
5bef77ee
编写于
6月 23, 2019
作者:
G
gongfuxiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
附件接口优化,新增api入口
上级
3d9f95f7
变更
12
隐藏空白更改
内联
并排
Showing
12 changed file
with
248 addition
and
200 deletion
+248
-200
api.php
api.php
+17
-0
application/admin/config/app.php
application/admin/config/app.php
+0
-183
application/admin/view/default/article/save_info.html
application/admin/view/default/article/save_info.html
+1
-1
application/admin/view/default/customview/save_info.html
application/admin/view/default/customview/save_info.html
+1
-1
application/admin/view/default/public/footer.html
application/admin/view/default/public/footer.html
+1
-1
application/api/config/app.php
application/api/config/app.php
+183
-0
application/api/controller/Common.php
application/api/controller/Common.php
+1
-1
application/api/controller/Ueditor.php
application/api/controller/Ueditor.php
+1
-8
application/common.php
application/common.php
+16
-3
application/index/view/default/public/footer.html
application/index/view/default/public/footer.html
+1
-1
config/app.php
config/app.php
+1
-1
public/api.php
public/api.php
+25
-0
未找到文件。
api.php
0 → 100644
浏览文件 @
5bef77ee
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
// 根目录入口
define
(
'IS_ROOT_ACCESS'
,
true
);
// 引入公共入口文件
require
'./public/api.php'
;
?>
\ No newline at end of file
application/admin/config/app.php
浏览文件 @
5bef77ee
...
...
@@ -30,188 +30,5 @@ return [
// 设置默认的模板主题
'DEFAULT_THEME'
=>
'Default'
,
// 百度编辑器配置信息 ueditor
'ueditor_config'
=>
[
// 上传图片配置项
// 执行上传图片的action名称
'imageActionName'
=>
'uploadimage'
,
// 提交的图片表单名称
'imageFieldName'
=>
'upfile'
,
// 上传大小限制,单位B
'imageMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 上传图片格式显示
'imageAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 是否压缩图片,默认是true
'imageCompressEnable'
=>
true
,
// 图片压缩最长边限制
'imageCompressBorder'
=>
1600
,
// 插入的图片浮动方式
'imageInsertAlign'
=>
'none'
,
// 图片访问路径前缀
'imageUrlPrefix'
=>
''
,
// 上传保存路径,可以自定义保存路径和文件名格式
'imagePathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 涂鸦图片上传配置项
// 执行上传涂鸦的action名称
'scrawlActionName'
=>
'uploadscrawl'
,
// 提交的图片表单名称
'scrawlFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'scrawlPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 上传大小限制,单位B
'scrawlMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 上传图片格式显示
'scrawlAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 图片访问路径前缀
'scrawlUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'scrawlInsertAlign'
=>
'none'
,
// 截图工具上传
// 执行上传截图的action名称
'snapscreenActionName'
=>
'uploadimage'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'snapscreenPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 图片访问路径前缀
'snapscreenUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'snapscreenInsertAlign'
=>
'none'
,
// 抓取远程图片配置
// 执行抓取远程图片的action名称
'catcherLocalDomain'
=>
[
'127.0.0.1'
,
'localhost'
,
'img.baidu.com'
],
// 执行抓取远程图片的action名称
'catcherActionName'
=>
'catchimage'
,
// 提交的图片列表表单名称
'catcherFieldName'
=>
'source'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'catcherPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 图片访问路径前缀
'catcherUrlPrefix'
=>
''
,
// 上传大小限制,单位B
'catcherMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 抓取图片格式显示
'catcherAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 上传视频配置
// 执行上传视频的action名称
'videoActionName'
=>
'uploadvideo'
,
// 提交的视频表单名称
'videoFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'videoPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/video/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 视频访问路径前缀
'videoUrlPrefix'
=>
''
,
// 上传大小限制,单位B,默认100MB
'videoMaxSize'
=>
MyC
(
'home_max_limit_video'
,
102400000
,
true
),
// 上传视频格式显示
'videoAllowFiles'
=>
[
'.swf'
,
'.ogg'
,
'.ogv'
,
'.mp4'
,
'.webm'
,
'.mp3'
],
// 上传文件配置
// controller里,执行上传视频的action名称
'fileActionName'
=>
'uploadfile'
,
// 提交的文件表单名称
'fileFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'filePathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/file/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 文件访问路径前缀
'fileUrlPrefix'
=>
''
,
// 上传大小限制,单位B,默认50MB
'fileMaxSize'
=>
MyC
(
'home_max_limit_file'
,
51200000
,
true
),
// 上传文件格式显示
'fileAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
,
'.flv'
,
'.swf'
,
'.mkv'
,
'.avi'
,
'.rm'
,
'.rmvb'
,
'.mpeg'
,
'.mpg'
,
'.ogg'
,
'.ogv'
,
'.mov'
,
'.wmv'
,
'.mp4'
,
'.webm'
,
'.mp3'
,
'.wav'
,
'.mid'
,
'.rar'
,
'.zip'
,
'.tar'
,
'.gz'
,
'.7z'
,
'.bz2'
,
'.cab'
,
'.iso'
,
'.doc'
,
'.docx'
,
'.xls'
,
'.xlsx'
,
'.ppt'
,
'.pptx'
,
'.pdf'
,
'.txt'
,
'.md'
,
'.xml'
],
// 列出指定目录下的图片
// 执行图片管理的action名称
'imageManagerActionName'
=>
'listimage'
,
// 指定要列出图片的目录
'imageManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 每次列出文件数量
'imageManagerListSize'
=>
20
,
// 图片访问路径前缀
'imageManagerUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'imageManagerInsertAlign'
=>
'none'
,
// 列出的文件类型
'imageManagerAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 列出指定目录下的文件
// 执行文件管理的action名称
'fileManagerActionName'
=>
'listfile'
,
// 指定要列出文件的目录
'fileManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/file/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 文件访问路径前缀
'fileManagerUrlPrefix'
=>
''
,
// 每次列出文件数量
'fileManagerListSize'
=>
20
,
// 列出的文件类型
'fileManagerAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
,
'.flv'
,
'.swf'
,
'.mkv'
,
'.avi'
,
'.rm'
,
'.rmvb'
,
'.mpeg'
,
'.mpg'
,
'.ogg'
,
'.ogv'
,
'.mov'
,
'.wmv'
,
'.mp4'
,
'.webm'
,
'.mp3'
,
'.wav'
,
'.mid'
,
'.rar'
,
'.zip'
,
'.tar'
,
'.gz'
,
'.7z'
,
'.bz2'
,
'.cab'
,
'.iso'
,
'.doc'
,
'.docx'
,
'.xls'
,
'.xlsx'
,
'.ppt'
,
'.pptx'
,
'.pdf'
,
'.txt'
,
'.md'
,
'.xml'
],
// 执行视频管理的action名称
'videoManagerActionName'
=>
'listvideo'
,
// 指定要列出文件的目录
'videoManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/video/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 文件访问路径前缀
'videoManagerUrlPrefix'
=>
''
,
// 每次列出文件数量
'videoManagerListSize'
=>
20
,
// 列出的文件类型
'videoManagerAllowFiles'
=>
[
'.swf'
,
'.ogg'
,
'.ogv'
,
'.mp4'
,
'.webm'
,
'.mp3'
],
],
];
?>
\ No newline at end of file
application/admin/view/default/article/save_info.html
浏览文件 @
5bef77ee
...
...
@@ -50,7 +50,7 @@
</div>
<div
class=
"am-form-group"
>
<label>
内容
</label>
<textarea
class=
"am-radius am-validate"
name=
"content"
rows=
"5"
minlength=
"10"
maxlength=
"105000"
{{
if
!
IsMobile
()}}
id=
"editor-tag"
data-url=
"{{:MyUrl('a
dmin
/ueditor/index', ['path_type'=>'article'])}}"
placeholder=
"内容长度最少 10~105000 个字符"
{{
else
/}}
placeholder=
"内容长度最少 10~105000 个字符更多编辑功能请使用电脑访问"
{{/
if
}}
data-validation-message=
"内容长度最少 10~105000 个字符"
required
>
{{if !empty($data)}}{{$data.content}}{{/if}}
</textarea>
<textarea
class=
"am-radius am-validate"
name=
"content"
rows=
"5"
minlength=
"10"
maxlength=
"105000"
{{
if
!
IsMobile
()}}
id=
"editor-tag"
data-url=
"{{:MyUrl('a
pi
/ueditor/index', ['path_type'=>'article'])}}"
placeholder=
"内容长度最少 10~105000 个字符"
{{
else
/}}
placeholder=
"内容长度最少 10~105000 个字符更多编辑功能请使用电脑访问"
{{/
if
}}
data-validation-message=
"内容长度最少 10~105000 个字符"
required
>
{{if !empty($data)}}{{$data.content}}{{/if}}
</textarea>
</div>
<div
class=
"am-alert am-alert-secondary"
>
...
...
application/admin/view/default/customview/save_info.html
浏览文件 @
5bef77ee
...
...
@@ -41,7 +41,7 @@
<div
class=
"am-form-group"
>
<label>
内容{{if IsMobile()}}
<span
class=
"am-form-group-label-tips"
>
更多编辑功能请使用电脑访问
</span>
{{/if}}
</label>
<textarea
class=
"am-radius am-validate"
name=
"content"
rows=
"5"
minlength=
"50"
maxlength=
"105000"
{{
if
!
IsMobile
()}}
id=
"editor-tag"
data-url=
"{{:MyUrl('a
dmin
/ueditor/index', ['path_type'=>'customview'])}}"
placeholder=
"内容长度最少 50~105000 个字符"
{{
else
/}}
placeholder=
"内容长度最少 50~105000 个字符更多编辑功能请使用电脑访问"
{{/
if
}}
data-validation-message=
"内容长度最少 50~105000 个字符"
required
>
{{if !empty($data)}}{{$data.content}}{{/if}}
</textarea>
<textarea
class=
"am-radius am-validate"
name=
"content"
rows=
"5"
minlength=
"50"
maxlength=
"105000"
{{
if
!
IsMobile
()}}
id=
"editor-tag"
data-url=
"{{:MyUrl('a
pi
/ueditor/index', ['path_type'=>'customview'])}}"
placeholder=
"内容长度最少 50~105000 个字符"
{{
else
/}}
placeholder=
"内容长度最少 50~105000 个字符更多编辑功能请使用电脑访问"
{{/
if
}}
data-validation-message=
"内容长度最少 50~105000 个字符"
required
>
{{if !empty($data)}}{{$data.content}}{{/if}}
</textarea>
</div>
<div
class=
"am-form-group am-form-group-refreshing"
>
<input
type=
"hidden"
name=
"id"
{{
if
!
empty
($
data
)}}
value=
"{{$data.id}}"
{{/
if
}}
/>
...
...
application/admin/view/default/public/footer.html
浏览文件 @
5bef77ee
<!-- commom html -->
<textarea
id=
"upload-editor-view"
data-url=
"{{:MyUrl('a
dmin
/ueditor/index', ['path_type'=>empty($editor_path_type) ? 'common' : $editor_path_type])}}"
style=
"display: none;"
></textarea>
<textarea
id=
"upload-editor-view"
data-url=
"{{:MyUrl('a
pi
/ueditor/index', ['path_type'=>empty($editor_path_type) ? 'common' : $editor_path_type])}}"
style=
"display: none;"
></textarea>
<!-- 公共底部钩子 -->
{{if !empty($plugins_admin_view_common_bottom_data) and is_array($plugins_admin_view_common_bottom_data) and (!isset($is_footer) or $is_footer eq 1)}}
...
...
application/api/config/app.php
浏览文件 @
5bef77ee
...
...
@@ -24,5 +24,188 @@ return [
'default_ajax_return'
=>
'json'
,
// 默认JSONP格式返回的处理方法
'default_jsonp_handler'
=>
'jsonpReturn'
,
// 百度编辑器配置信息 ueditor
'ueditor_config'
=>
[
// 上传图片配置项
// 执行上传图片的action名称
'imageActionName'
=>
'uploadimage'
,
// 提交的图片表单名称
'imageFieldName'
=>
'upfile'
,
// 上传大小限制,单位B
'imageMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 上传图片格式显示
'imageAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 是否压缩图片,默认是true
'imageCompressEnable'
=>
true
,
// 图片压缩最长边限制
'imageCompressBorder'
=>
1600
,
// 插入的图片浮动方式
'imageInsertAlign'
=>
'none'
,
// 图片访问路径前缀
'imageUrlPrefix'
=>
''
,
// 上传保存路径,可以自定义保存路径和文件名格式
'imagePathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 涂鸦图片上传配置项
// 执行上传涂鸦的action名称
'scrawlActionName'
=>
'uploadscrawl'
,
// 提交的图片表单名称
'scrawlFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'scrawlPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 上传大小限制,单位B
'scrawlMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 上传图片格式显示
'scrawlAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 图片访问路径前缀
'scrawlUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'scrawlInsertAlign'
=>
'none'
,
// 截图工具上传
// 执行上传截图的action名称
'snapscreenActionName'
=>
'uploadimage'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'snapscreenPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 图片访问路径前缀
'snapscreenUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'snapscreenInsertAlign'
=>
'none'
,
// 抓取远程图片配置
// 执行抓取远程图片的action名称
'catcherLocalDomain'
=>
[
'127.0.0.1'
,
'localhost'
,
'img.baidu.com'
],
// 执行抓取远程图片的action名称
'catcherActionName'
=>
'catchimage'
,
// 提交的图片列表表单名称
'catcherFieldName'
=>
'source'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'catcherPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 图片访问路径前缀
'catcherUrlPrefix'
=>
''
,
// 上传大小限制,单位B
'catcherMaxSize'
=>
MyC
(
'home_max_limit_image'
,
2048000
,
true
),
// 抓取图片格式显示
'catcherAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 上传视频配置
// 执行上传视频的action名称
'videoActionName'
=>
'uploadvideo'
,
// 提交的视频表单名称
'videoFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'videoPathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/video/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 视频访问路径前缀
'videoUrlPrefix'
=>
''
,
// 上传大小限制,单位B,默认100MB
'videoMaxSize'
=>
MyC
(
'home_max_limit_video'
,
102400000
,
true
),
// 上传视频格式显示
'videoAllowFiles'
=>
[
'.swf'
,
'.ogg'
,
'.ogv'
,
'.mp4'
,
'.webm'
,
'.mp3'
],
// 上传文件配置
// controller里,执行上传视频的action名称
'fileActionName'
=>
'uploadfile'
,
// 提交的文件表单名称
'fileFieldName'
=>
'upfile'
,
// 上传保存路径,可以自定义保存路径和文件名格式
'filePathFormat'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/file/'
.
input
(
'path_type'
,
'other'
)
.
'/{yyyy}/{mm}/{dd}/{time}{rand:6}'
,
// 文件访问路径前缀
'fileUrlPrefix'
=>
''
,
// 上传大小限制,单位B,默认50MB
'fileMaxSize'
=>
MyC
(
'home_max_limit_file'
,
51200000
,
true
),
// 上传文件格式显示
'fileAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
,
'.flv'
,
'.swf'
,
'.mkv'
,
'.avi'
,
'.rm'
,
'.rmvb'
,
'.mpeg'
,
'.mpg'
,
'.ogg'
,
'.ogv'
,
'.mov'
,
'.wmv'
,
'.mp4'
,
'.webm'
,
'.mp3'
,
'.wav'
,
'.mid'
,
'.rar'
,
'.zip'
,
'.tar'
,
'.gz'
,
'.7z'
,
'.bz2'
,
'.cab'
,
'.iso'
,
'.doc'
,
'.docx'
,
'.xls'
,
'.xlsx'
,
'.ppt'
,
'.pptx'
,
'.pdf'
,
'.txt'
,
'.md'
,
'.xml'
],
// 列出指定目录下的图片
// 执行图片管理的action名称
'imageManagerActionName'
=>
'listimage'
,
// 指定要列出图片的目录
'imageManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/images/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 每次列出文件数量
'imageManagerListSize'
=>
20
,
// 图片访问路径前缀
'imageManagerUrlPrefix'
=>
''
,
// 插入的图片浮动方式
'imageManagerInsertAlign'
=>
'none'
,
// 列出的文件类型
'imageManagerAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
],
// 列出指定目录下的文件
// 执行文件管理的action名称
'fileManagerActionName'
=>
'listfile'
,
// 指定要列出文件的目录
'fileManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/file/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 文件访问路径前缀
'fileManagerUrlPrefix'
=>
''
,
// 每次列出文件数量
'fileManagerListSize'
=>
20
,
// 列出的文件类型
'fileManagerAllowFiles'
=>
[
'.png'
,
'.jpg'
,
'.jpeg'
,
'.gif'
,
'.bmp'
,
'.flv'
,
'.swf'
,
'.mkv'
,
'.avi'
,
'.rm'
,
'.rmvb'
,
'.mpeg'
,
'.mpg'
,
'.ogg'
,
'.ogv'
,
'.mov'
,
'.wmv'
,
'.mp4'
,
'.webm'
,
'.mp3'
,
'.wav'
,
'.mid'
,
'.rar'
,
'.zip'
,
'.tar'
,
'.gz'
,
'.7z'
,
'.bz2'
,
'.cab'
,
'.iso'
,
'.doc'
,
'.docx'
,
'.xls'
,
'.xlsx'
,
'.ppt'
,
'.pptx'
,
'.pdf'
,
'.txt'
,
'.md'
,
'.xml'
],
// 执行视频管理的action名称
'videoManagerActionName'
=>
'listvideo'
,
// 指定要列出文件的目录
'videoManagerListPath'
=>
__MY_ROOT_PUBLIC__
.
'static/upload/video/'
.
input
(
'path_type'
,
'other'
)
.
'/'
,
// 文件访问路径前缀
'videoManagerUrlPrefix'
=>
''
,
// 每次列出文件数量
'videoManagerListSize'
=>
20
,
// 列出的文件类型
'videoManagerAllowFiles'
=>
[
'.swf'
,
'.ogg'
,
'.ogv'
,
'.mp4'
,
'.webm'
,
'.mp3'
],
],
];
?>
\ No newline at end of file
application/api/controller/Common.php
浏览文件 @
5bef77ee
...
...
@@ -123,7 +123,7 @@ class Common extends Controller
{
if
(
empty
(
$this
->
user
))
{
exit
(
json_encode
(
DataReturn
(
'登录失效,请重新登录'
,
-
400
)));
exit
(
json_encode
(
DataReturn
(
'登录失效,请重新登录
sss
'
,
-
400
)));
}
}
...
...
application/a
dmin
/controller/Ueditor.php
→
application/a
pi
/controller/Ueditor.php
浏览文件 @
5bef77ee
...
...
@@ -8,7 +8,7 @@
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
namespace
app\a
dmin
\controller
;
namespace
app\a
pi
\controller
;
use
think\facade\Hook
;
...
...
@@ -51,13 +51,6 @@ class Ueditor extends Common
$this
->
current_config
=
config
(
'ueditor_config'
);
$this
->
current_action
=
input
(
'action'
);
// 非获取配置信息登录校验
if
(
$this
->
current_action
!=
'config'
)
{
// 登录校验
$this
->
IsLogin
();
}
// action
switch
(
$this
->
current_action
)
{
...
...
application/common.php
浏览文件 @
5bef77ee
...
...
@@ -437,9 +437,15 @@ function MyUrl($path, $params=[])
// 避免从后台生成url入口错误
$script_name
=
CurrentScriptName
();
if
(
$script_name
!=
'index.php'
&&
substr
(
$path
,
0
,
6
)
==
'index/'
)
if
(
$script_name
!=
'index.php'
)
{
$url
=
str_replace
(
$script_name
,
'index.php'
,
$url
);
if
(
substr
(
$path
,
0
,
6
)
==
'index/'
)
{
$url
=
str_replace
(
$script_name
,
'index.php'
,
$url
);
}
elseif
(
substr
(
$path
,
0
,
4
)
==
'api/'
)
{
$url
=
str_replace
(
$script_name
,
'api.php'
,
$url
);
}
}
return
$url
;
...
...
@@ -479,7 +485,14 @@ function PluginsHomeUrl($plugins_name, $plugins_control, $plugins_action, $param
}
// 避免从后台生成url入口错误
$url
=
str_replace
(
CurrentScriptName
(),
'index.php'
,
$url
);
$script_name
=
CurrentScriptName
();
if
(
substr
(
$path
,
0
,
6
)
==
'index/'
)
{
$url
=
str_replace
(
$script_name
,
'index.php'
,
$url
);
}
elseif
(
substr
(
$path
,
0
,
4
)
==
'api/'
)
{
$url
=
str_replace
(
$script_name
,
'api.php'
,
$url
);
}
return
$url
;
}
...
...
application/index/view/default/public/footer.html
浏览文件 @
5bef77ee
<!-- commom html -->
<textarea
id=
"upload-editor-view"
data-url=
"{{:MyUrl('a
dmin
/ueditor/index', ['path_type'=>empty($editor_path_type) ? 'common' : $editor_path_type])}}"
style=
"display: none;"
></textarea>
<textarea
id=
"upload-editor-view"
data-url=
"{{:MyUrl('a
pi
/ueditor/index', ['path_type'=>empty($editor_path_type) ? 'common' : $editor_path_type])}}"
style=
"display: none;"
></textarea>
<!-- footer start -->
{{if !isset($is_footer) or $is_footer eq 1}}
...
...
config/app.php
浏览文件 @
5bef77ee
...
...
@@ -19,7 +19,7 @@ return [
// 应用地址
'app_host'
=>
''
,
// 应用调试模式
'app_debug'
=>
fals
e
,
'app_debug'
=>
tru
e
,
// 应用Trace
'app_trace'
=>
false
,
// 是否支持多模块
...
...
public/api.php
0 → 100644
浏览文件 @
5bef77ee
<?php
// +----------------------------------------------------------------------
// | ShopXO 国内领先企业级B2C免费开源电商系统
// +----------------------------------------------------------------------
// | Copyright (c) 2011~2019 http://shopxo.net All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: Devil
// +----------------------------------------------------------------------
// [ 接口入口文件 ]
namespace
think
;
// 加载基础文件
require
__DIR__
.
'/../thinkphp/base.php'
;
// 支持事先使用静态方法设置Request对象和Config对象
// 引入公共入口文件
require
__DIR__
.
'/core.php'
;
// 执行应用并响应
Container
::
get
(
'app'
)
->
run
()
->
send
();
?>
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录