<commit_before><!--
  ~ Copyright © 2013 VillageReach.  All Rights Reserved.  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  ~
  ~ If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
  -->

<div xmlns="http://www.w3.org/1999/html">
  <h2><span openlmis-message="label.search.user"></span>
    <a href="#/create-user" class="pull-right btn btn-primary"><span id="user-add-new"
                                                                     openlmis-message="button.add.new"></span></a>
  </h2>

  <div class="alert alert-success" id="saveSuccessMsgDiv" ng-show="userId">
    <span ng-bind="message"></span>.&nbsp;&nbsp;<a href="" ng-click="editUser(userId)"
                                                   openlmis-message="search.viewHere"></a>
  </div>

  <input id="searchUser" class="search-query input-xxlarge" type="text" ng-model="query"
         on-keyup="showUserSearchResults()" openlmis-message="placeholder.user.search"/>

  <div class="form-tip" openlmis-message="search.threeCharacters"></div>
  <div class="facility-list" ng-show="query.length > 2">
    <div ng-switch on="resultCount">
      <h3 ng-switch-when="0" openlmis-message="msg.no.matches|query"></h3>

      <h3 ng-switch-when="1" openlmis-message="msg.one.match|query"></h3>

      <h3 ng-switch-default openlmis-message="msg.many.matches|resultCount|query"></h3>
    </div>
    <a class="close-btn" href="" ng-click="clearSearch()" tabindex="-1"></a>
    <ul class="user-list">
      <li ng-repeat="user in filteredUsers">
        <a href="" ng-click="editUser(user.id)">
          <span class="user-name">{{user.firstName}} {{user.lastName}}</span>
          <span class="user-username">({{user.userName}})</span> -
          {{user.email}}
        </a>

        <div class="user-actions">
          <a href="" class="btn btn-primary btn-small" openlmis-message="button.edit"
             ng-click="editUser(user.id)" tabindex="-1"></a>
          <a href="" class="btn btn-primary btn-small" openlmis-message="button.reset.password"
             ng-click="changePassword(user)" tabindex="-1"></a>
        </div>
      </li>
    </ul>
  </div>

  <div id="changePassword" modal="changePasswordModal" options="{'backdrop':'static', 'escape':false}">
    <form name="passwordForm">
      <div class="modal-header">
        <h3>
          <span openlmis-message="message.reset.password"></span>&nbsp;<span ng-bind="user.firstName"></span>&nbsp;
          <span ng-bind="user.lastName"></span>
        </h3>
      </div>

      <div class="modal-body">
        <div ng-hide="message">
          <form name='ResetPasswordForm'>
              <div class="row-fluid">
                <div class="span12"><commit_msg>|#935| +Rahul| assigning ID to edit user link<commit_after><!--
  ~ Copyright © 2013 VillageReach.  All Rights Reserved.  This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0.
  ~
  ~ If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
  -->

<div xmlns="http://www.w3.org/1999/html">
  <h2><span openlmis-message="label.search.user"></span>
    <a href="#/create-user" class="pull-right btn btn-primary"><span id="user-add-new"
                                                                     openlmis-message="button.add.new"></span></a>
  </h2>

  <div class="alert alert-success" id="saveSuccessMsgDiv" ng-show="userId">
    <span ng-bind="message"></span>.&nbsp;&nbsp;<a href="" ng-click="editUser(userId)"
                                                   openlmis-message="search.viewHere"></a>
  </div>

  <input id="searchUser" class="search-query input-xxlarge" type="text" ng-model="query"
         on-keyup="showUserSearchResults()" openlmis-message="placeholder.user.search"/>

  <div class="form-tip" openlmis-message="search.threeCharacters"></div>
  <div class="facility-list" ng-show="query.length > 2">
    <div ng-switch on="resultCount">
      <h3 ng-switch-when="0" openlmis-message="msg.no.matches|query"></h3>

      <h3 ng-switch-when="1" openlmis-message="msg.one.match|query"></h3>

      <h3 ng-switch-default openlmis-message="msg.many.matches|resultCount|query"></h3>
    </div>
    <a class="close-btn" href="" ng-click="clearSearch()" tabindex="-1"></a>
    <ul class="user-list">
      <li ng-repeat="user in filteredUsers">
        <a id="user{{$index}}" href="" ng-click="editUser(user.id)">
          <span class="user-name">{{user.firstName}} {{user.lastName}}</span>
          <span class="user-username">({{user.userName}})</span> -
          {{user.email}}
        </a>

        <div class="user-actions">
          <a href="" class="btn btn-primary btn-small" openlmis-message="button.edit"
             ng-click="editUser(user.id)" tabindex="-1"></a>
          <a href="" class="btn btn-primary btn-small" openlmis-message="button.reset.password"
             ng-click="changePassword(user)" tabindex="-1"></a>
        </div>
      </li>
    </ul>
  </div>

  <div id="changePassword" modal="changePasswordModal" options="{'backdrop':'static', 'escape':false}">
    <form name="passwordForm">
      <div class="modal-header">
        <h3>
          <span openlmis-message="message.reset.password"></span>&nbsp;<span ng-bind="user.firstName"></span>&nbsp;
          <span ng-bind="user.lastName"></span>
        </h3>
      </div>

      <div class="modal-body">
        <div ng-hide="message">
          <form name='ResetPasswordForm'>
              <div class="row-fluid">
                <div class="span12">
{'fraction_non_alphanumeric': 0.18796592119275826, 'fraction_numerical': 0.011537096201632943, 'mean_word_length': 2.75917278185457, 'pattern_counts': {'":': 0, '<': 131, '<?xml version=': 0, '>': 133, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 10, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1894287', 'n_tokens_mistral': 1815, 'n_tokens_neox': 1754, 'n_words': 333}