{{!
This file is part of Moodle - http://moodle.org/

Moodle is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

Moodle is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with Moodle.  If not, see <http://www.gnu.org/licenses/>.

@template local_ascend_rewards/admin_dashboard_award
@copyright 2026 Elantis (Pty) LTD
@license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
}}
<h2>{{award_heading}}</h2>
<div class="card">
  <form method="post" data-award-form="1">
    <input type="hidden" name="tab" value="award">
    <input type="hidden" name="sesskey" value="{{sesskey}}">
    <div class="form-group">
      <label class="form-label">{{user_label}}:</label>
      <input type="text" name="userid" class="form-input" list="users" required placeholder="{{user_search_placeholder}}">
      <datalist id="users">
        {{#users_list}}
          <option value="{{label}}"></option>
        {{/users_list}}
      </datalist>
    </div>
    <div class="form-group">
      <label class="form-label">{{course_label}}:</label>
      <input type="text" id="courseid_input" name="courseid" class="form-input" list="courses" required placeholder="{{course_search_placeholder}}">
      <datalist id="courses">
        {{#courses_list}}
          <option value="{{label}}"></option>
        {{/courses_list}}
      </datalist>
    </div>
    <div class="form-group">
      <label class="form-label">{{badge_label}}:</label>
      <input type="text" id="badgeid_input" name="badgeid" class="form-input" list="badges" required placeholder="{{badge_search_placeholder}}">
      <datalist id="badges">
        {{#badges_list}}
          <option value="{{label}}"></option>
        {{/badges_list}}
      </datalist>
    </div>
    <button type="submit" name="action" value="award" class="btn btn-primary">{{award_button_label}}</button>
    <button type="submit" name="action" value="revoke" class="btn btn-secondary">{{revoke_button_label}}</button>
  </form>
</div>
