name is a ForeignKey field? If not, you shouldn't use queryset attribute
there. Use choices instead.
If you want to render all available choices from db, you can get it like
Model.objects.filter(...).values_list('name', flat=True)
On Friday, August 4, 2017 at 8:07:24 PM UTC+3, Arun S wrote:
>
>
what the problem here?
you can get all your Feeds by
feeds = Feed.objects.filter(user=me)
and then all the comments for each feed
comments = feed.comment_set.exclude(user=me)
or what?
if you want to get only comments, you can do
comments = Comment.objects.filter(feed__in=feeds).exclude(user=me)
it's a very strange way of import. if your forms and models are in the same
python module, you can do
from . import models
On Saturday, August 5, 2017 at 11:01:01 PM UTC+3, Prithviraj Mitra wrote:
>
> I have both versions python 2.7 and 3.4 installed. I am using some code
> which is developed
so, you can maybe show you models structure here?
also, if it is a ForeignKey, why you trying to filter qs by string values?
I mean Q(name = 'ACTIVE')
it's shouldn't work
On Sunday, August 6, 2017 at 5:22:21 AM UTC+3, Arun S wrote:
>
> Yes, name is a foreign key here.
--
You received this mess
name | varchar(32) | NO | UNI | NULL||
> | friendly_name | varchar(32) | NO | UNI | NULL||
> | description | varchar(255) | YES | | NULL||
> +---+--+--+-+-----++
&g
t; On Monday, August 7, 2017 at 3:37:04 PM UTC+5:30, lemme smash wrote:
>>
>> i meant EvalState model
>> if name attribute on it is a ForeignKey you should get corresponding
>> queryset of model it links to
>> if it's charfield, you should use text choice
you sure you have mysql server installed?
also, if you plan to start development, i recommend you to seriously think
about learning linux. it's a way more fit developers needs
On Thursday, October 25, 2018 at 2:27:43 PM UTC+3, Rabil Abdullahi wrote:
>
>
>
> I received error message while trying
wut?
On Saturday, September 14, 2019 at 7:01:13 AM UTC+3, nitin kumar wrote:
>
> How does make application to understand a document!
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails fr
it's more about client, so you probably want to look for calendar libraries
and then JUST make an api for it.
On Tuesday, September 24, 2019 at 12:47:37 AM UTC+3, Perceval Maturure
wrote:
>
> Is there anyone with a step by step procedure of doing this app in a
> Django 2.1 environment For newbi
you probably may want to figure out what you actually need to do first
On Tuesday, September 24, 2019 at 5:54:12 PM UTC+3, Rain wrote:
>
> i have a question how to create school year with start date and end date
> all transaction must under this year. Thanks..
>
--
You received this message bec
and you have no errors in browser console?
On Tuesday, October 1, 2019 at 11:41:28 PM UTC+3, Dmitri S. wrote:
>
> I have a formset with fields with Select2 widgets and a calendar
> (date-picker) from django app.
>
> And I use dynamic addition of formset forms.
>
>
> When I render a template for t
okay, but what you actually mean by "widgets don't work"?
also, from my experience I can say that when you have to work with some
dynamic forms is't much better to use pure js on client and only validate
it on backend
On Tuesday, October 1, 2019 at 11:41:28 PM UTC+3, Dmitri S. wrote:
>
> I have
okay, i think i got it. you probably need to provide some snippet to reload
list of choices to newly added form. try to look some examples of using
django-select2 with formsets...
by pure js i mean not necessarily vanila js, but pure client code, without
rendering templates on server. all the p
you probably may want to implement `get_context_data` method like:
def get_context_data(self):
context = super(BlogView, self).get_context_data()
context.update({
'authors':
Author.objects.filter(posts__isnull=False).distinct(),
'tags': Tag.objects.all()
suggestion:
it's better to post code snippets as text (i.e. use `code` markup)
about your question: what you mean by "i want to do a combination"? you
what to display both filters and both lists on the same page? in that case
you want to setup custom view.
On Thursday, October 10, 2019 at 1:48:5
so, it's not reproducing when you run it locally?
also, can you provide an example of string where you have "strange"
character? most probably you store it in database.
On Thursday, October 10, 2019 at 1:48:52 AM UTC+3, Boris Romero wrote:
>
> Hi!
>
> I recently update Django from 1.11 to 2.2.6
just create custom view and add those two querysets to context. if you want
to do search by one input in both querysets, you'll need to create custom
filter as well, or just filter it in a view by query from input
On Thursday, October 10, 2019 at 1:48:52 AM UTC+3, sotiris moustogiannis
wrote:
>
go
^^)
On Friday, October 11, 2019 at 8:39:33 PM UTC+3, Uzama Zaid Mohammed Jaward
wrote:
>
> Hi all
>
> What are the tech stack is good for micro service architecture in Django
>
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe
why you have type="button" on anchor?)
On Saturday, October 12, 2019 at 7:07:48 AM UTC+3, narendra thapa wrote:
>
> i have two template load_page.html and ask_questions.html while i am
> linking a ask_questions.html through load_page.html via a anchor tag i am
> not getting ask_questions.html bu
tabase encoding problem, it just
>> involves the templates, because the same database, with diferents instances
>> of the app (with the upload and without it) not make any differences.
>>
>> Thanks for the ideas!
>>
>>
>> On Thursday, October 10, 2019 at
psycopg2, djangorestframework, and subdomains (using a pull request for
> compatibility).
>
> The problems happens with DEBUG=False, and using nginx and uwsgi, using
> the same configuration for django 1.11 and django 2.2.x
>
> Greetings!
>
> On Wednesday, October 16, 2019 at 8:5
it's quite expected behavior. if you want to check if job exists, you
better use Job.objects.filter(name=job_name).exists()
On Monday, October 21, 2019 at 3:49:01 PM UTC+3, Gourab Mahapatra wrote:
>
> Traceback:
>
> File
> "C:\Users\Admin\PycharmProjects\autotask\AutoTaskVenv\lib\site-packages\d
i'm not sure, but i can say that it's quite strange not to have trailing
slash on `include` path. you want to have something like `api/v1case`?
On Sunday, October 20, 2019 at 1:07:48 AM UTC+3, Conor wrote:
>
> Hi All,
>
> I'm not sure whether this is a feature or a bug, so I thought it best to
>
okay, man. seems like you need to read and repeat everything you know about
python and django. i highly recommend you to go through django tutorial.
On Monday, October 21, 2019 at 3:49:01 PM UTC+3, Gourab Mahapatra wrote:
>
> Traceback:
>
> File
> "C:\Users\Admin\PycharmProjects\autotask\AutoTas
i'm recommend you to consider docker setup like
https://docs.docker.com/machine/examples/ocean/
https://testdriven.io/blog/dockerizing-django-with-postgres-gunicorn-and-nginx/#nginx
On Tuesday, November 5, 2019 at 1:27:55 AM UTC+3, Ram wrote:
>
> Hi,
> Please let me know if anyone has setup this s
i feel for you, but from this description there is no way to figure out how
to help. it's way too abstract. so you probably may want to provide code
piece and traceback to get any kind of help here.
On Saturday, December 7, 2019 at 2:08:41 AM UTC+3, Alaina Rowe wrote:
>
> I have not been able to
you've really did the great, but in order to receive data from reddit
you'll need to research on their api and it's not very related to django.
On Thursday, December 26, 2019 at 4:05:14 PM UTC+3, Shaurya Sharma wrote:
>
> Hey there , I am quite a newbie to Django and I am trying to understand
>
you doing something strange.
usually, when you want to setup angluar with django, you just using `ng
serve` to handle all the interface, and just use django for data and api.
it's not a good idea to render angular app with django
On Thursday, December 26, 2019 at 4:05:14 PM UTC+3, nitish kumar w
28 matches
Mail list logo