Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.

#1 Nov. 26, 2010 02:58:11

Chris T.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Weird problem after schema change


Hi,

I'm using sqlite3 and django-evolution (and sometimes manual ALTER TABLE
commands) for this website I'm making. Recently I added a new date field to one
of my models, but it's not showing up in the admin interface. (I'm also having
a problem in which the admin interface is taking taking a long time to load,
but I think that's because my model has a ManyToMany field to a model with a
lot of rows in the table.) How can I get the date field to show up in the admin
interface?

Thanks,
Chris

--
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
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#2 Nov. 26, 2010 03:07:20

Venkatraman S.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Weird problem after schema change


On Fri, Nov 26, 2010 at 6:30 AM, Chris Tandiono <chris.tandi...@gmail.com>wrote:

> How can I get the date field to show up in the admin interface?
>

Couple of checks:
- have you defined any custom forms for admin?
- Do the field names match properly?

A good practice generally is : do a 'sqlall' before you make the change in
your models.py and then again do the same after mod'ing your models.py file.
Do a diff between the two output sqlall files.

$python manage.py sqlall > before.txt
$vim ...models.py
$python manage.py sqlall > after.txt

-V-

--
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
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#3 Dec. 1, 2010 07:43:13

c.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Weird problem after schema change


Nope, haven't defined anything interesting for admin. The field name
matches, as far as I know.

Frankly, though, given the length of time it takes for the server to
reply (owing to the huge number of entries for the m2m field), I guess
this really isn't worth fixing if it's more involved than a simple
check. Ah well.

Thanks,
Chris

On Nov 25, 7:07 pm, Venkatraman S <venka...@gmail.com> wrote:
> On Fri, Nov 26, 2010 at 6:30 AM, Chris Tandiono
> <chris.tandi...@gmail.com>wrote:
>
> > How can I get the date field to show up in the admin interface?
>
> Couple of checks:
> - have you defined any custom forms for admin?
> - Do the field names match properly?
>
> A good practice generally is : do a 'sqlall' before you make the change in
> your models.py and then again do the same after mod'ing your models.py file.
> Do a diff between the two output sqlall files.
>
> $python manage.py sqlall > before.txt
> $vim ...models.py
> $python manage.py sqlall > after.txt
>
> -V-

--
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
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

Board footer

Moderator control

Enjoy the 18th of August
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support