Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
students
survey
Commits
34980609
"client/git@compmath.korea.ac.kr:students/search-page.git" did not exist on "cbc36f50e3c8e1cb6e82ecad30a8b9f45ab6dda5"
Commit
34980609
authored
Jan 11, 2023
by
Lee SeoYeon
Browse files
제목 입력시 확인 가능, 제목과 선택지 입력시 확인가능
parent
0150d3d8
Changes
1
Show whitespace changes
Inline
Side-by-side
frontend/src/surveys/Question.tsx
View file @
34980609
...
@@ -18,9 +18,13 @@ export const Question = ({
...
@@ -18,9 +18,13 @@ export const Question = ({
const
isEditing
=
question
.
isEditing
;
const
isEditing
=
question
.
isEditing
;
async
function
handleEditComplete
()
{
async
function
handleEditComplete
()
{
if
(
question
.
content
.
length
<
0
||
question
.
title
.
length
>
1
)
{
question
.
isEditing
=
false
;
handleQuestion
(
question
);
}
question
.
content
.
choices
.
map
((
choice
)
=>
{
question
.
content
.
choices
.
map
((
choice
)
=>
{
if
(
choice
.
text
.
trim
()
===
""
)
{
if
(
question
.
title
.
length
<
1
||
choice
.
text
.
trim
()
===
""
)
{
alert
(
"
질문작성이 완료되지 않았습니다.
"
);
alert
(
"
빈칸을 채워주세요
"
);
return
(
question
.
isEditing
=
true
);
return
(
question
.
isEditing
=
true
);
}
else
{
}
else
{
question
.
isEditing
=
false
;
question
.
isEditing
=
false
;
...
...
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