lundi 29 février 2016

Ember bind with controller instead of model

I am currently fetching my model into a list of input helpers and binding their value attributes with the field id(from the model). Like

{{input value=field.id  type=field.type 
  class="form-control" placeholder=field.placeholder}}

My aim is to have a mathematical operation carried out on this field and displayed on another input field(like a formula). I also have properties dynamically created in the controller in the afterRender hook(with the same ids of the model contents).

However, when I update my value in the input field, the corresponding controller property is not updated. Instead, the model is getting updated.




Aucun commentaire:

Enregistrer un commentaire