Hi all,
When I try to view list of objects in admin I get the following error
message for every list view of every application, including the
contributed ones such as comments:
'admin_list' is not a valid tag library: Could not load template
library from django.templatetags.admin_list, cannot im
Hi,
the prefix delimiter (minus) is not very javascript friendly. Why not
use e.g. two underscores?
See newforms/forms.py class BaseForm:
def add_prefix(self, field_name):
"""
Returns the field name with a prefix appended, if this Form has a
prefix set.
Subcla
BTW, my models do not yield any error, and everything except the admin
are working as expected.
On 3 Temmuz, 11:22, omat <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> When I try to view list of objects in admin I get the following error
> message for every list view of every application, including t
Hello people - I wrote earlier this mail on django devs but Adrian and
Graham pointed me, that I should write here.
I am using Apache 2.0 and mod python 3.3,1 on Ubuntu Dapper x86_64. I
found a strange behavior during SetEnv directive. But let's start from
the
beginning. I have two virtual hosts,
On Jul 3, 8:40 pm, bluszcz <[EMAIL PROTECTED]> wrote:
> Hello people - I wrote earlier this mail on django devs but Adrian and
> Graham pointed me, that I should write here.
>
> I am using Apache 2.0 and mod python 3.3,1 on Ubuntu Dapper x86_64. I
> found a strange behavior during SetEnv directive
Thanks Graham for the fast reply. Unfortunately, I cannot list the
sites directly - too much of them (about 100), and generally I have to
handle all except of 'admin' one :(
On 3 Lip, 13:07, Graham Dumpleton <[EMAIL PROTECTED]> wrote:
> On Jul 3, 8:40 pm, bluszcz <[EMAIL PROTECTED]> wrote:
>
>
>
My model named: Post
It has a field created_at as:
created_at = models.DateTimeField(auto_now_add = True)
Would Post.created_at be of string or datetime ?
I want to add 2 weeks to it, like Post.created_at + 14 days. Can I do
this?
Post.created_at =Post.created_at + datetime.timedelta(weeks=2)
Russell Keith-Magee wrote:
> On 7/3/07, adm <[EMAIL PROTECTED]> wrote:
>> Russ,
>> I sure can try that. The problem is I haven't gone through the
>> Django framework in details as such, which make me quite helpless
>> while adding the support.
>
> Thats fine. However, as fair warning - this
On 7/3/07, Carl Karsten <[EMAIL PROTECTED]> wrote:
>
> Russell Keith-Magee wrote:
> > Thats fine. However, as fair warning - this is the first time that
> > Sybase support has been requested (compared to the regular requests
> > for MS SQL Server support), so I wouldn't expect to see Sybase suppor
I've just found one thing - this happen if two users send two request
at once - one for admin.coke, second for *.coke. This happen when
apache handling these requests by one process (i set PID logging..)
On 3 Lip, 13:41, bluszcz <[EMAIL PROTECTED]> wrote:
> Thanks Graham for the fast reply. Unf
Hi
We are using mysql 5.0.42 and are getting this error when trying to
insert records of over 5M. We have set max_allowed_packet as per the
advice on http://dev.mysql.com/doc/refman/4.1/en/packet-too-large.html
to be 1G but to no avail althought this did allow the direct sql to
suceed. Does djang
I'd suggest:
from datetime import datetime, timedelta
p = Post() # create an instance of Post
# p.created_at should now be a datetime-object to python
p.created_at + timedelta(weeks=2)# will also be a datetime object
see also: http://docs.python.org/lib/module-datetime.html
--~--~
Russell Keith-Magee wrote:
> On 7/3/07, Carl Karsten <[EMAIL PROTECTED]> wrote:
>> Russell Keith-Magee wrote:
>>> Thats fine. However, as fair warning - this is the first time that
>>> Sybase support has been requested (compared to the regular requests
>>> for MS SQL Server support), so I wouldn't
Hi, I'm a django newb and I am trying to make an upload form.
my view is:
11 def newupload(request):
12 manipulator = PFile.AddManipulator()
13 username = request.user.username
14 u = User.objects.get(username=username)
15
16 if request.POST:
17
Am Tue, 03 Jul 2007 15:07:14 -
schrieb "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>:
> We are using mysql 5.0.42 and are getting this error when trying to
> insert records of over 5M.
I may sound nosy, and apologize for that. But don't you think that you
have a software design bug when one record
johnny wrote:
> My model named: Post
>
> It has a field created_at as:
> created_at = models.DateTimeField(auto_now_add = True)
>
> Would Post.created_at be of string or datetime ?
>
> I want to add 2 weeks to it, like Post.created_at + 14 days. Can I do
> this?
> Post.created_at =Post.created
It's indeed a python piece of code:
def is_visible_by(self, author):
projects = author.projects.all()
return author.user.is_staff or\
author.is_manager or\
(author.is_lead_writer and (self.project in projects)) or\
(author == self.main_auth
1. Rails people are big on not writing HTML.
<%= link_to 'Apple', :url => 'http://apple.com' %>
http://apple.com";>Apple
The shortcuts just aren't shorter. And, as anyone with a large Rails
app will tell you, once you get users, you frantically go around
removing all of those template helpers.
Martin Winkler wrote:
> Am Tue, 03 Jul 2007 15:07:14 -
> schrieb "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>:
>
>> We are using mysql 5.0.42 and are getting this error when trying to
>> insert records of over 5M.
>
> I may sound nosy, and apologize for that. But don't you think that you
> have a
On 7/3/07, scadink <[EMAIL PROTECTED]> wrote:
> 3a. I wish Django would simply assume that my templates are under
> app_name/templates. That way, I would have my models and views in the
Use the app template loader?
http://www.djangoproject.com/documentation/templates_python/#loader-types
>
On 7/3/07, jj <[EMAIL PROTECTED]> wrote:
> def is_visible_by(self, author):
> projects = author.projects.all()
> return author.user.is_staff or\
> author.is_manager or\
> (author.is_lead_writer and (self.project in projects)) or\
> (author =
On 7/2/07, Lawrence Wang <[EMAIL PROTECTED]> wrote:
> tell me more about transaction management -- i don't believe i'm using any,
> because there's nothing in my settings.py that would seem to apply, but
> perhaps i've overlooked something trivial.
You can read about it at [0]. You can read more
Hi!
In my project, I'm doing a .save() but nothing is being saved and I
cant figure out why...
The code is:
[models.py]
class LevelForm(forms.Form):
level_Name=RegexField('^level\d[a-b]?$', required=True,
max_length=20, initial='level', error_message='Blah')
instrument_Name=ChoiceField(re
On 7/3/07, Benjamin Slavin <[EMAIL PROTECTED]> wrote:
>
>
> On 7/2/07, Lawrence Wang <[EMAIL PROTECTED]> wrote:
> > tell me more about transaction management -- i don't believe i'm using
> any,
> > because there's nothing in my settings.py that would seem to apply, but
> > perhaps i've overlooked s
Hi,
I have a basic form question I have been struggling with.
I have a form with a set of radio options and I want to specify the
option values.
I got this to work. However, I was assigning the values external to
the form in the view. This form will be used in quite a few spots and
I would
I try, with not sucess to apply the patch for make worj django and MS
Sql.
The tickets is a jungle and not see the logic in how is the thing
organized. I'm building a store based in satchmo for integrate a
couple of local ERP system, based in MS Sql, so I have a motivation to
work on it...
Anyb
Am Tue, 3 Jul 2007 17:34:33 +0200
schrieb Martin Winkler <[EMAIL PROTECTED]>:
> If you have binary data, why don't you use FileField and ImageField?
> That way you'd store the large data in the filesystem and only have a
> reference to the file in the database.
Maybe I should clarify the problem
Hey guys,
I'm still new to Python and Django, heck I guess I consider myself new
to web development in general, and I'm at a part where I'm a little
lost on what to do. In a nutshell I have a form that will take in a
Country (from a drop down) and a postal code. I want to grab the
province/state
mamcxyz wrote:
> I try, with not sucess to apply the patch for make worj django and MS
> Sql.
>
>
> The tickets is a jungle and not see the logic in how is the thing
> organized. I'm building a store based in satchmo for integrate a
> couple of local ERP system, based in MS Sql, so I have a moti
Hey Roboto --
There isn't anything Django-specific about consuming web services;
it's just Python. You might want to check out the section of Dive Into
Python that covers web services:
http://diveintopython.org/http_web_services/index.html
God luck,
Jacob
--~--~-~--~~~-
Is there an easy way to augment deleting from the admin page.
Specifically, I'm uploading an image and as part of saving the image
model I make a thumbnail (which isn't part of the model). The admin
delete will remove the uploaded image but not the thumbnail, so I'd
like to basically say, whenever
Thanks Jacob,
I was looking for something like this!
On Jul 3, 2:17 pm, "Jacob Kaplan-Moss" <[EMAIL PROTECTED]>
wrote:
> Hey Roboto --
>
> There isn't anything Django-specific about consuming web services;
> it's just Python. You might want to check out the section of Dive Into
> Python that cov
rskm1 wrote:
> Any chance of getting the _DOCS_ updated?
>
> For example, it would be nice if the first place {{perms.foo}} was
> mentioned would at least hint that it wouldn't work in conjunction
> with the render_to_response() shortcut, or perhaps it could introduce
> the RequestContext class (
Jeremy Dunck wrote:
> On 5/23/07, Michael Lake <[EMAIL PROTECTED]> wrote:
> ...
> > return render_to_response('lab/user.html', data)
>
> Yeah, that's your problem right there.
> :
> ... I imagine this bites a lot of people on the ass. :(
Add me to the list of ass-bitten and extremely frust
Hi Ana,
>
> [views.py]
> level=Level()
> level.level_name=form.clean_data.get('level_Name')
> level.instrument_name=form.clean_data.get('instrument_Name')
> level.available=form.clean_data.get('available')
> level.tablename=form.clean_data.get('tabelname')
>
> level.save()
Hi,
> I was basing my template off
> of:http://www.djangoproject.com/documentation/0.95/forms/
You should definitely move to the newforms framework with either the
0.96 release or the SVN trunk. See the newforms docs here:
http://www.djangoproject.com/documentation/newforms/
-Rajesh
--~--~-
Hello:
I know that Django provides 3 ways in using Web forms: Admin Forms,
Generic views and New Forms where Admin forms is the easiest one to
use.
What I would like to know is:
1) Which determinant aspects should force me to use Generic Views
instead of Admin Forms? And
2) Which determinant aspec
I was really excited about Rails. But however much it claims that it
follows the DRY convention, I unfortunately do find myself repeating
myself for things like the admin area of my site.
That's why the Admin interface of Django has now become ever so much
more appealing to me. Having spent a who
> Ah, ok. Yeah, this has been broken a long while.
Well, I guess that's a good reason for it not to work! : )
> The comments contrib needs some love, but I understand Jacob's working
> on a rewrite
Good deal! I look forward to it.
> But you're in luck; I recently ported from an old version of
Hi,
Since I can't (as far as I can tell) enable inline editing on a one-to-
one field, I'm trying to use an inline-edited many-to-many field with
a related object maximum of 1. Trivial example:
class Trivial(models.Model):
name = models.CharField(maxlength=50)
class Admin:
pass
Hey guys, I'm trying to extend the User class to add some additional
information to user's profiles. I've been reading
http://www.b-list.org/weblog/2006/06/06/django-tips-extending-user-model
for some information, but I don't think the blog post really explains
how to get it fully working. What I'
I posted about the exact same issue a couple days ago and someone
suggested using the js attribute of the admin class. Unfortunately as
a novice programmer this is going to take me a while to navigate so
I've moved on to other areas of my application before I get down into
it. I'm watching this
Correct. The whole problem is effectively the result of a race
condition on setting os.environ the first time just before Django
settings file is imported. Normally the requests should be getting
handled in the same Python subinterpreter though and thus os.environ
would be different for each subin
I don't know if this exists or not, but I'd like to insert a tag (much
like cycle) that allows the random selection of a string. I'm trying
to randomly assign a class to a to simulate "random image
rotator" type functionality. Something like...
Any ideas?
--~--~-~--~~
> I don't know if this exists or not, but I'd like to insert a tag (much
> like cycle) that allows the random selection of a string. I'm trying
> to randomly assign a class to a to simulate "random image
> rotator" type functionality. Something like...
>
>
Sounds like you want to make a custo
On 7/4/07, Blaine Garrett <[EMAIL PROTECTED]> wrote:
>
> The very last line is the one that doesn't work. Says
> BookmarkSubmitForm is not defined. This makes sense, but I have no
> idea how idea to assign this. I tried self which is undefined, etc.
'self' won't be defined until there is an insta
On 7/4/07, Vizcayno <[EMAIL PROTECTED]> wrote:
>
> Hello:
> I know that Django provides 3 ways in using Web forms: Admin Forms,
> Generic views and New Forms where Admin forms is the easiest one to
> use.
> What I would like to know is:
> 1) Which determinant aspects should force me to use Generic
Hello all,
I have a trouble with newforms lib and MultiWidget.
I created a custom MultiWidget based on SplitDateTimeWidget.
The problem is that when I run the form.is_valid()
The value send to the DateField clean method is a list ['1', '1',
'2000'].
Then the strptime command in this function fai
On 7/4/07, Bryan Veloso <[EMAIL PROTECTED]> wrote:
>
> I don't know if this exists or not, but I'd like to insert a tag (much
> like cycle) that allows the random selection of a string. I'm trying
> to randomly assign a class to a to simulate "random image
> rotator" type functionality. Something
> One option is to use the 'random' filter; your context would need to
> define the list of possible strings:
>
> Context({
>'classes': ['class1','class2','class3','class4']
>
> })
>
> but then your template could use:
>
> {{ classes|random }}
Can you serve Context to the base template?
I tho
On 7/4/07, David <[EMAIL PROTECTED]> wrote:
>
> Please let me stress that that isn't the full implementation (if you
> want me to go into further detail, please let me know). Basically, I
> want to be able to assign many different objects (of different model
> types) to an Article. I need to be a
On Tue, 2007-07-03 at 15:21 +, Rishtastic wrote:
> Hi, I'm a django newb and I am trying to make an upload form.
>
> my view is:
>
> 11 def newupload(request):
> 12 manipulator = PFile.AddManipulator()
> 13 username = request.user.username
> 14 u = User.object
On 7/4/07, Bryan Veloso <[EMAIL PROTECTED]> wrote:
>
> > {{ classes|random }}
>
> Can you serve Context to the base template?
> I thought of that earlier, but I couldn't think of how to give it
> Context.
What do you mean? You pass a context to the template renderer; if the
template you render re
> If you want to hardcode the availability of the 'classes' variable in
> every context (so you don't have to remember to define it every time),
> you could write a context processor. See
> django.core.context_processors for examples.
That's probably what I'll need since it'll always have to be t
Hello!
I'm using the "nested set" abstraction to store some tree data in a
Django model. So the model class looks like
class TreeNode(models.Model):
value = models.CharField(maxlength=10)
leftVisit = models.IntegerField(primary_key=True)
rightVisit = models.IntegerField(db_index=True
On Wed, 2007-07-04 at 05:29 +, Lars wrote:
> Hello!
>
> I'm using the "nested set" abstraction to store some tree data in a
> Django model. So the model class looks like
[...]
> This all works fine, but, in this abstraction, an insert into the tree
> updates everything to the "right" of it. T
Hi Malcolm,
On Jul 4, 3:39 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> In the general case, this would be very hard to solve, because you could
> have objects in a different process space that also need to be notified.
Ah, I hadn't thought of that.
> If you are satisfied with only updat
On 4 juil, 04:45, xgdlm <[EMAIL PROTECTED]> wrote:
> Is there someting special to do before "cleaning" the form with
> MultiWidget based fields ?
The answer is ...
... implementing a custom value_from_datadict method for the class
DropDownDateWidget(MultiWidget)
xav
--~--~-~--~~---
58 matches
Mail list logo