From 5ac4d065e2b04ca9a62ae0b1677441adb25d0cd0 Mon Sep 17 00:00:00 2001 From: Harry Bomrah Date: Wed, 18 Jun 2014 17:54:54 +0800 Subject: [PATCH] fixed bug for autocomplete in member personal journals --- .../_author_autocomplete.html.erb | 57 +++++++++---------- app/views/admin/journal_papers/_form.html.erb | 4 +- 2 files changed, 29 insertions(+), 32 deletions(-) diff --git a/app/views/admin/journal_papers/_author_autocomplete.html.erb b/app/views/admin/journal_papers/_author_autocomplete.html.erb index bf8902b..1c0226c 100644 --- a/app/views/admin/journal_papers/_author_autocomplete.html.erb +++ b/app/views/admin/journal_papers/_author_autocomplete.html.erb @@ -1,34 +1,33 @@ \ No newline at end of file diff --git a/app/views/admin/journal_papers/_form.html.erb b/app/views/admin/journal_papers/_form.html.erb index 5a99891..28c2824 100644 --- a/app/views/admin/journal_papers/_form.html.erb +++ b/app/views/admin/journal_papers/_form.html.erb @@ -88,7 +88,7 @@
- <%= f.text_field :member_profile_id, id: "search", autocomplete: "off", data: { provide: "typeahead"}, class: "input-block-level", value: (@journal_paper.member_profile.name rescue nil), placeholder: t("personal_journal.author")%> + <%= f.text_field :member_profile_id, id: "member_autocomplete", autocomplete: "off", data: { provide: "typeahead"}, class: "input-block-level", value: (@journal_paper.member_profile.name rescue nil), placeholder: t("personal_journal.author")%> <%= f.hidden_field :member_profile_id, value: (@journal_paper.member_profile_id ? @journal_paper.member_profile_id : ""), id: "member_value" %>
@@ -311,8 +311,6 @@ <%= f.submit t('submit'), class: 'btn btn-primary' %> <%= link_to t('cancel'), get_go_back, :class=>"btn" %>
- - <%= render 'author_autocomplete'%>