23 lines
919 B
HTML
23 lines
919 B
HTML
<ul>
|
|
<li ng-repeat="(rk, room) in rooms">
|
|
<span ng-if="!room.edit" ng-bind="room.label"></span>
|
|
<button type="button" class="btn btn-sm btn-primary" ng-click="editRoom()" ng-if="!room.edit">
|
|
<span class="glyphicon glyphicon-edit" aria-hidden="true"></span>
|
|
</button>
|
|
<button type="button" class="btn btn-sm btn-danger" ng-click="delRoom(rk)" ng-if="!room.edit">
|
|
<span class="glyphicon glyphicon-remove" aria-hidden="true"></span>
|
|
</button>
|
|
<form ng-if="room.edit" ng-submit="saveRoom()">
|
|
<input ng-model="room.label" autofocus>
|
|
<button type="submit" class="btn btn-sm btn-success">
|
|
<span class="glyphicon glyphicon-check" aria-hidden="true"></span>
|
|
</button>
|
|
</form>
|
|
</li>
|
|
<li>
|
|
<button type="button" class="btn btn-sm btn-dark" ng-click="newRoom()">
|
|
<span class="glyphicon glyphicon-plus" aria-hidden="true"></span>
|
|
</button>
|
|
</li>
|
|
</ul>
|