mardi 30 décembre 2014

EmberJs: Component action not triggered in pagination example

I followed this pagination tutorial but can't get the "next-page" / "prev page" to work. http://webcloud.info/blog/2014/11/01/building-a-real-world-pagination-with-ember-js-the-right-way/


JSBIN - http://emberjs.jsbin.com/manetavule/2/


The alert never runs in the click event, any idea what I'm doing wrong?



Myapp.PaginatonBaseComponent = Ember.Component.extend({
tagName: 'button',
classNames: 'btn btn-default'.w(),
attributeBindings: ['disabled'],
enabled: true,
disabled: Ember.computed.not('enabled'),
action: null,
click: function(){
alert('not triggered!');
this.sendAction();
}
});




Aucun commentaire:

Enregistrer un commentaire