On Friday, August 29, 2014 5:47:19 PM UTC+5:30, Shubham Pansari wrote:
>
> You are missing csrf_token which is set by request for csrf verification.
> After the line
> http://127.0.0.1:8000/test/; method="post">
> in your code put {%csrf_token%} and it should work fine and also read why
> it
No problem.
I think I also found how to deal with M instances which are not related to
R (R instances have foreign key to M). I tried
M.filter(related_query_name_from_R__isnull=False) and it seems to work.
--
You received this message because you are subscribed to the Google Groups
"Django
The documentation is wrong, it should be:
# That's now the name of the reverse filter
Article.objects.*filter*(tag__name="important")
I'll commit a documentation admonition and give you credit.
Thanks for spotting this!
Le vendredi 29 août 2014 22:27:38 UTC-4, Petr Glotov a écrit :
>
>
Now I can read data from ajax to my def but I have not idea to how
send, for examle, an array to jquery and manage this from javascript...
I tried:
def json_prueba(request):
arrg = [1,2,3,4]
if request.method == 'POST':
return HttpResponse(simplejson.dumps({'array': arrg}),
Correction: first sentence of the question should read:
However, a model instance doesn't have filter() method.
--
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
Thanks Andréas,
I will try it.
Regards/AR
El 28/08/2014 02:57 a.m., Andreas Kuhne escribió:
Hi Antonio,
import simplejson as json
return HttpResponse(
json.dumps({
'array': example
}),
content_type="application/json"
)
That would do the trick. This is returned as JSON.
Django doc says:
ForeignKey.related_query_name
New in Django 1.6.
The name to use for the reverse filter name from the target model. Defaults
to the value of related_name if it is set, otherwise it defaults to the
name of the model:
# Declare the ForeignKey with related_query_name
class
I see now that I think the best course of action is to get the traceback by
adding the ADMINS settings. So I did that. Now I need to restart the uwsgi
server process. Any suggestions on how to kind of brute force do that right
now?
I see on their site they suggest "uwsgi --reload
Thank you Collin.
Em sexta-feira, 29 de agosto de 2014 16h49min37s UTC-3, Collin Anderson
escreveu:
>
> https://docs.djangoproject.com/en/dev/intro/tutorial01/#creating-models
>
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe
I didn't have my uwsgi setup to log. So I did with this command :
uwsgi --socket :8001 --wsgi-file wsgi.py --master --processes 5 --threads 2
--daemonize /var/log/uwsgi/lokalapp.log
So I went to the site to reach the 500 error to see if anything updates and
nothing is updated in the log file
https://docs.djangoproject.com/en/dev/intro/tutorial01/#creating-models
--
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
you have any examples of how to do this procedure?
Em sexta-feira, 29 de agosto de 2014 16h01min36s UTC-3, Collin Anderson
escreveu:
>
> the general way is to have a "rule" model with a foreign key to your main
> model, then use an inline in the admin
>
--
You received this message because
você tem algum exemplo de como fazer este procedimento?
Em sexta-feira, 29 de agosto de 2014 16h01min36s UTC-3, Collin Anderson
escreveu:
>
> the general way is to have a "rule" model with a foreign key to your main
> model, then use an inline in the admin
>
--
You received this message
Benjamin,
I solved my problem. I switched to SQLite for testing and now
run 500+ tests in 30 secs instead of 75 minutes. Much better!
Thanks for your help!
--Fred
Fred Stluka -- mailto:f...@bristle.com --
the general way is to have a "rule" model with a foreign key to your main
model, then use an inline in the admin
--
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
I figured it out.
Details:
I had set environment variable PYTHONPATH to help Django
find the sql_server.pyodbc files needed to make a connection
to a Microsoft SQL Server DB. This was keeping SQLite from
working properly. When I cleared the environment variable,
SQLite works fine.
I now get
Why are you adding a csrf token in your context?
On 29 Aug 2014 13:05, "Pawan Soni" wrote:
> Hi ,
>
> i have a simple html page,*p.html *which is not made in django
> application ,its just a ordinary html page which look like..
>
>
>
> http://127.0.0.1:8000/test/;
Good Afternoon Everyone,
I am Working with Django the little time and I'm facing a problem. I need
to create a form in the admin module of my project, and this record I have
a field called RULE. where I can register a field called RULE, RULE put the
field can have 1 or N records. My question
I'm pretty sure my ALLOWED_HOST is setup right to allow all url locations after
the main domain. I have not setup the EMAIL to send me notifications upon 500
server error. Will do now. About to check my uwsgi log and post it as well
--
You received this message because you are subscribed to
I use mock for every testcase I have in my app (no queries in my entire
test suite), but sometimes I also need to include a real model (but no
queries or db), due to the complexity of the situation (e.g., relying on a
bit more of Django's inner workings without having to mock 10-15 methods).
Hello,
I would like to build a real time web application, but have little idea of
where to start to from. It will have notification and feed system like
facebook or instagram. Would really appreciate if anyone who have already
done this type of web application could kindly guide me through. I will
On Fri, Aug 29, 2014 at 6:16 AM, Shubham Pansari
wrote:
> You are missing csrf_token which is set by request for csrf verification.
> After the line
> http://127.0.0.1:8000/test/; method="post">
> in your code put {%csrf_token%} and it should work fine
I'm a Django
Hi, can't you guys mock these models ?
On Thursday, August 28, 2014 9:31:04 PM UTC-3, Yo-Yo Ma wrote:
>
> Ugh... same problem here. It seems you can't really create a model in
> setUp anymore. I'll post a reply, if I find anything.
>
> On Wednesday, July 16, 2014 10:17:56 AM UTC-4, Alisue Lambda
is your ALLOWED_HOSTS set correctly?
it's also possible to set up ADMINS and email settings so you get an email
with details about the server 500 error.
Does your uWSGI log show any more info?
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
You are missing csrf_token which is set by request for csrf verification.
After the line
http://127.0.0.1:8000/test/; method="post">
in your code put {%csrf_token%} and it should work fine and also read why
it didnot worked without it from
https://docs.djangoproject.com/en/dev/ref/contrib/csrf/ .
Hello.
I believe I have successfully installed Django based on having no problems
with testing "import django" at the command prompt and in the Python
interpreter.
However, I cannot get the tutorial started.
As explained by the tutorial ("From the command line, cd into a directory
where you’d
Hi all,
Do you have any 'best practices' for translating Django?
It's just come to my attention that in a couple of places, it would be good
to add some context to certain translations. I just thought I'd ask to see
if you've discussed it before
A good example is the word 'Save' used in the
Hi,
I am trying to create a Django application as a plugin to integrate with
other Django framework applications or websites (for example: a Payment
gateway plugin). My application has package hierarchy as mentioned below.
DjangoProject
Hi ,
i have a simple html page,*p.html *which is not made in django application
,its just a ordinary html page which look like..
http://127.0.0.1:8000/test/; method="post">
In form's action i am passing the path of my django url..
this is my *urls.py* file..
from
I have created a ticket - https://code.djangoproject.com/ticket/23383
Should I try to proceed my investigations and create a patch?
пятница, 29 августа 2014 г., 11:50:01 UTC+6 пользователь Simon Charette
написал:
>
> I think you should create a single issue
>
30 matches
Mail list logo