--- lib/domain/content-form.ts
+++ lib/domain/content-form.ts
... | ... | @@ -275,6 +275,8 @@ |
| 275 | 275 |
'노출 문구를 다시 선택해 주세요.'; |
| 276 | 276 |
} |
| 277 | 277 |
|
| 278 |
+ // 백엔드 칸이 하나뿐이라(`cntntsQuizDescr`) 여기서 문구를 확정한다 — 코드를 골랐으면 |
|
| 279 |
+ // 그 코드명이, 기타면 직접 적은 값이 그대로 저장·노출된다. |
|
| 278 | 280 |
let text = message.text.trim().slice(0, ANSWER_MESSAGE_MAX_LENGTH); |
| 279 | 281 |
if (message.code === ANSWER_MESSAGE_ETC) {
|
| 280 | 282 |
if (text === '') {
|
... | ... | @@ -282,7 +284,8 @@ |
| 282 | 284 |
`${message.answer}에 노출할 문구를 입력해 주세요.`;
|
| 283 | 285 |
} |
| 284 | 286 |
} else {
|
| 285 |
- text = ''; |
|
| 287 |
+ text = |
|
| 288 |
+ allowedCodes.find((option) => option.code === message.code)?.label ?? ''; |
|
| 286 | 289 |
} |
| 287 | 290 |
return { ...message, text };
|
| 288 | 291 |
}); |
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?