【问题标题】:rails database operations performed twicerails 数据库操作执行了两次
【发布时间】:2015-05-11 17:38:09
【问题描述】:

我已经关注了 BearGrylls 对这个问题的回答:1

它在 heroku 上运行良好,但在 localhost 上,索引视图中的每个产品都会增加 2。这取决于我在 Ubuntu 14.04 (ruby 2.2.0p0) 上的 Rails 4.2 配置错误还是我错过了什么?

【问题讨论】:

标签: ruby-on-rails ruby heroku


【解决方案1】:

我发现了这个:

bundle exec rake assets:precompile
bundle exec rake assets:clean

清理浏览器的缓存

【讨论】:

  • 有效!谢谢!我花了几天的时间来解决这个问题!
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2020-07-13
相关资源
最近更新 更多