理解Django Forms源代码中的"_html_output()"



以下源代码来自django/forms/forms.py

class BaseForm(RenderableFormMixin):
def _html_output(self, normal_row, error_row, row_ender, help_text_html, errors_on_separate_row):
"Output HTML. Used by as_table(), as_ul(), as_p()."

as_table(), as_ul(), as_p()是如何使用/调用这个私有方法_html_output()的?我没有从源代码中找到。

该方法不再使用

https://docs.djangoproject.com/en/4.0/releases/4.0/#id2

由于表单呈现现在使用模板引擎,即未记录的BaseForm_html_output((辅助方法已弃用

最新更新