Sha256: d082d2726102e416021820eea8dc7d7a99cc112d9e2c53468ea05f846e4dd055

Contents?: true

Size: 1.78 KB

Versions: 25

Compression:

Stored size: 1.78 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("$('#bookmark_tag_list').focus()") -%>
  <%- else -%>
    <!-- bookmarked_by_other_patron_or_not_bookmarked -->
    <%= form_for(:bookmark, :url => user_bookmarks_path(current_user, :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("$('#bookmark_tag_list').focus()") -%>
  <%- end -%>
<%- end -%>

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
enju_bookmark-0.1.2.pre2 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.2.pre app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.1 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.0.pre app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.1.0 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.22 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.21 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.20 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.19 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.18 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.17 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.16 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.15 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.14 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.13 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.12 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.11 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.10 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.9 app/views/manifestations/_tag_edit.html.erb
enju_bookmark-0.0.8 app/views/manifestations/_tag_edit.html.erb