Sha256: b777e4d576c48f0eb66924b10dcb23957dfc1c7bf1f75a2beee45a7f180c6a39

Contents?: true

Size: 964 Bytes

Versions: 1

Compression:

Stored size: 964 Bytes

Contents

<div id="post_topics">
	<h4>Topics</h4>
	<ol>
		<li class='select_list'>
			<%= select_tag :topics, options_for_select(Topic.for_editing(resource_class, resource).collect{ |t| [t.title, t.id.to_s] }), id: 'all_topics_list' %>
			<%= link_to 'Add', '#', class: 'add_to_list icon_add ui-button', id:'add_topic_link', data: { ui_icon: 'plus' } %>
		</li>
		<li id="topic_selections" rel="<%= "post[topics][]" %>">
			<ul>
				<% form.object.topics.each do |topic| %>
				<li rel="<%= topic.id.to_s %>">
					<%= topic.title %>
					<%= hidden_field_tag "post[topics][]", topic.id.to_s %>
					<%= link_to 'Remove', '#', class: 'icon_delete remove_from_list' %>
				</li>
				<% end %>
			</ul>
		</li>
	</ol>
	<script type="text/javascript" charset="utf-8">
	//<![CDATA[
		jQuery('#all_topics_list').selectToList({ 
			target:'#topic_selections ul', 
			name:  jQuery('#topic_selections').attr('rel'), 
			add:   jQuery('#add_topic_link') });
	//]]>
	</script>
</div>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
transit-0.0.2 app/views/transit/topics/manage.html.erb