You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
xmrauctions/items/forms.py

19 lines
696 B
Python

5 years ago
from django import forms
from items.models import Item, address_is_valid_monero
class CreateItemForm(forms.ModelForm):
payout_address = forms.CharField(validators=[address_is_valid_monero])
class Meta:
model = Item
fields = ['name', 'description', 'whereabouts', 'ask_price_xmr', 'payout_address']
5 years ago
labels = {
'ask_price_xmr': 'Asking Price (XMR)',
'payout_address': 'Payout Wallet Address'
}
help_texts = {
'payout_address': 'Monero address where funds will be sent after sale is confirmed',
'whereabouts': 'A simple pointer to your general region - a nearby ZIP code would be perfect.'
5 years ago
}