简而言之,就是代码中在有使用link_to的时候 ,出现了@url


点此查看原文

If you get this error, and the error message is pointing you to a “link_to” call or something similar, then you may be using an instance variable that’s called ‘@url’ too.

This blog post did talk about the problem but it seemed limited to models only. I finally discovered that, in my case, I was using ‘@url’ in the controller for the view where I was making the ‘link_to’ call.

Long story short, if you see this error, comb through your code (models, controllers and views) for any variables that are called ‘@url’ and change them.

在ActiveAdmin下自定义filter

rails4之后,之前的`model`里加入`search_methods :filter_name`的做法已经失效,需修改为:``` ruby class PromoCode (ids) { with_tags(ids) } def self. …… Continue reading

Mac上搭建Phonegap环境

Published on October 02, 2014

Rails遗留程序里最常犯的错误(译)

Published on July 23, 2014