Created
July 21, 2014 09:08
-
-
Save makishvili/b1ae862b9df74e1f6110 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
modules.define( | |
'add-analyst', | |
['inherit', 'y-block'], | |
function (provide, inherit, YBlock) { | |
var AddAnalyst = inherit(YBlock, { | |
__constructor: function () { | |
this.__base.apply(this, arguments); | |
var input = this._findElement('input'); | |
var button = this._findElement('button'); | |
this._bindTo(button, 'submit', this._onFormSubmit); | |
}, | |
_onFormSubmit: function (e) { | |
e.preventDefault(); | |
console.log('clicked'); | |
} | |
}, { | |
getBlockName: function () { | |
return 'add-analyst'; | |
} | |
}); | |
provide(AddAnalyst); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment