Added all the functionality of app and admin

This commit is contained in:
bobbyvish
2024-03-11 14:48:48 +05:30
parent 69dbc56374
commit fd4aef5a40
92 changed files with 8931 additions and 716 deletions

View File

@@ -68,16 +68,4 @@ class FaqsForm(forms.ModelForm):
# "faq_category",
"question",
"answer",
"active",
]
# labels = {"faq_category": "Category"}
def __init__(self, *args, **kwargs):
instance = kwargs.get("instance")
super().__init__(*args, **kwargs)
# Fetch the choices for the faq_category field from the database
# self.fields["faq_category"].queryset = FaqCategory.objects.all()
if instance is None:
# This is an add operation, exclude the 'active' field
self.fields.pop("active")