event-info.html 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <div class="container">
  2. <h1>{{event.title}}
  3. <button ng-if="event._id" ng-click="$state.go('event.edit', {id: event._id})" class="btn btn-success">
  4. <span class="glyphicon glyphicon-plus-sign"></span>
  5. {{'Edit' | translate}}
  6. </button>
  7. </h1>
  8. <div class="panel panel-primary table-striped top5">
  9. <div class="panel-heading">{{'Persons' | translate}}</div>
  10. <div class="panel-body">
  11. <form class="form-inline">
  12. <div class="form-group">
  13. <label for="query-persons">{{'Search:' | translate}}</label>
  14. <input type="text" id="query-persons" class="form-control" placeholder="Name or email" ng-model="query">
  15. </div>
  16. <div class="form-group">
  17. <label for="persons-order">{{'Sort by:' | translate}}</label>
  18. <select id="persons-order" class="form-control" ng-model="orderProp">
  19. <option value="name" ng-selected="selected">{{'Alphabetical' | translate}}</option>
  20. <option value="_id">{{'ID' | translate}}</option>
  21. </select>
  22. </div>
  23. </form>
  24. <table class="table table-striped">
  25. <thead>
  26. <tr>
  27. <th>{{'Person' | translate}}</th>
  28. <th>{{'Attended' | translate}}</th>
  29. <th>{{'Actions' | translate}}</th>
  30. </tr>
  31. </thead>
  32. <tbody>
  33. <tr ng-repeat="person in event.persons | filter:query | orderBy:orderProp">
  34. <td><a href="/#/persons/{{person.person_id}}">{{person.name}} {{person.surname}}</a></td>
  35. <td>
  36. <button class="btn btn-link" name="switch-attended" ng-click="updateAttendee(person, !person.attended)"><span class="glyphicon {{(person.attended) && 'glyphicon-ok-sign text-success' || 'glyphicon-remove-sign text-danger'}}"></span></button>
  37. </td>
  38. <td>
  39. <button ng-click="removeAttendee(person)" type="button" class="btn btn-link glyphicon glyphicon-trash"></button>
  40. </td>
  41. </tr>
  42. </tbody>
  43. </table>
  44. </div>
  45. </div>
  46. </div>