If you're using a ForeignKey for this field, you'll get this behavior by
default in the Django admin.
Le 17 août 2012 08:45, "Madhu" a écrit :
> Hello,
>
> I want to add the button along with field in admin form.
>
> ex. Field name "URL" with the "Choose Page" button.
> If admin clicks on "Choose
You gave us the project layout, but where are the templates?
My guess is that Django is basically not picking them templates *up*, but I
might be off.
There are arguments to the makemessages command that can help you indicate
the directory you want messages created for. You can also use higher
ve
This is not really django specific, several objects bearing the same name
in the same namespace will always lead to trouble ; )
(And this is not even python specific)
Glad you could fix it and thanks for posting your solution in case someone
else has the same issue though. : )
Le 16 août 2012 21:0
Thanks for the replay.
Using foreign key it creates dropdown list, but i want the URL as the
character field and "Choose Page" button which having the function which
retrieves the database query list.
On Friday, August 17, 2012 12:51:35 PM UTC+5:30, Thomas Orozco wrote:
>
> If you're using a F
Huge props for having the python docs on localhost :-D
Le 16 août 2012 20:08, "Melvyn Sopacua" a écrit :
> On 16-8-2012 6:02, Kurtis Mullins wrote:
>
> > Not all of us host the Python docs, locally, haha.
>
> Lies! But yea, forgot to check that so thanks :)
>
> --
> Melvyn Sopacua
>
> --
> You re
Oh, yeah, sorry about that, it's an admin parameter that you must use,
can't recall the exact name, but it's something like id only.
Le 17 août 2012 09:41, "Madhu" a écrit :
> Thanks for the replay.
>
> Using foreign key it creates dropdown list, but i want the URL as the
> character field and "C
It's raw_id_fields! (see the docs for more detail : ) )
On your modeladmin, set that to a list including the name (as string) of
your field, and you should have what you want.
Let me know if I misunderstood.
Le 17 août 2012 09:47, "Thomas Orozco" a écrit :
> Oh, yeah, sorry about that, it's an
Change the ModelField to type "CharField" and you should have a input
box in the admin.
On Fri, Aug 17, 2012 at 12:14 PM, Madhu wrote:
> Hello,
>
> I want to add the button along with field in admin form.
>
> ex. Field name "URL" with the "Choose Page" button.
> If admin clicks on "Choose Page"
I am using session foreign key in my table.
class ClientJob(models.Model): #models.py
.
sess = models.ForeignKey(Session)
And in order to save its value in database, I used ,.
def add_job(request) #views.py
.
I might be off, but I believe that they want to get a list of objects from
the database, a ForeignKey seems more appropriate here, or am I missing
something?
Le 17 août 2012 09:58, "Amyth Arora" a écrit :
> Change the ModelField to type "CharField" and you should have a input
> box in the admin.
I think this is because you are passing it the "Session Key" instead
of the "Session Instance", you need to get the session instance and
then pass it to your function, Something like this:
profile.sess = Session.objects.get(session_key=request.session.session_key)
On Fri, Aug 17, 2012 at 1:28 P
Session key is the session 's primary key. Not the session itself.
What you want to assign to your field is a session, not its key. So use
request.session.
However.
Please very careful when using FK' s to sessions, sessions are meant to be
short lived, and could / should be deleted once they exp
On Fri, Aug 17, 2012 at 1:42 PM, Thomas Orozco
wrote:
> Session key is the session 's primary key. Not the session itself.
>
> What you want to assign to your field is a session, not its key. So use
> request.session.
>
> However.
>
> Please very careful when using FK' s to sessions, sessions are
I'm sorry, I have some trouble understanding exactly what you need, could
you please try and provide a bit more context ? :-)
Le 17 août 2012 10:27, "Sandeep kaur" a écrit :
> On Fri, Aug 17, 2012 at 1:42 PM, Thomas Orozco
> wrote:
> > Session key is the session 's primary key. Not the session i
On Fri, Aug 17, 2012 at 9:12 AM, Thomas Orozco
wrote:
> Session key is the session 's primary key. Not the session itself.
>
> What you want to assign to your field is a session, not its key. So use
> request.session.
>
This would not work; request.session is a
django.contrib.sessions.backends,Se
My mistake then, sorry about that!
Le 17 août 2012 10:34, "Tom Evans" a écrit :
> On Fri, Aug 17, 2012 at 9:12 AM, Thomas Orozco
> wrote:
> > Session key is the session 's primary key. Not the session itself.
> >
> > What you want to assign to your field is a session, not its key. So use
> > req
On Fri, Aug 17, 2012 at 1:39 PM, Amyth Arora wrote:
> I think this is because you are passing it the "Session Key" instead
> of the "Session Instance", you need to get the session instance and
> then pass it to your function, Something like this:
>
> profile.sess = Session.objects.get(session_key
You're Welcome. Glad to Help.
On Fri, Aug 17, 2012 at 2:28 PM, Sandeep kaur wrote:
> On Fri, Aug 17, 2012 at 1:39 PM, Amyth Arora
> wrote:
>> I think this is because you are passing it the "Session Key" instead
>> of the "Session Instance", you need to get the session instance and
>> then pass
Yes I can access the directories. Here's the traceback:
Traceback (most recent call last):
File "/usr/lib/python2.7/wsgiref/handlers.py", line 85, in run
self.result = application(self.environ, self.start_response)
File
"/usr/local/lib/python2.7/dist-packages/django/core/handlers/wsgi.py",
Thanks you for replying. Here is traceback:
Traceback (most recent call last):
File "/usr/lib/python2.7/wsgiref/handlers.py", line 85, in run
self.result = application(self.environ, self.start_response)
File
"/usr/local/lib/python2.7/dist-packages/django/core/handlers/wsgi.py", line
241,
While you get this error do you see your template dir listed on the
error/debug page ?
On Fri, Aug 17, 2012 at 2:46 PM, madala wrote:
> Thanks you for replying. Here is traceback:
>
> Traceback (most recent call last):
> File "/usr/lib/python2.7/wsgiref/handlers.py", line 85, in run
> self.
Can you please tell me how to add the Buttom on admin form in django?
I want to add the button beside the field.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/django-use
Django Admin by default only provides Dropdown option for Foreign Keys.
On Fri, Aug 17, 2012 at 2:56 PM, Madhu wrote:
> Can you please tell me how to add the Buttom on admin form in django?
> I want to add the button beside the field.
>
> --
> You received this message because you are subscribed
(again) did you try using raw_id_fields?
Le 17 août 2012 11:26, "Madhu" a écrit :
> Can you please tell me how to add the Buttom on admin form in django?
> I want to add the button beside the field.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users
I try the row_id_fields, but its not helpful for me.
I want the button will be display in admin form.
Using row_id_fields its just the linking of foreign key i don't want that.
The button functionality will be later before that i want the button tag
will be display on admin form.
--
You receive
Then there must be something I don't understand in what you need, could you
describe a bit more?
Le 17 août 2012 12:02, "Madhu" a écrit :
>
> I try the row_id_fields, but its not helpful for me.
> I want the button will be display in admin form.
> Using row_id_fields its just the linking of forei
Ok. I will explain it in brief.
I want the button like the image field having the Browse button with the
Image field in admin side i want the same button but the functionality may
be different. Don't want that the browser button functionality but i want
the button along with the my URL characte
So you would want to have a link to the url that was entered?
Le 17 août 2012 12:15, "Madhu" a écrit :
> Ok. I will explain it in brief.
>
> I want the button like the image field having the Browse button with the
> Image field in admin side i want the same button but the functionality may
> be d
Registering the model worked for me. Thanks!
On Tuesday, February 16, 2010 11:18:09 PM UTC+11, Matt Schinckel wrote:
>
> On Feb 14, 3:49 pm, john wrote:
> >
> > Yes, the Items model data can be accessed through another part of the
> > Admin interface, but I think the purpose of the Green Plus Sig
On the Django development server, django app works fine. But once I setup
the production test run, I get only the text contents, where template views
are not shown as intended. What am I going wrong?
I have django 1.5 latest.
Nginx - 0.8.54
uWSGI - 1.2.5
Also tried FAPWS3.0 similar result
Hi all,
I am just wondering, how can I turn my whole project into a pluggable
application so that others can just add my application to their project.
Thanks for your time!
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussi
No. URL linking is not the problem. I have the problem to add the input
button in admin form.
There will be so many buttons in admin form like save, add, delete. I want
to add my own button, but in the middle of admin form not at the submit
line or upper part of the admin form. That button shou
I'm sorry, I really have a hard time understanding what you need, but you
might want to try overriding the form template to add your button?
If so, try the change_form_template parameter.
Le 17 août 2012 12:42, "Madhu" a écrit :
> No. URL linking is not the problem. I have the problem to add the
17.8.2012 13:42, Madhu kirjoitti:
No. URL linking is not the problem. I have the problem to add the input
button in admin form.
There will be so many buttons in admin form like save, add, delete. I
want to add my own button, but in the middle of admin form not at the
submit line or upper part of
Thanks Thomas.
Just trying to apply the DropDownMultiple Widget that you have
suggested. I have followed the instruction:
|class MyForm(forms.ModelForm):
categories = forms.Field(widget=DropDownMultiple)
def __init__(self, *args, **kwargs):
self.base_fields['categories'].widge
Are you sure it's a views/templates issue? You're getting content that
looks correct in structure so I'd say the views + templates are fine.
Looks like a CSS issue to me.
If you're using firefox then install firebug and check the NET tab for
404s to your CSS files.
Paul
On Fri, 2012-08-17 at 02:
Yes, That's right. I tried to change the admin form, but the button is not
added.
the fuctionality Jani Tiainen said i want the same fuctionality, but the
now first problem is adding button in change form.
--
You received this message because you are subscribed to the Google Groups
"Django use
We built a fairly simple Django site and the client would like someone more
local to take over maintenance. If anyone is interested then drop me a
line. I'm happy to help with the handover.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To vi
Al 17/08/12 13:05, En/na Madhu ha escrit:
Yes, That's right. I tried to change the admin form, but the button is
not added.
the fuctionality Jani Tiainen said i want the same fuctionality, but the
now first problem is adding button in change form.
As Jani has pointed I think that a custom widge
On Fri, Aug 17, 2012 at 1:28 PM, Sandeep kaur wrote:
> I am using session foreign key in my table.
> if not request.session.exists(request.session.session_key):
> request.session.create()
> profile.sess = request.session.session_key
> pro
Thanks I solved it. Was looking up wrong directory because I followed the
instructions to put the absolute path. If I put the relative path it works
fine. Thanks for taking time to answer anyway. People are so kind! :0)
On Friday, 17 August 2012 10:21:22 UTC+1, Amyth wrote:
>
> While you get thi
Thanks I solved it. Was looking up wrong directory because I followed the
instructions to put the absolute path. If I put the relative path it works
fine. Thanks for taking time to answer anyway. People are so kind! :0)
On Tuesday, 14 August 2012 14:59:11 UTC+1, Alexis Roda wrote:
>
> Al 14/08/1
Thanks I solved it. Was looking up wrong directory because I followed the
instructions to put the absolute path. If I put the relative path it works
fine. Thanks for taking time to answer anyway. People are so kind! :0)
On Tuesday, 14 August 2012 14:54:45 UTC+1, ephan wrote:
>
> Have you checked
Thanks Melvyn,
Yes, I know about overriding a widget. I could override a Charfield with
a TextArea. For simple stuff it makes sense.
Against which widget do I override the existing M2M widget though?
On 17/08/12 01:01, Melvyn Sopacua wrote:
On 17-8-2012 1:05, Houman wrote:
What I am tryin
On 17-8-2012 15:00, houmie wrote:
> Yes, I know about overriding a widget. I could override a Charfield with
> a TextArea. For simple stuff it makes sense.
> Against which widget do I override the existing M2M widget though?
If the one that Tomas linked doesn't work for you, you'll need to
consu
Thanks Melvyn,
To be honest I would be willing to purchase a widget if there was one.
iw ill look into the list you have sent me.
On another note, Simone mentioned to extend the Formset in order to run
my own dropdown solution.
I was just looking at the modelformset_factory class and - surp
On 17-8-2012 4:15, Jojo wrote:
> I have created a locale folder and after I launched the django-admin.py
> makemessages command as explained in the documentation, but when I open a
> .po file (the command create the files actually), I can't found
> the msgid/msgstr relative to the translation i
Hi, I'm learning Django and I have problems with the urls.py. I show you
how that's writed:
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('users.views',
url(r'^volunters/$', 'voluntersindex'),
url(r'^volu
Al 17/08/12 17:42, En/na Rafael Romero Carmona ha escrit:
Hi, I'm learning Django and I have problems with the urls.py. I show you
how that's writed:
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('users.views',
Glad that you solved it! However, i would recommend using absolute
path instead of a relative path as it might break when you clone or
move it to another location.
On Fri, Aug 17, 2012 at 6:17 PM, madala wrote:
> Thanks I solved it. Was looking up wrong directory because I followed the
> instru
2012/8/17 Alexis Roda
> Al 17/08/12 17:42, En/na Rafael Romero Carmona ha escrit:
>
> Hi, I'm learning Django and I have problems with the urls.py. I show you
>> how that's writed:
>>
>> from django.conf.urls import patterns, include, url
>>
>> from django.contrib import admin
>> admin.autodisco
Hi all,
I'm new to Django, but really enjoying using it so far!
What I'm trying to do is to export data from an admin interface, when a record
is created or updated. I'm calling another web service to tell it the data on
site [A] has changed, by using signals.
e.g.
@receiver(post_save, sender
Although the auth module is very useful, there's still a lot of faffing to be
done just to get a standard user login system in place. Can anyone recommend a
sort of boilerplate solution with a full suite of registration, user profile
pages, etc. written up and ready to copy/paste or plug/play?
Hi!
I am new to the Django frameworks and and having difficulties getting it to
work on windows 7. I have successfully installed the latest release but
when I try to create a new project using the command "python
django-admin.py startproject mysite" it displays the following message:
can't open
Pinax?
On Sat, Aug 18, 2012 at 2:53 AM, pearlball
wrote:
> Although the auth module is very useful, there's still a lot of faffing to be
> done just to get a standard user login system in place. Can anyone recommend
> a sort of boilerplate solution with a full suite of registration, user
> pro
I think that this is not the problem because I can access to volunters
without problems. I have problems only with admin, organizers and events
paths.
So you have problems with all the urls past the first with a wrong pattern.
~$ python
Python 2.6.5 (r265:79063, Apr 16 2010, 13:09:56)
[GCC 4.4.
Yes, looks like something went wrong due to static file access; I find
http/1.1 404 not found error under web console of firefox
Status Code:
HTTP/1.1 404 NOT FOUND
I tried option from link
https://docs.djangoproject.com/en/1.4/ref/contrib/staticfiles/#static-file-development-view
still n
http://www.django-userena.org/
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more
i'm sorry, templates are in application folder in the templates directory
Il giorno venerdì 17 agosto 2012 04:15:59 UTC+2, Jojo ha scritto:
>
> Hi, the subject should be a little clear so, this is the project folder
> structure
>
> project folder
> locale
> en
> LC_MESSAGES
> django.
I've successfully installed Django-SEO, but when I try to limit the number
of backends (I only need/want my admin to have 'path' and not the other
three) I am met with the following error:
AttributeError at /admin/'NoneType' object has no attribute '_meta'
I am using the documentation here:
htt
I see the import in core.mail.backends.smtp, but I don't see sanity_address in
core.mail.message, which is where it's trying to import from:
from django.core.mail.message import sanitize_address
Please advise.
jan
--
You received this message because you are subscribed to the Google Groups
"D
I got it.
My templates files have htm extension and makemessages looks for htmL
files, so I used -e option specifying htm extension like this:
django-admin.py makemessages -l es -e htm
Now I have msgid/msgstr that I need.
NOW
I compiled the msgstr with the translations an compiled the messages
Please ignore this message. Seems to be a local issue with my instlal
somehow.
jan
On Friday, August 17, 2012 2:41:49 PM UTC-6, Jan Vilhuber wrote:
>
> I see the import in core.mail.backends.smtp, but I don't see
> sanity_address in core.mail.message, which is where it's trying to import
> fro
Ok guys, I was missing the LOCALE_PATHS in settings.py, now it works
properly.
Il giorno venerdì 17 agosto 2012 04:15:59 UTC+2, Jojo ha scritto:
>
> Hi, the subject should be a little clear so, this is the project folder
> structure
>
> project folder
> locale
> en
> LC_MESSAGES
>
> For example for this link
>
> {% trans "contacts" %}
>
> I have the msgstr="Contactos". I expect to see "Contactos" in the browser,
> but I still see "contacts". Any suggestion?
1) case-sensitive. Are you sure you haven't translated "Contacts"
instead of "contacts"?
2) fuzzy-mark. I've noticed t
I am sorry I know this is an old topics.
But I spent the whole day and still unable to fix this problem.
NoReverseMatch at /1/
Reverse for ''blog.views.add_comment'' with arguments '(1L,)' and keyword
arguments '{}' not found.
Request Method:GETRequest URL:http://192.168.71.58:8007/1/Django
either remove the quotes from {% url 'blog.views.add_comment' %} (so it's
{% url blog.views.add_comment %}) or {% load url from future %}
Loading from future is the better option, I think.
and for future reference:
Reverse for ''blog.views.add_comment'' with arguments '(1L,)' and
keyword argume
Tears
thanks!
But I am confused.
For example,
the following code needs to add single quote.
{% block content %}
Add Todo items
Is there a link to give me detailed description?
I want to learn it and never get stuck again.
Thanks!!
On Friday, August 17, 2012 5:3
In this case, you are using a 'named URL' in the Admin namespace. Here's
two links that may help you learn a bit more about this topic.
https://docs.djangoproject.com/en/dev/topics/http/urls/#naming-url-patterns
https://docs.djangoproject.com/en/dev/topics/http/urls/#defining-url-namespaces
https:
> But I am confused.
> For example,
> the following code needs to add single quote.
>
> {% block content %}
> Add Todo items
https://docs.djangoproject.com/en/dev/releases/1.3/#changes-to-url-and-ssi
also, that won't work with double quotes either, unless you import
future, and a bunch of other t
Just curious, which data do you not have available when using signals? You
mentioned the ID but this *should* be available during post_save and
pre_delete hooks, if I'm not mistaken.
Also, I'd recommend caution on performing external server calls during a
single HTTP Request. You might have better
+1 on "Roll your own" solution. Complicated M2Ms and Django Forms aren't
always the cleanest pair of features to work with when combined.
On Fri, Aug 17, 2012 at 9:36 AM, houmie wrote:
> Thanks Melvyn,
>
> To be honest I would be willing to purchase a widget if there was one. iw
> ill look into
> http://www.django-userena.org/
++
I've successfully combined it with django-social-auth to have
facebook/twitter/google/openId login
--
"The whole of Japan is pure invention. There is no such country, there
are no such people" --Oscar Wilde
|_|0|_|
|_|_|0|
|0|0|0|
(\__/)
(='.'=)This is Bunny
Thanks.
I am going to read it.
Have a great weekend!
On Friday, August 17, 2012 6:30:26 PM UTC-4, Tomas Neme wrote:
>
> > But I am confused.
> > For example,
> > the following code needs to add single quote.
> >
> > {% block content %}
> > Add Todo items
>
> https://docs.djangoproject.com
On 17-8-2012 18:41, Tom wrote:
> I'm able to export the data this way, but I can't get the attributes
> of the full model as I would as if I was using the Django shell.
> Particularly important is the ID of an object, because without that I
> won't know which ID to update on the remote web service
You may want to consider a library like Django Allauth by Raymond
Penners, it provides majority of Social Authentication options and a
Custom Registration option as well out of the box.
Repository: https://github.com/pennersr/django-allauth
Tutorial: http://techstricks.com/django-allauth-tutorial-
You can either create a symlink or add the django directory to your
path for it to work, on windows the django files are installed in
"C:\Python27\Lib\site-packages\django". You can replace the Python
directory according to the version of python you are using.
On Fri, Aug 17, 2012 at 11:10 PM, num
If you still face problem you can go through this tutorial right here
-> http://techstricks.com/install-django-on-windows-7/
On Sat, Aug 18, 2012 at 7:40 AM, Amyth Arora wrote:
> You can either create a symlink or add the django directory to your
> path for it to work, on windows the django files
I seem to be getting a DeprecationWarning when my view hits this line of
code:
return HttpResponseRedirect(reverse(results, args=[query.jobid]))
I'm not directly using any generic views here. Is this a bug? If not,
what is the right way to redirect to a different view? That line of code
79 matches
Mail list logo