init
Some checks failed
Build And Test / build-and-push (push) Failing after 53s

This commit is contained in:
2024-12-13 17:12:03 +09:00
parent a27be94b19
commit ea11832a53
695 changed files with 71766 additions and 1 deletions

14
blog/forms copy.py Normal file
View File

@ -0,0 +1,14 @@
from django import forms
from .models import Post
class PostForm(forms.ModelForm):
class Meta:
model = Post
# fields = ['title', 'content', 'summary', 'tags', 'image']
fields = ['title', 'content', 'summary', 'tags']
widgets = {
'title': forms.TextInput(attrs={'class': 'form-control'}),
'summary': forms.Textarea(attrs={'class': 'form-control'}),
'content': forms.Textarea(attrs={'class': 'form-control', 'id': 'id_content'}),
'tags': forms.TextInput(attrs={'class': 'form-control'}),
}