mirror of
https://github.com/ktds-dg0501/kt-event-marketing-fe.git
synced 2025-12-06 08:56:23 +00:00
주요 변경사항: - Step flow 통합: localStorage 기반 eventId 사용 - 자동 이미지 생성: 이미지 없을 시 자동 생성 트리거 - 진행률 바 추가: 0-100% 진행률 표시 - 동적 로딩 메시지: 단계별 메시지 업데이트 - Next.js 15 API routes 수정: params를 Promise로 처리 - 실제 배포 API 연동: Content API 서버 URL 설정 기술 세부사항: - API proxy routes 추가 (CORS 우회) - 2초 폴링 메커니즘 (최대 60초) - 환경변수: NEXT_PUBLIC_CONTENT_API_URL 설정 - CDN URL 디버그 오버레이 제거 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2.9 KiB
2.9 KiB
🔗 AI 이미지 생성 테스트 URL 가이드
✅ 올바른 URL
ContentPreview Step 직접 접속
http://localhost:3000/events/create?event-creation.step=contentPreview
또는 간단하게:
http://localhost:3000/events/create?step=contentPreview
Mock 데이터 설정 페이지
http://localhost:3000/init-mock-data.html
📝 URL 파라미터 설명
event-creation.step=contentPreview- Funnel의 step을 contentPreview로 설정step=contentPreview- 간단한 형식 (funnel id가 event-creation일 때)
🎯 전체 플로우 테스트 URL
1. 시작 (Objective Step)
http://localhost:3000/events/create
2. Channel Step까지 진행 후
http://localhost:3000/events/create?event-creation.step=channel
3. ContentPreview Step (이미지 생성)
http://localhost:3000/events/create?event-creation.step=contentPreview
💡 자동 Mock 데이터 생성
이제 contentPreview 페이지에 직접 접속하면:
- ✅ localStorage 확인
- ✅ 데이터 없으면 자동으로 Mock 데이터 생성
- ✅ 즉시 AI 이미지 생성 시작
더 이상 수동으로 Mock 데이터를 설정할 필요가 없습니다!
🧪 테스트 시나리오
시나리오 1: 가장 빠른 테스트
# 1. 개발 서버 실행
npm run dev
# 2. 브라우저에서 바로 접속
http://localhost:3000/events/create?event-creation.step=contentPreview
→ 자동으로 Mock 데이터 생성 & 이미지 생성 시작!
시나리오 2: 커스텀 데이터로 테스트
# 1. Mock 데이터 설정 페이지 열기
http://localhost:3000/init-mock-data.html
# 2. 원하는 데이터 입력 후 저장
# 3. ContentPreview 접속
http://localhost:3000/events/create?event-creation.step=contentPreview
시나리오 3: 전체 플로우 테스트
# 1. 처음부터 시작
http://localhost:3000/events/create
# 2. Objective 선택
# 3. Recommendation 확인
# 4. Channel 선택 (SNS, 우리동네TV, 지니TV 중 하나)
# 5. 자동으로 ContentPreview로 이동하며 이미지 생성 시작
🐛 문제 해결
"이벤트 정보를 찾을 수 없습니다" 에러
→ 이제 이 에러는 발생하지 않습니다! 자동으로 Mock 데이터가 생성됩니다.
이미지 생성 실패
# Content API 서버 확인
curl http://localhost:8084/api/v1/content/events/7777/images
# API 서버가 꺼져있다면 실행 필요
다른 이벤트 ID로 테스트하고 싶을 때
// 브라우저 콘솔에서
localStorage.setItem('eventCreationData', JSON.stringify({
eventDraftId: 8888, // 다른 ID
eventTitle: "커피 할인 이벤트",
eventDescription: "신메뉴 출시 기념",
industry: "카페",
location: "홍대",
trends: ["커피", "할인"],
prize: "아메리카노 1잔"
}));
// 페이지 새로고침
location.reload();