Sha256: 4507fa2b83a54c787676b028cc6be98b97cf0ddb0a570618287a7c0745bd40e8

Contents?: true

Size: 1.74 KB

Versions: 22

Compression:

Stored size: 1.74 KB

Contents

<%- if user_signed_in? -%>
  <%- unless @bookmark.blank? -%>
    <!-- bookmarked_by_me -->
    <%= form_for(:bookmark, url: bookmark_path(@bookmark, mode: 'tag_edit'), html: { method: :put }) do |f| -%>
      <div>
        <%= f.text_field :tag_list, value: @bookmark.tag_list.join(' '), class: 'editable_text_field' -%>
        <%= submit_tag t('page.update') -%>
        (<a onclick="$.ajax({data:'authenticity_token=' + encodeURIComponent('<%= form_authenticity_token %>'), success:function(request){$('#tag_list').html(request);}, type:'get', url:'<%= manifestation_path(manifestation, mode: 'tag_list') %>'}); return false;" href="#"><%= t('page.cancel') %></a>)
        <br />
        <%= t('tag.use_space_as_delimiter') -%>
      </div>
    <%- end -%>
    <%= javascript_tag("$(function(){$('#bookmark_tag_list').focus()})") %>
  <%- else -%>
    <!-- bookmarked_by_other_patron_or_not_bookmarked -->
    <%= form_for(:bookmark, url: bookmarks_path(mode: 'tag_edit'), html: { method: :post }) do |f| -%>
      <div>
        <%= f.text_field :tag_list, class: 'editable_text_field' -%>
        <%= f.hidden_field :title, value: manifestation.original_title -%>
        <%= f.hidden_field :url, value: manifestation_url(manifestation) -%>
        <%= submit_tag t('page.create') -%>
        (<a onclick="$.ajax({data:'authenticity_token=' + encodeURIComponent('<%= form_authenticity_token %>'), success:function(request){$('#tag_list').html(request);}, type:'get', url:'<%= manifestation_path(manifestation, mode: 'tag_list') %>'}); return false;" href="#"><%= t('page.cancel') %></a>)
        <br />
        <%= t('tag.use_space_as_delimiter') -%>
      </div>
    <%- end -%>
    <%= javascript_tag("$(function(){$('#bookmark_tag_list').focus()})") %>
  <%- end -%>
<%- end -%>

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
enju_bookmark-0.3.2 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.3.1 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.3.0 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.3.0.beta.1 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.2 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.1 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.0 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.0.beta.5 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.0.beta.3 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.0.beta.2 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.2.0.beta.1 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.3 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre23 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre22 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre21 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre20 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre19 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre18 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre17 app/views/manifestations/_tag_edit.html.erb