Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
starsw001
ShopXO
提交
7d95349a
ShopXO
项目概览
starsw001
/
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,发现更多精彩内容 >>
提交
7d95349a
编写于
5月 02, 2019
作者:
G
gongfuxiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
钱包
上级
fe034db1
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
140 addition
and
59 deletion
+140
-59
application/plugins/view/membershiplevel/admin/index.html
application/plugins/view/membershiplevel/admin/index.html
+1
-1
application/plugins/view/wallet/admin/index.html
application/plugins/view/wallet/admin/index.html
+62
-26
application/plugins/view/wallet/admin/saveinfo.html
application/plugins/view/wallet/admin/saveinfo.html
+48
-18
application/plugins/wallet/Admin.php
application/plugins/wallet/Admin.php
+17
-11
public/static/plugins/css/membershiplevel/admin/admin.css
public/static/plugins/css/membershiplevel/admin/admin.css
+0
-3
public/static/plugins/css/wallet/admin/admin.css
public/static/plugins/css/wallet/admin/admin.css
+12
-0
未找到文件。
application/plugins/view/membershiplevel/admin/index.html
浏览文件 @
7d95349a
...
...
@@ -10,7 +10,7 @@
<div
class=
"membershiplevel-content"
>
<!-- 基础数据 -->
<div
class=
"am-panel am-panel-secondary
membershiplevel-middle-banner
"
>
<div
class=
"am-panel am-panel-secondary"
>
<div
class=
"am-panel-hd"
>
<span
class=
"am-panel-title"
>
基础数据
</span>
<a
class=
"am-fr"
href=
"{{:PluginsAdminUrl('membershiplevel', 'admin', 'saveinfo')}}"
>
编辑
</a>
...
...
application/plugins/view/wallet/admin/index.html
浏览文件 @
7d95349a
...
...
@@ -4,46 +4,82 @@
<div
class=
"content-right"
>
<div
class=
"content"
>
<legend>
<span
class=
"fs-16"
>
会员等级
</span>
<span
class=
"fs-16"
>
钱包
</span>
<a
href=
"{{:MyUrl('admin/pluginsadmin/index')}}"
class=
"fr fs-14 m-t-5 am-icon-mail-reply"
>
返回
</a>
</legend>
<div
class=
"
membershiplevel
-content"
>
<div
class=
"
wallet
-content"
>
<!-- 基础数据 -->
<div
class=
"am-panel am-panel-secondary
membershiplevel-middle-banner
"
>
<div
class=
"am-panel am-panel-secondary
wallet-content-base
"
>
<div
class=
"am-panel-hd"
>
<span
class=
"am-panel-title"
>
基础数据
</span>
<a
class=
"am-fr"
href=
"{{:PluginsAdminUrl('
membershiplevel
', 'admin', 'saveinfo')}}"
>
编辑
</a>
<a
class=
"am-fr"
href=
"{{:PluginsAdminUrl('
wallet
', 'admin', 'saveinfo')}}"
>
编辑
</a>
</div>
<div
class=
"am-panel-bd"
>
<div
class=
"items"
>
<label>
等级规则模式
</label>
<div>
{{if isset($data['level_rules']) and isset($members_level_rules_list[$data['level_rules']])}}
{{:$members_level_rules_list[$data['level_rules']]['name']}}
{{else /}}
未设置,默认[ 积分(可用积分)]
{{/if}}
</div>
</div>
<div
class=
"items"
>
<label>
默认等级图标
</label>
<div
class=
"immages-tag"
>
<img
src=
"{{if !empty($data['default_level_images'])}}{{$data.default_level_images}}{{else /}}{{$attachment_host}}/static/plugins/images/membershiplevel/level-default-images.png{{/if}}"
/>
</div>
</div>
<ul
data-am-widget=
"gallery"
class=
"am-gallery am-avg-sm-2 am-avg-md-4 am-avg-lg-4 am-gallery-default"
data-am-gallery=
"{ pureview: true }"
>
<li>
<div
class=
"items"
>
<label>
开启充值
</label>
<div>
{{if isset($data['is_recharge']) and $data['is_recharge'] eq 1}}
是
{{else /}}
否
{{/if}}
</div>
</div>
</li>
<li>
<div
class=
"items"
>
<label>
开启提现申请
</label>
<div>
{{if isset($data['is_cash']) and $data['is_cash'] eq 1}}
是
{{else /}}
否
{{/if}}
</div>
</div>
</li>
<li>
<div
class=
"items"
>
<label>
开启余额支付功能
</label>
<div>
{{if isset($data['is_pay']) and $data['is_pay'] eq 1}}
是
{{else /}}
否
{{/if}}
</div>
</div>
</li>
<li>
<div
class=
"items"
>
<label>
充值赠送
</label>
<div>
{{if isset($data['recharge_give_type']) and isset($data['recharge_give_value']) and $data['recharge_give_value'] gt 0}}
{{if $data['recharge_give_type'] eq 0}}
固定金额({{$data.recharge_give_value}}元)
{{elseif $data['recharge_give_type'] eq 1 /}}
比例({{$data.recharge_give_value}}%)
{{/if}}
{{else /}}
不赠送
{{/if}}
</div>
</div>
</li>
</ul>
</div>
</div>
<!--
会员等级
-->
<div
class=
"am-panel am-panel-secondary
membershiplevel-level
-list"
>
<!--
管理
-->
<div
class=
"am-panel am-panel-secondary
wallet-middle
-list"
>
<div
class=
"am-panel-hd"
>
<span
class=
"am-panel-title"
>
会员等级
</span>
<a
class=
"am-fr"
href=
"{{:PluginsAdminUrl('membershiplevel', 'level', 'index')}}"
>
编辑
</a>
<span
class=
"am-panel-title"
>
管理
</span>
</div>
<div
class=
"am-panel-bd"
>
<iframe
src=
"{{:PluginsAdminUrl('membershiplevel', 'level', 'index', ['is_admin_index'=>1])}}"
></iframe>
hello
</div>
</div>
</div>
...
...
application/plugins/view/wallet/admin/saveinfo.html
浏览文件 @
7d95349a
...
...
@@ -4,35 +4,65 @@
<div
class=
"content-right"
>
<div
class=
"content"
>
<!-- form start -->
<form
class=
"am-form form-validation view-save"
action=
"{{:PluginsAdminUrl('
membershiplevel', 'admin', 'save')}}"
method=
"POST"
request-type=
"ajax-url"
request-value=
"{{:PluginsAdminUrl('membershiplevel
', 'admin', 'index')}}"
enctype=
"multipart/form-data"
>
<form
class=
"am-form form-validation view-save"
action=
"{{:PluginsAdminUrl('
wallet', 'admin', 'save')}}"
method=
"POST"
request-type=
"ajax-url"
request-value=
"{{:PluginsAdminUrl('wallet
', 'admin', 'index')}}"
enctype=
"multipart/form-data"
>
<legend>
<span
class=
"fs-16"
>
会员等级
</span>
<a
href=
"{{:PluginsAdminUrl('
membershiplevel
', 'admin', 'index')}}"
class=
"fr fs-14 m-t-5 am-icon-mail-reply"
>
返回
</a>
<span
class=
"fs-16"
>
钱包
</span>
<a
href=
"{{:PluginsAdminUrl('
wallet
', 'admin', 'index')}}"
class=
"fr fs-14 m-t-5 am-icon-mail-reply"
>
返回
</a>
</legend>
<div
class=
"am-form-group"
>
<label>
等级规则模式
<span
class=
"am-form-group-label-tips"
>
默认积分
</span></label>
<label>
开启充值
<span
class=
"am-form-group-label-tips"
>
默认关闭
</span></label>
<div>
{{foreach $
members_level_rules
_list as $v}}
{{foreach $
is_whether
_list as $v}}
<label
class=
"am-radio-inline m-r-10"
>
<input
type=
"radio"
name=
"
level_rules"
value=
"{{$v.value}}"
{{
if
isset
($
data
['
level_rules
'])
and
$
data
['
level_rules
']
eq
$
v
['
value
']}}
checked=
"checked"
{{
else
/}}{{
if
!
isset
($
data
['
level_rules
'])
and
isset
($
v
['
checked
'])
and
$
v
['
checked
']
eq
true
}}
checked=
"checked"
{{/
if
}}{{/
if
}}
data-am-ucheck
/>
{{$v.name}}
<input
type=
"radio"
name=
"
is_recharge"
value=
"{{$v.value}}"
{{
if
isset
($
data
['
is_recharge
'])
and
$
data
['
is_recharge
']
eq
$
v
['
value
']}}
checked=
"checked"
{{
else
/}}{{
if
!
isset
($
data
['
is_recharge
'])
and
isset
($
v
['
checked
'])
and
$
v
['
checked
']
eq
true
}}
checked=
"checked"
{{/
if
}}{{/
if
}}
data-am-ucheck
/>
{{$v.name}}
</label>
{{/foreach}}
</div>
</div>
<div
class=
"am-form-group am-form-file"
>
<label
class=
"block"
>
默认等级图标
<span
class=
"am-form-group-label-tips"
>
建议50像数X50像数
</span></label>
<ul
class=
"plug-file-upload-view plugins-default_level_images-view"
data-form-name=
"default_level_images"
data-max-number=
"1"
data-dialog-type=
"images"
>
{{if !empty($data['default_level_images'])}}
<li>
<input
type=
"text"
name=
"default_level_images"
value=
"{{$data.default_level_images_old}}"
data-validation-message=
"请上传默认等级图标"
/>
<img
src=
"{{$data.default_level_images}}"
/>
<i>
×
</i>
</li>
{{/if}}
</ul>
<div
class=
"plug-file-upload-submit"
data-view-tag=
"ul.plugins-default_level_images-view"
>
+上传图片
</div>
<div
class=
"am-form-group"
>
<label>
开启提现申请
<span
class=
"am-form-group-label-tips"
>
默认关闭
</span></label>
<div>
{{foreach $is_whether_list as $v}}
<label
class=
"am-radio-inline m-r-10"
>
<input
type=
"radio"
name=
"is_cash"
value=
"{{$v.value}}"
{{
if
isset
($
data
['
is_cash
'])
and
$
data
['
is_cash
']
eq
$
v
['
value
']}}
checked=
"checked"
{{
else
/}}{{
if
!
isset
($
data
['
is_cash
'])
and
isset
($
v
['
checked
'])
and
$
v
['
checked
']
eq
true
}}
checked=
"checked"
{{/
if
}}{{/
if
}}
data-am-ucheck
/>
{{$v.name}}
</label>
{{/foreach}}
</div>
</div>
<div
class=
"am-form-group"
>
<label>
开启余额支付功能
<span
class=
"am-form-group-label-tips"
>
默认关闭
</span></label>
<div>
{{foreach $is_whether_list as $v}}
<label
class=
"am-radio-inline m-r-10"
>
<input
type=
"radio"
name=
"is_pay"
value=
"{{$v.value}}"
{{
if
isset
($
data
['
is_pay
'])
and
$
data
['
is_pay
']
eq
$
v
['
value
']}}
checked=
"checked"
{{
else
/}}{{
if
!
isset
($
data
['
is_pay
'])
and
isset
($
v
['
checked
'])
and
$
v
['
checked
']
eq
true
}}
checked=
"checked"
{{/
if
}}{{/
if
}}
data-am-ucheck
/>
{{$v.name}}
</label>
{{/foreach}}
</div>
</div>
<div
class=
"am-alert am-alert-warning"
data-am-alert=
""
>
<button
type=
"button"
class=
"am-close"
>
×
</button>
<p>
赠送金额规则,小于0或空则不赠送
<br>
<span
class=
"mini-tips-text"
>
固定金额:填写相应的金额即可
<br>
比例:填写百分比数值,如 10% 则填写 10(小数保留两位、四舍五入)
</span>
</p>
</div>
<div
class=
"am-form-group"
>
<label>
充值赠送
<span
class=
"am-form-group-label-tips"
>
默认固定金额
</span></label>
<div>
{{foreach $recharge_give_type_list as $v}}
<label
class=
"am-radio-inline m-r-10"
>
<input
type=
"radio"
name=
"recharge_give_type"
value=
"{{$v.value}}"
{{
if
isset
($
data
['
recharge_give_type
'])
and
$
data
['
recharge_give_type
']
eq
$
v
['
value
']}}
checked=
"checked"
{{
else
/}}{{
if
!
isset
($
data
['
recharge_give_type
'])
and
isset
($
v
['
checked
'])
and
$
v
['
checked
']
eq
true
}}
checked=
"checked"
{{/
if
}}{{/
if
}}
data-am-ucheck
/>
{{$v.name}}
</label>
{{/foreach}}
</div>
<input
type=
"number"
name=
"recharge_give_value"
placeholder=
"充值赠送金额值"
step=
"0.01"
data-validation-message=
"请填写有效的充值赠送金额值"
class=
"am-radius m-t-10"
{{
if
!
empty
($
data
['
recharge_give_value
'])
and
$
data
['
recharge_give_value
']
gt
0}}
value=
"{{$data.recharge_give_value}}"
{{/
if
}}
/>
</div>
<div
class=
"am-form-group am-form-group-refreshing"
>
...
...
application/plugins/wallet/Admin.php
浏览文件 @
7d95349a
...
...
@@ -11,7 +11,7 @@
namespace
app\plugins\wallet
;
use
think\Controller
;
use
app\plugins\wallet\Service
;
use
app\plugins\wallet\
service\Base
Service
;
use
app\service\PluginsService
;
/**
...
...
@@ -33,12 +33,9 @@ class Admin extends Controller
*/
public
function
index
(
$params
=
[])
{
$ret
=
PluginsService
::
PluginsData
(
'wallet'
,
Service
::
$base_config_attachment_field
,
false
);
$ret
=
PluginsService
::
PluginsData
(
'wallet'
,
''
,
false
);
if
(
$ret
[
'code'
]
==
0
)
{
// 等级规则
$this
->
assign
(
'members_level_rules_list'
,
Service
::
$members_level_rules_list
);
{
$this
->
assign
(
'data'
,
$ret
[
'data'
]);
return
$this
->
fetch
(
'../../../plugins/view/wallet/admin/index'
);
}
else
{
...
...
@@ -56,11 +53,22 @@ class Admin extends Controller
*/
public
function
saveinfo
(
$params
=
[])
{
$ret
=
PluginsService
::
PluginsData
(
'wallet'
,
Service
::
$base_config_attachment_field
,
false
);
$ret
=
PluginsService
::
PluginsData
(
'wallet'
,
''
,
false
);
if
(
$ret
[
'code'
]
==
0
)
{
// 等级规则
$this
->
assign
(
'members_level_rules_list'
,
Service
::
$members_level_rules_list
);
// 是否
$is_whether_list
=
[
0
=>
array
(
'value'
=>
0
,
'name'
=>
'否'
,
'checked'
=>
true
),
1
=>
array
(
'value'
=>
1
,
'name'
=>
'是'
),
];
$this
->
assign
(
'is_whether_list'
,
$is_whether_list
);
// 充值赠送类型
$recharge_give_type_list
=
[
0
=>
array
(
'value'
=>
0
,
'name'
=>
'固定金额'
,
'checked'
=>
true
),
1
=>
array
(
'value'
=>
1
,
'name'
=>
'比例'
),
];
$this
->
assign
(
'recharge_give_type_list'
,
$recharge_give_type_list
);
$this
->
assign
(
'data'
,
$ret
[
'data'
]);
return
$this
->
fetch
(
'../../../plugins/view/wallet/admin/saveinfo'
);
...
...
@@ -79,8 +87,6 @@ class Admin extends Controller
*/
public
function
save
(
$params
=
[])
{
$level
=
Service
::
LevelDataList
();
$params
[
'level_list'
]
=
$level
[
'data'
];
return
PluginsService
::
PluginsDataSave
([
'plugins'
=>
'wallet'
,
'data'
=>
$params
]);
}
}
...
...
public/static/plugins/css/membershiplevel/admin/admin.css
浏览文件 @
7d95349a
...
...
@@ -16,9 +16,6 @@
.membershiplevel-content
.items
.immages-tag
img
{
max-width
:
100%
;
}
.membershiplevel-content
.edit-submit
{
margin-bottom
:
20px
;
}
/**
* iframe
...
...
public/static/plugins/css/wallet/admin/admin.css
浏览文件 @
7d95349a
/**
* 首页
*/
.wallet-content-base
.am-panel-bd
,
.wallet-content-base
.items
{
padding
:
10px
;
}
.wallet-content-base
.am-panel-bd
.am-gallery
{
padding
:
0
;
}
.wallet-content-base
.items
{
border
:
1px
dashed
#eee
;
}
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录