2010-07-30 148 views
1

我有一个'页面'控制器与一些静态页面,而不是使用其余方法(显示,索引等)。(ActionView :: MissingTemplate)将应用程序部署到heroku时出错

的静态文件查看罚款我的本地计算机上,但与Heroku的部署时,我得到了以下错误:

PagesController#used_cars_south_wales (ActionView::MissingTemplate) "Missing template pages/used_cars_south_wales.erb in view path app/views"

任何人都得到了同样的问题,知道的任何建议。

回答

2

错误消息说明了我的一切。 Heroku Rails正在寻找app/views/pages/used_cars_south_wales.html.erb,但它显然没有找到它。如果它在本地工作,那么该文件确实存在。在Heroku上没有工作表明它没有被添加,并在推送你的应用程序前致力于git repo。

$ git add app/views/pages/used_cars_south_wales.html.erb 
$ git commit -m "some comment..." 
$ git push heroku master 
+0

嘿那就是诀窍。我是heroku和git的新手,我承诺进行更改并且不添加文件。非常感谢。 – lyntaff 2010-07-30 12:57:32

相关问题