Toggle navigation
Toggle navigation
This project
Loading...
Sign in
wangshusheng
/
YOHOBUYPC
·
Commits
Go to a project
GitLab
Go to dashboard
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
Plain Diff
Browse Files
Authored by
xiaowei
9 years ago
Commit
a6abc59db4685de9953b8fbd075d2014f456eb31
2 parents
8fa27c2e
4a6280a0
Merge branch 'develop' of
http://git.dev.yoho.cn/web/yohobuy
into develop
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
44 additions
and
37 deletions
static/js/shopping-cart/order-ensure.js
template/m.yohobuy.com/actions/index/home/i-help.phtml → template/m.yohobuy.com/actions/index/home/help.phtml
template/m.yohobuy.com/actions/index/home/index.phtml
yohobuy/m.yohobuy.com/application/controllers/Home.php
yohobuy/m.yohobuy.com/application/models/Index/User.php
static/js/shopping-cart/order-ensure.js
View file @
a6abc59
...
...
@@ -9,6 +9,7 @@ var $ = require('jquery'),
Hammer
=
require
(
'yoho.hammer'
),
Handlebars
=
require
(
'yoho.handlebars'
),
tip
=
require
(
'../plugin/tip'
),
loading
=
require
(
'../plugin/loading'
),
orderInfo
=
require
(
'./order-info'
).
orderInfo
;
var
dispatchModeHammer
,
...
...
@@ -94,6 +95,7 @@ function orderCompute() {
}
function
submitOrder
()
{
loading
.
showLoadingMask
();
$
.
ajax
({
method
:
'POST'
,
url
:
'/shoppingCart/orderSub'
,
...
...
@@ -114,6 +116,7 @@ function submitOrder() {
var
url
;
if
(
!
res
)
{
loading
.
hideLoadingMask
();
tip
.
show
(
'网络出错'
);
return
;
}
...
...
@@ -125,11 +128,14 @@ function submitOrder() {
}
else
{
url
=
'/home/pay?order_code='
+
res
.
data
.
order_code
;
}
window
.
setCookie
(
'order-info'
,
''
);
window
.
location
.
href
=
url
;
}
else
{
loading
.
hideLoadingMask
();
tip
.
show
(
res
.
messege
||
'网络出错'
);
}
}).
fail
(
function
()
{
loading
.
hideLoadingMask
();
tip
.
show
(
'网络出错'
);
});
}
...
...
template/m.yohobuy.com/actions/index/home/
i-
help.phtml → template/m.yohobuy.com/actions/index/home/help.phtml
View file @
a6abc59
template/m.yohobuy.com/actions/index/home/index.phtml
View file @
a6abc59
...
...
@@ -106,15 +106,13 @@
<span
class=
"iconfont num"
>
604
;</span>
</a>
</div>
{
{!
<div
class=
"group-list"
>
<a
class=
"list-item"
href=
"/h
elp.html
"
>
<a
class=
"list-item"
href=
"/h
ome/help
"
>
<span
class=
"iconfont icon"
>
639
;</span>
帮助
<span
class=
"iconfont num"
>
604
;</span>
</a>
</div>
}}
{
{>
product/recommend-for-you
}
}
{
{>
product/suspend-cart
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Home.php
View file @
a6abc59
...
...
@@ -835,46 +835,51 @@ class HomeController extends AbstractAction
// 审判跳转登录页
$this
->
auditJumpLogin
();
/* 判断订单号是否传 */
$orderCode
=
$this
->
get
(
'order_code'
);
if
(
empty
(
$orderCode
))
{
$this
->
error
();
}
/* 订单信息不存在 */
$orderDetail
=
OrderModel
::
orderDetail
(
$orderCode
,
$this
->
_uid
,
$this
->
_usession
);
if
(
empty
(
$orderDetail
))
{
$this
->
error
();
}
$this
->
setTitle
(
'订单详情'
);
$this
->
setNavHeader
(
'订单详情'
);
$this
->
_view
->
display
(
'order-detail'
,
array
(
'orderDetailPage'
=>
true
,
'orderDetail'
=>
OrderModel
::
orderDetail
(
$orderCode
,
$this
->
_uid
,
$this
->
_usession
)
,
'orderDetail'
=>
$orderDetail
,
));
}
/**
* 帮助中心列表页
*/
/**
* 帮助中心列表页
*/
public
function
helpAction
()
{
$service
=
Home\HelpModel
::
serviceInfo
();
{
$this
->
setTitle
(
'帮助中心'
);
$this
->
setNavHeader
(
'帮助中心'
);
$data
=
array
(
'iHelp'
=>
$service
,
);
$this
->
_view
->
display
(
'i-help'
,
$data
);
}
$this
->
_view
->
display
(
'help'
,
array
(
'iHelp'
=>
Home\HelpModel
::
serviceInfo
(),
));
}
/**
* 帮助中心列表详细信息
*/
public
function
helpDetailAction
()
public
function
helpDetailAction
()
{
$caption
=
$this
->
get
(
'caption'
,
'帮助中心'
);
$code
=
$this
->
get
(
'code'
,
0
);
if
(
empty
(
$code
))
{
$this
->
error
();
}
$this
->
setTitle
(
$caption
);
$this
->
setNavHeader
(
$caption
);
...
...
@@ -883,27 +888,24 @@ class HomeController extends AbstractAction
));
}
/**
/**
* YOHO币详情 新版
*/
public
function
currencyDetailAction
()
{
// 审判跳转登录页
$this
->
auditJumpLogin
();
$this
->
setTitle
(
'YOHO币'
);
$this
->
setNavHeader
(
'YOHO币'
,
true
,
false
);
$data
[
'money'
]
=
'0'
;
$page
=
$this
->
post
(
'page'
,
1
);
$size
=
$this
->
post
(
'size'
,
20
);
// $data = UserModel::getYohoCoinLists($this->_uid,$page,$size);
$data
=
UserModel
::
getYohoCoinLists
(
3965746
,
$page
,
$size
);
$data
=
UserModel
::
getYohoCoinLists
(
$this
->
_uid
,
0
,
20
);
$this
->
_view
->
display
(
'currency-detail'
,
array
(
'money'
=>
$data
[
'money'
],
'pageFooter'
=>
true
,
'currencyDetail'
=>
true
,
'currencyDetailPage'
=>
true
));
}
/**
...
...
@@ -911,18 +913,18 @@ class HomeController extends AbstractAction
*/
public
function
ajaxCurrencyDetailAction
()
{
$data
[
'list'
]
=
array
();
$data
[
'money'
]
=
0
;
$page
=
$this
->
post
(
'page'
,
1
);
$size
=
$this
->
post
(
'size'
,
20
);
$data
=
UserModel
::
getYohoCoinLists
(
$this
->
_uid
,
$page
,
$size
);
//$data = UserModel::getYohoCoinLists(3965746,$page,$size);
$this
->
_view
->
display
(
'ajax-currency-detail'
,
array
(
'currency'
=>
$data
[
'list'
],
'pageFooter'
=>
true
,
'currencyDetailPage'
=>
true
));
if
(
$this
->
isAjax
())
{
$uid
=
$this
->
getUid
();
$page
=
$this
->
post
(
'page'
,
1
);
$data
=
UserModel
::
getYohoCoinLists
(
$uid
,
$page
,
20
);
$this
->
_view
->
display
(
'ajax-currency-detail'
,
array
(
'currency'
=>
$data
[
'list'
],
'pageFooter'
=>
true
,
'currencyDetailPage'
=>
true
));
}
else
{
echo
' '
;
}
}
}
...
...
yohobuy/m.yohobuy.com/application/models/Index/User.php
View file @
a6abc59
...
...
@@ -379,7 +379,7 @@ class UserModel
public
static
function
getYohoCoinLists
(
$uid
,
$page
,
$limit
)
{
$result
=
array
();
$data
[
'money'
]
=
'0'
;
// 调用接口获取YOHO币
$yohoCoin
=
UserData
::
yohoCoinData
(
$uid
,
$page
,
$limit
,
'post'
);
// 处理YOHO币数据
...
...
@@ -396,6 +396,7 @@ class UserModel
}
}
$data
[
'list'
]
=
$result
;
return
$data
;
}
...
...
Please
register
or
login
to post a comment