260806_01_ENH: 이메일 첨부파일 등록 추가
This commit is contained in:
@@ -27,6 +27,8 @@ import ApplyFilterOption, { validateApplyFilterTarget } from './ListDialogOption
|
||||
import { KriEditor } from '@/components/kri-editor'
|
||||
import { normalizeQrCodeForEditor, QR_CODE_ALLOWED_HTML, renderQrCodePreviewHtml } from '@/components/message-template/qrcode'
|
||||
import { applyLinkPreviewClass } from '@/components/kri-editor/utils/linkPreview'
|
||||
import TemplateAttachmentList from '@/components/message-template/TemplateAttachmentList'
|
||||
import type { TemplateEmailWithAttachments } from '@/types/message'
|
||||
|
||||
export type MessageSendMode = 'email' | 'sms'
|
||||
|
||||
@@ -339,19 +341,25 @@ const MessageSendDialog = ({
|
||||
/>
|
||||
</div>
|
||||
) : (
|
||||
<div
|
||||
className={cn('kri-editor-preview rounded-md border bg-muted/30 p-3')}
|
||||
dangerouslySetInnerHTML={{
|
||||
__html: renderQrCodePreviewHtml(
|
||||
applyLinkPreviewClass(
|
||||
sanitizeHtmlForPreview(
|
||||
normalizeQrCodeForEditor(selectedTemplate.tmplatBody) || '(내용 없음)',
|
||||
QR_CODE_ALLOWED_HTML,
|
||||
<>
|
||||
<div
|
||||
className={cn('kri-editor-preview rounded-md border bg-muted/30 p-3')}
|
||||
dangerouslySetInnerHTML={{
|
||||
__html: renderQrCodePreviewHtml(
|
||||
applyLinkPreviewClass(
|
||||
sanitizeHtmlForPreview(
|
||||
normalizeQrCodeForEditor(selectedTemplate.tmplatBody) || '(내용 없음)',
|
||||
QR_CODE_ALLOWED_HTML,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
}}
|
||||
/>
|
||||
}}
|
||||
/>
|
||||
<TemplateAttachmentList
|
||||
tmplatIdx={selectedTemplate.tmplatIdx}
|
||||
atchFl={(selectedTemplate as TemplateEmailWithAttachments).atchFl}
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
|
||||
@@ -19,7 +19,8 @@ import { sanitizeHtmlForPreview } from '@/components/kri-editor/utils/sanitizeHt
|
||||
import { KriEditor } from '@/components/kri-editor'
|
||||
import { getNearestFutureDateTime } from '@/lib/datetime'
|
||||
import type { DialogId } from '@/store/jotai/dialog'
|
||||
import type { MessageSendChannel } from '@/types/message'
|
||||
import type { MessageSendChannel, TemplateEmailWithAttachments } from '@/types/message'
|
||||
import TemplateAttachmentList from '@/components/message-template/TemplateAttachmentList'
|
||||
|
||||
const titleMap: Record<MessageSendChannel, string> = {
|
||||
email: '메일 발송',
|
||||
@@ -214,10 +215,16 @@ const SingleMessageSendDialog = ({
|
||||
/>
|
||||
</div>
|
||||
) : (
|
||||
<div
|
||||
className="rounded-md border bg-muted/30 p-3 text-sm"
|
||||
dangerouslySetInnerHTML={{ __html: sanitizeHtmlForPreview(selectedTemplate.tmplatBody || '(내용 없음)') }}
|
||||
/>
|
||||
<>
|
||||
<div
|
||||
className="rounded-md border bg-muted/30 p-3 text-sm"
|
||||
dangerouslySetInnerHTML={{ __html: sanitizeHtmlForPreview(selectedTemplate.tmplatBody || '(내용 없음)') }}
|
||||
/>
|
||||
<TemplateAttachmentList
|
||||
tmplatIdx={selectedTemplate.tmplatIdx}
|
||||
atchFl={(selectedTemplate as TemplateEmailWithAttachments).atchFl}
|
||||
/>
|
||||
</>
|
||||
)}
|
||||
</>
|
||||
)}
|
||||
|
||||
Reference in New Issue
Block a user