Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yoho-blk
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
1
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
王水玲
8 years ago
Commit
f294d514052843cdea7075c8a4d95429605adf5d
1 parent
c2311a39
登录接口改成加密登录接口
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
6 deletions
apps/passport/controllers/reg.js
apps/passport/models/aes-pwd.js
apps/passport/models/login-api.js
apps/product/views/action/shop-index.hbs
apps/passport/controllers/reg.js
View file @
f294d51
...
...
@@ -78,7 +78,8 @@ let index = (req, res) => {
t
:
Date
.
now
()
}),
itemUrl
:
helpers
.
urlFormat
(
'/help/detail'
,
{
id
:
25
id
:
103
,
contId
:
239
}),
referUrl
:
refer
,
loginUrl
:
helpers
.
urlFormat
(
'/passport/login'
,
{
...
...
apps/passport/models/aes-pwd.js
0 → 100644
View file @
f294d51
/**
* 登录注册密码加密,uid加密
* @author: wsl<shuiling.wang@yoho.cn>
* @date: 2016/07/07
*/
'use strict'
;
const
crypto
=
global
.
yoho
.
crypto
;
/**
* 密码加密
**/
const
aesPwd
=
(
pwd
)
=>
{
return
crypto
.
encryption
(
'yoho9646yoho9646'
,
pwd
);
};
module
.
exports
=
{
aesPwd
};
...
...
apps/passport/models/login-api.js
View file @
f294d51
...
...
@@ -3,18 +3,18 @@
*/
'use strict'
;
const
aes
=
require
(
'./aes-pwd'
);
const
api
=
global
.
yoho
.
API
;
/**
* 手机或邮箱登录
* 手机或邮箱登录
app.passport.signin => app.passport.signinAES 加密
*/
const
signinAsync
=
(
area
,
profile
,
password
,
shoppingKey
)
=>
{
let
param
=
{
method
:
'app.passport.signin'
,
method
:
'app.passport.signin
AES
'
,
area
:
area
,
profile
:
profile
,
password
:
password
password
:
aes
.
aesPwd
(
password
)
};
if
(
shoppingKey
)
{
...
...
apps/product/views/action/shop-index.hbs
View file @
f294d51
...
...
@@ -31,7 +31,6 @@
{{/if}}
{{#if
newProducts
}}
{{
log
newProducts
}}
<div
class=
"center-content clearfix new-arrival-warp"
>
<div
class=
"floor-header clearfix"
>
<h2
class=
"floor-title en-size"
>
NEW ARRIVALS
</h2>
...
...
Please
register
or
login
to post a comment