context = window rest = context.JK.Rest() @JamClassTeacherLandingPage = React.createClass({ render: () -> loggedIn = context.JK.currentUserId? if this.state.done ctaButtonText = 'sending you in...' else if this.state.processing ctaButtonText = 'hold on...' else if loggedIn ctaButtonText = 'Enter Teacher Profile' else ctaButtonText = 'Sign Up' if loggedIn register = `` else if this.state.loginErrors? for key, value of this.state.loginErrors break errorText = context.JK.getFullFirstError(key, this.state.loginErrors, {email: 'Email', password: 'Password', 'terms_of_service' : 'The terms of service'}) register = `
{errorText}
` `
teacher instructing a jam class

JAMCLASS

Finally, online music lessons
that really work!

Sign Up as Teacher

Sign up and start getting students referred from our marketplace.

We'll give you all the 1:1 help you need to get set up and running. We can help if you need tech support with gear, and we'll get you in a session to make sure you're ready to go!

Sign up now to join our community. We will not share your email. See our privacy policy

{register}

We guarantee you will be blown away by how much better this is than Skype for online lessons.

JamClass by JamKazam is by far the best way to teach online music lessons. Using our unique, patented technologies, you can play live in sync with your students over the Internet with incredible audio quality. Teach students who live far away. Teach during normally “off hours”. And let JamKazam bring students to you through our lesson marketplace, increasing your income in multiple dimensions. All while avoiding the time and cost of travel to and from lessons.

` getInitialState: () -> {loginErrors: null, processing:false} privacyPolicy: (e) -> e.preventDefault() context.JK.popExternalLink('/corp/privacy') termsClicked: (e) -> e.preventDefault() context.JK.popExternalLink('/corp/terms') componentDidMount:() -> $root = $(this.getDOMNode()) $checkbox = $root.find('.terms-checkbox') context.JK.checkbox($checkbox) # add item to cart, create the user if necessary, and then place the order to get the free JamTrack. ctaClick: (e) -> e.preventDefault() return if @state.processing @setState({loginErrors: null}) loggedIn = context.JK.currentUserId? if loggedIn @markTeacher() else @createUser() @setState({processing:true}) markTeacher: () -> rest.updateUser({teacher: true}) .done((response) => this.setState({done: true}) context.location = '/client#/teachers/setup/introduction' ) .fail((jqXHR) => this.setState({processing: false}) context.JK.app.notifyServerError(jqXHR, "Unable to Mark As Teacher") ) createUser: () -> $form = $('.jamtrack-signup-form') email = $form.find('input[name="email"]').val() password = $form.find('input[name="password"]').val() terms = $form.find('input[name="terms"]').is(':checked') rest.signup({email: email, password: password, first_name: null, last_name: null, terms:terms, teacher : true}) .done((response) => @setState({done: true}) context.location = '/client#/teachers/setup/introduction' ).fail((jqXHR) => @setState({processing:false}) if jqXHR.status == 422 response = JSON.parse(jqXHR.responseText) if response.errors @setState({loginErrors: response.errors}) else context.JK.app.notify({title: 'Unknown Signup Error', text: jqXHR.responseText}) else context.JK.app.notifyServerError(jqXHR, "Unable to Sign Up") ) })