Also, any change in the Link from_hub or to_hub will result in the
form being reloaded so no need to change the dropdown lists after
being loaded
On Oct 8, 9:22 am, sico <allensi...@gmail.com> wrote:
> by the way, I'm using django 1.0.2 but am not against upgrading
> if
by the way, I'm using django 1.0.2 but am not against upgrading
if it helps me solve this problem!
On Oct 7, 3:36 pm, sico <allensi...@gmail.com> wrote:
> Suppose I have 4 models as below:
>
> class Hub(models.Model):
> name = models.CharField("Name&q
Suppose I have 4 models as below:
class Hub(models.Model):
name = models.CharField("Name", )
something-else = models.CharField("Something", )
class HubPlug(model.Model):
hub = models.ForeignKey(Hub)
plug_id = models.CharField("Plug Id (A, B, C, etc)", )
class Link(model.Model):
Hey,
I can get to the inline_admin_formset by indexing the
inline_admin_formsets variable
e.g.
{{ inline_admin_formsets.0.formset }}
is there an alternative to use the index number for picking the
formset?? I've tried the model name but it doesn't seem to work...
any suggestions??
thanks,
Hey,
Is it at all possible to have more than one admin interface for one
model?
I'd like to have a simple view that just edits the one model fields,
and another (maybe more) that edit the model, plus several inline
associated models.
I can get this to work by having separate AdminSites, is
the binding of the data from the form to the model.
thanks,
Simon
On Aug 4, 1:12 pm, sico <allensi...@gmail.com> wrote:
> Hi,
>
> I have several models linked OneToOne by their primary keys.
>
> I can make a single view that has a form for each model and allow the
> user to
Hi,
I have several models linked OneToOne by their primary keys.
I can make a single view that has a form for each model and allow the
user to edit data from the each of the models in a single screen (as
if it were all stored in a single table/model)
I'd like to be able to do this in a grid,
Is it possible to have more than one admin interface for a form in the
same AdminSite ?
I'd like to have an admin form for just editing the model, and another
one for editing the model and some sub-records. Is this possible
within the same AdminSite ??
You're not allowed to do more than one:
Hey,
I've been a little distracted but I'm back on to this now...
Thanks for the information, I'm going to try it out now (assuming no
more interruptions!) and I'll get back to you on how I get on...
On Jul 24, 8:55 pm, Matthias Kestenholz
wrote:
> On Fri,
Hey,
I had a problem recently that caused me some confusion!
I have a model that has a OneToOne field as the primary key. When
adding a new record in the admin form and entering a key that already
existed, I wasn't getting the expected "record already exists" error,
instead it was just
Hi,
I want to be able to edit fields from several different models on the
same form/view.
The models are related one-to-one... can they be defined as "Inline"
forms in the admin system?? The documentation doesn't make any
mention of using inline forms for anything except parent child
relations
This has been put in the "too hard" basket for now. I'm upgrading
from django 0.96 to 1.0.2 and was hoping to make this custom view a
configured admin view but am leaving that till later now as it's
taking too much time away from porting the rest of the system.
On Jul 21, 11:4
report back as soon as I can test it
On Jul 21, 11:32 am, Joshua Russo <josh.r.ru...@gmail.com> wrote:
> On Mon, Jul 20, 2009 at 10:26 PM, sico <allensi...@gmail.com> wrote:
>
> > thats cool to know, but not quite what I'm after I don't think. If
> > the
I'm thinking overriding the change_view on the admin model - add the
extra data to extra_context and then reference it as Rajeesh suggested
below...
On Jul 21, 9:08 am, sico <allensi...@gmail.com> wrote:
> heh... right you are!
>
> But how do I make extra data from other models av
fields
depending on a data value
e.g.
if field1 = 1 then hide field7 else hide field8
On Jul 20, 11:47 pm, rajeesh <rajeeshrn...@gmail.com> wrote:
> On Jul 20, 9:38 am, sico <allensi...@gmail.com> wrote:
>
>
>
> > Its quite simple to customize the admin
<rajeeshrn...@gmail.com> wrote:
> On Jul 20, 4:06 am, sico <allensi...@gmail.com> wrote:
>
> > Hi,
>
> > Using django 1.0.2 and I'd like to put some extra read-only info in a
> > sidebar on the editing forms for specific models.
>
> > coltype= colMS
Its quite simple to customize the admin template for a specific model
by creating a change_form.html in the templates/admin//
/ directory.
But, is it possible to refer to particular fields in the model/form
directly?
E.g.
Instead of using the loops:
for fieldset in adminform:
for
Hi,
Using django 1.0.2 and I'd like to put some extra read-only info in a
sidebar on the editing forms for specific models.
coltype= colMS looks perfect for this, but how/where do I tell django
what I want to put in the sidebar??
thanks,
Simon
2009/7/17 Michael :
> On Fri, Jul 17, 2009 at 1:30 PM, Lic. José M. Rodriguez Bacallao
> wrote:
>>
>> anyone?
>>
>>
>> On 7/17/09, Lic. José M. Rodriguez Bacallao wrote:
>> > hi folks, it's be a long time without writing to the list but
2009/7/17 Lokesh :
>
> Hi,
>
> Initially the table created with the following code
> Class user_privileges(models.Model):
> user_id = models.ForeignKey(User)
> is_deleted= models.CharField(null=False, blank=False,
> max_length=1)
> is_email_active =
okay... seems the use of a Manipulator was the issue, and adding
raw_id_admin = True to the Foreign Key field definition fixed it!
On Jul 13, 9:58 am, sico <allensi...@gmail.com> wrote:
> <I'm sure I already posted this but I can't find it anywhere so
> reposting>
>
> Ca
Can anyone shed some light on how django validates foreign keys for
me??
I have a model that I'm writing a whole lot of records in a single
request. With the Foreign Key defined in the model it takes ages!!!
Have about
Can anyone shed some light on how django validates foreign keys for
me??
I have a model that I'm writing a whole lot of records in a single
request. With the Foreign Key defined in the model it takes ages!!!
Have about 100 records and it takes minutes. When I change the field
to CharField, it
So, using automatic transaction management, there is no way to cause a
transaction rollback without the user seeing the exception...
stink...
thanks for your help!
On Jun 30, 3:07 am, Karen Tracey <kmtra...@gmail.com> wrote:
> On Sun, Jun 28, 2009 at 11:14 PM, sico <allensi...@gmai
the transaction without the user seeing an exception
thanks!
On Jun 26, 11:13 pm, Karen Tracey <kmtra...@gmail.com> wrote:
> On Fri, Jun 26, 2009 at 12:59 AM, sico <allensi...@gmail.com> wrote:
>
> > Hi
>
> > Is it possible to rollback the transaction without raising an
&g
Hi
Is it possible to rollback the transaction without raising an
exception when the transactions are tied to http requests??
I'm writing several records in one post call, if any fail I'd like to
rollback the transaction but return a nice error message to the user.
Surely I'm missing something as
Hey,
I was getting a weird can't adapt error when saving a record.
Previous posts talked about charset conversions, unicode, etc...
The problem I had turned out to be trying to write an object reference
where I should have put the key value instead.
e.g.
rec["myfk"] = myObj
changed to:
btw... using 0.96 here...
On Jan 20, 9:27 am, sico <allensi...@gmail.com> wrote:
> Hi,
>
> I'm filtering a model on some criteria... and based on the resultset I
> want to retrieve associated related models (all one-to-one
> relationships)
>
> Whats the most effic
Hi,
I'm filtering a model on some criteria... and based on the resultset I
want to retrieve associated related models (all one-to-one
relationships)
Whats the most efficient way to do this without resorting to custom
SQL?
this is the best I can come up with:
obj1s =
I suppose I want to know if there is anyway to customize the field
output at runtime to add properties like class, disabled etc...
Would rather not use javascript too .
On Jan 16, 1:53 pm, sico <allensi...@gmail.com> wrote:
> doh! its one thing being stupid... its another bei
doh! its one thing being stupid... its another being stupid in front
of a big crowd of people!
if my field is readonly... it probably doesn't need a dropdown list
does it??
would still be nice to set date field text box class to vDateField to
get nice pop-up thingy!
On Jan 16, 1:38 pm, sico
Hi,
I've inherited a django app - running on 0.96. So far, the people
before me have not created any views, and have just used the built-in
admin app to modify everything.
I want to create a view to control adding/editing records for a
specific model.
#So, I create form from the model like:
just an FYI here as have fixed the problem.
was getting the error as described here
http://groups.google.com/group/django-users/browse_thread/thread/04fa8425d18f9242
but only every so often then I noticed the ProcessID at the top
of the error was always the same. Apache was running 11
33 matches
Mail list logo