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
毕凯
9 years ago
Commit
f3ce62dc52212121ee74cffb54258e5e3578dc21
2 parents
41e2ae08
4a6fd933
增加地址选择 默认值
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
6 deletions
framework
static/js/shopping-cart/order-ensure.js
static/js/shopping-cart/order-info.js
template/m.yohobuy.com/actions/index/shoppingCart/order-ensure.phtml
yohobuy/m.yohobuy.com/application/controllers/ShoppingCart.php
framework
@
75bbc3b0
Subproject commit
e9d066dd88a8e7e37103021c427a205a5cfcdcec
Subproject commit
75bbc3b075de19f239532f60c5995d06c5f814e2
...
...
static/js/shopping-cart/order-ensure.js
View file @
f3ce62d
...
...
@@ -98,8 +98,8 @@ function submitOrder() {
data
:
{
addressId
:
orderInfo
(
'addressId'
),
cartType
:
orderInfo
(
'cartType'
),
deliveryId
:
orderInfo
(
'deliveryId'
),
deliveryTimeId
:
orderInfo
(
'deliveryTimeId'
),
deliveryId
:
orderInfo
(
'deliveryId'
)
||
1
,
deliveryTimeId
:
orderInfo
(
'deliveryTimeId'
)
||
1
,
invoiceText
:
orderInfo
(
'invoiceText'
),
invoiceType
:
orderInfo
(
'invoiceType'
),
msg
:
orderInfo
(
'msg'
),
...
...
@@ -109,13 +109,24 @@ function submitOrder() {
yohoCoin
:
orderInfo
(
'yohoCoin'
)
}
}).
then
(
function
(
res
)
{
console
.
log
(
res
);
if
(
!
res
)
{
tip
.
show
(
'网络出错'
);
}
if
(
res
.
code
!==
200
)
{
tip
.
show
(
res
.
message
||
'网络出错'
);
}
else
{
console
.
log
(
1
);
}
}).
fail
(
function
()
{
tip
.
show
(
'网络出错'
);
});
}
// 界面点击,状态存 cookie
if
(
!
orderInfo
(
'addressId'
))
{
orderInfo
(
'addressId'
,
$
(
'.address-wrap'
).
data
(
'address-id'
));
}
$
(
'.dispatch-mode'
).
on
(
'touchend'
,
'li'
,
function
()
{
orderInfo
(
'deliveryId'
,
$
(
this
).
data
(
'id'
));
orderCompute
();
...
...
static/js/shopping-cart/order-info.js
View file @
f3ce62d
...
...
@@ -22,6 +22,7 @@ try {
invoiceType
:
null
,
msg
:
null
};
window
.
setCookie
(
'order-info'
,
JSON
.
stringify
(
info
));
}
exports
.
orderInfo
=
function
(
key
,
value
)
{
...
...
template/m.yohobuy.com/actions/index/shoppingCart/order-ensure.phtml
View file @
f3ce62d
{
{>
layout/header
}
}
<div
class=
"order-ensure-page yoho-page"
>
{
{#
orderEnsure
}
}
<a
class=
"address-wrap block"
href=
"/shoppingCart/selectAddress"
>
<a
class=
"address-wrap block"
href=
"/shoppingCart/selectAddress"
data-address-id=
"{{addressId}}"
>
<p
class=
"infos"
>
收货地址
<span
class=
"per-info"
>
{
{name
}
}
{
{phoneNum
}
}</span>
...
...
yohobuy/m.yohobuy.com/application/controllers/ShoppingCart.php
View file @
f3ce62d
...
...
@@ -195,7 +195,7 @@ class ShoppingCartController extends AbstractAction
'orderEnsurePage'
=>
true
,
'orderEnsure'
=>
CartModel
::
cartPay
(
$uid
,
$cartType
,
$cookieData
)
);
// var_dump($data);
$this
->
_view
->
display
(
'order-ensure'
,
$data
);
}
...
...
Please
register
or
login
to post a comment