Skip to content

Freelancing Digest

Menu
  • Past Issues
  • Articles
  • About Me
    • Hire Me
    • Contact Me

Redmine Refactor #132: Convert Timelogs to REST Resource

Now that TimelogController has most of the REST actions it needs, I’m able to convert it to a REST resource. Before 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 # config/routes.rb …

Read more

  • redmine
  • refactoring
  • ruby

Refactoring Redmine – the first 30 days

It’s hard to believe that a little over one month ago, I unveiled Refactoring Redmine to my private mailing list. Part of me feels like the book has always been for sale, while another part of me feels like it just launched last week… Since I’m open with much of my business, I wanted to …

Read more

  • rails
  • refactoring redmine
  • ruby

Redmine Refactor #131: Extract Method TimelogController#edit to TimelogController#update

Finally, today I was able to refactor enough of TimelogController in order to start removing the extra code from #edit. Using extract method I pulled out the #update method that will perform the actual database saves for a TimeEntry. Before 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 …

Read more

  • extract-method
  • redmine
  • refactoring
  • ruby

Redmine Refactor #130: Extract Method TimelogController#edit to TimelogController#new

Yesterday’s refactoring of TimelogController#edit took care of it’s first action. Now I need to use extract method again to pull out the “save new TimeEntry” action (#create). Before 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 class TimelogController [:new, :edit, :destroy]   def edit (render_403; return) …

Read more

  • extract-method
  • redmine
  • refactoring
  • ruby

Refactoring Rails Guest Post on RailsInside.com

My guest post The First Step of Refactoring a Rails Application was just posted to RailsInside.com last night. I’m going to write more posts in the series over the next few weeks. If you have a refactoring question that you want me to answer, let me know in the comments.

Read more

  • rails
  • refactoring
  • ruby
Posts navigation
Newer posts
Older posts

About Eric | Twitter | Google Plus
Best of Eric Davis | Best of Freelancing | Best of Product Business | Best of Ruby and Rails Programming
Privacy Policy | Terms of Use | A Little Stream Software website

Want to transition from coder to consultant? Learn more: