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
7ae37291
Commit
7ae37291
authored
Apr 01, 2017
by
2breakegg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
i18n + 修改账户信息 无密码长度约束
parent
871ea484
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
203 additions
and
190 deletions
+203
-190
.idea/workspace.xml
.idea/workspace.xml
+171
-164
i18n.json
i18n.json
+1
-2
src/components/EmailForm.js
src/components/EmailForm.js
+1
-1
src/components/PasswordForm.js
src/components/PasswordForm.js
+4
-4
src/components/SendEmail.js
src/components/SendEmail.js
+2
-2
src/components/UserNameForm.js
src/components/UserNameForm.js
+4
-4
src/index.js
src/index.js
+3
-6
src/routes/Reset.js
src/routes/Reset.js
+17
-7
No files found.
.idea/workspace.xml
View file @
7ae37291
...
...
@@ -8,13 +8,8 @@
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/components/PasswordForm.js"
afterPath=
"$PROJECT_DIR$/src/components/PasswordForm.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/components/SendEmail.js"
afterPath=
"$PROJECT_DIR$/src/components/SendEmail.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/components/UserNameForm.js"
afterPath=
"$PROJECT_DIR$/src/components/UserNameForm.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/config.js"
afterPath=
"$PROJECT_DIR$/src/config.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/index.js"
afterPath=
"$PROJECT_DIR$/src/index.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Activate.js"
afterPath=
"$PROJECT_DIR$/src/routes/Activate.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Forgot.js"
afterPath=
"$PROJECT_DIR$/src/routes/Forgot.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Login.js"
afterPath=
"$PROJECT_DIR$/src/routes/Login.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Profiles.js"
afterPath=
"$PROJECT_DIR$/src/routes/Profiles.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Register.js"
afterPath=
"$PROJECT_DIR$/src/routes/Register.js"
/>
<change
type=
"MODIFICATION"
beforePath=
"$PROJECT_DIR$/src/routes/Reset.js"
afterPath=
"$PROJECT_DIR$/src/routes/Reset.js"
/>
</list>
<ignored
path=
"$PROJECT_DIR$/.tmp/"
/>
<ignored
path=
"$PROJECT_DIR$/temp/"
/>
...
...
@@ -34,8 +29,8 @@
<file
leaf-file-name=
"i18n.json"
pinned=
"false"
current-in-tab=
"true"
>
<entry
file=
"file://$PROJECT_DIR$/i18n.json"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"7
10
"
>
<caret
line=
"1
57"
column=
"56"
lean-forward=
"false"
selection-start-line=
"157"
selection-start-column=
"5"
selection-end-line=
"157"
selection-end-column=
"56
"
/>
<state
relative-caret-position=
"7
22
"
>
<caret
line=
"1
22"
column=
"5"
lean-forward=
"true"
selection-start-line=
"122"
selection-start-column=
"5"
selection-end-line=
"122"
selection-end-column=
"30
"
/>
<folding
/>
</state>
</provider>
...
...
@@ -49,23 +44,23 @@
<component
name=
"ExecutionTargetManager"
SELECTED_TARGET=
"default_target"
/>
<component
name=
"FileEditorManager"
>
<leaf
SIDE_TABS_SIZE_LIMIT_KEY=
"300"
>
<file
leaf-file-name=
"
Login
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/routes/
Login
.js"
>
<file
leaf-file-name=
"
Reset
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/routes/
Reset
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
1
71"
>
<caret
line=
"
33"
column=
"35"
lean-forward=
"true"
selection-start-line=
"33"
selection-start-column=
"35"
selection-end-line=
"33"
selection-end-column=
"35
"
/>
<state
relative-caret-position=
"
-2
71"
>
<caret
line=
"
62"
column=
"18"
lean-forward=
"true"
selection-start-line=
"62"
selection-start-column=
"18"
selection-end-line=
"62"
selection-end-column=
"18
"
/>
<folding>
<element
signature=
"e#0#6
5
#0"
expanded=
"true"
/>
<element
signature=
"e#0#6
3
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
SendEmail
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/components/
SendEmail
.js"
>
<file
leaf-file-name=
"
EmailForm
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/components/
EmailForm
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
712
"
>
<caret
line=
"
39"
column=
"48"
lean-forward=
"true"
selection-start-line=
"39"
selection-start-column=
"48"
selection-end-line=
"39"
selection-end-column=
"48
"
/>
<state
relative-caret-position=
"
594
"
>
<caret
line=
"
84"
column=
"30"
lean-forward=
"false"
selection-start-line=
"84"
selection-start-column=
"30"
selection-end-line=
"84"
selection-end-column=
"30
"
/>
<folding>
<element
signature=
"e#0#41#0"
expanded=
"true"
/>
</folding>
...
...
@@ -73,11 +68,11 @@
</provider>
</entry>
</file>
<file
leaf-file-name=
"UserNameForm.js"
pinned=
"false"
current-in-tab=
"
fals
e"
>
<file
leaf-file-name=
"UserNameForm.js"
pinned=
"false"
current-in-tab=
"
tru
e"
>
<entry
file=
"file://$PROJECT_DIR$/src/components/UserNameForm.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
30
4"
>
<caret
line=
"
34"
column=
"81"
lean-forward=
"true"
selection-start-line=
"34"
selection-start-column=
"81"
selection-end-line=
"34"
selection-end-column=
"81
"
/>
<state
relative-caret-position=
"
49
4"
>
<caret
line=
"
62"
column=
"16"
lean-forward=
"true"
selection-start-line=
"62"
selection-start-column=
"16"
selection-end-line=
"62"
selection-end-column=
"16
"
/>
<folding>
<element
signature=
"e#0#35#0"
expanded=
"true"
/>
</folding>
...
...
@@ -85,72 +80,66 @@
</provider>
</entry>
</file>
<file
leaf-file-name=
"
Reset.js"
pinned=
"false"
current-in-tab=
"tru
e"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Reset
.js"
>
<file
leaf-file-name=
"
PasswordForm.js"
pinned=
"false"
current-in-tab=
"fals
e"
>
<entry
file=
"file://$PROJECT_DIR$/src/
components/PasswordForm
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
1558
"
>
<caret
line=
"
82"
column=
"16"
lean-forward=
"false"
selection-start-line=
"82"
selection-start-column=
"12"
selection-end-line=
"82"
selection-end-column=
"16
"
/>
<state
relative-caret-position=
"
304
"
>
<caret
line=
"
16"
column=
"41"
lean-forward=
"true"
selection-start-line=
"16"
selection-start-column=
"41"
selection-end-line=
"16"
selection-end-column=
"41
"
/>
<folding>
<element
signature=
"e#0#
63
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
41
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
EmailForm
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
components/EmailForm
.js"
>
<file
leaf-file-name=
"
auth
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/auth
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
328
"
>
<caret
line=
"
64"
column=
"100"
lean-forward=
"false"
selection-start-line=
"64"
selection-start-column=
"100"
selection-end-line=
"64"
selection-end-column=
"100
"
/>
<state
relative-caret-position=
"
-3643
"
>
<caret
line=
"
13"
column=
"29"
lean-forward=
"false"
selection-start-line=
"13"
selection-start-column=
"29"
selection-end-line=
"13"
selection-end-column=
"29
"
/>
<folding>
<
element
signature=
"e#0#41#0"
expanded=
"true
"
/>
<
marker
date=
"1491013796228"
expanded=
"true"
signature=
"5524:5531"
ph=
"{...}
"
/>
</folding>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
Activate
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Activate
.js"
>
<file
leaf-file-name=
"
common
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/common
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"133"
>
<caret
line=
"7"
column=
"23"
lean-forward=
"true"
selection-start-line=
"7"
selection-start-column=
"23"
selection-end-line=
"7"
selection-end-column=
"23"
/>
<folding>
<element
signature=
"e#0#30#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
<folding
/>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
Profiles
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Profiles
.js"
>
<file
leaf-file-name=
"
example
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/example
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
95
"
>
<caret
line=
"
5"
column=
"54"
lean-forward=
"true"
selection-start-line=
"5"
selection-start-column=
"54"
selection-end-line=
"5"
selection-end-column=
"54
"
/>
<state
relative-caret-position=
"
0
"
>
<caret
line=
"
0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0
"
/>
<folding
/>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
PasswordForm
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
components/PasswordForm
.js"
>
<file
leaf-file-name=
"
haha
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/haha
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"157"
>
<caret
line=
"87"
column=
"100"
lean-forward=
"false"
selection-start-line=
"87"
selection-start-column=
"100"
selection-end-line=
"87"
selection-end-column=
"100"
/>
<folding>
<element
signature=
"e#0#41#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"190"
>
<caret
line=
"10"
column=
"6"
lean-forward=
"true"
selection-start-line=
"10"
selection-start-column=
"6"
selection-end-line=
"10"
selection-end-column=
"6"
/>
<folding
/>
</state>
</provider>
</entry>
</file>
<file
leaf-file-name=
"
Verify
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Verify
.js"
>
<file
leaf-file-name=
"
user
.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/user
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"95"
>
<caret
line=
"5"
column=
"27"
lean-forward=
"true"
selection-start-line=
"5"
selection-start-column=
"27"
selection-end-line=
"5"
selection-end-column=
"27"
/>
<folding>
<element
signature=
"e#0#26#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"-1178"
>
<caret
line=
"21"
column=
"6"
lean-forward=
"true"
selection-start-line=
"21"
selection-start-column=
"6"
selection-end-line=
"21"
selection-end-column=
"6"
/>
<folding
/>
</state>
</provider>
</entry>
...
...
@@ -158,8 +147,8 @@
<file
leaf-file-name=
"Register.js"
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/src/routes/Register.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
418
"
>
<caret
line=
"
22"
column=
"17"
lean-forward=
"true"
selection-start-line=
"22"
selection-start-column=
"17"
selection-end-line=
"22
"
selection-end-column=
"17"
/>
<state
relative-caret-position=
"
242
"
>
<caret
line=
"
38"
column=
"17"
lean-forward=
"true"
selection-start-line=
"38"
selection-start-column=
"17"
selection-end-line=
"38
"
selection-end-column=
"17"
/>
<folding>
<element
signature=
"e#0#70#0"
expanded=
"true"
/>
</folding>
...
...
@@ -171,14 +160,6 @@
</component>
<component
name=
"FindInProjectRecents"
>
<findStrings>
<find>
re
</find>
<find>
profiles
</find>
<find>
intl
</find>
<find>
user
</find>
<find>
提交
</find>
<find>
language
</find>
<find>
save
</find>
<find>
Format
</find>
<find>
new
</find>
<find>
old
</find>
<find>
not found
</find>
...
...
@@ -200,7 +181,15 @@
<find>
label
</find>
<find>
messages
</find>
<find>
密码必须为8
</find>
<find>
profiles
</find>
<find>
sub
</find>
<find>
密码至少为8
</find>
<find>
context
</find>
<find>
locale
</find>
<find>
again
</find>
<find>
Incorrect
</find>
<find>
password
</find>
<find>
passwordProps
</find>
</findStrings>
<replaceStrings>
<replace>
"
,
</replace>
...
...
@@ -218,19 +207,19 @@
<option
value=
"$PROJECT_DIR$/.eslintrc"
/>
<option
value=
"$PROJECT_DIR$/src/models/auth.js"
/>
<option
value=
"$PROJECT_DIR$/src/services/auth.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Reset.js"
/>
<option
value=
"$PROJECT_DIR$/src/index.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Login.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Forgot.js"
/>
<option
value=
"$PROJECT_DIR$/src/config.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Profiles.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Activate.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Register.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Profiles.js"
/>
<option
value=
"$PROJECT_DIR$/src/components/SendEmail.js"
/>
<option
value=
"$PROJECT_DIR$/src/index.js"
/>
<option
value=
"$PROJECT_DIR$/i18n.json"
/>
<option
value=
"$PROJECT_DIR$/src/components/UserNameForm.js"
/>
<option
value=
"$PROJECT_DIR$/src/components/EmailForm.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Reset.js"
/>
<option
value=
"$PROJECT_DIR$/src/components/PasswordForm.js"
/>
<option
value=
"$PROJECT_DIR$/src/routes/Register.js"
/>
<option
value=
"$PROJECT_DIR$/src/components/EmailForm.js"
/>
<option
value=
"$PROJECT_DIR$/src/components/UserNameForm.js"
/>
</list>
</option>
</component>
...
...
@@ -512,7 +501,7 @@
<workItem
from=
"1490847126780"
duration=
"9606000"
/>
<workItem
from=
"1490864807162"
duration=
"4566000"
/>
<workItem
from=
"1490926971269"
duration=
"431000"
/>
<workItem
from=
"1491013749160"
duration=
"
12810
000"
/>
<workItem
from=
"1491013749160"
duration=
"
20485
000"
/>
</task>
<task
id=
"LOCAL-00001"
summary=
"i18n"
>
<created>
1490948057319
</created>
...
...
@@ -535,11 +524,18 @@
<option
name=
"project"
value=
"LOCAL"
/>
<updated>
1490954495731
</updated>
</task>
<option
name=
"localTasksCounter"
value=
"4"
/>
<task
id=
"LOCAL-00004"
summary=
"i18n"
>
<created>
1491026796456
</created>
<option
name=
"number"
value=
"00004"
/>
<option
name=
"presentableId"
value=
"LOCAL-00004"
/>
<option
name=
"project"
value=
"LOCAL"
/>
<updated>
1491026796456
</updated>
</task>
<option
name=
"localTasksCounter"
value=
"5"
/>
<servers
/>
</component>
<component
name=
"TimeTrackingManager"
>
<option
name=
"totallyTimeSpent"
value=
"
49625
000"
/>
<option
name=
"totallyTimeSpent"
value=
"
57300
000"
/>
</component>
<component
name=
"TodoView"
selected-index=
"3"
>
<todo-panel
id=
"selected-file"
>
...
...
@@ -558,7 +554,7 @@
<window_info
id=
"Event Log"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.32917467"
sideWeight=
"0.5021075"
order=
"7"
side_tool=
"true"
content_ui=
"tabs"
/>
<window_info
id=
"Find"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.33"
sideWeight=
"0.5"
order=
"1"
side_tool=
"false"
content_ui=
"tabs"
/>
<window_info
id=
"Run"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.32917467"
sideWeight=
"0.49789253"
order=
"2"
side_tool=
"false"
content_ui=
"tabs"
/>
<window_info
id=
"Version Control"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"
fals
e"
show_stripe_button=
"true"
weight=
"0.32917467"
sideWeight=
"0.49789253"
order=
"7"
side_tool=
"false"
content_ui=
"tabs"
/>
<window_info
id=
"Version Control"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"
tru
e"
show_stripe_button=
"true"
weight=
"0.32917467"
sideWeight=
"0.49789253"
order=
"7"
side_tool=
"false"
content_ui=
"tabs"
/>
<window_info
id=
"npm"
active=
"false"
anchor=
"left"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.25237092"
sideWeight=
"0.50500715"
order=
"2"
side_tool=
"true"
content_ui=
"tabs"
/>
<window_info
id=
"Structure"
active=
"false"
anchor=
"left"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.25"
sideWeight=
"0.5"
order=
"1"
side_tool=
"false"
content_ui=
"tabs"
/>
<window_info
id=
"Terminal"
active=
"false"
anchor=
"bottom"
auto_hide=
"false"
internal_type=
"DOCKED"
type=
"DOCKED"
visible=
"false"
show_stripe_button=
"true"
weight=
"0.26679462"
sideWeight=
"0.49367756"
order=
"7"
side_tool=
"false"
content_ui=
"tabs"
/>
...
...
@@ -586,7 +582,14 @@
</component>
<component
name=
"XDebuggerManager"
>
<breakpoint-manager>
<option
name=
"time"
value=
"2"
/>
<breakpoints>
<line-breakpoint
enabled=
"true"
type=
"javascript"
>
<url>
file://$PROJECT_DIR$/src/index.js
</url>
<properties
/>
<option
name=
"timeStamp"
value=
"2"
/>
</line-breakpoint>
</breakpoints>
<option
name=
"time"
value=
"3"
/>
</breakpoint-manager>
<watches-manager
/>
</component>
...
...
@@ -615,6 +618,7 @@
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
<folding
/>
</state>
</provider>
</entry>
...
...
@@ -622,9 +626,7 @@
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"475"
>
<caret
line=
"25"
column=
"28"
lean-forward=
"false"
selection-start-line=
"25"
selection-start-column=
"28"
selection-end-line=
"25"
selection-end-column=
"28"
/>
<folding>
<element
signature=
"e#0#65#0"
expanded=
"true"
/>
</folding>
<folding
/>
</state>
</provider>
</entry>
...
...
@@ -632,7 +634,9 @@
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"1881"
>
<caret
line=
"105"
column=
"11"
lean-forward=
"false"
selection-start-line=
"105"
selection-start-column=
"11"
selection-end-line=
"105"
selection-end-column=
"11"
/>
<folding
/>
<folding>
<element
signature=
"e#0#61#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
...
...
@@ -700,27 +704,6 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/user.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"-32"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/common.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/haha.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"190"
>
<caret
line=
"10"
column=
"7"
lean-forward=
"false"
selection-start-line=
"10"
selection-start-column=
"7"
selection-end-line=
"10"
selection-end-column=
"7"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/components/PasswordForm.css"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
...
...
@@ -732,13 +715,7 @@
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"247"
>
<caret
line=
"13"
column=
"0"
lean-forward=
"false"
selection-start-line=
"13"
selection-start-column=
"0"
selection-end-line=
"13"
selection-end-column=
"0"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/example.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
<folding
/>
</state>
</provider>
</entry>
...
...
@@ -845,16 +822,6 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/index.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"190"
>
<caret
line=
"10"
column=
"0"
lean-forward=
"true"
selection-start-line=
"10"
selection-start-column=
"0"
selection-end-line=
"10"
selection-end-column=
"0"
/>
<folding>
<element
signature=
"e#0#31#0"
expanded=
"false"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/components/SubmitButton.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
...
...
@@ -865,16 +832,6 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/auth.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"-3211"
>
<caret
line=
"13"
column=
"29"
lean-forward=
"false"
selection-start-line=
"13"
selection-start-column=
"29"
selection-end-line=
"13"
selection-end-column=
"29"
/>
<folding>
<marker
date=
"1491013796228"
expanded=
"true"
signature=
"5524:5531"
ph=
"{...}"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/services/auth.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"120"
>
...
...
@@ -914,103 +871,153 @@
<state
relative-caret-position=
"95"
>
<caret
line=
"5"
column=
"27"
lean-forward=
"true"
selection-start-line=
"5"
selection-start-column=
"27"
selection-end-line=
"5"
selection-end-column=
"27"
/>
<folding>
<element
signature=
"e#0#26#0"
expanded=
"
tru
e"
/>
<element
signature=
"e#0#26#0"
expanded=
"
fals
e"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/routes/
Login
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/routes/
Activate
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"1
71
"
>
<caret
line=
"
33"
column=
"35"
lean-forward=
"true"
selection-start-line=
"33"
selection-start-column=
"35"
selection-end-line=
"33"
selection-end-column=
"35
"
/>
<state
relative-caret-position=
"1
33
"
>
<caret
line=
"
7"
column=
"23"
lean-forward=
"true"
selection-start-line=
"7"
selection-start-column=
"23"
selection-end-line=
"7"
selection-end-column=
"23
"
/>
<folding>
<element
signature=
"e#0#
65
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
30
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
components/SendEmail
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Profiles
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
712
"
>
<caret
line=
"39"
column=
"
48"
lean-forward=
"true"
selection-start-line=
"39"
selection-start-column=
"48"
selection-end-line=
"39"
selection-end-column=
"48
"
/>
<state
relative-caret-position=
"
498
"
>
<caret
line=
"39"
column=
"
12"
lean-forward=
"false"
selection-start-line=
"39"
selection-start-column=
"12"
selection-end-line=
"39"
selection-end-column=
"12
"
/>
<folding>
<element
signature=
"e#0#
4
1#0"
expanded=
"true"
/>
<element
signature=
"e#0#
6
1#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
components/UserNameForm
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Login
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"304"
>
<caret
line=
"34"
column=
"81"
lean-forward=
"true"
selection-start-line=
"34"
selection-start-column=
"81"
selection-end-line=
"34"
selection-end-column=
"81"
/>
<state
relative-caret-position=
"76"
>
<caret
line=
"4"
column=
"0"
lean-forward=
"false"
selection-start-line=
"4"
selection-start-column=
"0"
selection-end-line=
"4"
selection-end-column=
"56"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/index.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"133"
>
<caret
line=
"7"
column=
"33"
lean-forward=
"false"
selection-start-line=
"7"
selection-start-column=
"27"
selection-end-line=
"7"
selection-end-column=
"33"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/components/SendEmail.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"342"
>
<caret
line=
"39"
column=
"0"
lean-forward=
"false"
selection-start-line=
"39"
selection-start-column=
"0"
selection-end-line=
"39"
selection-end-column=
"48"
/>
<folding>
<element
signature=
"e#0#
35
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
41
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
components/EmailForm
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Register
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
328
"
>
<caret
line=
"
64"
column=
"100"
lean-forward=
"false"
selection-start-line=
"64"
selection-start-column=
"100"
selection-end-line=
"64"
selection-end-column=
"100
"
/>
<state
relative-caret-position=
"
242
"
>
<caret
line=
"
38"
column=
"17"
lean-forward=
"true"
selection-start-line=
"38"
selection-start-column=
"17"
selection-end-line=
"38"
selection-end-column=
"17
"
/>
<folding>
<element
signature=
"e#0#
41
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
70
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Activate
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/auth
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
13
3"
>
<caret
line=
"
7"
column=
"23"
lean-forward=
"true"
selection-start-line=
"7"
selection-start-column=
"23"
selection-end-line=
"7"
selection-end-column=
"23
"
/>
<state
relative-caret-position=
"
-364
3"
>
<caret
line=
"
13"
column=
"29"
lean-forward=
"false"
selection-start-line=
"13"
selection-start-column=
"29"
selection-end-line=
"13"
selection-end-column=
"29
"
/>
<folding>
<
element
signature=
"e#0#30#0"
expanded=
"true
"
/>
<
marker
date=
"1491013796228"
expanded=
"true"
signature=
"5524:5531"
ph=
"{...}
"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Profiles
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
models/common
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"95"
>
<caret
line=
"5"
column=
"54"
lean-forward=
"true"
selection-start-line=
"5"
selection-start-column=
"54"
selection-end-line=
"5"
selection-end-column=
"54"
/>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/example.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"0"
>
<caret
line=
"0"
column=
"0"
lean-forward=
"false"
selection-start-line=
"0"
selection-start-column=
"0"
selection-end-line=
"0"
selection-end-column=
"0"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/haha.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"190"
>
<caret
line=
"10"
column=
"6"
lean-forward=
"true"
selection-start-line=
"10"
selection-start-column=
"6"
selection-end-line=
"10"
selection-end-column=
"6"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/models/user.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"-1178"
>
<caret
line=
"21"
column=
"6"
lean-forward=
"true"
selection-start-line=
"21"
selection-start-column=
"6"
selection-end-line=
"21"
selection-end-column=
"6"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/i18n.json"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"7
10
"
>
<caret
line=
"1
57"
column=
"56"
lean-forward=
"false"
selection-start-line=
"157"
selection-start-column=
"5"
selection-end-line=
"157"
selection-end-column=
"56
"
/>
<state
relative-caret-position=
"7
22
"
>
<caret
line=
"1
22"
column=
"5"
lean-forward=
"true"
selection-start-line=
"122"
selection-start-column=
"5"
selection-end-line=
"122"
selection-end-column=
"30
"
/>
<folding
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/routes/Reset.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"-271"
>
<caret
line=
"62"
column=
"18"
lean-forward=
"true"
selection-start-line=
"62"
selection-start-column=
"18"
selection-end-line=
"62"
selection-end-column=
"18"
/>
<folding>
<element
signature=
"e#0#63#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/components/PasswordForm.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
157
"
>
<caret
line=
"
87"
column=
"100"
lean-forward=
"false"
selection-start-line=
"87"
selection-start-column=
"100"
selection-end-line=
"87"
selection-end-column=
"100
"
/>
<state
relative-caret-position=
"
304
"
>
<caret
line=
"
16"
column=
"41"
lean-forward=
"true"
selection-start-line=
"16"
selection-start-column=
"41"
selection-end-line=
"16"
selection-end-column=
"41
"
/>
<folding>
<element
signature=
"e#0#41#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Register
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
components/EmailForm
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
418
"
>
<caret
line=
"
22"
column=
"17"
lean-forward=
"true"
selection-start-line=
"22"
selection-start-column=
"17"
selection-end-line=
"22"
selection-end-column=
"17
"
/>
<state
relative-caret-position=
"
594
"
>
<caret
line=
"
84"
column=
"30"
lean-forward=
"false"
selection-start-line=
"84"
selection-start-column=
"30"
selection-end-line=
"84"
selection-end-column=
"30
"
/>
<folding>
<element
signature=
"e#0#
70
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
41
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/src/
routes/Reset
.js"
>
<entry
file=
"file://$PROJECT_DIR$/src/
components/UserNameForm
.js"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
1558
"
>
<caret
line=
"
82"
column=
"16"
lean-forward=
"false"
selection-start-line=
"82"
selection-start-column=
"12"
selection-end-line=
"8
2"
selection-end-column=
"16"
/>
<state
relative-caret-position=
"
494
"
>
<caret
line=
"
62"
column=
"16"
lean-forward=
"true"
selection-start-line=
"62"
selection-start-column=
"16"
selection-end-line=
"6
2"
selection-end-column=
"16"
/>
<folding>
<element
signature=
"e#0#
63
#0"
expanded=
"true"
/>
<element
signature=
"e#0#
35
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
...
...
i18n.json
View file @
7ae37291
...
...
@@ -48,7 +48,6 @@
"You can use this E-mail address."
:
"You can use this E-mail address."
,
"This user name has been token."
:
"This user name has been token."
,
"You can use this user name."
:
"You can use this user name."
,
"Password is not correct."
:
"Password is not correct."
,
"User does not exisit."
:
"User does not exisit."
,
"Incorrect password."
:
"Incorrect password."
,
"Please check your registration info again."
:
"Please check your registration info again."
,
...
...
@@ -128,7 +127,6 @@
"You can use this E-mail address."
:
"邮箱可以使用"
,
"This user name has been token."
:
"该用户名已被注册"
,
"You can use this user name."
:
"用户名可以使用"
,
"Password is not correct."
:
"密码不一致"
,
"User does not exisit."
:
"用户不存在"
,
"Incorrect password."
:
"密码不正确"
,
"Please check your registration info again."
:
"请填写正确的注册信息。"
,
...
...
@@ -156,6 +154,7 @@
"old-password"
:
"原密码"
,
"new-password"
:
"新密码"
,
"Password length must be between 8 and 24 characters"
:
"密码必须为8-24位"
,
"Please confirm your password"
:
""
,
"密码至少为8-24位"
:
"密码至少为8-24位"
,
...
...
src/components/EmailForm.js
View file @
7ae37291
...
...
@@ -82,7 +82,7 @@ class EmailForm extends React.Component {
<
/FormItem
>
<
FormItem
{...
passwordProps
.
fromItem
}
>
{
getFieldDecorator
(
`password`
,
{...
passwordProps
.
decorator
}
)(
{
getFieldDecorator
(
'
password
'
)(
<
Input
{...
passwordProps
.
input
}
/
>
)}
<
/FormItem
>
...
...
src/components/PasswordForm.js
View file @
7ae37291
...
...
@@ -66,7 +66,7 @@ class EmailForm extends React.Component {
rules
:
[
{
required
:
true
,
message
:
messages
[
'
Password length must be between 8 and 24 characters
'
],
pattern
:
/^.
{8,24}
$/
},
{
validator
:
this
.
checkConfirm
}
]
]
,
},
input
:
{
placeholder
:
messages
[
'
old-password
'
],
...
...
@@ -87,7 +87,7 @@ class EmailForm extends React.Component {
rules
:
[
{
required
:
true
,
message
:
messages
[
'
Password length must be between 8 and 24 characters
'
],
pattern
:
/^.
{8,24}
$/
},
{
validator
:
this
.
checkPassword
}
]
]
,
},
input
:
{
placeholder
:
messages
[
'
password-again
'
],
...
...
@@ -98,13 +98,13 @@ class EmailForm extends React.Component {
return
(
<
Form
onSubmit
=
{
this
.
onSubmit
}
>
<
FormItem
{...
passwordProps
.
fromItem
}
label
=
{
messages
[
'
old-password
'
]}
>
{
getFieldDecorator
(
`password`
,
{...
passwordProps
.
decorator
}
)(
{
getFieldDecorator
(
'
password
'
)(
<
Input
{...
passwordProps
.
input
}
/
>
)}
<
/FormItem
>
<
FormItem
{...
passwordProps
.
fromItem
}
label
=
{
messages
[
'
new-password
'
]}
>
{
getFieldDecorator
(
`new_password`
,
{...
passwordProps
.
decorator
})(
{
getFieldDecorator
(
'
new_password
'
,
{...
passwordProps
.
decorator
})(
<
Input
{...
passwordProps
.
input2
}
/
>
)}
<
/FormItem
>
...
...
src/components/SendEmail.js
View file @
7ae37291
import
React
,
{
PropTypes
}
from
'
react
'
;
import
styles
from
'
./EmailForm.css
'
;
import
{
connect
}
from
'
react-redux
'
import
{
Form
,
Input
,
Icon
,
Button
,
Modal
}
from
'
antd
'
import
{
Form
,
Input
,
Icon
,
Button
,
Modal
}
from
'
antd
'
;
const
FormItem
=
Form
.
Item
;
import
SubmitButton
from
'
./SubmitButton
'
import
SubmitButton
from
'
./SubmitButton
'
;
const
formItemLayout
=
{
labelCol
:
{
span
:
4
},
...
...
src/components/UserNameForm.js
View file @
7ae37291
...
...
@@ -2,8 +2,8 @@ import { Form, Input } from 'antd';
import
React
,
{
PropTypes
}
from
'
react
'
;
import
{
connect
}
from
'
react-redux
'
;
import
SubmitButton
from
'
./SubmitButton
'
;
const
FormItem
=
Form
.
Item
;
const
FormItem
=
Form
.
Item
;
const
formItemLayout
=
{
labelCol
:
{
span
:
4
},
wrapperCol
:
{
span
:
15
},
...
...
@@ -35,7 +35,7 @@ class EmailForm extends React.Component {
const
{
form
,
dispatch
,
data
,
checkUsername
,
isUserNameExists
}
=
this
.
props
;
const
{
getFieldDecorator
}
=
form
;
const
{
id
,
username
}
=
data
;
const
{
intl
:
{
messages
}
}
=
this
.
context
;
const
{
intl
:
{
messages
}
}
=
this
.
context
;
const
usernameProps
=
{
fromItem
:
{
...
...
@@ -73,13 +73,13 @@ class EmailForm extends React.Component {
return
(
<
Form
onSubmit
=
{
this
.
onSubmit
}
>
<
FormItem
{...
usernameProps
.
fromItem
}
>
{
getFieldDecorator
(
`username`
,
{
...
usernameProps
.
decorator
})(
{
getFieldDecorator
(
'
username
'
,
{
...
usernameProps
.
decorator
})(
<
Input
{...
usernameProps
.
input
}
/>
,
)}
<
/FormItem
>
<
FormItem
{...
passwordProps
.
fromItem
}
>
{
getFieldDecorator
(
`password`
,
{
...
passwordProps
.
decorator
}
)(
{
getFieldDecorator
(
'
password
'
)(
<
Input
{...
passwordProps
.
input
}
/>
,
)}
<
/FormItem
>
...
...
src/index.js
View file @
7ae37291
...
...
@@ -49,12 +49,11 @@ app.router(require('./router'));
addLocaleData
([...
en
,
...
zh
]);
/*eslint-disable */
let
language
=
navigator
.
language
||
(
navigator
.
languages
&&
navigator
.
languages
[
0
])
||
navigator
.
userLanguage
;
let
language
=
localStorage
.
getItem
(
'
locale
'
)
||
navigator
.
language
||
(
navigator
.
languages
&&
navigator
.
languages
[
0
])
||
navigator
.
userLanguage
;
/*eslint-enable */
if
(
localStorage
.
getItem
(
'
locale
'
)){
language
=
localStorage
.
getItem
(
'
locale
'
);
}
const
languageWithoutRegionCode
=
language
.
toLowerCase
().
split
(
/
[
_-
]
+/
)[
0
];
language
=
(
localeData
[
languageWithoutRegionCode
]
||
localeData
[
language
])
?
language
:
'
zh-CN
'
;
const
messages
=
localeData
[
languageWithoutRegionCode
]
||
localeData
[
language
]
||
localeData
.
zh
;
const
App
=
app
.
start
();
...
...
@@ -65,5 +64,3 @@ ReactDOM.render(
document
.
getElementById
(
'
root
'
),
);
console
.
log
(
language
);
src/routes/Reset.js
View file @
7ae37291
import
{
Button
,
Form
,
Icon
,
Input
,
Select
,
Spin
}
from
'
antd
'
;
import
{
connect
}
from
'
dva
'
;
import
React
,
{
PropTypes
}
from
'
react
'
;
import
{
FormattedMessage
as
Format
}
from
'
react-intl
'
;
import
React
from
'
react
'
;
const
FormItem
=
Form
.
Item
;
const
Option
=
Select
.
Option
;
class
Reset
extends
React
.
Component
{
static
contextTypes
=
{
intl
:
PropTypes
.
object
.
isRequired
,
};
onSubmitReset
=
(
e
)
=>
{
const
{
form
,
dispatch
,
location
:
{
query
:
{
key
,
user_id
}
}
}
=
this
.
props
;
...
...
@@ -43,35 +48,40 @@ class Reset extends React.Component {
render
()
{
const
{
getFieldDecorator
}
=
this
.
props
.
form
;
const
{
isResetSubmit
=
false
}
=
this
.
props
;
const
{
intl
:
{
messages
}
}
=
this
.
context
;
return
(
<
div
style
=
{{
display
:
'
flex
'
,
justifyContent
:
'
center
'
,
alignItems
:
'
center
'
,
height
:
'
100%
'
}}
>
<
Spin
spinning
=
{
isResetSubmit
}
delay
=
{
100
}
>
<
Form
onSubmit
=
{
this
.
onSubmitReset
}
className
=
"
login-form
"
>
<
FormItem
>
<
h1
><
Format
id
=
'
reset-password
'
/><
/h1
>
<
/FormItem
>
<
FormItem
>
{
getFieldDecorator
(
'
password
'
,
{
rules
:
[{
required
:
true
,
message
:
'
Please input your Password!
'
}],
rules
:
[{
required
:
true
,
message
:
messages
[
'
Password can not be blank
'
]
}],
},
{
validator
:
this
.
checkConfirm
,
})(
<
Input
prefix
=
{
<
Icon
type
=
"
lock
"
style
=
{{
fontSize
:
13
}}
/>} type="password" placeholder="Password"/
>
,
<
Input
prefix
=
{
<
Icon
type
=
"
lock
"
style
=
{{
fontSize
:
13
}}
/>} type="password
"
placeholder
=
{
messages
.
password
}
/>
,
)}
<
/FormItem
>
<
FormItem
>
{
getFieldDecorator
(
'
confirm
'
,
{
rules
:
[{
required
:
true
,
message
:
'
Please confirm your password!
'
,
required
:
true
,
message
:
messages
[
'
Incorrect password.2
'
]
,
},
{
validator
:
this
.
checkPassword
,
}],
})(
<
Input
type
=
"
password
"
onBlur
=
{
this
.
handleConfirmBlur
}
placeholder
=
"
Password Again
"
/>
,
<
Input
type
=
"
password
"
onBlur
=
{
this
.
handleConfirmBlur
}
placeholder
=
{
messages
[
'
password-again
'
]}
/>
,
)}
<
/FormItem
>
<
Button
type
=
"
primary
"
htmlType
=
"
submit
"
className
=
"
login-form-button
"
>
Submit
<
Format
id
=
'
reset-password
'
/>
<
/Button
>
<
/Form
>
<
/Spin
>
...
...
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