feat: [esign] 알림톡 템플릿명 환경별 분기 (운영: 원본, 개발: _DEV)
- resolveTemplateName() 헬퍼 메서드 추가 (두 컨트롤러)
- production 환경: 전자계약_서명요청, 전자계약_완료, 전자계약_리마인드
- 개발 환경: 전자계약_서명요청_DEV, 전자계약_완료_DEV, 전자계약_리마인드_DEV
- config('app.url')은 이미 환경별 도메인 자동 사용
This commit is contained in:
@@ -1047,7 +1047,7 @@ private function sendAlimtalk(
|
||||
$expires = $contract->expires_at?->format('Y-m-d H:i') ?? '없음';
|
||||
|
||||
if (! $templateName) {
|
||||
$templateName = $isReminder ? '전자계약_리마인드' : '전자계약_서명요청';
|
||||
$templateName = $this->resolveTemplateName($isReminder ? '전자계약_리마인드' : '전자계약_서명요청');
|
||||
}
|
||||
|
||||
// 등록된 템플릿 본문 + 버튼 정보 조회 (정확한 포맷 유지)
|
||||
@@ -1208,6 +1208,14 @@ private function getKakaotalkChannelId(BarobillService $barobill, string $bizNo)
|
||||
*
|
||||
* @return array{content: string|null, buttons: array}
|
||||
*/
|
||||
/**
|
||||
* 환경별 알림톡 템플릿명 반환 (운영: 원본, 개발: _DEV 접미사)
|
||||
*/
|
||||
private function resolveTemplateName(string $baseName): string
|
||||
{
|
||||
return $baseName.(app()->environment('production') ? '' : '_DEV');
|
||||
}
|
||||
|
||||
private function getTemplateData(BarobillService $barobill, string $bizNo, string $channelId, string $templateName): array
|
||||
{
|
||||
$empty = ['content' => null, 'buttons' => []];
|
||||
|
||||
Reference in New Issue
Block a user