--- lib/domain/content-form.ts
+++ lib/domain/content-form.ts
... | ... | @@ -82,12 +82,8 @@ |
| 82 | 82 |
* 백엔드 UPDATE가 `QUIZ_POINT = #{quizPoint}`로 무조건 덮어써서, 안 보내면 지워진다.
|
| 83 | 83 |
*/ |
| 84 | 84 |
points: string; |
| 85 |
- /** |
|
| 86 |
- * 기존 QUIZ_TITLE. 키워드가 기획에서 빠져 화면에 입력 칸이 없지만, 수정 SQL이 |
|
| 87 |
- * `QUIZ_TITLE = #{quizTitle}`로 무조건 덮어써서 안 보내면 지워진다(`points`와 같은 이유).
|
|
| 88 |
- */ |
|
| 89 |
- title: string; |
|
| 90 | 85 |
level: string; |
| 86 |
+ keywords: ContentKeyword[]; |
|
| 91 | 87 |
question: string; |
| 92 | 88 |
answer: string; |
| 93 | 89 |
answerMessageCode: string; |
... | ... | @@ -289,11 +285,14 @@ |
| 289 | 285 |
answerMessageText = ''; |
| 290 | 286 |
} |
| 291 | 287 |
|
| 288 |
+ const keywords = normalizeKeywords(values.keywords); |
|
| 289 |
+ validateKeywords(keywords, errors); |
|
| 290 |
+ |
|
| 292 | 291 |
if (Object.keys(errors).length > 0) {
|
| 293 | 292 |
return { ok: false, errors };
|
| 294 | 293 |
} |
| 295 | 294 |
return {
|
| 296 | 295 |
ok: true, |
| 297 |
- values: { ...values, question, explanation, answerMessageText },
|
|
| 296 |
+ values: { ...values, question, explanation, answerMessageText, keywords },
|
|
| 298 | 297 |
}; |
| 299 | 298 |
} |
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?