Kim Majali wrote on 08/06/2022
class Sample(models.Model):
users = models.ManyToManyField(User, blank=True) # if not blank=True it will not be required, null=True is meaningless
Read moreKim Majali wrote on 08/06/2022
context['branch'] = CompanyBranch.objects.filter(company=1).first()
Read moreKim Majali wrote on 07/06/2022
admin.site.site_header= "Pollster Admin"
admin.site.site_title= "Pollster Admin Area"
admin.site.index_title= "Welcome to the Pollster Admin area"
Read moreKim Majali wrote on 07/06/2022
class TextContentAdmin(admin.ModelAdmin):
list_display = ("name", "page", "en_text", "ar_text")
list_filter = ("page",)
Read moreKim Majali wrote on 07/06/2022
from django.contrib import admin
from backoffice.models import *
Read more