From 7849c63507309a2bbbcdeed78c7e3dea9f312e51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=B3=B4=EA=B3=A4?= Date: Thu, 19 Feb 2026 23:55:28 +0900 Subject: [PATCH] =?UTF-8?q?fix:=EB=B0=9C=EC=86=A1=20=EB=B0=A9=EC=8B=9D=20?= =?UTF-8?q?=EC=84=A0=ED=83=9D=20UI=20=EA=B0=9C=EC=84=A0=20-=20=EC=9D=B4?= =?UTF-8?q?=EB=A9=94=EC=9D=BC/=EC=95=8C=EB=A6=BC=ED=86=A1=20=EC=84=A0?= =?UTF-8?q?=ED=83=9D=20=EA=B0=80=EB=8A=A5,=20=EC=9D=B4=EB=A9=94=EC=9D=BC?= =?UTF-8?q?=20=EA=B8=B0=EB=B3=B8=EA=B0=92,=20=EB=A6=AC=EB=A7=88=EC=9D=B8?= =?UTF-8?q?=EB=8D=94=20=EB=B0=9C=EC=86=A1=20=EB=B0=A9=EC=8B=9D=20=EB=AA=A8?= =?UTF-8?q?=EB=8B=AC=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/ESign/EsignApiController.php | 5 +- resources/views/esign/detail.blade.php | 63 ++++++++++++++++--- resources/views/esign/send.blade.php | 10 ++- 3 files changed, 61 insertions(+), 17 deletions(-) diff --git a/app/Http/Controllers/ESign/EsignApiController.php b/app/Http/Controllers/ESign/EsignApiController.php index 49b387fa..738fb863 100644 --- a/app/Http/Controllers/ESign/EsignApiController.php +++ b/app/Http/Controllers/ESign/EsignApiController.php @@ -843,12 +843,15 @@ public function remind(Request $request, int $id): JsonResponse ->orderBy('sign_order') ->first(); + // 요청에서 발송 방식 지정이 있으면 우선 사용, 없으면 계약 저장값, 최종 기본값은 email + $sendMethod = $request->input('send_method') ?: ($contract->send_method ?? 'email'); + $notificationResults = []; if ($nextSigner) { $nextSigner->update(['status' => 'notified']); $results = $this->dispatchNotification( $contract, $nextSigner, - $contract->send_method ?? 'email', + $sendMethod, $contract->sms_fallback ?? true, isReminder: true, ); diff --git a/resources/views/esign/detail.blade.php b/resources/views/esign/detail.blade.php index cca161ba..d6c099cf 100644 --- a/resources/views/esign/detail.blade.php +++ b/resources/views/esign/detail.blade.php @@ -75,6 +75,8 @@ const [contract, setContract] = useState(null); const [loading, setLoading] = useState(true); const [actionLoading, setActionLoading] = useState(''); + const [showRemindModal, setShowRemindModal] = useState(false); + const [remindMethod, setRemindMethod] = useState('email'); const fetchContract = useCallback(async () => { try { @@ -87,12 +89,14 @@ useEffect(() => { fetchContract(); }, [fetchContract]); - const doAction = async (action, confirm_msg) => { + const doAction = async (action, confirm_msg, body = {}) => { if (confirm_msg && !window.confirm(confirm_msg)) return; setActionLoading(action); try { const res = await fetch(`/esign/contracts/${CONTRACT_ID}/${action}`, { - method: 'POST', headers: getHeaders(), + method: 'POST', + headers: { ...getHeaders(), 'Content-Type': 'application/json' }, + body: JSON.stringify(body), }); const json = await res.json(); if (json.success) fetchContract(); @@ -101,6 +105,11 @@ setActionLoading(''); }; + const handleRemind = () => { + setShowRemindModal(false); + doAction('remind', null, { send_method: remindMethod }); + }; + if (loading) return
로딩 중...
; if (!contract) return
계약을 찾을 수 없습니다.
; @@ -249,17 +258,18 @@ className="w-8 h-8 flex items-center justify-center rounded-lg text-gray-400 hov 서명 위치 설정 - + + 서명 요청 발송 + )} {['pending', 'partially_signed'].includes(c.status) && ( - + <> + + )} {!['completed', 'cancelled', 'rejected'].includes(c.status) && ( + + + + + )} ); }; diff --git a/resources/views/esign/send.blade.php b/resources/views/esign/send.blade.php index 5e258ffb..3c21cc0f 100644 --- a/resources/views/esign/send.blade.php +++ b/resources/views/esign/send.blade.php @@ -24,8 +24,8 @@ const SEND_METHODS = [ { value: 'email', label: '이메일', desc: '수신자 이메일로 서명 요청 링크 발송', icon: '✉', recommended: true }, - { value: 'alimtalk', label: '카카오톡 알림톡', desc: '수신자 휴대폰으로 알림톡 발송 (카카오 채널 개설 후 사용 가능)', icon: '💬', disabled: true }, - { value: 'both', label: '알림톡 + 이메일 (동시)', desc: '두 채널 모두 발송하여 확인율 극대화 (카카오 채널 개설 후 사용 가능)', icon: '📡', disabled: true }, + { value: 'alimtalk', label: '카카오톡 알림톡', desc: '수신자 휴대폰으로 알림톡 발송 (카카오 채널 필요, 실패 시 이메일 자동 폴백)', icon: '💬' }, + { value: 'both', label: '이메일 + 알림톡 (동시)', desc: '두 채널 모두 발송하여 확인율 극대화', icon: '📡' }, ]; const App = () => { @@ -113,17 +113,15 @@
{SEND_METHODS.map(m => (