Split of App.Wizard into App.WizardModal and App.WizardFullScreen.
This commit is contained in:
parent
988b5848c6
commit
ba2d92a15d
4 changed files with 23 additions and 33 deletions
|
@ -677,7 +677,9 @@ class App.Sidebar extends App.Controller
|
|||
# show sidebar if not shown
|
||||
@showSidebar()
|
||||
|
||||
class App.Wizard extends App.Controller
|
||||
class App.WizardModal extends App.Controller
|
||||
className: 'modal fade'
|
||||
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
@ -723,3 +725,11 @@ class App.Wizard extends App.Controller
|
|||
for field, type of fields
|
||||
if type
|
||||
@$(".#{screen}").find("[name=\"options::#{field}\"]").closest('.form-group').addClass('has-error')
|
||||
|
||||
class App.WizardFullScreen extends App.WizardModal
|
||||
className: 'getstarted fit'
|
||||
|
||||
constructor: ->
|
||||
super
|
||||
$('.content').addClass('hide')
|
||||
$('#content').removeClass('hide')
|
||||
|
|
|
@ -436,12 +436,10 @@ class App.ChannelEmailEdit extends App.ControllerModal
|
|||
@formEnable(e)
|
||||
)
|
||||
|
||||
class App.ChannelEmailAccountWizard extends App.Wizard
|
||||
class App.ChannelEmailAccountWizard extends App.WizardModal
|
||||
elements:
|
||||
'.modal-body': 'body'
|
||||
|
||||
className: 'modal fade'
|
||||
|
||||
events:
|
||||
'submit .js-intro': 'probeBasedOnIntro'
|
||||
'submit .js-inbound': 'probeInbound'
|
||||
|
@ -775,12 +773,10 @@ class App.ChannelEmailAccountWizard extends App.Wizard
|
|||
e.preventDefault()
|
||||
@el.modal('hide')
|
||||
|
||||
class App.ChannelEmailNotificationWizard extends App.Wizard
|
||||
class App.ChannelEmailNotificationWizard extends App.WizardModal
|
||||
elements:
|
||||
'.modal-body': 'body'
|
||||
|
||||
className: 'modal fade'
|
||||
|
||||
events:
|
||||
'change .js-outbound [name=adapter]': 'toggleOutboundAdapter'
|
||||
'submit .js-outbound': 'probleOutbound'
|
||||
|
|
|
@ -1,6 +1,4 @@
|
|||
class Index extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
|
||||
class Index extends App.WizardFullScreen
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
@ -62,8 +60,6 @@ App.Config.set( 'getting_started', Index, 'Routes' )
|
|||
|
||||
|
||||
class AutoWizard extends App.ControllerContent
|
||||
className: 'getstarted fit'
|
||||
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
@ -130,8 +126,7 @@ App.Config.set( 'getting_started/auto_wizard', AutoWizard, 'Routes' )
|
|||
App.Config.set( 'getting_started/auto_wizard/:token', AutoWizard, 'Routes' )
|
||||
|
||||
|
||||
class Admin extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
class Admin extends App.WizardFullScreen
|
||||
events:
|
||||
'submit form': 'submit'
|
||||
|
||||
|
@ -247,8 +242,7 @@ class Admin extends App.Wizard
|
|||
App.Config.set( 'getting_started/admin', Admin, 'Routes' )
|
||||
|
||||
|
||||
class Base extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
class Base extends App.WizardFullScreen
|
||||
elements:
|
||||
'.logo-preview': 'logoPreview'
|
||||
|
||||
|
@ -384,8 +378,7 @@ class Base extends App.Wizard
|
|||
App.Config.set( 'getting_started/base', Base, 'Routes' )
|
||||
|
||||
|
||||
class EmailNotification extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
class EmailNotification extends App.WizardFullScreen
|
||||
events:
|
||||
'change .js-outbound [name=adapter]': 'toggleOutboundAdapter'
|
||||
'submit .js-outbound': 'submit'
|
||||
|
@ -505,9 +498,7 @@ class EmailNotification extends App.Wizard
|
|||
App.Config.set( 'getting_started/email_notification', EmailNotification, 'Routes' )
|
||||
|
||||
|
||||
class Channel extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
|
||||
class Channel extends App.WizardFullScreen
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
@ -558,9 +549,7 @@ class Channel extends App.Wizard
|
|||
|
||||
App.Config.set( 'getting_started/channel', Channel, 'Routes' )
|
||||
|
||||
class ChannelEmailPreConfigured extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
|
||||
class ChannelEmailPreConfigured extends App.WizardFullScreen
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
@ -603,8 +592,7 @@ class ChannelEmailPreConfigured extends App.Wizard
|
|||
|
||||
App.Config.set( 'getting_started/channel/email_pre_configured', ChannelEmailPreConfigured, 'Routes' )
|
||||
|
||||
class ChannelEmail extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
class ChannelEmail extends App.WizardFullScreen
|
||||
events:
|
||||
'submit .js-intro': 'probeBasedOnIntro'
|
||||
'submit .js-inbound': 'probeInbound'
|
||||
|
@ -895,8 +883,7 @@ class ChannelEmail extends App.Wizard
|
|||
|
||||
App.Config.set( 'getting_started/channel/email', ChannelEmail, 'Routes' )
|
||||
|
||||
class Agent extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
class Agent extends App.WizardFullScreen
|
||||
events:
|
||||
'submit form': 'submit'
|
||||
|
||||
|
@ -995,9 +982,7 @@ class Agent extends App.Wizard
|
|||
|
||||
App.Config.set( 'getting_started/agents', Agent, 'Routes' )
|
||||
|
||||
class Channel extends App.Wizard
|
||||
className: 'getstarted fit'
|
||||
|
||||
class Channel extends App.WizardFullScreen
|
||||
constructor: ->
|
||||
super
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
class App.InviteUser extends App.Wizard
|
||||
className: 'modal fade'
|
||||
class App.InviteUser extends App.WizardModal
|
||||
events:
|
||||
'click .js-close': 'hide'
|
||||
'submit .js-user': 'submit'
|
||||
|
|
Loading…
Reference in a new issue