'테스트 고객', 'customer_email' => $notification_type === 'email' ? $test_recipient : 'test@example.com', 'customer_phone' => $notification_type === 'sms' ? $test_recipient : '01012345678', 'estimate_id' => 'TEST-001', 'estimate_subject' => '테스트 견적 요청', 'total_amount' => '1,500,000', 'visit_fee' => '50,000', 'account_info' => '국민은행 123-456-789012 (주)창호전문', 'dealer_name' => '테스트 대리점', 'construction_date' => '2024-02-15', 'visit_datetime' => '2024-02-10 14:00', 'interim_payment_date' => '2024-02-13', 'days_remaining' => '2', 'bid_amount' => '1,200,000', 'selected_date' => date('Y-m-d H:i') ]; $notification_helper = new NotificationHelper(); // 알림 발송 if ($template_type === 'customer') { $result = $notification_helper->sendCustomerNotification($template_key, $test_data); } elseif ($template_type === 'dealer') { $result = $notification_helper->sendDealerNotification($template_key, $test_data); } else { throw new Exception('유효하지 않은 템플릿 타입입니다.'); } if ($result['success']) { $message = '테스트 알림이 성공적으로 발송되었습니다.'; if (isset($result['debug_info'])) { $message .= '\n\n디버그 정보: ' . $result['debug_info']; } alert($message); } else { throw new Exception('알림 발송 실패: ' . $result['message']); } } } catch (Exception $e) { alert('오류: ' . $e->getMessage()); } goto_url('./notification_test.php'); exit; } // 템플릿 목록 조회 $email_templates = []; $sms_templates = []; $email_sql = "SELECT template_key, template_name FROM order_mail_templates ORDER BY template_key ASC"; $email_result = sql_query($email_sql); while ($row = sql_fetch_array($email_result)) { $email_templates[] = $row; } $sms_sql = "SELECT template_key, template_name FROM order_sms_templates ORDER BY template_key ASC"; $sms_result = sql_query($sms_sql); while ($row = sql_fetch_array($sms_result)) { $sms_templates[] = $row; } include_once(G5_ADMIN_PATH . '/admin.head.php'); ?>

이메일 및 SMS 알림 템플릿의 실제 발송을 테스트할 수 있습니다.
개발 단계에서는 알림창으로 표시되며, 운영 단계에서는 실제 발송됩니다.

알림 발송 테스트
발송 방식을 먼저 선택하세요
발송 모드 설정
현재 모드
모드 설명
  • 개발 모드: 실제 발송 대신 알림창으로 내용을 표시합니다.
  • 운영 모드: 실제 이메일/SMS를 발송합니다.
사용 가능한 템플릿 변수
변수명 설명 예시값
{customer_name} 고객명 홍길동
{estimate_id} 견적 번호 12345
{estimate_subject} 견적 제목 아파트 창호 교체 견적
{total_amount} 총 금액 1,500,000
{visit_fee} 방문 비용 50,000
{dealer_name} 대리점명 김대리점
{construction_date} 시공 예정일 2024-02-15
{account_info} 계좌 정보 국민은행 123-456-789012