but even if you trigger 'change', the model attributes hasn't changed, no ?


2014-05-09 10:13 GMT+02:00 Joseph Silvestre <notifications@github.com>:

> In client/modal_share_view.coffee:
>
> > @@ -151,6 +151,9 @@ module.exports = class CozyClearanceModal extends Modal
> >          request 'PUT', "clearance/#{@model.id}", @saveData(),
> >              error: -> Modal.error 'server error occured'
> >              success: (data) =>
> > +                # force rerender of the view because this request
> > +                # doesn't trigger the set
> > +                @model.set 'clearance', data
>
> If I change it to data.clearance it doesn't work anymore (makes sense,
> somehow). Maybe the @model.trigger 'change' is the way to go here?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/mycozycloud/cozy-clearance/pull/5/files#r12467149>
> .
>