Open jendiamond opened 9 years ago
I am unclear on whether or not we can view or watch the videos. It looks like u have to be a paid member...or do we have access?
Hey Ken,
The videos should be free to everyone. Here's the link again : https://www.skillshare.com/classes/technology/Ruby-on-Rails-in-3-Weeks-Build-Evernote-Pinterest-and-Wordpress/1493287244?via=search-layout-grid
I know on that site the other tutorials require you to pay, but surprisingly these vids are free.
On Thu, Aug 13, 2015 at 10:12 AM, ken mcfadden notifications@github.com wrote:
I am unclear on whether or not we can view or watch the videos. It looks like u have to be a paid member...or do we have access?
— Reply to this email directly or view it on GitHub https://github.com/LARailsLearners/three-in-one_blog/issues/2#issuecomment-130764389 .
At first I was getting a link to join, but now they seem to be free.
thanks. On 8/13/15 11:23 AM, kkchu791 wrote:
Hey Ken,
The videos should be free to everyone. Here's the link again : https://www.skillshare.com/classes/technology/Ruby-on-Rails-in-3-Weeks-Build-Evernote-Pinterest-and-Wordpress/1493287244?via=search-layout-grid
I know on that site the other tutorials require you to pay, but surprisingly these vids are free.
On Thu, Aug 13, 2015 at 10:12 AM, ken mcfadden notifications@github.com wrote:
I am unclear on whether or not we can view or watch the videos. It looks like u have to be a paid member...or do we have access?
— Reply to this email directly or view it on GitHub
https://github.com/LARailsLearners/three-in-one_blog/issues/2#issuecomment-130764389 .
— Reply to this email directly or view it on GitHub https://github.com/LARailsLearners/three-in-one_blog/issues/2#issuecomment-130788821.
Go to Ruby on Rails in 3 Weeks
Everyone was so on top of it this week why don't we push through and finish the whole thing by next week. Then next week we can start a new one.
We will NOT be coding during the Meetup next time so be sure to finish before then. If you have any questions pose them in the google group.
Do the work for 10-16 in the videos.
10. Add Validation to Blog Posts 11. Edit and Delete Blog Posts 12. Add Comments to Blog Posts 13. Deleting Comments on Blog Posts 14. About Page -- Static Pages and Profile Picture 15. Add Users to Blog, Limit Options to Non-Users 16. Finish Blog App
The repository of the code
The directions from the video are written below.
Remember: $ means type this command in your terminal. Don't type it in. :)
+ Means add this code here. Don't type it in. :)
10. Add Validation to Blog Posts
app/models/post.rb
app/controllers/posts_controller.rb
app/views/posts/new.html.erb
11. Edit and Delete Blog Posts
app/controllers/posts_controller.rb
Create a new file called
app/views/posts/_form.html.erb
app/views/posts/new.html.erb
app/views/posts/new.html.erb
and thenapp/views/posts/_form.html.erb
fileChange the first line in the
app/views/posts/_form.html.erb
fileChange your
app/views/posts/new.html.erb
to look like thisCreate a new file called
app/views/posts/edit.html.erb
Update your
app/views/posts/show.html.erb
to add a link to be able to edit your postUpdate your
app/controllers/posts_controller.rb
to add a the action to be able to delete your postUpdate your
app/views/posts/show.html.erb
to add a link to be able to delete your post12. Add Comments to Blog Posts
Add a new Model called Comment so you can comment on your blog posts
$ rails g model Comment name:string body:string post:references
$ rake db:migrate
Add
has_many :comments
to theapp/models/post.rb
file to associate the post with the commentsUpdate your
config/routes.rb
file to add a link to nest the Comments into the PostsCreate the Comments Controller
$ rails g controller Comments
Update your new Comments Controller
app/controller/comment_controller.rb
to add a create actionCreate
app/views/comments/_form.html.erb
Create
app/views/comments/_comment.html.erb
Update
app/views/posts/show.html.erb
13. Deleting Comments on Blog Posts
Update your Comments Controller
app/controller/comment_controller.rb
to add a delete actionUpdate your
app/views/comments/_comment.html.erb
so you can delete a comment14. About Page -- Static Pages and Profile Picture
Update your
app/models/post.rb
to includedependent: :destroy
to make sure that when the post is deleted that all the associated comments are also deletedCreate a Pages Controller
$ rails g controller pages
In your new
app/controller/pages_controller.rb
add an about actionUpdate your
config/routes.rb
file to add a link to the About PageUpdate your
app/views/layouts/application.html.erb
Create
app/views/pages/about.html.erb
Add an image called
profile.jpg
inapp/assets/images
15. Add Users to Blog, Limit Options to Non-Users
Get the most recent version of the Devise Gem and Add it to your Gemfile
Bundle your
Gemfile
$ bundle
Re-Start your server
$ rails g devise:install
Add this line to the bottom of your
config/environments/development.rb
Wrap the
app/view/devise/sessions/new.html.erb
in<div id="page_wrapper"> code</div>
Add a before_action to your
app/controller/post_controller.rb
Add some authentication to
app/views/layouts/application.html.erb
using Devise methodsUpdate your
app/views/posts/show.html.erb
to only allowe a signed in user to be able to delete or edit a postUpdate your
app/views/comments/_comment.html.erb
to only allow a signed in user to be able to delete or edit a post16. Finish Blog App
You are finished! :)
Add more functionality
Add Tests
Or just move on to the Pinterest App