how does angular.js edit specific parts of ng-repeat?
< hr > loops out a detail page with ng-repeat. After clicking the "Edit" button, becomes editable < input >.
every module has id. I didn"t write it. Is it possible to directly manipulate the array?
I don"t know how to select a particular module, so I came to ask for help. Thank you
(as shown in the following figure, attached to the code)
:
<div class="info-file" ng-repeat="item in info">
<button class="btn" ng-click="toEdit()" ng-show="editPara"></button>
<button class="btn" ng-click="add()" ng-hide="editPara"></button>
<div class="form-group">
<label class="label">:</label>
<input class="input" name="name" ng-model="item.name" ng-hide="editPara">
<span class="span info-span" ng-show="editPara">{{item.name}}</span>
</div>
<div class="form-group">
<label class="label">:</label>
<input class="input" name="age" ng-model="item.age" ng-hide="editPara">
<span class="span info-span" ng-show="editPara">{{item.age}}</span>
</div>
</div>