👽 Use capital to deal with mfa
This commit is contained in:
parent
85764c37c2
commit
e9e6f3313e
@ -176,7 +176,7 @@ class PostEditorController extends GetxController {
|
|||||||
visibleUsers.clear();
|
visibleUsers.clear();
|
||||||
invisibleUsers.clear();
|
invisibleUsers.clear();
|
||||||
visibility.value = 0;
|
visibility.value = 0;
|
||||||
thumbnail.value = 0;
|
thumbnail.value = null;
|
||||||
publishedAt.value = null;
|
publishedAt.value = null;
|
||||||
publishedUntil.value = null;
|
publishedUntil.value = null;
|
||||||
isDraft.value = false;
|
isDraft.value = false;
|
||||||
|
@ -79,8 +79,8 @@ class _SignInPopupState extends State<SignInPopup> with ProtocolListener {
|
|||||||
onPressed: () {
|
onPressed: () {
|
||||||
const redirect = 'solink://auth?status=done';
|
const redirect = 'solink://auth?status=done';
|
||||||
launchUrlString(
|
launchUrlString(
|
||||||
ServiceFinder.buildUrl('passport',
|
ServiceFinder.buildUrl('capital',
|
||||||
'/mfa?redirect_uri=$redirect&ticketId=${e.ticketId}'),
|
'/auth/mfa?redirect_uri=$redirect&ticketId=${e.ticketId}'),
|
||||||
mode: LaunchMode.inAppWebView,
|
mode: LaunchMode.inAppWebView,
|
||||||
);
|
);
|
||||||
Navigator.pop(context);
|
Navigator.pop(context);
|
||||||
|
@ -5,15 +5,15 @@ abstract class ServiceFinder {
|
|||||||
|
|
||||||
static const String dealerUrl =
|
static const String dealerUrl =
|
||||||
devFlag ? 'http://localhost:8442' : 'https://api.sn.solsynth.dev';
|
devFlag ? 'http://localhost:8442' : 'https://api.sn.solsynth.dev';
|
||||||
static const String passportUrl =
|
static const String capitalUrl =
|
||||||
devFlag ? 'http://localhost:8444' : 'https://id.solsynth.dev';
|
devFlag ? 'http://localhost:8444' : 'https://solsynth.dev';
|
||||||
|
|
||||||
static String buildUrl(String serviceName, String? append) {
|
static String buildUrl(String serviceName, String? append) {
|
||||||
append ??= '';
|
append ??= '';
|
||||||
if (serviceName == 'dealer') {
|
if (serviceName == 'dealer') {
|
||||||
return '$dealerUrl$append';
|
return '$dealerUrl$append';
|
||||||
} else if (serviceName == 'passport') {
|
} else if (serviceName == 'capital') {
|
||||||
return '$passportUrl$append';
|
return '$capitalUrl$append';
|
||||||
}
|
}
|
||||||
return '$dealerUrl/cgi/$serviceName$append';
|
return '$dealerUrl/cgi/$serviceName$append';
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user