Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
YOHOBUYWAP
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
郭成尧
9 years ago
Commit
d738677d352330d1560818b1057bf7f231e89e33
1 parent
ccc90e92
前端列表接口数据格式
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
16 deletions
library/Plugin/DataProcess/CouponFloorProcess.php
template/m.yohobuy.com/actions/index/coupon/test.phtml
library/Plugin/DataProcess/CouponFloorProcess.php
View file @
d738677
...
...
@@ -69,11 +69,26 @@ class CouponFloorProcess
* @return array
* @internal param $type
*/
private
static
function
getCoupon
(
&
$data
)
private
static
function
getCoupon
(
$data
)
{
if
(
empty
(
$data
))
{
return
array
();
}
foreach
(
$data
[
'list'
]
as
&
$item
)
{
switch
(
$item
[
'status'
])
{
case
1
:
$item
[
'isGet'
]
=
true
;
break
;
case
2
:
$item
[
'isZero'
]
=
true
;
break
;
case
3
:
$item
[
'isGeted'
]
=
true
;
break
;
default
:
break
;
}
}
$data
[
'isCoupon'
]
=
true
;
return
$data
;
}
...
...
template/m.yohobuy.com/actions/index/coupon/test.phtml
View file @
d738677
{
{>
layout/header
}
}
{
{#
floor
}
}
{
{#if
isCoupon
}
}
{
{#
list
}
}
<div>
{
{status
}
}</div>
{
{#tarIf
status
1
}
}
<div>isCoupon</div>
{
{/
tarIf
}
}
{
{/
list
}
}
{
{/if
}
}
{
{#if
isCarouselBanner
}
}
{
{#
list
}
}
<div>isCarouselBanner</div>
{
{/
list
}
}
{
{/if
}
}
{
{/
floor
}
}
{
{#
floor
}
}
{
{#if
isCoupon
}
}
{
{#
list
}
}
{
{#if
isGet
}
}
<div>
{
{status
}
}</div>
{
{/if
}
}
{
{#if
isZero
}
}
<div>
{
{status
}
}</div>
{
{/if
}
}
{
{#if
isGeted
}
}
<div>
{
{status
}
}</div>
{
{/if
}
}
{
{/list
}
}
{
{/if
}
}
{
{#if
isCarouselBanner
}
}
{
{#
list
}
}
<div>isCarouselBanner</div>
{
{/list
}
}
{
{/if
}
}
{
{/
floor
}
}
{
{>
layout/footer
}
}
\ No newline at end of file
...
...
Please
register
or
login
to post a comment