Hey,
I have a model for Thumbnail, but I cannot save it. It says:
AttributeError: 'Thumbnail' object has no attribute 'id'.
What is wrong?
I use django 1.0-final-SVN-unknown
thanks, Manuel
Here is an example:
>>> from portfolio.models import Photo, Thumbnail
>>> p = Photo.objects.all()[0]
Am 30.09.2008 um 20:21 schrieb Rajesh Dhawan:
>
> You are overriding __init__ but not making sure to call the base
> class's __init__ method which does a whole bunch of stuff whenever a
> new instance of a Model class is created. This is most definitely
> causing your problem. It's best not to ov
ilImage.ANTIALIAS)
image.save(self.miniature_filename, image.format)
### Signals instead of overwriting __init__(self)
from django.db.models.signals import post_init
def thumb_init(sender, **kwargs):
kwargs['instance'].process()
kwargs['instance'].make_
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
Hey,
to a model Event i attach some images. But how can I delete images
from an Event?
If I use something like
http://localhost:8000/moor/admin/doccms/eventimage/2/delete/
manually, the Image's sql entry will be removed, but a Error fol
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
Hey,
is it possible, to send a output, generated by a filter pipeline
chain to a template tag?
I want to split a page's tag, that is already processed by the
reStructuredText filter and a link generation filter, in several
subtexts to mix it
{% do_something el %}
>{% endfor %}
> {% endwith %}
>
> Regards,
> Aidas Bendoraitis aka Archatas
>
>
> On 6/25/07, Manuel Meyer <[EMAIL PROTECTED]> wrote:
>>
>> -BEGIN PGP SIGNED MESSAGE-
>> Hash: SHA256
>>
>> Hey,
>>
>> i
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
Hey,
how can I change the string for date/datetime fields in the admin
interface?
2007-08-15 should be changed to 15.8.2007 ("d.m.Y H:i")
Thanks, Manuel
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (Darwin)
iQEVAwUBRoJWtDOKNHIOcnYMAQj31g
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
Hey,
from other projects, running on the same django instance, I know that
there is a possibility to display a '+' icon located over the
ManyToManyField, that allows u to add a new object to relate to.
So - in my case - you could add a contact
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256
Yes, of course... THANKS!!!
>
> You need to add the Admin class to ContactPerson
>
> -rob
>
> On Jul 12, 6:59 am, Manuel Meyer <[EMAIL PROTECTED]> wrote:
>> -BEGIN PGP SIGNED MESSAGE-
>> Hash: SHA256
Hi,
in a model Article i want to store the user who created the article.
I have this:
class Article(models.Model):
owner = models.ForeignKey(User, null=True, blank=True)
But I wonder, if it is possible, to set the owner in an overwritten
save() method, as a drop-down list is
Hey,
I have a type Article in which i hold a Type HeaderImage within an
OneToOneField-Relationship.
When adding an article via contrib.admin interface everything works
as expected.
But if I edit an existing article, the drop-down list doesn't appear
anymore.
class Article(models.Model):
> No, that's they way it is documented as working. The one-to-one
> field acts as the primary key for the model, and primary keys can't
> be edited. From http://www.djangoproject.com/documentation/model-
> api/#one-to-one-relationships:
>
> This OneToOneField will actually replace the prima
> On Sun, Apr 13, 2008 at 8:34 AM, Manuel Meyer
> <[EMAIL PROTECTED]> wrote:
>
> > No, that's they way it is documented as working. The one-to-one
> > field acts as the primary key for the model, and primary keys can't
> > be edited. From http:
Hey,
as described here [1] I get an NoReverseMatch error on debian when
using django-threadedcomments, while everything works well an mac.
In both cases I use 0.97-pre-SVN-7436.
Does anybody know this behaivior?
Thanks, Manuel
[1] http://groups.google.com/group/django-threadedcomments/
bro
I twisted some letters in the urls-entry
Am 19.04.2008 um 22:28 schrieb Manuel Meyer:
> Hey,
> as described here [1] I get an NoReverseMatch error on debian when
> using django-threadedcomments, while everything works well an mac.
>
> In both cases I use 0.97-pre-SVN-7436.
&
Hey,
I wonder how to get a ':' (btw: what's its name in english?) in my
url, so it is shown as : in the address and not as %3A .
Like wikipedia does:
http://en.wikipedia.org/wiki/Portal:Arts
If i try
def get_absolute_url(self):
return '/top-category:'+self.title_plural
it gets print
Hey,
I want to get the Fieldmodel(Charfield, TextField, SlugField...) of
each member of any given object.
What I have now is this:
def search_objects_attributes(o):
object_dir = dir(o)
for i in object_dir:
try:
current_attribute = getattr(o
Hey,
I am using Free threaded comments on a 0.97-pre-SVN-7436 site.
I am developing on Mac and run the site on debian/apache2/mod_python.
under debian i found a strange behavior:
Some comments are pre-dated 7 hours. ie.:
In my timezone it's 15:23. A new comment will be published with this
time
Did anyone succeed in integrating KSS in django?
I tried to make the kss.django demo-app "coolwiki" run, but it didn't
work:
KeyError: 'Plugin is not registered: scriptaculous-effects'
Where should the PlugIn be, where can I add it?
Thanks, Manuel
--~--~-~--~~~-
Hey,
I added a class "News" to models.py of an installed app. But its
permissions doesn't appear in the Change User View of the admin
interface. Need it to be activated somehow?
As superuser I can use News.
I use .96-pre
Thanks, Manuel
--~--~-~--~~~---~--~~
Y
To answer my own question:
python manage.py syncdb
> Hey,
>
> I added a class "News" to models.py of an installed app. But its
> permissions doesn't appear in the Change User View of the admin
> interface. Need it to be activated somehow?
> As superuser I can use News.
> I use .96-pre
>
Hey,
I have Category and Projects. Both can have a Category as parent =
models.ForeignKey(Category).
So it is possible, that Projects and Categories can have the same
Category as parent.
But what I want to have is, that any Category - that is parent for
any Project - cannot be parent for an
Hey,
inside a inclusion tag I try to set a variable to the context. But in
no template it is accessible.
I followed http://www.djangoproject.com/documentation/
templates_python/#setting-a-variable-in-the-context
If I print the context in [1], level is defined, but if I use {%
debug %} not
Hi,
I want to write a web site for tourists about the city I live in.
A main component will be a sightseeing product:
It consists of sights, that can be ordered in lists or in guided tours.
As I am an absolute beginner in django, I need already help at this
point:
How can I add sights to guide
Hi,
I want to try automatic header-graphics according to this recipes:
http://www.jacobian.org/2006/jun/30/improved-text-image-view/ and
http://www.jacobian.org/2006/jun/30/improved-text-image-view/
But when i try to access
http://localhost:8000/a/?text=this
I get an error:
Tracebac
Hi,
I try to bring a django-project online via fastcgi, but i get
following error:
You don't have permission to access /home/myusername/public_html/
ultimateWeimar/django.fcgi/ on this server.
my .htaccess looks like this
AddHandler fastcgi-script .fcgi
RewriteEngine On
RewriteRule ^(media
Hello list members!
Since yesterday I am testing around with Django, and this GREAT tool
impresses me a lot!
So, I still play with the poll tutorial. I trying to make some
improvements to it's code, to learn techniques I will use in future
work.
I.e. I added image-upload. Adding works perf
27 matches
Mail list logo