On Sep 30, 5:05 pm, Matt wrote:
> I'm using the redirect() function provided in Django
> 1.1:http://docs.djangoproject.com/en/dev/topics/http/shortcuts/#django.sh...
>
> I have a view:
> my_editing_view(request, id, args={})
>
> for which the URL is:
> url(r'^/edit/(?P.+)$', 'views.my_editing_vi
On Sep 30, 4:59 pm, Gabriel Rossetti
wrote:
> Hello everyone,
>
> how can I pass an object in between pages without using the session? The
> problem is that the object can be pickled so it can be put in a session,
> any ideas?
>
> Thank you,
> Gabriel
Why can't it be pickled? Clearly, since ever
On Sep 30, 9:17 pm, ringemup wrote:
> From [1]:
>
> "You can also delete objects in bulk. Every QuerySet has a delete()
> method, which deletes all members of that QuerySet."
>
> This suggests that there is a Queryset.delete() method for bulk
> deletion, but this method is not documented at [2].
On Oct 1, 11:56 am, Matt wrote:
> How do you add an article to that? I mean put some python and django
> code down so I can understand it but, here's what I think it might be:
>
> example.py
>
> #!C:/Python/python
>
> import datetime
>
> today = datetime.datetime.today()
>
> class article_list():
On Oct 1, 3:09 pm, kurak wrote:
> Hello,
> How can I render new form for object X and inline formset for model Y
> (with foreign key to X) on the same- the same way it's done in django-
> admin.
>
> I've been struggling with it for a while, I tried to render form and
> formset separately but it w
On Oct 2, 11:45 am, Maksymus007 wrote:
> I used query in form
>
> a = X.objects.select_related('gate__keywords_set').filter(field=value)
>
> and then tried to get elements from related
> a[x].gate.keywords_set - there is a RelatedManager object which forces
> me to call all() method to get elemen
On Oct 3, 6:23 pm, guillermooo
wrote:
> Inside django.contrib.comments there is:
>
> 1) a folder named "url" with an __init__.pyc file
> 2) a file named "url" with a few urls
>
> I've solved the problem renaming the "url" folder to "url_".
>
> Maybe this is a bug?
>
> Regards,
>
> Guillermo
This
On Oct 5, 2:27 am, Christophe Pettus wrote:
> On Oct 4, 2009, at 6:21 PM, Ross wrote:
>
> > Could the problem be
> > that I have not written views for everything that the urlconf
> > references?
>
> Precisely. The documentation that Karen Tracey mentions discusses this:
>
> http://docs.dj
On Oct 5, 10:34 pm, "neri...@gmail.com" wrote:
> I was interested in finding out how I would go about accessing django
> vars in my javascript file i.e., media_url within javascript. Do I
> need to use a serializer to achieve this?
>
> Thanks,
>
> Jason
Just put a script element in your Django t
On Oct 5, 9:58 pm, davisd wrote:
> I have a question concerning django architecture with multiple
> applications and combined views.
>
> A View accepts an HttpRequest and returns an HttpResponse.
>
> The flow for a view is: HttpRequest in from the visitor -> process ->
> HttpResponse out to visit
On Oct 6, 11:55 am, veasna bunhor wrote:
> Do you know how to use unit testing in django ? Could you please give me an
> example?
>
> Thanks in advanced,
http://docs.djangoproject.com/en/dev/topics/testing/
--
DR
--~--~-~--~~~---~--~~
You received this message bec
On Oct 6, 6:28 pm, Aaron wrote:
> On Oct 6, 2:09 pm, Karen Tracey wrote:
>
> > Yes, you'll have to save the change to the DB. But note if you were called
> > with force_insert=True you do not want to call the superclass save with
> > force_insert=True twice.
>
> OK. Would calling "super(MyMode
On Oct 6, 6:01 pm, Carlos Gustavo wrote:
> Hi Everyone,
>
> I am Django newbie and the experience has been exciting.
>
> I want some help with the ff. challenge I am now facing:
>
> How can I get a Django form to process a bash script executing a bunch of C
> programs running on linux.
>
> Any po
On Oct 6, 4:49 pm, Geobase Isoscale wrote:
> Hi all,
> Firstly, I'm looking for modules and folders that supports ORM (object
> relation mapper ) that will enable me to extend the functionality of Django
> to enable me wrap SQL statements to result with database triggers and
> views.
Not sure w
On Oct 8, 4:05 pm, Chris Withers wrote:
> Hi All,
>
> I have a set of models that all have the same implementation for a
> method, so I thought I'd create a base class for these:
>
> class UrlModel(models.Model):
> def get_absolute_url(self):
> return reverse(index,kwargs=dict(fk=se
On Oct 9, 9:06 am, Eva Hamilton wrote:
> Oops, sorry, that's a typo in the post - but not present in the actual
> code.
>
> It should have read...
>
> world = Species.objects.all.select_related()
No, it shouldn't. Compare your original:
> > > >>> world = Species.objects.all().select_related()
On Oct 9, 11:03 am, "british.assassin"
wrote:
> Hi,
>
> I am trying to add some more fields for new members to fill in on
> registration to my site by subclassing the RegistrationForm from the
> django-registration app. My question is: is there away to do
> something like this for saving:
>
> cl
On Oct 9, 1:01 pm, Christian Wittwer wrote:
> > from shcbelpa.season.models import Game
> > This is the line of code that generates the error right?
> > Is myapp = shcbelpa ?
>
> Yes, exactly. I forgot to replace..
> Any idea why the import doesn't work?
Most likely you have a circular dependenc
On Oct 10, 3:43 pm, djbahati wrote:
> Hi All,
> Am new to django,
> am developing application but i face a problem in displaying template.
> The browser does not display any template it just display plain text.
> am using django 1.1 and xampp 1.7.1. Any idea?
http://docs.djangoproject.com/en/dev
On Oct 10, 4:01 pm, dbakerweb wrote:
> I have gotten to the point where I want to test my install of Django.
> I run "import django" and get the "No module named django" error. I
> suspect it is a path issue but I've not been able to understand any
> googled results for fixing path issues. I am a
On Oct 11, 9:22 am, The Danny Bos wrote:
> Heya, thanks for all the help of late, I'm about four late nights from
> finishing my first big app I'm guessing.
>
> Anyway,
> I'm working on paging in my app and am completely stuck (again),
> here's what I'm trying for:
> eg:http://www.domain
On Oct 11, 9:05 am, Denis Bahati wrote:
> Thanx a lot for the information, but i managed to get it working before this
> information.
> I have another problem that the __unicode()__ is not working. It just gives
> me Poll object instead of the name of data from the database, i put the
> function
On Oct 11, 12:38 pm, Kristaps Kūlis wrote:
> There can be multiple associated Model2 objects to Model1, but without one
> Model2 Model1 cannot exist.
>
> Kristaps Kūlis
The best bet is to define custom validation for your inline formset,
to ensure that there's at least one valid entry.
class
On Oct 12, 11:28 am, A_Swtos wrote:
> I'm new in django and i try to do what tutorial says about activating
> the admin site but i take the following error:
>
> IndentationError at /admin/
> ('unexpected indent', ('/home/sotathan/mysite/../mysite/urls.py', 4,
> 1, ' from django.contrib import adm
On Oct 12, 10:33 am, phoebebright wrote:
> Are there any django apps suitable for a events photographer who wants
> to sell their photos online?
I believe Satchmo has the facility to sell downloads as well as
physical products.
--
DR.
--~--~-~--~~~---~--~~
You rec
On Oct 13, 3:09 am, LuisC wrote:
> Hi!!!
>
> I am having some trouble trying to output a database record to a
> form
>
> **My form:
> class ClientesFIForm(forms.Form):
> ClienteCodigo = forms.IntegerField(label='Codigo Cliente')
> ClienteNombre = forms.CharField(label='Nombre Cliente'
On Oct 13, 11:42 am, elminio wrote:
> Hi,
>
> By admin I can choose what users can do with model objects. And what
> about certain pages. Do I have to write if in everyone view method (to
> check is current user may access given view ?
>
> Or is there any built in tool that makes it possible to r
On Oct 13, 11:55 am, DrKJam wrote:
> Hi,
>
> I'm following the advice here :-
>
> http://docs.djangoproject.com/en/dev/ref/contrib/admin/actions/
>
> to try and add a custom action to the list display of one of my models in
> the admin interface.
>
> Sadly, as hard as I try, the option is not app
On Oct 13, 9:41 pm, LuisC wrote:
> Daniel,
> .get() was one of the several options I tried before with no
> results... When I use .get() the form only displays the submit
> button... I am asuming that that is because the template is specting
> a dictionary and I am only supplying a value...
Wh
On Oct 14, 10:29 am, luca72 wrote:
> Hello if i use request.META['REMOTE_USER'] i get key error, but if i
> use 'REMOTE_HOST' not
> can you tell me how to get the user that is authenticate
> I use the decorator @login_required and so the user is authenticated
> correct?
>
> Regards
>
> Luca
requ
On Oct 14, 10:39 am, luca72 wrote:
> Thanks but have you got idea why i get this error, request.user return
> the correct value, but for my understanding also the META
> ['REMOTE_USER'] has to give the same value.
No, that's not true, and the documentation doesn't say it does. The
values in META
On Oct 14, 10:38 am, grimmus wrote:
> Hi,
>
> I have 2 Models, Link and SaveLink.
>
> Link allows URL's with title's and descripions to be added to the
> site.
> SaveLink allows the logged in user to save their favourite links.
>
> When i output all the links on the page i would like to check if
On Oct 14, 10:42 am, Kenneth Gonsalves wrote:
> On Wednesday 14 Oct 2009 3:08:00 pm robin nanola wrote:
>
> > try reading this
> >http://www.cotellese.net/2007/12/11/adding-model-field-validation-to-...
> >ango-admin-page/
>
> I do not think validators exist in django now - that blog post was don
#x27; from
> 'user.has_saved_link:object'
>
> I think it's an issue with how the objects are being passed to the
> tag ?
>
> I'm a bit of a Noob with all this (as you can probably tell !!)
>
> Thanks
>
> On Oct 14, 12:16 pm, Daniel Roseman wrote:
&g
On Oct 14, 2:26 pm, Aaron wrote:
> I have a bunch of models that each have a field X. I want this X to be
> unique not just within a particular model (table) but unique across
> several models. So, a model of type A can't have a value for its X if
> that value is already in the X of a model of ty
On Oct 15, 8:16 am, ev wrote:
> May be there were developers solutions? Where should I look for?
>
Look at the django-mptt project. It implements an efficient algorithm
for tree access, and also has some useful libraries that help with
displaying trees. You might be able to use one of them.
Alt
On Oct 15, 1:46 pm, bruno desthuilliers
wrote:
> On 15 oct, 13:51, jul wrote:
>
> > Hi,
>
> > I've got the two models Country and Restaurant shown below. Is there a
> > way to directly set a country by instanciating a restaurant with a
> > Country instance? Something like:
>
> > r=Restaurant(nam
On Oct 15, 2:58 pm, eka wrote:
> Hi all
>
> I need to override the ModelAdmin save_model and I found out that is
> not being called. I checked the documentation where it says how to use
> it and the searched around the code to see if there is a call to that
> method and can't find any call to sav
On Oct 16, 2:18 pm, wmstudio wrote:
> Hi,
>
> I have a model containing:
>
> class Book(models.Model):
> title = models.CharField(max_length=128)
> price = models.DecimalField(max_digits=8, decimal_places=2,
> help_text='Please enter the price in $')
> summary = models.TextField(blank
On Oct 18, 3:11 am, jeffself wrote:
> I've got a view that returns a generic list. It contains the following
> fields:
> school, wins, losses, pf, pa, rating
>
> I want to add a field called rank that assigns the values 1 through
> whatever for each of the records returned. Is this possible using
On Oct 18, 6:54 pm, DjangoRocks wrote:
> Hi all,
> The environment i am using to set up my django project/app on a
> production server is as follows:
> Ubuntu 9.04, Django 1.02, Python version 2.6.2.
>
> Mysql, mysqldb, apache2 and php is all set up and good to go.
>
> I have followed the tutoria
On Oct 19, 6:12 am, aju wrote:
> Hi
>
> I installed django-notify. But in that django-notify folder it does
> not contain the file notify_user.py. I need this file. Plese send me
> the file notify_user.py
What do you think this file is supposed to do? What makes you think
you need it?
--
DR.
--~
On Oct 19, 9:41 am, Nicolas Steinmetz wrote:
> Re,
>
> Anybody for helping me in my quest ?
>
> Nicolas
>
> On 16 oct, 21:58, Nicolas Steinmetz wrote:
>
>
>
> > Hello,
>
> > I'm building a django app to manage the reverse proxies of my firm. I'm
> > at the step where I want to generate configura
On Oct 19, 5:20 am, Keith wrote:
> I'm writing some code that does something like...
>
> 1. check url for specific information
> 2. do some logic based on named group
> 3. pass results along on request
>
> It is easy for me to do this through urls.py for a single request.
> However, i want to per
On Oct 19, 10:17 am, aju mathew wrote:
> Hi Daniel,
>
> I want to create a forum application using djangobb.
>
> For this it need django-notify, openauth etc.
>
> I install all these and specified in the INSTALLED_APPS in settings.py
>
> Inside openauth views.py It calls the methods in notify_use
On Oct 19, 4:17 pm, Tomasz Zieliński
wrote:
> Say I have Object model, which has ObjectRevision-s (ObjectRevision
> has ForeignKey to Object). I want to fetch from database all latest
> ObjectRevision-s. In SQL I can do it like this:
>
> SELECT r1.some_data
> FROM objectrevision r1
> LEFT OUTER J
On Oct 19, 5:25 pm, Tomasz Zieliński
wrote:
> On 19 Paź, 17:52, Daniel Roseman wrote:
>
> > On Oct 19, 4:17 pm, Tomasz Zieliński
>
> > It's not clear what you mean by 'all latest ObjectRevisions'. Do you
> > mean all Obje
On Oct 21, 9:28 am, Mike Thon wrote:
> I'm new to web programming and I have a basic question about the
> design of my Django application. my application will do some number
> crunching on data files uploaded by users. The data processing will
> take from minutes to hours for each job. I don't
On Oct 21, 11:56 am, robin wrote:
> I have installed Django on my mac with OS 10.6. It installed just fine
> and I was setting up my first project. I then ran python manage.py
> syncdb as I am using MySQL, but I got the following errors:
>
> Traceback (most recent call last):
> File "manage.py"
On Oct 21, 2:42 pm, Caisys wrote:
> Hi,
> Suppose i have 3 model classes:
>
> class model1(model.Models):
> fields .
>
> class child1(models.Model):
> model1 = models.ForeignKey(model1)
>
> class child2(models.Model):
> model1 = models.ForeignKey(model1)
>
> ---
On Oct 20, 2:04 pm, wonderfullyrich wrote:
> I'm trying to use a mix between thehttp://wiki.dreamhost.com/Django#Setup
> andhttp://webhostingreal.com/content/view/18/1/(which looks slightly
> more recent then the wiki) to setup django on a PS server with
> Dreamhost. I'm stuck at the easy_instal
On Oct 22, 6:20 pm, Dhruv Adhia wrote:
> Hello,
>
> Quite a basic question.. I am posting data from Unity, its like name
> and score. I want to read the posted data and display it.
>
> Here is the code that I currently have inside views.py
>
> def add_score(request):
> response_dict ={}
> i
On Oct 22, 7:19 pm, Dhruv Adhia wrote:
> oops that was a typo.. thanks for pointing that out... Yep I see atleast the
> html elements getting displayed like those arrows...
>
> on the views side I didnt get what f4nt meant.. can you show me an example?
>
You had it right in your reply to him: re
On Oct 22, 7:35 pm, Dhruv Adhia wrote:
> Allright, I see some progress, so now my views looks like this with that
> little modification
>
> def add_score(request):
> response_dict ={}
> if request.POST:
> name = request.POST['name']
> score = request.POST['score']
> has
On Oct 23, 4:16 pm, Ralph wrote:
> I am using Django 1.1 with Python 2.6.1 and have a problem with
> testing
> views that require a login. I was hoping someone could enlighten me
> were
> it all goes wrong
>
> in the setup function of a unit test i am adding a user and create a
> test client
On Oct 26, 10:39 am, aju mathew wrote:
> Hi
>
> How can I populate values from a python file to database.
>
> Is it any commands their for db migration from command prompt.
>
> --
> Thanks & Regards,
> Aju P Mathew
What do you mean a 'Python file'? If it's in a Python file, you can
use ORM comma
On Oct 26, 5:19 am, robinne wrote:
> I am noticing that when I load an existing ModelForm into a template,
> and I save (POST), I can't seem to get the primary key back in order
> to update that specific record. I am starting to head down the path of
> formsets...but that is not what I need. I am
On Oct 25, 11:47 pm, Caisys wrote:
> Thanks but I am not very familiar with forms yet I barely managed to
> override the default form.
> However, I thought that its ok for the time being since places and
> subplaces are not changed frequently so i can live with it for the
> time being and move to
On Oct 26, 4:22 pm, Alessandro Ronchi
wrote:
> I need to create a static method for a model class like this. The line
> Settore.objects.all()[0].id gives error (
> psycopg2.InternalError: current transaction is aborted) when creating
> the tables at first syncdb. What's the correct way to do tha
On Oct 26, 10:35 pm, "jon...@cox.net" wrote:
> SyntaxError at /
>
> ('invalid syntax', ('c:\\Users\\Vincent\\Documents\\django_bookmarks\
> \..\\django_bookmarks\\bookmarks\\views.py', 15, 20, 'return Http
> Response(output)\n'))
>
> SCRIPT FROM VIEWS.PY
>
> from django.http import HttpResponse
>
On Oct 27, 10:48 am, James Harrison Fisher
wrote:
> Hi,
>
> I've recently come across something that's stumped me. I am creating
> a 'shortcut' function for easier creation of add/edit views. This
> function needs to make a query on a model in the simple form:
>
> model.objects.get(field_name=v
On Oct 27, 2:49 pm, Victor Hooi wrote:
> heya,
>
> In my models.py, I've got an "Address", as well as an abstract "Trip"
> object, and then a "ToTrip", and "ReturnTrip" object that derive from
> that. ToTrip and ReturnTrip both contain references to two Address
> objects (models.ForeignKey).
>
>
On Oct 28, 8:45 am, zayatzz wrote:
> Hi.
>
> I have a problem with django project that is beeing hosting in a
> server where i have no shell access... so how can i do syncdb there.
> doing mysql dumps in development db and updating hosting mysql is
> kinda slow..
>
> Is it possible do this run sy
On Oct 29, 6:38 am, Denis Bahati wrote:
> Hi all,
> I've gone through and successfully made the poll application and I've
> begun to play around and tried to change a few things. The first thing
> I would like to do is have the user vote without login to django admin. ie
> creating my own form wh
On Oct 29, 4:42 pm, bruno desthuilliers
wrote:
> (FWIW and IIRC, the appropriate english term is 'Customer' - please
> someone correct me if I'm wrong)
OK... the French word 'client' maps to both 'client' and 'customer'. A
lawyer, doctor, accountant etc would have clients; a shop has
customers.
On Oct 29, 5:32 pm, Marco wrote:
> Hi all,
>
> I going a little bit crazy that's why I'm posting here ...
>
> I have a view :
>
> def index(request):
> request.session['hello'] = 'world !!!'
> print "hello!!!"
> return render_to_response('index.html')
>
> in this page index.html I have
>
On Nov 1, 9:27 pm, "bax...@gretschpages.com"
wrote:
> I finally installed the django debug toolbar, which looks like a very
> nice piece of work, but it's not reporting sql queries for me. Every
> page: 0 queries, 0 seconds.
>
> Any suggestions on where the problem may lie?
Have you added the De
On Nov 3, 11:38 am, sridharpandu wrote:
> Hi
>
> I am reading the second part of the Django tutorial on the Django
> website. The Tutorial mentions that I should copy the base_site.html
> page from "django/contrib/admin/templates" to an Admin directory under
> my HOME directory. The problem is I
On Nov 4, 4:19 am, JohnL wrote:
> Hi All,
>
> I just joined linode and followed there instructions in setting up
> Django athttp://library.linode.com/lamp-guides/ubuntu-9.10-karmic/.
>
>
> ServerAdmin squ...@bucknell.net
> ServerName bucknell.net
> ServerAliaswww.bucknell.net
>
On Nov 4, 4:26 am, Denis Bahati wrote:
> Am real need to reinvent the wheel because i have a project which needs to
> define some user roles, and enable users to update the status of their own
> properties and not the other property. Thanks in advance for any help you
> give me.
>
Then use a Use
On Nov 4, 9:50 am, NMarcu wrote:
> Hello all,
>
> I got an error, and I don't know how to pass on it. I got this
> error when I try to use ajax from django templates.
> I use this, from jquery:
> $('#create-user').click(function() {
> $( '#test_div' ).load( "{% url test_ajax %}
On Nov 4, 2:50 pm, DavodM wrote:
> Hello,
>
> I have a many to many relationship between 'Projects' and 'Tags' in my
> app.
>
> In the admin screen I would like to be able to use the
> filter_horizontal interface for adding/editing from both sides of the
> relationship but I can only seem to get
On Nov 4, 3:58 pm, chewynougat wrote:
> Hi
>
> When I want a user to edit a form, I would like previously checked
> checkboxes to show as checked. However, they are not showing (just
> unchecked checkboxes). Can anyone explain to me why this is?
>
> Model:
>
> class GroupOption(models.Model):
>
On Nov 4, 3:34 pm, David wrote:
> Hello
>
> I have just started to learn Django.
>
> I have setup a Blog model, and an Entry model. I would like to use a
> generic view to list all of the entries in a given blog. The url to
> this should be /blog-slug/.
>
> I am unclear how I can bring up all of
On Nov 4, 7:22 pm, John Boxall wrote:
> Both of these will raise a FieldError:
>
> people_with_bffs = Person.objects.filter(bbf_id__isnull=False)
> people_with_bffs = Person.objects.filter(bbf_pk__isnull=False)
>
> Cannot resolve keyword 'bbf_pk' into field. Choices are 'bbf'.
>
> Thanks for the
On Nov 9, 8:47 am, Lars Stavholm wrote:
> Hi All,
>
> I'm looking to implement collapsible fields in a django powered
> page, so far with no luck.
>
> Any hints on the best way of doing it?
>
> In the mean time, I checked out how it's done in the admin interface,
> and came up with a simple test
On Nov 9, 4:24 am, SeanB wrote:
> Many web sites offer faceted browsing such that a series of categories
> can be selected to narrow a large set of records down to a few (or
> one). Such interfaces often show how many records match the various
> category values, which sometimes helps direct the s
On Nov 10, 1:36 am, Julien Phalip wrote:
> Hi,
>
> I've tried to install MySQL for an existing project, and I'm getting a
> strange error (see traceback below). Apparently "self.converter" is
> None, but I can't see why.
>
> I can access the database just fine using the 'mysql' command in the
> t
On Nov 10, 12:57 pm, Zeynel wrote:
> Hi Tim,
>
> Yes, I syncdb several times.
>
> C:\sw\sw>manage.py syncdb
>
> C:\sw\sw>manage.py sql wkw
>
> BEGIN;
> CREATE TABLE "wkw_school" (
> "id" integer NOT NULL PRIMARY KEY,
> "school" varchar(200) NOT NULL
> )
> ;
> CREATE TABLE "wkw_lawyer" (
>
On Nov 10, 3:02 pm, Zeynel wrote:
> Thanks. I will try what you suggested. But I am almost there with the
> admin, the only thing is I need to change the date format so that it
> takes only the year. Now DateField requires month, day and year. I
> tried this
>
> year_graduated = models.DateField(
On Nov 10, 7:34 pm, nash wrote:
> hi i have defined a function in my view.py
>
> from django.http import HttpResponse
>
> class work(request):
> def get(self):
> return HttpResponse("its working")
>
> but when i browse to mysite/work i am getting "name 'request' is not
> d
On Nov 10, 9:32 pm, nash wrote:
> hi thanks for the reply i am trying to get django up and running with
> googleapp engine as. i understand in django correct me if i am wrong
> return is a global variable when a url is matched as defined in the
> url.py it calls the class that is matched in views
On Nov 11, 7:50 am, neridaj wrote:
> I'm trying to use some flatpages for static content and I don''t
> understand why they keep failing to load media files. I have my
> template_dirs defined, media_root and media_url - when used in
> template does not resolve to media_root i.e., template contain
On Nov 11, 10:04 am, gerhard.oe...@ogersoft.at wrote:
> Hello
>
> I am new to django and try to use the ModelForm paradigma, but can't get the
> point ;-((
As the documentation says, the point of a modelform is firstly to
validate input from a user and save it to the database, and secondly
to dis
On Nov 11, 3:48 pm, neridaj wrote:
> On Nov 11, 12:07 am, Daniel Roseman wrote:
> >
> > Have you set anything up to serve media files?
> I have a symbolic link named site_media in my project directory.
How does that answer the question? What is serving the
On Nov 12, 9:51 am, Steinar Rune Eriksen
wrote:
> I have not used Django in external environments before, just Intranet
> applications.
>
> I am wondering how to mask URLs so that object IDs are not shown?
> Obviously one would create security on the server to check if a user
> has access to view
On Nov 13, 2:18 pm, ses1984 wrote:
> In short, I have been having a hard time getting a ModelFormSet to
> save. The formset is created from a queryset, and it's only intended
> to edit one field of existing objects.
>
> After a long string of mistakes and fixes, I'm finally stumped. The
> followin
On Nov 14, 12:04 am, Continuation wrote:
> How do I do queries when ContentType is involved?
>
> Using the example in the doc
> (http://docs.djangoproject.com/en/dev/ref/contrib/contenttypes/#id1
> )
>
> class TaggedItem(models.Model):
> tag = models.SlugField()
> content_type = models.Fo
On Nov 14, 4:42 am, neridaj wrote:
> I'm using django-tagging and I think it's causing an error when I try
> to access the admin page. If I comment out the urls that reference
> django-tagging views the error goes away.
>
> from django.conf.urls.defaults import *
> from blog.models import Entry, L
On Nov 15, 8:13 am, Continuation wrote:
> > As the docs show, when you've defined a GenericRelation, querying is
> > exactly the same as with a reverse foreign key. So:
> > Bookmark.objects.get(tags__tag='django')
>
> I don't quite understand your use of tags__tag='django' in retrieving
> the obje
On Nov 16, 8:12 am, Continuation wrote:
> > As the docs show, when you've defined a GenericRelation, querying is
> > exactly the same as with a reverse foreign key. So:
> > Bookmark.objects.get(tags__tag='django')
>
> A somewhat related question:
>
> What if instead of having a ForeignKey to Conte
On Nov 16, 2:06 pm, Andy wrote:
> Thank you all for your replies. Karen, both good points. pjrharley,
> I agree with Dennis. If the user is required to re-type their email
> address, then that in combination with Django's simple built in email
> validation should be sufficient.
>
> I am using a
On Nov 16, 4:31 pm, Zeynel wrote:
> Thanks!
>
> I noticed that using
>
> class Lawyer(models.Model):
> ...
> ordering = ('last',)
>
> did not work.
>
> But this worked
>
> class Lawyer(models.Model):
> ...
> class Meta:
> ordering = ('last',)
>
> copied fromhttp://www.djang
On Nov 17, 9:28 am, neridaj wrote:
> I can't figure out why my comment vars aren't available in my
> template. I'm using django.contrib.markup and when I try to preview
> the comments nothing is displayed, however, the comment var is
> available in {{ comment|linebreaks }} but not in
> {{ comment.
On Nov 17, 10:26 am, Radhikavk wrote:
> Hi ,
>
> I have 2 tables room_types and room
>
> the table structure
>
> class room_types(models.Model):
> room_type_id = models.AutoField(primary_key=True,null=False,blank=False)
> room_type_name =
> models.CharField(max_length=100,unique=True,null=
On Nov 18, 6:46 pm, Wayne wrote:
> Hi,
>
> I am working with a legacy database which does not set foreign key
> constraints at all between tables. I am wondering if I can still
> create Inline admin interface by relating two objects through
> different methods. If it is doable, what is the best wa
On Nov 18, 10:50 pm, Wayne wrote:
> Thanks for your reply.
>
> My situation is a little bit more tricky. I have table A and table B.
> Table B has several columns, two of which are tableID and resourceID.
> Table B is related to table A in the following way:
> select * from table B where b.tableID
On Nov 20, 3:26 pm, JHeasly wrote:
> In using Simon W.'s "simple example of row-level permissions in the
> admin" (http://www.djangosnippets.org/snippets/1054/), I'm trying to
> extend the concept by modifying the 'list_filter' tuple of the
> subclassed ModelAdmin based upon the request.user.is_s
On Nov 23, 8:34 am, Hanne Moa wrote:
> On Mon, Nov 23, 2009 at 00:46, Russell Keith-Magee
>
>
>
>
>
> wrote:
> > On Mon, Nov 23, 2009 at 1:59 AM, Hanne Moa wrote:
> >> I have models M, N, which both have a foreignkey to User. When in the
> >> shell/runserver, User has attributes for both M and N
On Nov 20, 8:31 am, "Boris Schaeling" wrote:
> Is there a shortcut to create and update a model object from a form? For
> example I'd like to write something like:
>
> MyModel.objects.create(mymodel_form.cleaned_data)
>
> or
>
> model_obj = get_object_or_404(MyModel, pk=id)
> model_obj.update(my
801 - 900 of 2396 matches
Mail list logo