Hi,

as written on the ticket already you have to present __why__ and __what__ 
your class based view makes easier. As it currently stands I cannot see 
anything which you couldn't also achieve by "inheriting" the function based 
view.

Cheers,
Florian

On Thursday, April 11, 2019 at 11:05:36 PM UTC+2, Thomas Turner wrote:
>
>
> Hi all
>
> I want to make a case for converting the Serve Static to Class Base View 
> it is ticket number 30344 https://code.djangoproject.com/ticket/30344
>
>
> I am the maintainer of a project called Django Tenants ​
> http://github.com/tomturner/django-tenants which allows you to have 
> tenants in Django ie a.mydomain.com and b.mydomain.com. The problem I 
> have is that on the different domains I want to serve different static 
> files. The problem is I cant pick up the domain and set the correct tenant 
> for static files. I believe this could be done easier if the serve static 
> is class based. Making the serve static class base will not affect users of 
> Django and I know a lot of other areas in Django have been converted to 
> class base views such as the admin
>
>
> I believe one could override the entry point could be manual added to a URL
>
>
> re_path(r'^site_media/(?P<path>.*)$', 
> static.ServeStatic.as_view(document_root=media_dir, show_indexes=True))
>
>
> I know server static should only be used for development use only.
>
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/2236b26f-51d7-4cad-a986-e6726e7ac192%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to