Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module ApplicationHelper
- def community_posts_path post
- topic = post.topic
- forum = topic.forum
- return community_forum_topics_post_path(forum, topic, post)
- end
- def community_post_path post
- topic = post.topic
- forum = topic.forum
- return community_forum_topic_post_path(forum, topic, post)
- end
- def edit_community_post_path post
- topic = post.topic
- forum = topic.forum
- return edit_community_forum_topic_post_path(forum, topic, post)
- end
- def new_community_post_path
- topic = params[:topic_id]
- forum = params[:forum_id]
- return new_community_forum_topic_post_path(forum, topic)
- end
- end
Add Comment
Please, Sign In to add comment