You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
18 lines
386 B
18 lines
386 B
from django import forms |
|
from django.contrib.auth import models as auth_models |
|
|
|
from .models import Article |
|
|
|
|
|
class ArticleForm(forms.ModelForm): |
|
class Meta: |
|
model = Article |
|
fields = ('body', 'link',) |
|
|
|
|
|
class UserForm(forms.ModelForm): |
|
password = forms.PasswordInput() |
|
|
|
class Meta: |
|
model = auth_models.User |
|
fields = ('username', 'password',)
|
|
|