Personally I think the code has a very weird "smell"... Assuming you don't
have any way of rewriting the calling code and are stuck with editing this
single method, I'd suggest something along the lines of:
@staticmethod
def in_circle_check(obj_type, item, uuid):
if obj_type not in ['trees', '
est-framework.org/api-guide/views/
>>>
>>> On Tue, 19 Jul 2022 at 06:38, Nikhil Chawla
>>> wrote:
>>>
>>>> Don't clutter the django views with DRF requests. Keep them separate,
>>>> available at, say `api` endpoints.
>>&g
ssions and serializers mentioned above,
as well as any additional actions that didn't fit within the normal REST
verbs
4) Created a router and registered the viewsets with it
5) Added the router's urls into the projects url configuration
I hope that's useful :)
Kind Regards,
Michael Thomas
to get wrong, in my opinion at least!
Kind Regards,
Michael Thomas
On Thu, May 19, 2022 at 9:34 AM Mike Dewhirst wrote:
> The code below appears to work perfectly but it worries me because I
> have never used the global keyword before.
>
> Is there a generous guru who will criticise
https://docs.djangoproject.com/en/4.0/intro/tutorial02/#playing-with-the-api
Kind Regards,
Michael Thomas
On Thu, Dec 16, 2021 at 3:08 PM Amor Zamora wrote:
> Can you help me?
> I need to obtain the country of where the users access from the IP and
> insert that information into the sqlite3 databa
es requests too, which is invaluable
in the long run.
Kind Regards,
Michael Thomas
On Wed, Jun 2, 2021 at 8:16 PM sukhy gill wrote:
> Dear frnd,
> I am getting stuck at same point with static with new project.
> May I get setting for settings.py ?
>
> Regards
>
>
need that then
you may be better off with regular django session authentication, signed
cookies, etc..
Kind Regards,
Michael Thomas
On Sat, May 8, 2021 at 11:02 AM narendra thapa
wrote:
> Thank You @Michal Thomas, i was able to refresh a token now, But i got
> another confusion from your answer
re each request, and call the refresh view to get a replacement before
making the request.
I hope that helps!
Kind Regards,
Michael Thomas
On Sat, May 8, 2021 at 6:49 AM narendra...@gmail.com <
narendrathapa...@gmail.com> wrote:
> i'm using django as my backend and react as frontend.
tegr@te System wrote:
>
> Hi Michael,
>
> Some templates as mako, jinja, genshi...
>
>
>
>
> On Fri, Jul 10, 2020, 4:23 PM Michael Thomas > wrote:
>
>> Hi all,
>>
>> Does anyone know of a straightforward way to create an independent
>> templ
Hi all,
Does anyone know of a straightforward way to create an independent template
engine instance with a subset of the tags/filters/etc. defined?
The use-case is for allowing user-supplied template content, while
preventing said users from being able to use features that could be
dangerous,
1500kbps is horrendously slow too, really..
If you're seeing a significant difference between small transfers vs large, you
might be stumbling into an incorrect MTU size for the network.
This has popped up a little more often in recent years with the rise of vxlans
over public connections.
If
Django is a backend platform - it's agnostic as to what type of front end
you build with it.
On Thu, Nov 14, 2019 at 4:27 PM Inna Reddy wrote:
> Hi,
>
> Can we build Single page web applications with Django ?
>
> --
> You received this message because you are subscribed to the Google Groups
> "D
Naimur: I am - that SQL was in response to Aldian's question :)
On Fri, Apr 12, 2019 at 8:23 PM naimur rahman
wrote:
> use ORM istead of SQL
>
> On Fri, Apr 12, 2019, 7:42 PM Michael Thomas <
> michael.thomas.s...@gmail.com> wrote:
>
>> SELECT
>>
IN (
SELECT
U1."foo_id"
FROM "app_bar" U1
WHERE U1."attribute_1" = 1
)
)
AND "app_bar"."attribute_2" = 2
)
On Fri, Apr 12, 2019 at 6:59 PM Aldian Fazrihady wrote:
> What'
You're not using a template, nor generating HTML in your views - where are
you expecting bullets to come from?
--
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 dj
gh, a simple query for attribute_1=1 and attribute_2=2
works as expected, so it would be trivial to do this with a __ne operator
(if it existed), without any other changes to the ORM:
print(Foo.objects.filter(bar__attribute_1=1, bar__attribute_2=2).query)
SELECT
"app_foo"."i
16 matches
Mail list logo