Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
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
ccbikai
9 years ago
Commit
2ee204b9f13641fee25949570384b1cfa557fd29
1 parent
61852eea
修改频道 cookie作用域
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
8 deletions
apps/channel/controllers/index.js
public/js/channel/home.js
apps/channel/controllers/index.js
View file @
2ee204b
...
...
@@ -34,6 +34,10 @@ let _renderData = {
* @return {[type]}
*/
let
_channelPage
=
(
req
,
res
,
data
)
=>
{
res
.
cookie
(
'_Channel'
,
data
.
gender
,
{
maxAge
:
2592000
,
domain
:
'yohobuy.com'
});
return
channelModel
.
getChannelData
({
// TODO 内部的Promise方法必须 return 出来
gender
:
data
.
gender
,
uid
:
_
.
toString
(
req
.
user
.
uid
)
...
...
public/js/channel/home.js
View file @
2ee204b
...
...
@@ -203,12 +203,4 @@ $('.home-header .iconfont').on('touchstart', function() {
// 底部留出tab 的高度
window
.
reMarginFooter
(
'.footer-tab'
);
// set cookie
exports
.
set
=
function
(
c
)
{
window
.
setCookie
(
'_Channel'
,
c
,
{
expires
:
365
,
domain
:
'.yohobuy.com'
});
};
require
(
'./maybe-like'
)();
...
...
Please
register
or
login
to post a comment