Anyone know of any projects like this in Django? The closest I can find
is Luca http://www.epx.com.br/luca/ which is based on turbogears.
I find myself in need of at least some accounts receivable app that can
track user invoices, payments, balances, and the standard stuff required
for
Oh yeah, SQL output:
[EMAIL PROTECTED]:~/iFriends$ python manage.py sql People
BEGIN;
CREATE TABLE "People_blog" (
"id" serial NOT NULL PRIMARY KEY,
"title" varchar(200) NOT NULL,
"text" text NOT NULL
);
CREATE TABLE "People_person" (
"id" serial NOT NULL PRIMARY KEY,
On Mar 8, 2008, at 7:04 AM, Evert Rol wrote:
>
> Have you checked what 'd' is here? It may be something different than
> you'd expect or hope, in particular for the __dict__[d] lookup (not
> sure what you're expecting here).
> I would actually work with something like
>
brydon,
You won't get two almost identical tables if you use the above linked
approach. Reason being is that the above approach effectively
constructs the additional table needed for a many-to-many relationship
explicitly. The model Writer is effectively the users_user_link table.
Not that no
On Sat, 2008-03-08 at 16:59 -0800, brydon wrote:
> That's helpful and I'll likely take that approach but I believe that
> means I have two almost identical tables?
If you have two things related via a many-to-many relation and an
intermediate table, that's three tables serving different
On Sat, 2008-03-08 at 19:18 -0600, Michael Hipp wrote:
> I have a legacy database that happens to be PostgreSQL. It has this primary
> key field:
>
> CREATE TABLE foo (
> id integer PRIMARY KEY,
>
> When I do 'inspectdb' it gives me a model with this in it:
>
> class
I have a legacy database that happens to be PostgreSQL. It has this primary
key field:
CREATE TABLE foo (
id integer PRIMARY KEY,
When I do 'inspectdb' it gives me a model with this in it:
class Foo(models.Model):
id = models.IntegerField(primary_key=True)
But
That's helpful and I'll likely take that approach but I believe that
means I have two almost identical tables?
I'll likely get these table names wrong don't pay too much attention
to themSay I created a UserLink class that had user, link, and
date_created. I think I'd end up with a
On Sat, 2008-03-08 at 16:19 -0800, brydon wrote:
> I know this answer should exist somewhere in documentation or on the
> net, hopefully someone can point me there. I'm looking for model help
> and I think I can frame it best with an example. Say you're building a
> delicious like model. You
I know this answer should exist somewhere in documentation or on the
net, hopefully someone can point me there. I'm looking for model help
and I think I can frame it best with an example. Say you're building a
delicious like model. You have users, user have links. Those links
have common elements
On Sat, 2008-03-08 at 14:49 -0800, Brandon Taylor wrote:
> Hello,
>
> Yes, I'm using MySQL 5 and Django .097 pre. Actually, I just went into
> the introspection.py file and changed the first line to:
>
> from django.db.backends.mysql.base import DatabaseOperations
>
> ...and we're good to go.
Hello,
Yes, I'm using MySQL 5 and Django .097 pre. Actually, I just went into
the introspection.py file and changed the first line to:
from django.db.backends.mysql.base import DatabaseOperations
...and we're good to go. I'm not sure why it would be that way in the
repository, but it seems to
If you put those options in each they will each be checked for
uniqueness on that date. If you want them unique together with the
date check unique together and include the date field. This is all
explained in the models documentation that I gave you.
> > call. You can then use the unique for
> File
> "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/
> site-packages/django/db/backends/mysql/introspection.py",
> line 1, in
>from django.db.backends.mysql_old.base import DatabaseOperations
> ImportError: No module named mysql_old.base
>
>
> I'm using Python 2.5.1
On Sat, Mar 8, 2008 at 2:52 PM, DuncanM <[EMAIL PROTECTED]> wrote:
> And I have a home page that I would like to display a "widget" (5 most
> relevant of each) on that home page...
> In the current situation I have created the view in the Events
> application. How would I create a view
Nick,
Thanks for the reply.
How would I scale something like this though?
Imagine I had the apps:
News,
Events,
Menus,
Offers
And I have a home page that I would like to display a "widget" (5 most
relevant of each) on that home page...
In the current situation I have created the view in the
DuncanM wrote:
> My events.views:
> [code]
> from sakushi.events.models import Event
> from sakushi.news.models import News
> from django.shortcuts import get_object_or_404, render_to_response
> from django.http import HttpResponseRedirect
>
> def events(request):
> latest_events_list =
Hi everyone, I'm brand-new to Django, so please bear with me.
I have created an app called 'portfolio' within my project, and added it to
my installed apps in 'settings.py'
In my models.py, here are my class definitions:
from django.db import models
class WorkCategory(models.Model):
All the fun of middleware can be found here -
http://www.djangoproject.com/documentation/middleware/
On Mar 8, 6:38 pm, binaryj <[EMAIL PROTECTED]> wrote:
> hi group,
> i have patched my cvs build of django with patch #2070. the patch
> works well and is great except that it throws very little
hi group,
i have patched my cvs build of django with patch #2070. the patch
works well and is great except that it throws very little light on how
to build a progress bar for the upload!
i read this line in the patch
1 """
2 MultiPart parsing for file uploads.
You were absolutely right. Thanks! It works now.
On Feb 25, 11:09 am, Rajesh Dhawan <[EMAIL PROTECTED]> wrote:
> Hi Dave,
>
> > I'm a bit of a Django noob, coming from -- shudder -- PHP. I'm trying
> > to make an Ajax page that saves data from a form with a view that
> > requires authentication.
Justin Fagnani wrote:
> This is the third time this issue has come up in the last day :)
>
> Try this, since it'll work for dictionaries, lists, and objects:
>
> from django.template import resolve_variable
> @register.filter
> def lookup(value, key):
> return resolve_variable(key,value)
>
>
Thanks Malcolm. I did some testing and the listdir function returns
extremely quickly so I don't think it's a big deal. But this will come
in handy if the gallery grows much larger. Thanks again.
On Fri, Mar 7, 2008 at 8:26 AM, Malcolm Tredinnick
<[EMAIL PROTECTED]> wrote:
>
>
>
> On Fri,
Thank you very much, that was exactly what I was looking for!
2B
On Mar 3, 11:58 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Mon, 2008-03-03 at 14:23 -0800, Berco Beute wrote:
> > I want to create a form for editing existing Poll objects and their
> > associated Choice objects (see
On Sat, Mar 8, 2008 at 6:49 AM, speleolinux <[EMAIL PROTECTED]>
wrote:
>
> Hi
>
> On Mar 7, 11:26 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
> wrote:
> > It is fairly important when reporting an error like this that you give
> > enough information to indicate where the error is coming from.
> ...
> thanks that did work!
>
> I did have max_length but it didn't like it
>
> must update django??
No, probably not yet then. I'm just using 0.97pre, where the warning
showed up. Probably doesn't in 0.96, but keep it in mind in case you
do update. (Unless of course you're still at 0.95.)
hello
thanks that did work!
I did have max_length but it didn't like it
must update django??
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
> Hi there
> I am having a problem with ForeignKey(Class) in my models.py
> if the Class it comes before the class then it says I should put it in
> quotes.
>
> ForeignKey('Class')
>
> put when i run python manage.py validate to check its ok it doesn't
> like it
You didn't give the error from
> I am going Django (liking it so far), and I seem to hit a wall with
> one of the exercises. It likely because of my unfamiliarity with
> Python, so bear with me, please.
>
> At the end of Hour 6, I got two exercises to do:
>
> 1. Create an additional view for the People object that displays
Hi
On Mar 7, 11:26 pm, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> It is fairly important when reporting an error like this that you give
> enough information to indicate where the error is coming from.
...
Sorry. See at bottom.
> Guessing a lot here (it looks like there's only one place
Hi there
I am having a problem with ForeignKey(Class) in my models.py
if the Class it comes before the class then it says I should put it in
quotes.
ForeignKey('Class')
put when i run python manage.py validate to check its ok it doesn't
like it
here is my models.py:
from django.db import
Does "unique for date" work for multiple fields? I want both the slug
AND the user to be unique for date.
On Mar 7, 8:24 pm, Michael <[EMAIL PROTECTED]> wrote:
> Here is a simpler solution for you. Try creating a custom field type
> for your
>
On Mar 8, 2:03 am, Brian Rosner <[EMAIL PROTECTED]> wrote:
[snip]
> Given you have a Poll and Choice models your code would look like::
>
> ChoiceFormSet = inline_formset(Poll, Choice)
[snip]
> I know I already spent way too much energy into this even though it may
> go away some day
33 matches
Mail list logo