<label>Capital
<input type="number" ng-model="vm.capital" ng-keyup="vm.total()">
</label>
<label>Honorarios
<input type="number" ng-model="vm.honorarium" ng-keyup="vm.total()">
</label>
<h1>{{ vm.sum }}</h1>
The function:
this.total = function(){
this.sum = capital + honorarium;
}
I need to make the sum between capital and honorarium. But my solution does not work, maybe I have some problem in logic.