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
Rock Zhang
9 years ago
Commit
e102eea8c17abe7819b27c8109ca246cf666c6c2
1 parent
abae4c47
修复app中分享有关
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
14 deletions
library/Action/HuodongAction.php
yohobuy/huodong.m.yohobuy.com/application/modules/Cuxiao/controllers/Yuanxiao.php
library/Action/HuodongAction.php
View file @
e102eea
...
...
@@ -67,7 +67,7 @@ class HuodongAction extends Controller_Abstract
}
// 判断是否是应用访问, 拼接APP需要的URL参数
$this
->
_isApp
=
(
null
!==
$this
->
get
(
'app_version'
)
||
null
!==
$this
->
get
(
'uid'
)
);
$this
->
_isApp
=
(
null
!==
$this
->
get
(
'app_version'
));
}
/**
...
...
yohobuy/huodong.m.yohobuy.com/application/modules/Cuxiao/controllers/Yuanxiao.php
View file @
e102eea
...
...
@@ -34,12 +34,12 @@ class YuanxiaoController extends HuodongAction
$playUrlEncode
=
strtr
(
$playUrl
,
array
(
'/'
=>
'\\/'
));
$this
->
_view
->
display
(
'index'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'staticFile'
=>
self
::
STATIC_FILE
,
'staticJS'
=>
array
(
'home.js'
),
'shareDesc'
=>
'元宵快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareDesc'
=>
'元宵
节
快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareImg'
=>
'http://img02.yohoboys.com/staticimg/2016/02/19/16/02dbd38c84eccf1097b7e240452f0de856.png'
,
'shareUrl'
=>
Helpers
::
url
(
'/cuxiao/yuanxiao/index'
),
'playUrl'
=>
$this
->
isApp
()
?
$playUrl
.
'?openby:yohobuy={"action":"go.weblogin","params":{"jumpurl":{"url":"'
.
$playUrlEncode
.
'","param":{"from":"app"}},"requesturl":{"url":"","param":{}},"priority":"N"}}'
:
$playUrl
,
...
...
@@ -72,6 +72,7 @@ class YuanxiaoController extends HuodongAction
// 调用接口
$result
=
YuanxiaoModel
::
getChouqianInfo
(
$uid
,
$nickName
,
$FormatBirthday
,
$gender
);
if
(
$result
[
'code'
]
===
200
)
{
// 处理成功就跳转到等待页
// 将返回的结果存入cookeie中15分钟
$cookieData
=
array
(
...
...
@@ -79,10 +80,14 @@ class YuanxiaoController extends HuodongAction
'type'
=>
$result
[
'data'
][
'randomCode'
]
);
$this
->
setCookie
(
'yuanxiaochouqian'
,
json_encode
(
$cookieData
),
time
()
+
15
*
60
);
$this
->
go
(
Helpers
::
url
(
'/cuxiao/yuanxiao/wait'
));
$waitUrl
=
Helpers
::
url
(
'/cuxiao/yuanxiao/wait'
);
$this
->
go
(
$this
->
_isApp
?
$waitUrl
.
'?openby:yohobuy={"action":"go.h5","params":{"islogin":"N"}}'
:
$waitUrl
);
}
else
{
// 不成功就显示返回的错误信息
$this
->
_view
->
display
(
'info'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'staticFile'
=>
self
::
STATIC_FILE
,
'staticJS'
=>
array
(
'info.js'
...
...
@@ -101,12 +106,12 @@ class YuanxiaoController extends HuodongAction
$userData
=
YuanxiaoModel
::
getUserProfileData
(
$uid
);
$this
->
_view
->
display
(
'info'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'staticFile'
=>
self
::
STATIC_FILE
,
'staticJS'
=>
array
(
'info.js'
),
'shareDesc'
=>
'元宵快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareDesc'
=>
'元宵
节
快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareImg'
=>
'http://img02.yohoboys.com/staticimg/2016/02/19/16/02dbd38c84eccf1097b7e240452f0de856.png'
,
'shareUrl'
=>
Helpers
::
url
(
'/cuxiao/yuanxiao/index'
),
'birthday'
=>
date_format
(
date_create
(
$userData
[
'birthday'
]),
'Y年m月d日'
),
...
...
@@ -124,15 +129,16 @@ class YuanxiaoController extends HuodongAction
{
// 审判跳转登录页
// $this->auditJumpLogin();
$activityUrl
=
Helpers
::
url
(
'/cuxiao/yuanxiao/result'
);
$this
->
_view
->
display
(
'wait'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'staticFile'
=>
self
::
STATIC_FILE
,
'activityUrl'
=>
Helpers
::
url
(
'/cuxiao/yuanxiao/result'
)
,
'activityUrl'
=>
$this
->
_isApp
?
$activityUrl
.
'?openby:yohobuy={"action":"go.h5","params":{"islogin":"N","share":"'
.
$activityUrl
.
'", shareparam:":{"share_id":"1"}}}'
:
$activityUrl
,
'staticJS'
=>
array
(
'wait.js'
),
'shareDesc'
=>
'元宵快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareDesc'
=>
'元宵
节
快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareImg'
=>
'http://img02.yohoboys.com/staticimg/2016/02/19/16/02dbd38c84eccf1097b7e240452f0de856.png'
,
'shareUrl'
=>
Helpers
::
url
(
'/cuxiao/yuanxiao/index'
),
));
...
...
@@ -159,12 +165,12 @@ class YuanxiaoController extends HuodongAction
));
$this
->
_view
->
display
(
'result'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'needShare'
=>
$this
->
checkNeedShare
(),
// 是否需要微信分享
'staticFile'
=>
self
::
STATIC_FILE
,
'result'
=>
$result
,
'shareTitle'
=>
$result
[
'name'
]
.
'的2016年潮流运势是'
.
$this
->
getChouqianTitle
(
$result
[
'type'
]),
'shareDesc'
=>
'元宵快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareDesc'
=>
'元宵
节
快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareImg'
=>
'http://img02.yohoboys.com/staticimg/2016/02/19/16/02dbd38c84eccf1097b7e240452f0de856.png'
,
'shareUrl'
=>
$shareUrl
,
'staticJS'
=>
array
(
...
...
@@ -190,7 +196,7 @@ class YuanxiaoController extends HuodongAction
$result
=
YuanxiaoModel
::
getChoujiangShareInfo
(
$uid
);
$this
->
_view
->
display
(
'share'
,
array
(
'staticTitle'
=>
'2016潮流运势测试
!
'
,
'staticTitle'
=>
'2016潮流运势测试'
,
'staticFile'
=>
self
::
STATIC_FILE
,
'result'
=>
array
(
'name'
=>
$result
[
'name'
],
...
...
@@ -200,7 +206,7 @@ class YuanxiaoController extends HuodongAction
'staticJS'
=>
array
(
'share.js'
),
'shareDesc'
=>
'元宵快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareDesc'
=>
'元宵
节
快乐!一起来YOHO!BUY有货玩2016年潮流开运测试!'
,
'shareImg'
=>
'http://img02.yohoboys.com/staticimg/2016/02/19/16/02dbd38c84eccf1097b7e240452f0de856.png'
));
}
...
...
Please
register
or
login
to post a comment