#wzc: 评论相关的表单定义
from django import forms
from django.forms import ModelForm

from .models import Comment


class CommentForm(ModelForm):
    """wzc: 评论表单，支持父评论ID"""
    parent_comment_id = forms.IntegerField(
        widget=forms.HiddenInput,
        required=False,
        help_text="wzc: 父评论ID，用于回复功能"
    )

    class Meta:
        model = Comment
        fields = ['body']