Ruby on Rails Community Forum
let users edit their own posts
2
General
I currently have it setup to where only the admin can edit posts, but would like if the user can edit their posts but no other posts that were not made by them.
Forum Posts Controller
class Forum...
Chris Oliver replied
Updating Forum_Posts getting routes error
2
General
app/views/forum_posts/_forum_post.html.erb
<%= div_for @forum_post do %>
<%= image_tag forum_post.user(:size => 65), :class => "img-circle avatar" %>
Posted by <%= forum_post...
Erick Sitter replied
Checking if Forum_Thread is updating?
3
General
Now the actual update is simple it's just @forum_thread.update params and redirect, but as you can see it redirects to the forum_thread which renders the show.html.erb which then causes @forum_pos...
Chris Oliver replied
Devise no current_user data after update
1
Gems / Libraries
Forum Threads Controller
class ForumThreadsController < ApplicationController
before_action :authenticate_user!, except: [:index, :show]
before_action :set_forum_thread, except: [:index, :new, ...
Chris Oliver replied
Updating forum thread creates new post...
0
General
Forum Thread Controller
class ForumThreadsController < ApplicationController
before_action :authenticate_user!, except: [:index, :show]
before_action :set_forum_thread, except: [:index, :ne...
Erick Sitter posted
How would i go with making an inventory for products?
4
General
I'm not sure if i'm saying it right but how can i manage inventory for my products? What are some steps that i have to take to get started?
Chris Oliver replied
No action "edit" in forum_posts_controller
0
General
Forum_Posts Controller
class ForumThreads::ForumPostsController < ApplicationController
before_action :authenticate_user!
before_action :set_forum_thread
def create
@forum_post = @for...
Erick Sitter posted
undefined method username after update
0
General
Forum_threads Controller
class ForumThreadsController < ApplicationController
require 'forum_controller'
before_action :authenticate_user!, except: [:index, :show]
before_action :set_foru...
Erick Sitter posted
How do I implement Facades Pattern on a already advanced Ruby on Rails project?
2
General
A few days ago read the [four rules for developers](https://robots.thoughtbot.com/sandi-metz-rules-for-developers) and the Facade Pattern got my attention, however, find it somehow complicated to i...
Andres Max replied
Forum_posts edit coming up as nil
2
General
ActionView::Template::Error (First argument in form cannot contain nil or be empty):
1: <%= form_for [@forum_thread, @forum_post] do |f| %>
2: Reply to thread
3:
4: ...
Erick Sitter replied
Number of posts on index / Posts pagination
2
Rails
I followed your forum series and it's going to work out well for me, but I couldn't figure out how to display the number of posts on the main index for each forum thread.
I'd think it would hav...
Erick Sitter replied
Backend and Frontend co-operation
1
General
In our rails applications, I generally work on the backend (models and controllers) while another developer focuses on the (Views + JS magic).
Generally he gets all the fields available from a mod...
Chris Oliver replied
Facets with Searchkick
8
General
Great job on the Searchkick tutorial! However, I'm really interested in faceted search for an application I'm building, and the documentation on the internet is not really good enough. Any ideas? T...
Simon Cooper replied
Orders and Order Items
2
General
I have 2 models, Orders and Order Items.
I want the user to be able to add any number of items to an order in the view. How can I structure a form so that I can iterate over the order items or is ...
Michael Victor replied
Subdomains Email reset with Devise
1
Gems / Libraries
Hi Chris so im trying to work with subdomain and maindomain email reset password
I use the code on devise and for subdomain work like a charm but for the main domain I get this erro because they do...
Chris Oliver replied
Could you do a screencast on how to build notifications with Rails?
9
General
I've been trying to add a notification system (bell icon on the header) to the app I'm building. The implementation I came up with is very awkward and I'm sure there's a better way to do it (maybe ...
Chris Oliver replied
What are the benefits of using rails-assets version of Bootstrap over bootstrap-sass version?
2
General
And for other JS libraries as well.
[Screencast](https://gorails.com/episodes/rails-assets)
Dan K replied
How about an episode on zero-downtime deployment?
3
General
I have a Rails app on Heroku running on just 2 web dynos (Standard type).
I'd like to know how best to ensure uninterrupted access to the app for my users while also allowing me to deploy any time...
Chris Oliver replied
Activity Feed with Public Activity Gem ?
1
Gems / Libraries
Hi Chris,
Thanks for the tutorial. It really helped me a lot. Can you please post a video about How to install the public activity gem to show all the activities done by the user. Thanks a lot again.
Chris Oliver replied
Firefox rendering issues
1
General
The site - leanhire.co that I'm working on seems to render perfectly on Chrome but it seems to be a mess when I view the site via Firefox.
What do you think is missing and what is the best way to ...
Chris Oliver replied