jam-cloud/web/app/assets/javascripts/wizard/gear/step_configure_tracks.js

60 lines
1.6 KiB
JavaScript

(function (context, $) {
"use strict";
context.JK = context.JK || {};
context.JK.StepConfigureTracks = function (app) {
var ASSIGNMENT = context.JK.ASSIGNMENT;
var VOICE_CHAT = context.JK.VOICE_CHAT;
var MAX_TRACKS = context.JK.MAX_TRACKS;
var logger = context.JK.logger;
var configureTracksHelper = new context.JK.ConfigureTracksHelper(app);
var $step = null;
var successfullyAssignedOnce = false;
var wizard = null;
function handleHelp() {
return "https://jamkazam.desk.com/customer/en/portal/articles/2400702-using-the-setup-wizard-%E2%80%93-step-3-%E2%80%93-configure-tracks"
}
function handleNext() {
/** var saved = configureTracksHelper.trySave();
if(saved) {
context.JK.GA.trackConfigureTracksCompletion(context.JK.detectOS());
successfullyAssignedOnce = true;
}
*/
return context.ConfigureTracksStore.editingTrackValid()
}
function newSession() {
successfullyAssignedOnce = false;
}
function beforeShow() {
var forceInputsToUnassigned = !successfullyAssignedOnce;
window.ConfigureTracksActions.reset(false);
//configureTracksHelper.reset(forceInputsToUnassigned, wizard.getChosenInputs())
}
function initialize(_$step, _wizard) {
$step = _$step;
wizard = _wizard;
configureTracksHelper.initialize($step);
}
this.handleHelp = handleHelp;
this.newSession = newSession;
this.handleNext = handleNext;
this.beforeShow = beforeShow;
this.initialize = initialize;
return this;
}
})(window, jQuery);