Fakultas Ilmu Komputer UI
Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
ppl-fasilkom-ui
2021
Kelas D
Justika - Pengembangan Platform untuk UMKM
Justika UMKM Legal - Frontend
Commits
03306d27
Commit
03306d27
authored
Apr 26, 2021
by
Shafiya Adzhani
Browse files
[CHORES] fix stepper in page 3
parent
dc5cb75b
Pipeline
#73243
passed with stages
in 13 minutes and 29 seconds
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/components/Dropdown/EmployeeDropdown.js
View file @
03306d27
...
...
@@ -5,7 +5,6 @@ import {dataEmployee} from '../../data/employee'
import
PropTypes
from
'
prop-types
'
const
EmployeeDropdown
=
({
setEmployeeData
,
defaultValue
,
dataTestId
})
=>
{
console
.
log
(
defaultValue
)
const
[
selectedValue
,
setSelectedValue
]
=
useState
(
defaultValue
)
const
[
showDropdown
,
setShowDropdown
]
=
useState
(
false
)
...
...
src/components/FormIUMK/FormIUMK3.js
View file @
03306d27
import
React
from
'
react
'
import
PropTypes
from
'
prop-types
'
const
FormIUMK3
=
({
data
,
onSubmit
,
handleSubmit
,
konstan
})
=>
{
const
FormIUMK3
=
({
data
,
onSubmit
,
handleSubmit
,
konstan
,
setValue
})
=>
{
const
urutan
=
[
'
nama
'
,
'
email
'
,
...
...
@@ -82,6 +82,7 @@ const FormIUMK3 = ({data, onSubmit, handleSubmit, konstan}) => {
<
button
className
=
"
bg-poporange text-white heading-3 px-10 md:px-28 lg:px-24 xl:px-24 2xl:px-24 py-2 mb-10 float-right shadow rounded-lg submit
"
data
-
testid
=
"
submit-button
"
onClick
=
{()
=>
setValue
(
'
page
'
,
'
end
'
)}
>
Submit
<
/button
>
...
...
@@ -96,6 +97,7 @@ FormIUMK3.propTypes = {
konstan
:
PropTypes
.
object
,
handleSubmit
:
PropTypes
.
func
,
onSubmit
:
PropTypes
.
func
,
setValue
:
PropTypes
.
func
,
}
export
default
FormIUMK3
src/pages/FormPendirianPT.js
View file @
03306d27
...
...
@@ -42,14 +42,16 @@ const FormPendirianPT = () => {
}
const
onSubmit
=
(
input
)
=>
{
setPageNumber
(
input
.
page
)
if
(
input
.
page
!=
'
end
'
)
{
setPageNumber
(
input
.
page
)
}
if
(
pageNumber
!=
3
)
{
if
(
pageNumber
==
1
)
{
setData
({...
data
,
...
input
})
}
else
{
setData
({...
data
,
...
input
,
...{
karyawan
:
employeeData
}})
}
}
else
{
}
else
if
(
input
.
page
==
'
end
'
)
{
axios
.
post
(
`
${
BASE_URL
.
API_BASE_URL
}
/api/v1/pt/`
,
...
...
@@ -149,6 +151,7 @@ const FormPendirianPT = () => {
konstan
=
{
konstan
}
onSubmit
=
{
onSubmit
}
handleSubmit
=
{
handleSubmit
}
setValue
=
{
setValue
}
/
>
)}
<
/div
>
...
...
src/pages/formiumk.js
View file @
03306d27
...
...
@@ -40,14 +40,16 @@ const FormIUMK = () => {
}
const
onSubmit
=
(
input
)
=>
{
setPageNumber
(
input
.
page
)
if
(
input
.
page
!=
'
end
'
)
{
setPageNumber
(
input
.
page
)
}
if
(
pageNumber
!=
3
)
{
if
(
pageNumber
==
1
)
{
setData
({...
data
,
...
input
})
}
else
{
setData
({...
data
,
...
input
,
...{
karyawan
:
employeeData
}})
}
}
else
{
}
else
if
(
input
.
page
==
'
end
'
)
{
axios
.
post
(
`
${
BASE_URL
.
API_BASE_URL
}
/api/v1/iumk/`
,
...
...
@@ -147,6 +149,7 @@ const FormIUMK = () => {
konstan
=
{
konstan
}
onSubmit
=
{
onSubmit
}
handleSubmit
=
{
handleSubmit
}
setValue
=
{
setValue
}
/
>
)}
<
/div
>
...
...
Write
Preview
Supports
Markdown
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