I have the following:
<tr>
<td>{{object.valor | number:2}}</td>
<td>
<input type="number" ng-model="object2.valor"
ng-init="object2.valor=object.valor" ng-value="object.valor"/>
</td>
</tr>
Object : {{object}} => {valor: 15}
Object 2 : {{object2}} => {}
The funny thing that in the input text is that I see the value 15 or if I modify the input to another number if it updates the value of object2
An alternative that I have thought is in my js:
var valor = {valor:12};
$scope.object = valor;
$scope.object2 = valor;
<input type="number" ng-model="object.valor" /
<input type="number" ng-model="object2.valor" />
But if I change the value of one tb, the other one is modified, how can I make them independent?