Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
thalia
concrexit
Commits
e0e1d321
Commit
e0e1d321
authored
Sep 10, 2018
by
Thom Wiggers
📐
Browse files
Merge branch 'docs/payments' into 'master'
Complete docs for payments package Closes
#580
See merge request
!937
parents
aca5a3b3
30be2755
Changes
2
Hide whitespace changes
Inline
Side-by-side
website/payments/models.py
View file @
e0e1d321
...
...
@@ -9,6 +9,9 @@ from django.utils.translation import ugettext_lazy as _
class
Payment
(
models
.
Model
):
"""
Describes a payment
"""
id
=
models
.
UUIDField
(
primary_key
=
True
,
default
=
uuid
.
uuid4
,
editable
=
False
)
...
...
website/payments/widgets.py
View file @
e0e1d321
"""Widgets provided by the payments package"""
from
django.forms
import
Widget
from
payments.models
import
Payment
class
PaymentWidget
(
Widget
):
"""
Custom widget for the Payment object, used in registrations
"""
template_name
=
'payments/widget.html'
def
value_from_datadict
(
self
,
data
,
files
,
name
):
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment