Django 购物车/篮解决方案(或者我应该 DIM)?
我即将建立一个网站,其中包含大约六种相当相似的产品。 它们都是 DVD,因此它们非常适合非常“固定”的数据库。 我本来打算制作一个 DVD 模型。 给它们贴上标签。 一切都很简单。 一切都很容易。
但我们需要能够出售它们。 当前网站将整个采购系统外包,但这在新网站上不会实现。 我们希望整合一切,直到付款(出于用户体验原因,加上我们可以更多地定制流程)。
外包问题的另一个问题是,它没有考虑到不需要缴纳增值税(销售税)的人,也没有考虑到如果您购买多于一件或多件相同的东西,您可以获得折扣的事实同时SKU。
所以我一直在四处寻找。
Satchmo 看起来就像一个完整的迷你框架。 它具有我所处理的 SKU 数量不需要的列表选项。
django-cart 从三月份开始已经被重新哈希,但从那时起它看起来就被废弃了。
我正在寻找可以让我执行以下操作的内容:
- 向其传递模型实例、价格和数量
- 应用基于唯一 SKU 数量的数量公式以及同一标题
- 列表中的副本 每个页面上的购物车中的内容
就这样(不过,这还是相当麻烦的)。 我可以处理最终的订单处理废话。
或者我只是很傻?
我应该继续自己做吗? 如果这是你的投票,我以前从未制造过购物车,那么对于以前只使用过购物车的人来说,是否有任何考虑因素不明显?
I'm about to build a site that has about half a dozen fairly similar products. They're all DVDs so they fit into a very "fixed" database very well. I was going to make a DVD model. Tag them up. All very simple. All very easy.
But we need to be able to sell them. The current site outsources the whole purchasing system but that's not going to fly on the new site. We want to integrate everything right up until the payment (for both UX reasons plus we get to customise the process a lot more).
The other problem with the outsourced problem is it doesn't account for people that don't need to pay VAT (sales tax) or for the fact you get a discounts if you buy more than one of the same thing, or more than one SKU at the same time.
So I've been looking around.
Satchmo looks like a whole mini-framework. It has listing options that I just don't need with the quantities of SKUs I'm dealing with.
django-cart has been re-hashed as of March but it looks pretty abandoned since then.
I'm looking for something that will let me:
- pass it a model instances, a price and a quantity
- apply a quantities formula based on the number of unique SKUs and copies in the same title
- list what's in the cart on every page
That's about it (but it's quite fiddly, nevertheless). I can handle the final order processing nonsense.
Or am I just being silly?
Should I just get on and Do It Myself? If that's your vote, I've never built a cart before so are there any considerations that are not obvious to somebody who has only used shopping carts before?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
既然你问:如果你的需求那么有限,那对我来说听起来确实像是一个 DIY 的情况。 我不明白这有什么奇怪的; 定价公式有多复杂,您都计划以任何一种方式提供。 添加 Django 的内置会话支持,您就已经完成了大部分工作。
Since you asked: if your needs are that limited, it does sound like a DIY situation to me. I don't see what's so fiddly about it; what complexity there is is all in the pricing formula, and you're planning to supply that either way. Add in Django's built-in session support and you're most of the way there.
有一个可用的开源解决方案:http://www.getlfs.com
我不知道您是否可以调整它以适合您,但它基于您提到的技术。 该许可证非常自由并且得到大力维护。
There is an open source solution available: http://www.getlfs.com
I don't know if you could tweak it to suit you but it's based on the technologies you mention. The license is very liberal and it is heavily maintained.