VRFS-4193 - pop open system browser for Stripe Connect when in app
This commit is contained in:
parent
c6b11e64ad
commit
9db218d518
|
|
@ -12,6 +12,9 @@ UserStore = context.UserStore
|
|||
clicked:false
|
||||
}
|
||||
|
||||
openBrowser: () ->
|
||||
context.JK.popExternalLink("https://www.jamkazam.com/client#/jamclass")
|
||||
|
||||
onStripeConnect: (e) ->
|
||||
|
||||
if this.state.clicked
|
||||
|
|
@ -19,6 +22,21 @@ UserStore = context.UserStore
|
|||
|
||||
e.preventDefault()
|
||||
|
||||
if window.jamClient.IsNativeClient()
|
||||
buttons = []
|
||||
buttons.push({name: 'CLOSE', buttonStyle: 'button-grey'})
|
||||
buttons.push({
|
||||
name: 'OPEN BROWSER',
|
||||
buttonStyle: 'button-orange',
|
||||
click: (() => (@openBrowser()))
|
||||
})
|
||||
context.JK.Banner.show({
|
||||
title: "Browser Needed",
|
||||
html: "You must connect to Stripe in a normal browser.<br/><br/>Please select the OPEN BROWSER button to open this page in your system browser.",
|
||||
buttons: buttons
|
||||
})
|
||||
return
|
||||
|
||||
this.setState({clicked: true})
|
||||
StripeActions.connect(this.props.purpose, this.props.user)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue