Re: How to get superuser access to bypass payments page

2022-10-20 Thread Gabriel Araya Garcia
In template you should put an conditional, if it is an any user then show
the real price and if it's a superuser then show zero. And on the back-end
you should ask the same question at the time to save.

gabrielaraya2...@gmail.com

Regards


Gabriel Araya Garcia
GMI - Desarrollo de Sistemas Informáticos




El jue, 20 oct 2022 a las 15:55, Silver Trinity ()
escribió:

> Hello all new developer here,
>
> I am working with existing code base and want to fix an issue in the
> system. Here is the problem:
>
> When a superuser logs into the site and selects a product, he is charged
> and I have to implement a 100% discount to his price so he doesn't have to
> pay. This is inefficient and I want to do it another way.
>
> How can I change this so that a superuser can select a product,  and
> bypass the payment section? Here is some code for reference along with the
> mixins being used:
>
> Code snippets:
> https://pastebin.com/3RTKAi9U
> https://pastebin.com/g6vdX5Uk
>
>
>
>
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/eea3c99f-e086-4cd8-8874-dfe4e333e276n%40googlegroups.com
> 
> .
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAKVvSDAUkUkP6SYpyyFDt60zbhHQ8wdx6HpyVWOpS6uquNNsUQ%40mail.gmail.com.


How to get superuser access to bypass payments page

2022-10-20 Thread Silver Trinity
Hello all new developer here,

I am working with existing code base and want to fix an issue in the 
system. Here is the problem: 

When a superuser logs into the site and selects a product, he is charged 
and I have to implement a 100% discount to his price so he doesn't have to 
pay. This is inefficient and I want to do it another way. 

How can I change this so that a superuser can select a product,  and bypass 
the payment section? Here is some code for reference along with the mixins 
being used:

Code snippets:
https://pastebin.com/3RTKAi9U
https://pastebin.com/g6vdX5Uk





-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/eea3c99f-e086-4cd8-8874-dfe4e333e276n%40googlegroups.com.