Hi Danfi,
Thanks for your quick response. But can you explain a little more how
can we connect ChangeList class with that function change_view.
Confuse about it.
--RJ
2010/5/20 Danfi :
> In Auth group you can create a group and set the limits.
>
> see different panel maybe use changelist_view
On Fri, May 21, 2010 at 9:41 AM, Werner wrote:
> Hello,
>
> How can you include annotated results in a serialized QuerySet?
>
> I have this serialized query:
> serializers.serialize('json',
> Song.objects.filter(is_playing=False).annotate(nr_votes=Count('votes')).order_by('-nr_votes'))
>
> Howeve
On Fri, May 21, 2010 at 1:47 AM, Joe D wrote:
> Has anyone had any luck running Django on IronPython ?
Testing under IronPython hasn't been part of our regular testing
regimen, so I can't comment on the level of compatibility.
> This seems to have been reported to the IronPython team here:
>
> h
In Auth group you can create a group and set the limits.
see different panel maybe use changelist_view
I saw this just be similar to yours'
class Part(models.Model):
is_deleted = models.BooleanField()
//
class PartAdmin(admin.ModelAdmin):
actions =None
On May 21, 9:45 am, VWAllen wrote:
> I have my project set up to use Apache/mod_wsgi with different configs
> for dev, staging and production. I'd like to set up my dev server to
> automatically reload the WSGI app per request (without touching my
> django.wsgi file each time).
If you want to d
Hi Everyone,
I would like to implement different views in admin panel based on the user.
if the user is any other user apart from admin
then for all those models, the user should just be able to see those
objects,( no change, delete and add).
Those users should also not see the select boxes or b
On Fri, May 21, 2010 at 11:45 AM, VWAllen wrote:
> I have my project set up to use Apache/mod_wsgi with different configs
> for dev, staging and production. I'd like to set up my dev server to
> automatically reload the WSGI app per request (without touching my
> django.wsgi file each time).
I'
Hello,
How can you include annotated results in a serialized QuerySet?
I have this serialized query:
serializers.serialize('json',
Song.objects.filter(is_playing=False).annotate(nr_votes=Count('votes')).order_by('-nr_votes'))
However the key/value pare {'nr_votes': number} is not include into t
Hi, I'm writing a facebook app with django and it is running on google
app engine. Part of the application is calculating the strength of a
relationship between friends, and classifying it as 1 (weak), 2
(acquaintance), or 3 (close bond).
A copy of the relevant code is http://pastebin.com/AtQZDu65
You could create your own manager and have it do whatever you want -- even run
the SQL query you already want to write and still return a queryset.
http://docs.djangoproject.com/en/1.1/topics/db/managers/#id2
Shawn
--
You received this message because you are subscribed to the Google Groups
"
Anything wrong with adding a flag to the profile model? If the flag is not
set, show the profile stuff?
It keeps all the profile management in one model.
The "flag" could even be a timestamp, so you could show the prompt again, if
after X time the user has not added anything to their profile.
I would use auth.User as is.
When a new user (no existing django session) enters the code, django creates a
user account (random username and password) behind the scenes and logs in the
user. Then the user is identifiable as long as they stay on that machine. Set
the logout interval to whatev
John M wrote:
Sounds like two queries to me, sum all the refunds and then subtract
them from all the non-refund amounts. does that work for ya?
Not really, that requires two queries. I know this can be done in one
query in SQL, just wondering how to express that in Django ORM speak...
Chris
Sounds like two queries to me, sum all the refunds and then subtract
them from all the non-refund amounts. does that work for ya?
On May 20, 5:17 pm, Chris Withers wrote:
> Hi All,
>
> I have a Transaction model with a DecimalField called "amount" and a
> CharField called "action".
>
> How do I
Hi All,
I have a Transaction model with a DecimalField called "amount" and a
CharField called "action".
How do I sum all the transactions, multipling the amount by -1 when the
action is REFUND?
cheers,
Chris
--
Simplistix - Content Management, Batch Processing & Python Consulting
I have my project set up to use Apache/mod_wsgi with different configs
for dev, staging and production. I'd like to set up my dev server to
automatically reload the WSGI app per request (without touching my
django.wsgi file each time). I looked at two wsgi middleware projects,
memento and amnesia,
Thanks Karen for the reply.
I overlooked the ticket you mention.
Just for reference for others reading in the future this thread, here
is a simpler (and more portable) solution other than applying the
patch attached to http://code.djangoproject.com/ticket/7623.
If you modify the child model as fo
On Thu, May 20, 2010 at 4:26 PM, peppo wrote:
> I have the following problem with admin and multi table inheritance I
> don't understand (django 1.1.1).
>
> Model definition
>
> class Place(models.Model):
>name = models.CharField(max_length=50)
>address = models.CharField(max_length=80)
>
Hi,
I have the following problem with admin and multi table inheritance I
don't understand (django 1.1.1).
Model definition
class Place(models.Model):
name = models.CharField(max_length=50)
address = models.CharField(max_length=80)
class Restaurant(Place):
serves_hot_dogs = models.Bo
I've resolved my problem, the django project was in the directory "/
var/aplicações". So I've tried to access the folder "media/css" and I
couldn't because django couldn't resolve name "apilcações". So, I've
just rename the folder.
On May 18, 5:37 pm, C4m1l0 wrote:
> Hi, I've encountered the same
Has anyone had any luck running Django on IronPython ?
I get the following error:
File "C:\vcs\django\django\utils\functional.py", line 180, in
__prepare_class__
AssertionError: Cannot call lazy() with both str and unicode return
types.
I tried with the release version of django (1.2) as well as
For a one month contract opportunity in Toronto, offsite will be
considered as well.
Individuals only, no third party companies, sorry:)
Please contact me directly at tperro...@aquent.com as soon as possible
if you're interested.
Cheers!
Aquent Tree
--
You received this message because you are s
On 18 May 2010 17:30, Mitch Anderson wrote:
> Depending on your ADMIN_MEDIA_PREFIX in settings.py (default is /media/)
>
> your webserver should be configured to point to the django admin media
> location...
>
> I have this line in my apache config
>
> Alias /media/ /usr/share/pyshared/django/cont
On Thu, May 20, 2010 at 4:24 AM, shofty wrote:
> thanks for the swift response.
>
> On May 19, 10:05 pm, Bill Freeman wrote:
>> You could put a method on your basket object which calculates the shipping.
>> Then if the basket object is included in the context, you can trivially call
>> it.
>>
>
I'm trying to get rid of a weak Updates table that a coworker had been
hacking up for use as a "user was changed on such and such day/
time..." and replace it with AuditTrail but there are a number of
confounding issues.
AuditTrail: I don't have the User model overridden, how would I hook
it into
Thanks Peter ! But I don't want to use these, I want to know how to
realize it, maybe I have to refer to them.
On May 20, 5:59 pm, Peter Bengtsson wrote:
> There are much more efficient tree implementation made available for
> Django.https://tabo.pe/projects/django-treebeard/
> A much better plac
I'm really liking customizing the admin.
I would like to know if I could use the change_view.html template
with my own form data.
My question is how do I setup a fieldset from some arbitrary form such
that I can pass it to a change_view.html page.
I see that there is a admin/includes/fieldset.ht
SQ9MEV pisze:
> Lee Hinde pisze:
>> What's best practice here?
> Yet another way using nginx as a webserver:
> http://wiki.nginx.org/NginxHttpAccessKeyModule
And another one:
http://wiki.nginx.org/NginxHttpSecureDownload
--
Bart
--
You received this message because you are subscribed to the Goog
Lee Hinde pisze:
> What's best practice here?
Yet another way using nginx as a webserver:
http://wiki.nginx.org/NginxHttpAccessKeyModule
--
Bart
--
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...@
So, I managed to fix the problem.
If some has the same problem here are some useful infos:
- if you have a normal setting.py file then you should not have this
problem with djangojs domain translations
- if you have your settings.py file split into several sub-settings
the locale directory should
On 13/04/10 09:04, urukay wrote:
Hi,
I'm trying to create full text search on model, everything goes fine
when
searching TextFields but I have a problem with ForeignKey field.
How can i do that? Can anyone point me to the right direction?
Do you mean you want the results for Model2 searches
Hi,
I have a djangojs.po file and am compiling the messages with
compilemessages command.
I don't get any error but I can't see my translations in the js
catalog. I can only see the admin js translations.
How can I debug this problem?
Thanks in advance.
--
You received this message because you
thank you so much
On Apr 23, 8:19 pm, Nick Serra wrote:
> Whenever I use django on my windows box, i use XAMPP, which is a all
> in one installer that gets apache and mysql.
>
> So I:
> - install XAMPP
> - install python
> - svn checkout django in the site-packages folder
> - install mysql bindin
Hallöchen!
Tomasz Zieliński writes:
> On 20 Maj, 04:19, Mike Dewhirst wrote:
>
>> If it has to be secure rather than just wishful thinking the
>> webserver must demand credentials. If you are using Apache, that
>> means .htaccess files which point to a list of credentials for
>> each group.
>
>
Hi all,
I got some of the documents to enable static generator but still for
away from the result.
Please show me the way to implement it for my site so that I can
enhance the performance.
I am using apache + mod_wsgi.
I need to get detail about the apache configuration. How can I
configure it for
On 20 Maj, 04:19, Mike Dewhirst wrote:
>
> If it has to be secure rather than just wishful thinking the webserver
> must demand credentials. If you are using Apache, that means .htaccess
> files which point to a list of credentials for each group.
>
What is the difference between long, random f
Hello,
is there an easy way to reorder field display in a tabular admin inline, like
fieldsets for common admin forms?
Consider the following models, with Bar being edited inline:
class Foo(models.Model):
field1 = models.CharField(max_length=255)
field2 = models.CharField(max_length=255
Have you ever wanted to check the contents of a session or to search
the django_admin_log table?
Probably you will find this "free-and-little-more-than-a-snippet-
project" useful:
http://code.google.com/p/hyperlog/
Enjoy :-)
Ciao.
Marco.
--
http://thinkcode.tv/catalog/amazing-python - Capir
There are much more efficient tree implementation made available for
Django.
https://tabo.pe/projects/django-treebeard/
A much better place to start.
On 20 May, 07:06, Danfi wrote:
> Hi,
> In my models, I use "parent = models.ForeignKey('self', blank = True,
> null = True) " create a Folder tree
The way you set up the ordering (e.g. 'change_date') just change that
to '-change_date'. A minus in front of the ordering keyword reverses
the sort order.
On 20 May, 06:32, rahul jain wrote:
> Hi,
>
> In my model, I have set up one filter which helps in filtering out the
> results on admin Panel.
> Now that we have a fully PEP 302 compliant loading structure, it is exposing
> bugs in the PyAMF loader implementation.
Indeed it is - we have already come across this issue and fixed it -
check http://dev.pyamf.org/ticket/770 for details.
Cheers,
Nick
--
You received this message because y
thanks for the swift response.
On May 19, 10:05 pm, Bill Freeman wrote:
> You could put a method on your basket object which calculates the shipping.
> Then if the basket object is included in the context, you can trivially call
> it.
>
That seems simple enough for me to do.
> Or perhaps bette
On Thu, May 20, 2010 at 3:17 PM, ben wrote:
>
>
> On May 18, 9:35 pm, Russell Keith-Magee
> wrote:
>> On Tue, May 18, 2010 at 6:12 PM, ben wrote:
>> > Hi All,
>>
>> > After a recent svn update to my copy of Django/trunk I’ve been getting
>> > a persistent error relating to module loading (see be
Hi,
In my models, I use "parent = models.ForeignKey('self', blank = True,
null = True) " create a Folder tree
like :
A
-a1
-a2
--a21
--a211
--a22
B
-b1
and I use the "parent" as list_filter ,but I get a problem , when I
click 'a1' ,it only show the information in a1,
but I want it also show its ch
On May 18, 9:35 pm, Russell Keith-Magee
wrote:
> On Tue, May 18, 2010 at 6:12 PM, ben wrote:
> > Hi All,
>
> > After a recent svn update to my copy of Django/trunk I’ve been getting
> > a persistent error relating to module loading (see below). I am able
> > to create the same error from many b
class CheckIn(models.Model):
sample_id = models.AutoField(db_column='SampleID', primary_key=True)
date_arrived = models.DateField(db_column='DateArrived')
company_name = models.CharField(max_length=100, db_column='Company')
< plus any extra fields >
class Meta:
db_table
46 matches
Mail list logo