Fakultas Ilmu Komputer UI
Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
PMPL
Class Project
Kape
Commits
f64c9891
Commit
f64c9891
authored
Mar 28, 2017
by
M. Reza Qorib
Browse files
[#140654507] #12 #13 fix typo on Server component name
parent
4a3f519a
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
.tmp/mocha-webpack/455fffbb3125fc1ebc427c559e4e5438/455fffbb3125fc1ebc427c559e4e5438-output.js
View file @
f64c9891
This diff is collapsed.
Click to expand it.
assets/js/components/LoginForm.jsx
View file @
f64c9891
import
React
from
'
react
'
;
import
{
Form
,
Input
,
Button
,
Message
,
Image
}
from
'
semantic-ui-react
'
;
import
{
browserHistory
}
from
'
react-router
'
;
import
Server
from
'
../lib/
s
erver
'
;
import
Server
from
'
../lib/
S
erver
'
;
export
default
class
LoginForm
extends
React
.
Component
{
...
...
@@ -35,8 +35,8 @@ export default class LoginForm extends React.Component {
const
data
=
{
type
:
this
.
props
.
type
,
email
:
this
.
state
.
email
,
password
:
this
.
state
.
password
}
password
:
this
.
state
.
password
,
}
;
Server
.
post
(
'
api/login/
'
,
data
).
then
(()
=>
{
browserHistory
.
push
(
'
/home
'
);
},
()
=>
{
...
...
@@ -46,21 +46,21 @@ export default class LoginForm extends React.Component {
render
=
()
=>
(
<
div
className
=
"formLogin"
>
<
Form
onSubmit
=
{
(
e
)
=>
this
.
handleSubmit
(
e
)
}
error
=
{
this
.
state
.
errorFlag
}
>
<
Form
onSubmit
=
{
e
=>
this
.
handleSubmit
(
e
)
}
error
=
{
this
.
state
.
errorFlag
}
>
<
div
className
=
"formHeader"
>
<
Image
src
=
{
`./assets/img/
${
this
.
props
.
imgSrc
}
`
}
size
=
{
this
.
props
.
imgSize
}
verticalAlign
=
"middle"
/>
<
span
>
{
this
.
props
.
header
}
</
span
>
</
div
>
<
Form
.
Group
widths
=
"equal"
>
<
Form
.
Field
required
>
<
label
htmlFor
=
"id"
>
Email
</
label
>
<
Input
type
=
"text"
id
=
"email"
icon
=
"user"
iconPosition
=
"left"
placeholder
=
"email"
onChange
=
{
(
e
)
=>
this
.
handleChange
(
e
,
'
email
'
)
}
required
/>
<
Input
type
=
"text"
id
=
"email"
icon
=
"user"
iconPosition
=
"left"
placeholder
=
"email"
onChange
=
{
e
=>
this
.
handleChange
(
e
,
'
email
'
)
}
required
/>
</
Form
.
Field
>
</
Form
.
Group
>
<
Form
.
Group
widths
=
"equal"
>
<
Form
.
Field
required
>
<
label
htmlFor
=
"password"
>
Password
</
label
>
<
Input
type
=
"password"
id
=
"password"
icon
=
"key"
iconPosition
=
"left"
placeholder
=
"password"
onChange
=
{
(
e
)
=>
this
.
handleChange
(
e
,
'
password
'
)
}
required
/>
<
Input
type
=
"password"
id
=
"password"
icon
=
"key"
iconPosition
=
"left"
placeholder
=
"password"
onChange
=
{
e
=>
this
.
handleChange
(
e
,
'
password
'
)
}
required
/>
</
Form
.
Field
>
</
Form
.
Group
>
...
...
assets/js/components/TopMenu.jsx
View file @
f64c9891
import
React
from
'
react
'
;
import
{
Menu
,
Image
}
from
'
semantic-ui-react
'
;
import
{
Link
}
from
'
react-router
'
;
import
Server
from
'
.
/.
./lib/
s
erver
'
;
import
Server
from
'
../lib/
S
erver
'
;
export
default
class
TopMenu
extends
React
.
Component
{
state
=
{
activeItem
:
'
home
'
};
...
...
assets/js/lib/
s
erver.jsx
→
assets/js/lib/
S
erver.jsx
100755 → 100644
View file @
f64c9891
File moved
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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