Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
飞鱼0526
ShopXO
提交
1e4c5d60
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,发现更多精彩内容 >>
提交
1e4c5d60
编写于
4月 24, 2021
作者:
D
Devil
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
系统在线更新+插件在线更新开发优化
上级
0e386733
变更
9
显示空白变更内容
内联
并排
Showing
9 changed file
with
77 addition
and
16 deletion
+77
-16
application/admin/controller/Common.php
application/admin/controller/Common.php
+2
-0
application/admin/view/default/index/init.html
application/admin/view/default/index/init.html
+2
-2
application/admin/view/default/pluginsadmin/index.html
application/admin/view/default/pluginsadmin/index.html
+2
-2
application/admin/view/default/public/footer.html
application/admin/view/default/public/footer.html
+14
-2
application/service/PluginsUpgradeService.php
application/service/PluginsUpgradeService.php
+4
-0
application/service/StoreService.php
application/service/StoreService.php
+10
-8
application/service/SystemUpgradeService.php
application/service/SystemUpgradeService.php
+4
-0
changelog.txt
changelog.txt
+17
-1
public/static/admin/default/js/common.js
public/static/admin/default/js/common.js
+22
-1
未找到文件。
application/admin/controller/Common.php
浏览文件 @
1e4c5d60
...
...
@@ -270,9 +270,11 @@ class Common extends Controller
// 站点商店信息
$site_store_info
=
StoreService
::
SiteStoreInfo
();
//print_r($site_store_info);
if
(
empty
(
$site_store_info
))
{
$res
=
StoreService
::
SiteStoreAccountsBindHandle
();
if
(
$res
[
'code'
]
==
0
)
{
$site_store_info
=
StoreService
::
SiteStoreInfo
();
...
...
application/admin/view/default/index/init.html
浏览文件 @
1e4c5d60
...
...
@@ -10,9 +10,9 @@
{{if !empty($site_store_info) and !empty($site_store_info['user'])}}
<i
class=
"am-icon-user"
></i>
<span>
{{$site_store_info.user.user_name_view}}
</span>
<a
href=
"javascript:;"
class=
"am-margin-left-xs
"
data-am-modal=
"{target: '#store-accounts-popup'}
"
>
修改
</a>
<a
href=
"javascript:;"
class=
"am-margin-left-xs
store-accounts-event
"
>
修改
</a>
{{else /}}
<a
href=
"javascript:;"
class=
"am-margin-left-xs
"
data-am-modal=
"{target: '#store-accounts-popup'}
"
>
绑定ShopXO商店账户
</a>
<a
href=
"javascript:;"
class=
"am-margin-left-xs
store-accounts-event
"
>
绑定ShopXO商店账户
</a>
{{/if}}
<!-- 广告 -->
...
...
application/admin/view/default/pluginsadmin/index.html
浏览文件 @
1e4c5d60
...
...
@@ -26,10 +26,10 @@
<button
type=
"button"
class=
"am-btn am-btn-secondary am-radius am-btn-xs am-margin-left-xs am-icon-check submit-move-sort-save am-hide"
>
保存
</button>
<button
type=
"button"
class=
"am-btn am-btn-danger am-radius am-btn-xs am-margin-left-xs am-icon-close submit-move-sort-cancel am-hide"
>
取消
</button>
</p>
{{if empty($site_store_info)}}
{{if empty($site_store_info)
or empty($site_store_info['user'])
}}
<p>
<span>
3. 绑定ShopXO应用商店帐号、获取插件最新版本信息、在线安装及更新
</span>
<button
type=
"button"
class=
"am-btn am-btn-secondary am-radius am-btn-xs am-margin-left-xs am-icon-gg
"
data-am-modal=
"{target: '#store-accounts-popup'}
"
>
绑定ShopXO商店账户
</button>
<button
type=
"button"
class=
"am-btn am-btn-secondary am-radius am-btn-xs am-margin-left-xs am-icon-gg
store-accounts-event
"
>
绑定ShopXO商店账户
</button>
</p>
{{/if}}
</div>
...
...
application/admin/view/default/public/footer.html
浏览文件 @
1e4c5d60
<!-- 应用商店账户绑定 -->
<div
class=
"am-popup popup-not-title"
id=
"store-accounts-popup"
>
<div
class=
"am-popup-inner"
>
{{if empty($site_store_info) or empty($site_store_info['base']) or !isset($site_store_info['base']['is_user_not_cloae_accounts_popup']) or $site_store_info['base']['is_user_not_cloae_accounts_popup'] eq 0}}
<span
data-am-modal-close
class=
"am-close am-close-alt am-icon-times"
></span>
{{/if}}
<div
class=
"am-popup-bd"
>
<!-- form start -->
<form
class=
"am-form form-validation-store-accounts view-save"
action=
"{{:MyUrl('admin/index/storeaccountsbind')}}"
method=
"POST"
request-type=
"ajax-reload"
>
...
...
@@ -165,3 +167,13 @@
{{/if}}
{{/foreach}}
{{/if}}
<script
type=
"text/javascript"
>
$
(
function
()
{
// 绑定商店帐号
{{
if
!
empty
(
$site_store_info
)
and
!
empty
(
$site_store_info
[
'
base
'
])
and
isset
(
$site_store_info
[
'
base
'
][
'
is_user_force_bind_accounts
'
])
and
$site_store_info
[
'
base
'
][
'
is_user_force_bind_accounts
'
]
eq
1
and
!
in_array
(
$module_name
.
$controller_name
.
$action_name
,
[
'
adminindexindex
'
,
'
adminadminlogininfo
'
])
and
empty
(
$site_store_info
[
'
user
'
])}}
StoreAccountsPopupOpen
();
{{
/
if
}}
});
</script>
\ No newline at end of file
application/service/PluginsUpgradeService.php
浏览文件 @
1e4c5d60
...
...
@@ -189,6 +189,10 @@ class PluginsUpgradeService
// 帐号信息
$accounts
=
MyC
(
'common_store_accounts'
);
$password
=
MyC
(
'common_store_password'
);
if
(
empty
(
$accounts
)
||
empty
(
$password
))
{
return
DataReturn
(
'请先绑定应用商店帐号'
,
-
1
);
}
// 获取信息
$ret
=
StoreService
::
RemoteStoreData
(
$accounts
,
$password
,
self
::
$store_plugins_upgrade_url
,
$params
);
...
...
application/service/StoreService.php
浏览文件 @
1e4c5d60
...
...
@@ -165,7 +165,7 @@ class StoreService
*/
public
static
function
SiteStoreAccountsBindHandle
(
$accounts
=
''
,
$password
=
''
)
{
// 帐号信息
// 帐号信息
、站点初始化信息接口、帐号信息可以为空
if
(
empty
(
$accounts
))
{
$accounts
=
MyC
(
'common_store_accounts'
);
...
...
@@ -189,7 +189,7 @@ class StoreService
}
/**
* 检查更新
*
站点
检查更新
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
...
...
@@ -227,6 +227,10 @@ class StoreService
// 帐号信息
$accounts
=
MyC
(
'common_store_accounts'
);
$password
=
MyC
(
'common_store_password'
);
if
(
empty
(
$accounts
)
||
empty
(
$password
))
{
return
DataReturn
(
'请先绑定应用商店帐号'
,
-
1
);
}
// 获取信息
$request_params
=
[
...
...
@@ -255,6 +259,10 @@ class StoreService
// 帐号信息
$accounts
=
MyC
(
'common_store_accounts'
);
$password
=
MyC
(
'common_store_password'
);
if
(
empty
(
$accounts
)
||
empty
(
$password
))
{
return
DataReturn
(
'请先绑定应用商店帐号'
,
-
1
);
}
// 获取更新信息
return
self
::
RemoteStoreData
(
$accounts
,
$password
,
self
::
$store_plugins_upgrade_info_url
,
$params
);
...
...
@@ -277,12 +285,6 @@ class StoreService
*/
public
static
function
RemoteStoreData
(
$accounts
,
$password
,
$url
,
$params
=
[])
{
// 帐号信息
if
(
empty
(
$accounts
)
||
empty
(
$password
))
{
return
DataReturn
(
'请先绑定应用商店帐号'
,
-
1
);
}
// 基础数据获取
$bo
=
new
\
base\Behavior
();
...
...
application/service/SystemUpgradeService.php
浏览文件 @
1e4c5d60
...
...
@@ -301,6 +301,10 @@ class SystemUpgradeService
// 帐号信息
$accounts
=
MyC
(
'common_store_accounts'
);
$password
=
MyC
(
'common_store_password'
);
if
(
empty
(
$accounts
)
||
empty
(
$password
))
{
return
DataReturn
(
'请先绑定应用商店帐号'
,
-
1
);
}
// 获取信息
$ret
=
StoreService
::
RemoteStoreData
(
$accounts
,
$password
,
self
::
$store_plugins_upgrade_url
,
$params
);
...
...
changelog.txt
浏览文件 @
1e4c5d60
+=========================================================+
ShopXO 2.0.1 20210412 --- http://shopxo.net
ShopXO 2.0.2 Release 000000 http://shopxo.net
+=========================================================+
全局
1.
web端
1. 系统、功能插件、支付插件、web端主题、小程序主题支持在线安装更新
小程序
1.
插件
1.
+=========================================================+
ShopXO 2.0.1 Release 20210412 http://shopxo.net
+=========================================================+
全局
1. 公共图片上传重绘加开关
...
...
public/static/admin/default/js/common.js
浏览文件 @
1e4c5d60
...
...
@@ -163,6 +163,21 @@ function PackageUpgradeRequestHandle(params)
});
}
/**
* 打开商店帐号绑定弹窗
* @author Devil
* @blog http://gong.gg/
* @version 1.0.0
* @date 2021-04-24
* @desc description
*/
function
StoreAccountsPopupOpen
()
{
$
(
'
#store-accounts-popup
'
).
modal
({
closeViaDimmer
:
false
});
}
$
(
function
()
{
// 插件更新操作事件
...
...
@@ -193,7 +208,7 @@ $(function()
$modal
.
find
(
'
.package-upgrade-submit
'
).
attr
(
'
data-type
'
,
type
).
attr
(
'
data-value
'
,
value
).
attr
(
'
data-terminal
'
,
terminal
);
$modal
.
modal
({
closeViaDimmer
:
false
,
width
:
3
3
0
,
width
:
3
1
0
,
height
:
257
});
});
...
...
@@ -215,6 +230,12 @@ $(function()
PackageUpgradeRequestHandle
({
"
url
"
:
url
,
"
type
"
:
type
,
"
value
"
:
value
,
"
terminal
"
:
terminal
});
});
// 商店帐号绑定事件
$
(
document
).
on
(
'
click
'
,
'
.store-accounts-event
'
,
function
()
{
StoreAccountsPopupOpen
();
});
// 商品规格和参数上下移动
$
(
'
.specifications-table,.parameters-table
'
).
on
(
'
click
'
,
'
.line-move
'
,
function
()
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录