2025.09.17-19:07:57
This commit is contained in:
26
tinywiki/forms.py
Normal file
26
tinywiki/forms.py
Normal file
@@ -0,0 +1,26 @@
|
||||
from django import forms
|
||||
from .models import Page,Image
|
||||
|
||||
class PageForm(forms.ModelForm):
|
||||
class Meta:
|
||||
model = Page
|
||||
fields = [
|
||||
'title',
|
||||
'slug',
|
||||
'status_data',
|
||||
'content_type_data',
|
||||
'content',
|
||||
]
|
||||
|
||||
class PageAdminForm(forms.ModelForm):
|
||||
class Meta:
|
||||
model = Page
|
||||
fields = [
|
||||
'title',
|
||||
'author',
|
||||
'slug',
|
||||
'status_data',
|
||||
'content_type_data',
|
||||
'content',
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user