Re: how to get the id in an admin template

2008-11-06 Thread webcomm
ahh. Thanks. On Nov 6, 4:20 pm, "Alex Koshelev" <[EMAIL PROTECTED]> wrote: > `example.com` is default Site added by the project setup into sites contrib > application [1] > > [1]:http://docs.djangoproject.com/en/dev/ref/contrib/sites/#ref-contrib-s... > > On Fri, Nov 7, 2008 at 00:12, webcomm

Re: how to get the id in an admin template

2008-11-06 Thread Alex Koshelev
`example.com` is default Site added by the project setup into sites contrib application [1] [1]: http://docs.djangoproject.com/en/dev/ref/contrib/sites/#ref-contrib-sites On Fri, Nov 7, 2008 at 00:12, webcomm <[EMAIL PROTECTED]> wrote: > > I don't understand the documentation. I am able to get

Re: how to get the id in an admin template

2008-11-06 Thread Steve Holden
It's in the only row in your sites table. regards Steve webcomm wrote: > I don't understand the documentation. I am able to get the "view on > site" link to show, but the URL is wrong. The correct URL for the > instance is... > > http://www.mysite.com/billing/321 > > ...so I tried this... > >

Re: how to get the id in an admin template

2008-11-06 Thread webcomm
I don't understand the documentation. I am able to get the "view on site" link to show, but the URL is wrong. The correct URL for the instance is... http://www.mysite.com/billing/321 ...so I tried this... def get_absolute_url(self): return "/billing/%i" % self.id ...but when I cl

Re: how to get the id in an admin template

2008-11-04 Thread Adi Jörg Sieker
On 04.11.2008 17:19 Uhr, webcomm wrote: > How do I get the instance id from within an admin template? I want to > add a link to view the instance, and I need the id to create that > link. Like so... > > View this item > > if your Model supplies a get_absolute_url method, then the Admin will

how to get the id in an admin template

2008-11-04 Thread webcomm
How do I get the instance id from within an admin template? I want to add a link to view the instance, and I need the id to create that link. Like so... View this item Thanks, Ryan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the