Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
M
Moecube Accounts Web
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
MyCard
Moecube Accounts Web
Commits
e56e1de8
Commit
e56e1de8
authored
Apr 06, 2017
by
神楽坂玲奈
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
travis
parent
db292f14
Changes
9
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
448 additions
and
256 deletions
+448
-256
.idea/workspace.xml
.idea/workspace.xml
+401
-232
.travis.yml
.travis.yml
+22
-0
src/models/user.js
src/models/user.js
+5
-7
src/routes/Activate.js
src/routes/Activate.js
+1
-1
src/routes/Forgot.js
src/routes/Forgot.js
+1
-1
src/routes/Profiles.js
src/routes/Profiles.js
+12
-10
src/routes/Register.js
src/routes/Register.js
+3
-3
src/routes/Reset.js
src/routes/Reset.js
+1
-1
src/routes/Verify.js
src/routes/Verify.js
+2
-1
No files found.
.idea/workspace.xml
View file @
e56e1de8
This diff is collapsed.
Click to expand it.
.travis.yml
0 → 100644
View file @
e56e1de8
language
:
node_js
node_js
:
node
#sudo: false
#dist: trusty
env
:
global
:
secure
:
pL8y9VeZcluWZ1DmYg1wt7N9A6BV98lBuP9jWSnBr98vra2e/Ivcr40CxIXbIVC5DAgoIPpLl9FzoHmm2rudG+6HBxzOAaXNCO7U2HtmDP0o7n4eXUu6PUseRs88R/h6QhiTTxwwVnv8H5OyvsR5wsqzs0c8WKwTf5+Gxq3rHFam7dccY7UMGNRAu565veT/uhBnEXrI5vqb3DEs6hPv0YJZIOWsV109s5E/j9sbGZOaDx4XJAe1kGWKI98A2K5mvmm61yKyb2V14F+NDoICgKBgnLNYsCuaNR+88iOAAvblb/ZbPj49cfim2rMnE8W3wjm8cgzThrw+d+Q982zq9pq9AO4pdP+Od1xKe+c0eU57DZ2KUEwfQm9rc4OENYHfUU8Vr35dJ4nJCOzYOIuJCIJVsfLcZejSpSUCEodp8WypaJbiZa8QAlhmDyhtK2WaGwOAsy6qGBT3M5+Om2sNcckvsQXYpCdGLSNvlZ30KpiNrrVYn7reJzk+FEN5gHh1PajgMuXo88ix3g56ZTE4s8S1KoZ2PghZlIUmhEiUuxkWjC++E9ha9tEmE/7JdVPhzgpx6iWRKGB20VB4MZGays+u/CqX4PEkJ4DhvKu5oC8aaaoUfEG3uA7hdRQPb8zDAwf3usB55n4UrAFnvLd4MZjtZJnWPjXoP1WHOWiUBfE=
script
:
npm run build
before_deploy
:
-
curl --location --retry 5 --output ossutil 'https://github.com/mycard/ossutil/releases/download/1.0.0.Beta2/ossutil'
-
chmod +x ossutil
-
./ossutil config --endpoint oss-cn-hangzhou.aliyuncs.com --access-key-id $ALIYUN_ID --access-key-secret $ALIYUN_SECRET
deploy
:
provider
:
script
script
:
./ossutil cp -rf dist oss://mycard/accounts
skip_cleanup
:
true
on
:
branch
:
master
src/models/user.js
View file @
e56e1de8
...
...
@@ -204,19 +204,17 @@ export default {
const
token
=
localStorage
.
getItem
(
'
token
'
);
if
(
token
)
{
dispatch
({
type
:
'
getAuthUser
'
,
payload
:
{
token
}
});
}
else
{
if
(
location
.
pathname
==
'
/profiles
'
)
{
dispatch
(
routerRedux
.
replace
(
'
/signin
'
))
}
}
else
if
(
location
.
pathname
===
'
/profiles
'
)
{
dispatch
(
routerRedux
.
replace
(
'
/signin
'
));
}
history
.
listen
(({
pathname
,
query
})
=>
{
if
(
pathname
===
'
/
'
)
{
dispatch
({
type
:
'
preLogin
'
,
payload
:
{
token
}
});
}
if
(
pathname
===
'
/reset
'
||
pathname
==
"
/activate
"
)
{
if
(
!
query
[
"
key
"
]
)
{
message
.
error
(
"
缺少参数
"
)
if
(
pathname
===
'
/reset
'
||
pathname
==
=
'
/activate
'
)
{
if
(
!
query
.
key
)
{
message
.
error
(
'
缺少参数
'
);
}
}
});
...
...
src/routes/Activate.js
View file @
e56e1de8
...
...
@@ -14,7 +14,7 @@ class Active extends React.Component {
render
()
{
const
{
loading
}
=
this
.
props
;
return
(
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
Button
type
=
"
primary
"
icon
=
"
poweroff
"
loading
=
{
loading
}
onClick
=
{
this
.
handleClick
}
>
<
Format
id
=
{
'
verify-email
'
}
/
>
<
/Button
>
...
...
src/routes/Forgot.js
View file @
e56e1de8
...
...
@@ -35,7 +35,7 @@ class Login extends React.Component {
const
{
loading
}
=
this
.
props
;
const
{
intl
:
{
messages
}
}
=
this
.
context
;
return
(
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
Spin
spinning
=
{
loading
}
delay
=
{
100
}
>
<
Form
onSubmit
=
{
this
.
onSubmitLogin
}
className
=
"
login-form
"
>
...
...
src/routes/Profiles.js
View file @
e56e1de8
...
...
@@ -101,29 +101,31 @@ class Profiles extends React.Component {
<
Form
onSubmit
=
{
this
.
onUpdateSubmit
}
>
<
FormItem
style
=
{{
display
:
'
flex
'
,
justifyContent
:
'
center
'
}}
>
<
div
style
=
{{
display
:
isUpload
?
'
flex
'
:
'
none
'
,
flexDirection
:
'
column
'
}}
>
<
div
style
=
{{
display
:
isUpload
?
'
flex
'
:
'
none
'
,
flexDirection
:
'
column
'
}}
>
<
Cropper
ref
=
{
cropper
=>
{
ref
=
{
(
cropper
)
=>
{
this
.
cropper
=
cropper
;
}}
src
=
{
imageUrl
||
defaultAvatar
}
src
=
{
imageUrl
||
defaultAvatar
}
style
=
{{
height
:
'
20vw
'
,
width
:
'
20vw
'
}}
aspectRatio
=
{
1
/
1
}
guides
=
{
true
}
guides
/>
<
Button
type
=
"
primary
"
onClick
=
{
this
.
handleUpload
}
>
<
Icon
type
=
"
upload
"
/>
upload
<
/Button
>
<
/div
>
<
div
style
=
{{
display
:
!
isUpload
?
'
flex
'
:
'
none
'
,
flexDirection
:
'
column
'
}}
>
<
img
src
=
{
avatar
||
imageUrl
||
defaultAvatar
}
/
>
<
Button
onClick
=
{()
=>
{
dispatch
({
type
:
'
upload/start
'
})
}}
>
<
div
style
=
{{
display
:
!
isUpload
?
'
flex
'
:
'
none
'
,
flexDirection
:
'
column
'
}}
>
<
img
alt
=
"
avatar
"
src
=
{
avatar
||
imageUrl
||
defaultAvatar
}
/
>
<
Button
onClick
=
{()
=>
{
dispatch
({
type
:
'
upload/start
'
})
;
}}
>
<
label
>
<
Icon
type
=
"
plus
"
/>
Change
Avatar
<
input
type
=
"
file
"
onChange
=
{
this
.
onGetFile
}
ref
=
{
file
=>
{
this
.
file
=
file
;
}}
style
=
{{
display
:
'
none
'
}}
/
>
<
input
type
=
"
file
"
onChange
=
{
this
.
onGetFile
}
ref
=
{(
file
)
=>
{
this
.
file
=
file
;
}}
style
=
{{
display
:
'
none
'
}}
/
>
<
/label
>
<
/Button
>
<
/div
>
...
...
src/routes/Register.js
View file @
e56e1de8
...
...
@@ -60,12 +60,12 @@ class Register extends React.Component {
const
emailProps
=
{
hasFeedback
:
true
,
validateStatus
:
checkEmail
,
extra
:
isEmailExists
?
messages
[
'
i_email_exists
'
]
:
''
,
extra
:
isEmailExists
?
messages
.
i_email_exists
:
''
,
};
const
emailInputProps
=
{
onBlur
:
()
=>
!
form
.
getFieldError
(
"
email
"
)
&&
dispatch
({
type
:
'
auth/checkEmail
'
,
payload
:
{
...
form
.
getFieldsValue
()
}
}),
onBlur
:
()
=>
!
form
.
getFieldError
(
'
email
'
)
&&
dispatch
({
type
:
'
auth/checkEmail
'
,
payload
:
{
...
form
.
getFieldsValue
()
}
}),
placeholder
:
messages
.
email
,
};
...
...
@@ -76,7 +76,7 @@ class Register extends React.Component {
};
const
usernameInputProps
=
{
onBlur
:
()
=>
!
form
.
getFieldError
(
"
username
"
)
&&
dispatch
({
type
:
'
auth/checkUsername
'
,
payload
:
{
...
form
.
getFieldsValue
()
}
}),
onBlur
:
()
=>
!
form
.
getFieldError
(
'
username
'
)
&&
dispatch
({
type
:
'
auth/checkUsername
'
,
payload
:
{
...
form
.
getFieldsValue
()
}
}),
placeholder
:
messages
.
username
,
};
...
...
src/routes/Reset.js
View file @
e56e1de8
...
...
@@ -51,7 +51,7 @@ class Reset extends React.Component {
const
{
intl
:
{
messages
}
}
=
this
.
context
;
return
(
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
Spin
spinning
=
{
isResetSubmit
}
delay
=
{
100
}
>
<
Form
onSubmit
=
{
this
.
onSubmitReset
}
className
=
"
login-form
"
>
<
FormItem
>
...
...
src/routes/Verify.js
View file @
e56e1de8
...
...
@@ -69,7 +69,8 @@ class Verify extends React.Component {
return
(
<
div
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
style
=
{{
display
:
'
flex
'
,
flex
:
1
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
Spin
spinning
=
{
loading
}
delay
=
{
100
}
>
<
Steps
size
=
"
large
"
current
=
{
1
}
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment