Yes, it's possible to write this code without using regexp, and it should
work the same.
If you have a look at the source code of the routers, there's a method
`get_urls` in SimpleRouter (you can find it here
https://github.com/encode/django-rest-framework/blob/master/rest_framework/routers.py)
I cannot see any reply
On Thursday, May 23, 2019 at 7:56:54 AM UTC+5:30, Kevin Jay wrote:
>
> kevin@kjay,net
>
> On Wed, May 22, 2019 at 10:19 AM Rounak Jain > wrote:
>
>>
>> I am using DRF Viewsets to auto-generate URLs for different views. Is it
>> possible to write the code below without usi
kevin@kjay,net
On Wed, May 22, 2019 at 10:19 AM Rounak Jain wrote:
>
> I am using DRF Viewsets to auto-generate URLs for different views. Is it
> possible to write the code below without using regex?
> Thanks
>
> from .views import TaskViewSet
> from rest_framework.routers import DefaultRouter
>
Thanks for the reply. I understand how to use them in urls.py when creating
normal routes but here in case of drf, it would help if you could show me
how to do it
On Wed, May 22, 2019 at 10:11 PM Onasanya Tunde
wrote:
> Use Django2.X
>
> --
> You received this message because you are subscribed
Use Django2.X
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@google
I am using DRF Viewsets to auto-generate URLs for different views. Is it
possible to write the code below without using regex?
Thanks
from .views import TaskViewSet
from rest_framework.routers import DefaultRouter
router = DefaultRouter()
router.register(r'', TaskViewSet, basename='task')
urlpatt
6 matches
Mail list logo