angular-utils-pagination的分页控件依赖于dirPagination.tpl.html。我使用bower在bower_components中安装了它。因此,树结构是
vendor
└── assets
├── bower_components
├── angular-utils-pagination
├── README.md
├── bower.json
├── dirPagination.js
└── dirPagination.tpl.htmlconfig/application.rb
config.assets.paths << Rails.root.join('vendor','assets','bower_components')
config.assets.precompile << %r(.*.(?:eot|svg|ttf|woff|html)$)当我将应用程序部署到生产环境中时,资产预编译会生效,并将dirPagination.tpl.html复制到public/assets/angular-utils-pagination/dirPagination.tpl-8832242a2286b6a5e4623e6597069175.html。当angular试图包含该文件时,应用程序会给出404。
我如何告诉angular从哪里访问这个文件?
发布于 2016-01-19 00:41:11
我使用以下指令
<dir-pagination-controls boundary-links="true" on-page-change="pageChangeHandler(newPageNumber)" **template-url="Templates\dirPagination.tpl.html"**>
它对我来说很好
https://stackoverflow.com/questions/29015136
复制相似问题