本身不是编程问题,更多的是功能问题。我正在尝试 Django-Oscar,发现它很棒。是否有按类别过滤产品的内置方法?
还有按价格对产品进行分类的内置方法吗?我可以自己构建它,只是询问是否已经有一些功能可用。我尝试阅读它的文档:http ://django-oscar.readthedocs.org/ 。我没有发现什么。
本身不是编程问题,更多的是功能问题。我正在尝试 Django-Oscar,发现它很棒。是否有按类别过滤产品的内置方法?
还有按价格对产品进行分类的内置方法吗?我可以自己构建它,只是询问是否已经有一些功能可用。我尝试阅读它的文档:http ://django-oscar.readthedocs.org/ 。我没有发现什么。
首先安装 Solr 4。例如在 OSX 上,您可以:
$ brew tap homebrew/versions
$ brew install solr4
(必须是 Solr 4 才能使用 Oscar 的现成 conf)
然后获取 Oscar 源代码的副本:
$ git clone https://github.com/django-oscar/django-oscar.git
然后将 Solr 示例站点中的 conf(Solr 服务器默认提供的服务)替换为 Oscar 演示站点中包含的 Solr conf 的符号链接,大致按照 Oscar docs here
首先找到你的 Solr 安装:
$ brew info solr4
homebrew/versions/solr4: stable 4.10.4
Enterprise search platform from Apache Lucene project
https://lucene.apache.org/solr/
Conflicts with: solr
/usr/local/Cellar/solr4/4.10.4 (4658 files, 248M) *
Built from source
然后看看,这里是我符号链接 conf 的地方:
$ ls -l /usr/local/Cellar/solr4/4.10.4/example/solr/collection1/
total 24
-rw-r--r-- 1 me wheel 2146 8 Sep 2014 README.txt
lrwxr-xr-x 1 me wheel 44 7 Jun 13:37 conf -> <path to oscar repo>/sites/demo/deploy/solr
drwxr-xr-x 24 me wheel 816 27 Feb 2015 conf.original
-rw-r--r-- 1 me wheel 16 8 Sep 2014 core.properties
drwxr-xr-x 4 me wheel 136 6 Jun 17:03 data