To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / app / views / users / new.html.erb @ 1298:4f746d8966dd
History | View | Annotate | Download (1.16 KB)
| 1 | 909:cbb26bc654de | Chris | <h2><%= link_to l(:label_user_plural), users_path %> » <%=l(:label_user_new)%></h2> |
|---|---|---|---|
| 2 | 37:94944d00e43c | chris | |
| 3 | 1115:433d4f72a19b | Chris | <%= labelled_form_for @user do |f| %>
|
| 4 | 909:cbb26bc654de | Chris | <%= render :partial => 'form', :locals => { :f => f } %>
|
| 5 | <% if email_delivery_enabled? %>
|
||
| 6 | <p><label><%= check_box_tag 'send_information', 1, true %> <%= l(:label_send_information) %></label></p> |
||
| 7 | <% end %>
|
||
| 8 | <p>
|
||
| 9 | <%= submit_tag l(:button_create) %>
|
||
| 10 | <%= submit_tag l(:button_create_and_continue), :name => 'continue' %>
|
||
| 11 | </p>
|
||
| 12 | 37:94944d00e43c | chris | <% end %>
|
| 13 | 1295:622f24f53b42 | Chris | |
| 14 | <% if @auth_sources.present? && @auth_sources.any?(&:searchable?) %>
|
||
| 15 | <%= javascript_tag do %>
|
||
| 16 | observeAutocompleteField('user_login', '<%= escape_javascript autocomplete_for_new_user_auth_sources_path %>', {
|
||
| 17 | select: function(event, ui) {
|
||
| 18 | $('input#user_firstname').val(ui.item.firstname);
|
||
| 19 | $('input#user_lastname').val(ui.item.lastname);
|
||
| 20 | $('input#user_mail').val(ui.item.mail);
|
||
| 21 | $('select#user_auth_source_id option').each(function(){
|
||
| 22 | if ($(this).attr('value') == ui.item.auth_source_id) {
|
||
| 23 | $(this).attr('selected', true);
|
||
| 24 | $('select#user_auth_source_id').trigger('change');
|
||
| 25 | } |
||
| 26 | }); |
||
| 27 | } |
||
| 28 | }); |
||
| 29 | <% end %>
|
||
| 30 | <% end %> |