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
Email Patches
Plain Diff
Browse Files
Authored by
hf
9 years ago
Commit
c72d8f472d4f3229a933623814d121122a44a205
1 parent
0caeafc4
do add nginx config to preview
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
369 additions
and
4 deletions
script/nginx/conf/vhosts/nginx.pre.yohobuy.conf.conf
yohobuy/m.yohobuy.com/application/controllers/Home.php
yohobuy/m.yohobuy.com/application/modules/Passport/controllers/Login.php
script/nginx/conf/vhosts/nginx.pre.yohobuy.conf.conf
0 → 100644
View file @
c72d8f4
server
{
listen
80
;
server_name
m
.
yohobuy
.
com
*.
m
.
yohobuy
.
com
;
#access_log /Data/logs/access.buy.test.yoho.cn.log combined;
error_log
/
Data
/
logs
/
nginx
/
error
.
m
.
yohobuy
.
com
.
log
warn
;
root
/
Data
/
code
/
git
/
yohobuy
/
yohobuy
/
m
.
yohobuy
.
com
/
public
;
location
~* \.(
ico
|
woff
)$ {
expires
7
d
;
}
location
= /
crossdomain
.
xml
{
expires
7
d
;
}
location
= /
appembed
{
default_type
application
/
json
;
return
200
'{"code":200,"message":"appembed","data":{"open":"N","url":"http://m.yohobuy.com"}}'
;
}
location
= /
reg
.
html
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
signin
.
html
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
login
.
html
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
emailback
.
html
{
root
/
Data
/
code
/
git
/
yohobuy
/
yohobuy
/
assets
;
expires
7
d
;
}
location
= /
phoneback
.
html
{
root
/
Data
/
code
/
git
/
yohobuy
/
yohobuy
/
assets
;
expires
7
d
;
}
location
= /
error
.
html
{
root
/
Data
/
code
/
git
/
yohobuy
/
yohobuy
/
assets
;
expires
7
d
;
}
location
^~ /
passport
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= / {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
boys
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
girls
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
kids
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
lifestyle
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
girl
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
boys
/
bottomBanner
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
girls
/
bottomBanner
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
cate
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
brands
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
sale
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
brands
/
search
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
product
/
new
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
hotrank
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
newsale
/ {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
opt
/ {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
recom
/ {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
pro_
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
intro_
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
product
/
detail
/ {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
guang
/ {
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
tags
/
index
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
author
/
index
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
info
/
index
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
plustar
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
search
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
index
/
search
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
home
{
proxy_redirect
off
;
proxy_pass
http
://
yohobuy
;
proxy_set_header
Host
$
host
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
^~ /
home
/
message
{
proxy_redirect
off
;
proxy_pass
http
://
61
.
155
.
222
.
163
;
proxy_set_header
Host
m
.
yohobuy
.
com
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
home
/
orders
/
detail
{
proxy_redirect
off
;
proxy_pass
http
://
61
.
155
.
222
.
163
;
proxy_set_header
Host
m
.
yohobuy
.
com
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
= /
home
/
orders
/
cancel
{
proxy_redirect
off
;
proxy_pass
http
://
61
.
155
.
222
.
163
;
proxy_set_header
Host
m
.
yohobuy
.
com
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
location
/ {
proxy_redirect
off
;
proxy_pass
http
://
61
.
155
.
222
.
163
;
proxy_set_header
Host
m
.
yohobuy
.
com
;
proxy_set_header
X
-
Real
-
IP
$
remote_addr
;
proxy_set_header
X
-
Forwarded
-
For
$
proxy_add_x_forwarded_for
;
proxy_set_header
Accept
-
Encoding
"gzip"
;
}
}
server
{
listen
80
;
server_name
cdn
.
yoho
.
cn
;
#access_log /Data/logs/nginx/access.static.m.yohobuy.com.log combined;
#error_log /Data/logs/nginx/error.static.m.yohobuy.com.log warn;
root
/
Data
/
code
/
git
/
yohobuy
/
static
/
dist
;
location
/ {
log_not_found
off
;
access_log
off
;
expires
30
d
;
}
location
~* \.(
svg
|
eot
|
ttf
|
woff
|
otf
)$ {
add_header
Access
-
Control
-
Allow
-
Origin
*;
expires
30
d
;
}
}
...
...
yohobuy/m.yohobuy.com/application/controllers/Home.php
View file @
c72d8f4
...
...
@@ -137,7 +137,7 @@ class HomeController extends AbstractAction
if
(
$this
->
isAjax
())
{
$uid
=
$this
->
getUid
(
true
);
$page
=
$this
->
post
(
'page'
,
1
);
$gender
=
Helpers
::
getGenderByCookie
();
$gender
=
Helpers
::
getGenderByCookie
();
$result
=
UserModel
::
getFavBrandData
(
$uid
,
$gender
,
$page
,
10
);
}
...
...
@@ -636,13 +636,14 @@ class HomeController extends AbstractAction
* 我的订单页面,获得nav导航条焦点。并且异步请求订单详情列表页(getOrders)
*
*/
public
function
ordersAction
()
{
// 审判跳转登录页
$this
->
auditJumpLogin
();
$backUrl
=
Helpers
::
url
(
'/home'
);
$this
->
setTitle
(
'我的订单'
);
$this
->
setNavHeader
(
'我的订单'
,
$backUrl
);
...
...
@@ -773,6 +774,7 @@ class HomeController extends AbstractAction
/*
* 我的订单-付款跳转页
*/
public
function
payAction
()
{
// 审判跳转登录页
...
...
@@ -780,12 +782,12 @@ class HomeController extends AbstractAction
$this
->
setTitle
(
'支付中心'
);
$this
->
setNavHeader
(
'支付中心'
);
$orderCode
=
$this
->
get
(
'order_code'
);
if
(
empty
(
$orderCode
))
{
$this
->
error
();
}
$this
->
_view
->
display
(
'pay'
,
array
(
'payAppInfo'
=>
array
(
0
=>
array
(
...
...
yohobuy/m.yohobuy.com/application/modules/Passport/controllers/Login.php
View file @
c72d8f4
...
...
@@ -131,6 +131,7 @@ class LoginController extends AbstractAction
/* 调用登录接口进行登录 */
$data
=
LoginData
::
signin
(
$area
,
$profile
,
$password
);
if
(
$data
[
'code'
]
!=
200
||
!
isset
(
$data
[
'data'
][
'uid'
]))
{
$this
->
setSession
(
'_TOKEN'
,
Helpers
::
makeToken
(
$data
[
'data'
][
'uid'
]));
break
;
}
...
...
Please
register
or
login
to post a comment