마정한
마정한
토스페이먼츠 결제 현대카드 v3 오류
https://techchat.tosspayments.com/m/1308975211676172389 해당글에 답변해주신거처럼 https://github.com/youjun-lee/flutter_webview_sample_app 샘플에도 rawValue로 작성 하여야하는것아닌가요? 오늘만 현대카드 결제 클레임이 3건입니다 . shouldOverrideUrlLoading: (controller, navigationAction) async { var uri = navigationAction.request.url!; if (uri.scheme == 'http' || uri.scheme == 'https') { // 표준 웹 URL 체크 return NavigationActionPolicy.ALLOW; } else { // 그 외의 경우에는 tossPaymentsWebvew 함수로 검증 if(Platform.isAndroid) { // 마켓 넘어갈때 안드로이드에서 Err_unknown_url_scheme 해결 if (!navigationAction.isForMainFrame) { await controller.stopLoading(); }
} tossPaymentsWebview(uri.rawValue); return NavigationActionPolicy.CANCEL; } }, tossPaymentsWebview(url) { final appScheme = ConvertUrl(url); // Intent URL을 앱 스킴 URL로 변환 if (appScheme.isAppLink()) { // 앱 스킴 URL인지 확인 appScheme.launchApp(mode: LaunchMode.externalApplication); // 앱 설치 상태에 따라 앱 실행 또는 마켓으로 이동 return NavigationActionPolicy.CANCEL; } } 이렇게만 변경하면 되는걸까요 ?
5 replies
flutter Webview 결제 오류 문의
https://techchat.tosspayments.com/m/1336953556153925683 여기랑 증상 똑같습니다. https://docs.tosspayments.com/guides/v2/webview 여기참고해서 앱스킴 등록해주고 https://github.com/youjun-lee/flutter_webview_sample_app 여기 참고해서 버전 완전히 일치 시켯습니다. onNavigationRequest: (NavigationRequest request) { print('test:dd'); if (request.url.startsWith('https') || request.url.startsWith("http")) { // 표준 웹 URL 체크 return NavigationDecision.navigate; } tossPaymentsWebview(request.url); // 그 외의 경우에는 tossPaymentsWebvew 함수로 검증 return NavigationDecision.prevent; }, tossPaymentsWebview(url) { final appScheme = ConvertUrl(url); // Intent URL을 앱 스킴 URL로 변환 print('applink : ${appScheme.url}'); if (appScheme.isAppLink()) { // 앱 스킴 URL인지 확인 appScheme.launchApp(mode: LaunchMode.externalApplication); // 앱 설치 상태에 따라 앱 실행 또는 마켓으로 이동 return NavigationDecision.prevent; } } 여기 자체에서 kb랑 카카오뱅크만 Err_unknown_urlscheme 오류뜹니다..... 최초는 https://cdn.answeroverflow.com/1072747046492184636/Flutter-Tosspayments__.pdf 해당 예시로 구현했는데 여기도 마찬가지로 kb랑 카뱅만 onNavigationRequest 이게 실행이 안됩니다.
32 replies