On Saturday 06 March 2010 06:07:30 dogfuel wrote:
> most of you probably know this will not give the desired result - it
> shows the correct test, but not as a hyperlink.
Moving the method to ModelAdmin and setting `allow_tags` True on it should
solve this problem:
class
Getting out of the bed, I partly found why this new problem occurs.
This is because the following HTML line:
Becomes this after the first submit by the browser:
Then I loose "id_form-0" substring and the corrupted HTML cannot work
twice.
This seem encouraging, but now I need to sleep. I will
I made some progress replacing the defective line with:
formset.forms[i] = ArticleForm(cd[i])
Mysteriously: it work when the browser send the first submit. But the
form becomes empty if I submit twice.
Here is the template:
Test
Test
{% if form.errors %}
Karen Tracey wrote:
I'm guessing you are using MySQL That's just how it behaves, by
default. See:
http://dev.mysql.com/doc/refman/5.1/en/server-session-variables.html#sysvar_sql_auto_is_null
Wow, thanks. I now see that this has been brought up a few times
before. This MySQL behavior
Good evening,
I stick with the above error message in the following example. I
looked at each
attributes of the object (Base_fields, etc.), but I can't find how I
to assign the new dataset back into the form.
def manage_articles(request):
ArticleFormSet = formset_factory(ArticleForm)
if
In a model, I have added a method that builds text for a html link
(based on model attributes) similar to:
-
from django.db import models
class Destination(models.Model)
name = models.CharField(max_length=25)
location_nbr = models.CharField(max_length=4)
I'm guessing you are using MySQL That's just how it behaves, by default.
See:
http://dev.mysql.com/doc/refman/5.1/en/server-session-variables.html#sysvar_sql_auto_is_null
Karen
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this
Ilya Braude wrote:
Hello!
I've run into a problem when calling .get on a related field manager
with id = None.
As far as I understand, doing an objects.get(id=None) should throw a
DoesNotExist exception.
However, it seems that there is some caching going on, as demonstrated
in this trivial
This is something I've been looking around for earlier. Thanks for
posting it here as well! I originally found it here: (http://
groups.google.com/group/django-users/browse_thread/thread/
1f97ae29f23f71d4)
But after using that type of method to list a ManyToManyField (in my
case, a field called
Hello!
I've run into a problem when calling .get on a related field manager
with id = None.
As far as I understand, doing an objects.get(id=None) should throw a
DoesNotExist exception.
However, it seems that there is some caching going on, as demonstrated
in this trivial example:
Any ideas? Can anyone else try this and report back? Just insert the
code below into a view function and start the dev. server with "python
-Wall manage.py runserver". Thanks.
On Feb 28, 5:28 pm, Brian Neal wrote:
> I'm having trouble seeing PendingDeprecationWarning's on
Russell Keith-Magee (freakboy3...@gmail.com) wrote:
> On Sat, Mar 6, 2010 at 6:55 AM, Kenny Meyer wrote:
> > Wilmer A. Delpratt (wdelprat...@gmail.com) wrote:
> >> Hi everyone..i'm new in this group...my friends says this is one of
> >> the best groups...
> >> I'd like to
On Sat, Mar 6, 2010 at 9:09 AM, Phlip wrote:
>> >>> (I also disagree with leaving out the spaces around =, but obviously
>> >>> obeying a team style guide supersedes improving it...)
>>
>> >> ... the goal of clarity/legibility
>>
>> > uh...
>>
>> ;) I meant *having* a style
> >>> (I also disagree with leaving out the spaces around =, but obviously
> >>> obeying a team style guide supersedes improving it...)
>
> >> ... the goal of clarity/legibility
>
> > uh...
>
> ;) I meant *having* a style guide was consistent with said goal.
right - following an aesthetic style
On Sat, Mar 6, 2010 at 6:55 AM, Kenny Meyer wrote:
> Wilmer A. Delpratt (wdelprat...@gmail.com) wrote:
>> Hi everyone..i'm new in this group...my friends says this is one of
>> the best groups...
>> I'd like to know how i can use a ManyToManyField in a "list_display",
>> i've
Wilmer A. Delpratt (wdelprat...@gmail.com) wrote:
> Hi everyone..i'm new in this group...my friends says this is one of
> the best groups...
> I'd like to know how i can use a ManyToManyField in a "list_display",
> i've read the documentation, but there says this is not possible
> (isn't
Hola Wilmer!
Is it not available in the newest Django?
-Wolf
sent from the research lab at http://networksecuritynews.net
On Mar 5, 2010 3:14 PM, "Wilmer A. Delpratt" wrote:
Hi everyone..i'm new in this group...my friends says this is one of
the best groups...
I'd like
Hi everyone..i'm new in this group...my friends says this is one of
the best groups...
I'd like to know how i can use a ManyToManyField in a "list_display",
i've read the documentation, but there says this is not possible
(isn't supported),i wish to know if there is another way to solve
this
On Mar 5, 2010, at 1:03 PM, Phlip wrote:
> On Mar 5, 8:41 am, Peter Herndon wrote:
>
>> On Mar 4, 2010, at 7:37 PM, Phlip wrote:
>
>>> (I also disagree with leaving out the spaces around =, but obviously
>>> obeying a team style guide supersedes improving it...)
>>
>>
On Mar 5, 8:41 am, Peter Herndon wrote:
> On Mar 4, 2010, at 7:37 PM, Phlip wrote:
> > (I also disagree with leaving out the spaces around =, but obviously
> > obeying a team style guide supersedes improving it...)
>
> ... the goal of clarity/legibility
uh...
--
You
Senior Web Developer (Python/Django) - Joslin Diabetes Center, Boston
MA
Job Description: The Senior Web Developer position is responsible for
leading the design, development, support and management of internal
and external database driven web applications for the Research
community at the Joslin
Ah. That does make sense! I cant believe I missed that in the docs.
Thanks for pointing it out!
On Mar 5, 7:08 am, David De La Harpe Golden
wrote:
> On 05/03/10 01:30, NaMaK wrote:
>
> class DateTest(forms.Form):
> > ...
Thanks Karen for the tip on SELinux. After researching, I found i
needed to do:
setsebool -P httpd_enable_homedirs 1
chcon -R -t httpd_user_content_t /home/mysite
On Thu, Mar 4, 2010 at 8:15 PM, Karen Tracey wrote:
>
> Fedora 12 has the security-enhanced linux kernel.
On Mar 4, 2010, at 7:37 PM, Phlip wrote:
>
> Sorry, I didn't say "operator overload" (which are either spot-on or
> sophomoric, when they work).
I'm using "operator overloading" in this case because "id=" already has a
specific function, and you would have it do something in addition to that
On Friday 05 March 2010 18:09:22 gintare wrote:
> b = Blog( [name, tagline] , ['Beatles Blog', 'All the latest Beatles
> news] )
>
> >>> b.save()
How many items are you saving at once? Have you measured the time required to
execute these queries and the total time your view/management command
Yes. Look at the syntax for executemany() (as opposed to execute()).
Shawn
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
Hello,
Is it possible to pack name of the column and value before submitting
to the database.
I mean something to save( dictionary), where dictionaries key is the
name of column and dictionaries item is value to be saved) or
save(list_column_names, list_values)?
b = Blog( [name, tagline] ,
On Friday 05 March 2010 11:10:29 Omer Barlas wrote:
> How can I use a unicode string as a model instance?
You can't. However you can get a reference to your model class like this:
> from django.db.models.loading import get_model
> model_class = get_model('myapp', 'mymodel')
> instance =
2010/3/5 Omer Barlas
> I have an ajax form which updates the status field of a table's status
> column dynamically. I send the table name, and the Id to be replaced to the
> ajax processor, but when I try to call
>
> what = model_name.objects.get(Id=id_number)
>
> django
I have an ajax form which updates the status field of a table's status
column dynamically. I send the table name, and the Id to be replaced to the
ajax processor, but when I try to call
what = model_name.objects.get(Id=id_number)
django barks at me like this;
Traceback:
File
On 5 Mar 2010, at 05:15 , aditya bhargava wrote:
>
> Not quite, because 'in' does exact matching, and I'm looking for the inexact
> matching that 'contains' provides. Here's one way to simulate a
> 'contains_any' filter:
>
>t = ["acrylic","watercolors"] # my list of tags
>
>q =
On Mar 3, 5:32 pm, Oshadha wrote:
> Hia fellas,
>
> I'm kind of new to Django framework.as far as I know Django only
> supports four major database engines.I have a requirement to use
> Cassandra(http://incubator.apache.org(/cassandra/) as the database
> backend,but I
Cheers Karen.
I just wanted to make sure that all aspects of my question were
answered, so I separated the second problem into this thread. Thanks
for your help. (See other thread.)
Ken
On 5 Mar, 02:17, Karen Tracey wrote:
> I answered your question in the other thread
Many thanks Karen. This worked perfectly (though the 'name' attribute
is just name without the quotes).
Cheers,
Ken
On 5 Mar, 01:42, Karen Tracey wrote:
> On Thu, Mar 4, 2010 at 2:24 PM, Ken wrote:
> > Thanks for your example, but whilst you're
On 05/03/10 01:30, NaMaK wrote:
class DateTest(forms.Form):
... in_date=forms.DateTimeField(initial=datetime.datetime.now())
...
Well, note that the now() was executed when python first saw it, which
was just a bit after it first saw the class definition. Think about it -
it does make
Instead of passing media_url to each view, I do the following:
1) in my urls.py I put:
...
url(r'^media/(?P.*)$', 'django.views.static.serve',
{'document_root': settings.MEDIA_ROOT}, 'media'),
...
2) in my templates I put:
...
...
On Mar 4, 1:57 am, "mendes.rich...@gmail.com"
For those interested:
In my base template I've added this:
{% load custom_tags %}
{% if form %}
{% formerrors request form %}
{% endif %}
In my custom_tags template tags library:
@register.simple_tag
def formerrors(request, form):
for field, errors in form.errors.items():
for
37 matches
Mail list logo