토스페이먼츠 결제 현대카드 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;
}
}
이렇게만 변경하면 되는걸까요 ?
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;
}
}
이렇게만 변경하면 되는걸까요 ?
1. 신용카드결제 선택
2. 현대카드 선택
3. PIN번호 결제 선택
V3 Mobile Plus 에 앱푸시로 "오류가 발생하여 서버 접속을 실패했습니다. (오류코드: 4202)" 가 노출되며 더 이상 결제를 진행할 수 없습니다.
https://docs.tosspayments.com/guides/v2/webview 문서를 기반으로 AndroidManifest.xml 설정도 정상적 완료했습니다.
inAppwebView: ^6.0.0
tosspayment_widget_sdk_flutter: ^2.0.7
1. webView-shouldOverrideUrlLoading 에서 url = intent://....end;...
2. 현대카드 선택
3. PIN번호 결제 선택
V3 Mobile Plus 에 앱푸시로 "오류가 발생하여 서버 접속을 실패했습니다. (오류코드: 4202)" 가 노출되며 더 이상 결제를 진행할 수 없습니다.
https://docs.tosspayments.com/guides/v2/webview 문서를 기반으로 AndroidManifest.xml 설정도 정상적 완료했습니다.
inAppwebView: ^6.0.0
tosspayment_widget_sdk_flutter: ^2.0.7
1. webView-shouldOverrideUrlLoading 에서 url = intent://....end;...
GitHub
flutter webview sample. Contribute to youjun-lee/flutter_webview_sample_app development by creating an account on GitHub.
