byteweaver / django-coupons Goto Github PK
View Code? Open in Web Editor NEWA reuseable Django application for coupon gereration and handling.
License: BSD 3-Clause "New" or "Revised" License
A reuseable Django application for coupon gereration and handling.
License: BSD 3-Clause "New" or "Revised" License
While installing this package on Django 3, it gives such an error in models.py file
`import random
from django.conf import settings
from django.db import IntegrityError
from django.db import models
from django.dispatch import Signal
from django.utils.encoding import python_2_unicode_compatible #this gives an error
from django.utils import timezone
from django.utils.translation import ugettext_lazy as _
`
I do not see any save methods or anything in the code. The closest I can find is the redeem function in the model for Coupon
. Can you provide some guidance as to how a user can actually redeem their code?
More of a feature request. It would be nice if you can make a campaign in which only one code from said campaign can be ushered by a user. Say you want a user to be able to use either a 25% off code or a flat $10 off code but they will have to choose 1 or the other and cannot use both.
If it is not possible now I think it would be a great addition.
Add time range during which a code is valid
add option that makes a single coupon usable by multiple unique users
I am not familiar to djingo.
My question is , when I git clone it from website, how can i run it ?
I have using python setup.py build and python setup.py install
It seems that the module hosted via pip is old and throws error for Django 1.11. However, the code seems updated.
I installed this via a fork from this repo and merged it up with another fork that works better than this one for my needs
I would like to do something like
from src.django_coupons.coupons.models import foobar
I would like to know how to use this module programmatically to create coupons on demand based on actions.
Hi, guys! You've wrote that this package could be used for unlimited coupons - everybody can use it, but individually only once. But there is no any code that explicitly implements this case.
This case could be implemented by creating extra coupons by redeem_done
signal. But code
field is unique!
If I want to limit the quantity of the coupon that can be redeem, how I can achieve that?
add some campaign or tag field to group coupons for analytics
I've noticed the Pypi package is a bit dated, 2015-11-20, any plans to release a new version? Current master seems to support Django 1.10 while Pypi's version doesn't.
Lastly, is this project still being used / maintained?
Thanks!
Hi,
If the setting COUPONS_COUPON_TYPES
is set it will generate additional django-coupons
migrations, because it's being used as an input to modelfield type
in models.py#L73:
type = models.CharField(_("Type"), max_length=20, choices=COUPON_TYPES)
This is not ideal as it can break a user app if django-coupons
add migrations in the future. I suggest choices
are only applied to form and not the coupon model.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.