Sum, Count works when we try to get sum/count for a column,
for this case you can try something like this
def get_yes_count_by(id):
user = User.objects.get(id=id)
count = 0
for val in user.__dict__.values():
if val == "YES":
count += 1
return count
On Tue, 21 S
Add a property to count Y for each column
Or add a computed field that tallies that on save
For reference
https://stackoverflow.com/questions/1454727/do-properties-work-on-django-model-fields
On Mon, Sep 20, 2021 at 6:41 PM J.T. wrote:
> I have a model called member that has 6 columns: ID,
On Tue, Sep 21, 2021 at 2:11 AM hey there wrote:
1. oracle autonomous linux's epl dont have certbot
>
pip install certbot
You already have pip installed if you're running Django. This takes all of
10-15 seconds...
and
> 2. I mostly like Cloudflare than certbot because Cloudflare has some own
I have a model called member that has 6 columns: ID, Value1, Value2,
Value3, Value4, Value5
The values in columns Value1, Value2, Value3, Value4, Value5 are either Y
or N.
I'm trying to query by ID to count the number of Y values for each member.
For example one row would be: 5, Y, N, Y, N, N
Hello, I am learning Django, I need help with my Django formset. The
template-webpage would open when I just had a regular form but the look and
feel was not what I wanted. I decided that I wanted to develop a formset.
Along with the formset I want some values to populate automatically so the
u
1. oracle autonomous linux's epl dont have certbot
and
2. I mostly like Cloudflare than certbot because Cloudflare has some own
methods to maintain ssl certificate
On Mon, Sep 20, 2021 at 2:37 PM FIRDOUS BHAT wrote:
> Why don't you explore certbot?
>
> On Sun, Sep 19, 2021, 8:14 PM MR INDIA wr
I noticed a list comprehension bombs in the "./manage.py shell" shell that
I think would
be ok in normal Python shell. What is different about "./manage.py shell"
that makes it not like certain list comprehensions?
Here is the code erase that I run this way..."./manage.py shell < erase"
import
Hi. I don't see anything in your code samples that would cause this. One
line in admin.py caused the server to stop because of the extra
parenthesis, and the default for status should be 'r' instead of
'refereed', but those don't cause the problem you're describing. Maybe a
browser issue?
Why don't you explore certbot?
On Sun, Sep 19, 2021, 8:14 PM MR INDIA wrote:
> Select os and server and it will show the docs, you have to first shutdown
> the server then after following the docs restart the server.
>
>
> On Saturday, 18 September 2021 at 19:33:31 UTC+5:30 hey there wrote:
>
>>
I have set some variables in context.py, which need to be rendered in the
base template of an application. It's working fine when I normally log in
into the system.
BUT I have an email workflow feature. So when I log in via a link in email,
that time it won't render the values in the base template
Not at all a "new" topic :-)
On Sun, Sep 19, 2021 at 8:11 AM Jet Ezra wrote:
> I know this may not be necessary at the moment because we are comfortable
> depending on front-end frameworks, but I have my two ideas here:
> 1. what if django alone without any framework can be used to design
> prog
Hi Salima,
Stack trace? Always the first call for triage on python exceptions.
Also (and unrelated to your issue) google "django messages bootstrap" and
check on how to avoid the {% if message.tags == .. %} horror show and make
your templates much more readable/easily maintained.
On Mon, Sep 2
12 matches
Mail list logo