Displaying items of a linked object in a template

2008-12-01 Thread Marco
Hello, I have this in my models.py : class Device(models.Model): name = models.CharField(max_length=30) class DeviceProperty(models.Model): key = models.CharField(max_length=30) value = models.CharField(max_length=80) device = models.ForeignKey(Device) In my vie

Re: Displaying items of a linked object in a template

2008-12-02 Thread Marco
@Daniel and Bruno, Thanks a lot it is working ! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group,

Displaying data in the admin edit form

2009-09-10 Thread Marco
Hello, I saw in Django's tutorial that it was possible to display some data coming from a method of your model (for example 'was_published_today'). You just have to use list_display and call your method. But what if I want to display this in the edit form? Is there a way to do that? Thanks, Mar

Re: Displaying data in the admin edit form

2009-09-18 Thread Marco
Ok thanks a lot justind! On Sep 15, 8:40 pm, justind wrote: > Marco, > > See this portion of the > docs:http://docs.djangoproject.com/en/dev/ref/contrib/admin/#overriding-ad... > You can override change_form.html template and display what you need > there. > > On Sep 1

Trouble accessing session data from a template

2009-10-29 Thread Marco
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 value : {{ request.session.hello }} But nothing is dis

Re: Trouble accessing session data from a template

2009-10-30 Thread Marco
On Oct 29, 9:04 pm, Daniel Roseman wrote: > 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

MVC (mtv!) schema...

2011-01-04 Thread marco
hi! i'm reading the djangobook, and it ocurred to me this drawing, to graphic the mtv concept. hope you like it, and you are free to use it! http://marcobernich.blogspot.com/2011/01/mvc.html -- You received this message because you are subscribed to the Google Groups "Django users" group. To

No module named contact.forms

2011-01-07 Thread marco
i'm reading the djangobook, and doing the example(s). in chapter 7 (forms), when i try to run : >>> from contact.forms import ContactForm the shell gives me this error: Traceback (most recent call last): File "", line 1, in ImportError: No module named contact.forms can you help me to fix th

Re: ANN: Django 1.3 released

2011-03-23 Thread Marco
so happy On Wed, Mar 23, 2011 at 5:34 PM, bruno desthuilliers < bruno.desthuilli...@gmail.com> wrote: > On 23 mar, 07:15, James Bennett wrote: > > It's here! > > > > Django 1.3 has been officially released. > > Yay great ! Congrats guys. > > -- > You received this message because you are subscri

more study case on django

2008-03-31 Thread Marco
Hi, all I'm a beginner on Django. I wanna know are there some studycase website core for learning? Thank you! -- LinuX Violin Canon EOS --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To p

ManyToMany via intemediary model and admin interface

2008-10-08 Thread Marco Buttu
them by ``save and continue editing''). Here's what happens when I try to add another person: http://www.nanoelectronic.net/temp/intermediary.png I don't have any problem adding more than two persons in a group by shell instead. Any sugge

Re: Which IDE do you choose with django?

2008-10-12 Thread Marco Bazzani
On Sun, Oct 12, 2008 at 11:32 PM, Jeff Anderson <[EMAIL PROTECTED]>wrote: > zjffdu wrote: > > I am a newbie of django, and want to know which IDE is suit for > > django? > > > I'd say that it'd be good to continue using whatever IDE you use for > your other Python development. Django is, after all

Re: ManyToManyField with extra content and Django admin

2008-10-15 Thread Marco Buttu
/group/django-users/browse_thread/thread/141d50f3b91ee877 Regards, -- Marco Buttu --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@goo

Re: Apache Segmentation Fault on succesful authentication

2008-11-12 Thread marco ghidinelli
On Wed, Nov 12, 2008 at 03:22:02AM -0800, huw_at1 wrote: > > An update on this. > > 'which python' returns: > > libpython2.5.so.1.0 => not found > libpthread.so.0 => /lib64/libpthread.so.0 (0x0039a4a0) > libdl.so.2 => /lib64/libdl.so.2 (0x0039a460) >

ManyToMany and save method

2008-11-17 Thread Marco Minutoli
The assigned_to is correctly insert into the db. Why? Sorry for my bad English.. Marco. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users

how to use generic_inlineformset_factory ?

2008-12-07 Thread Marco Louro
Hi, I'm trying to use generic_inlineformset_factory. There are no docs for it except a Generic Relations Model example @ http://www.djangoproject.com/documentation/models/generic_relations/ on the bottom (GenericInlineFormSet tests) My question here is how to pass the POST vars to it? In a mode

Re: how to use generic_inlineformset_factory ?

2008-12-07 Thread Marco Louro
T,request.FILES)) Exception Value: 'NoneType' object has no attribute '_meta' Exception Location: /usr/lib/python2.5/site-packages/django/contrib/ contenttypes/generic.py in __init__, line 295 On Dec 8, 4:07 am, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Sun,

Re: how to use generic_inlineformset_factory ?

2008-12-07 Thread Marco Louro
Well, i've spent countless hours on this, and it was so easy.. I guess it could be added to the docs since It's a really nice feature. I've posted my very bad view code at dpaste, but it might be enough if anyone who has a similar problem http://dpaste.com/hold/96937/ On Dec 8,

Adding costum css classes to form labels based on validation rules outside the admin

2008-12-09 Thread Marco Louro
Hi, I guess the subject sums it up.. Basicly, in the admin we have: City: But oustide there is no 'class="required"'. Is there a way to define this so that it shows up? That would make my life much easier since I could just code some javascript to do client side validation based on css classes.

ANN: Softwarefabrica Django Wiki (PRE-RELEASE)

2008-12-16 Thread Marco Pantaleoni
t I hope to ship a "more final" release in a few days, with the help of your feedback :-) Please give it a try! Comments, suggestions, bug reports and patches are very welcome! Cheers, Marco -- Marco Pantaleoni --~--~-~--~~~---~--~~ You received this m

ANN: Softwarefabrica Django Utils (PRE-RELEASE)

2008-12-18 Thread Marco Pantaleoni
with easy_install) Please give it a try! Comments, suggestions, bug reports and patches are very welcome! Check also the other libraries on Launchpad: http://launchpad.net/softwarefabrica Cheers, Marco -- Marco Pantaleoni --~--~-~--~~~---~--~~ You received

ANN: Softwarefabrica Django Forms (PRE-RELEASE)

2008-12-18 Thread Marco Pantaleoni
n.org/pypi/softwarefabrica.django.forms Please give it a try! Comments, suggestions, bug reports and patches are very welcome! Check also the other libraries on Launchpad: http://launchpad.net/softwarefabrica Cheers, Marco -- Marco Pantaleoni --~--~-~--~~~---~--~~ You received th

nested template problem

2008-12-18 Thread marco ghidinelli
hello. Does django template engine supports nested dictionary? i'm trying to display a nested array with no luck. that's my tries: --- python manage.py shell --- from django.template import Template, Context list_parts = { 'root': {'value': [{'tag': 'a'},

Re: nested template problem

2008-12-19 Thread marco ghidinelli
On Thu, Dec 18, 2008 at 11:42:19AM -0800, bruno desthuilliers wrote: > > i'm trying to display a nested array with no luck. > > > > that's my tries: > > > > --- python manage.py shell --- > > from django.template import Template, Context > > list_parts = { > >

ANN: Softwarefabrica Django CRUD (PRE-RELEASE)

2008-12-19 Thread Marco Pantaleoni
arefabrica Cheers, Marco -- Marco Pantaleoni --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this

Re: Your IDE of choice

2009-01-08 Thread Marco Buttu
some > tweaking for Windows. I am using PySmell to autocomplete Django code, but I think omnicomplete is better. Tomorrow I'll try it :-) Thanks -- Marco Buttu --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

model inheritance with foreign key problem

2009-01-16 Thread Marco Minutoli
S': '2', # the number of forms rendered 'addresses-INITIAL_FORMS': '0', # the number of forms with initial data 'addresses-0-name': 'Test test', } formset = inline_formset(data, instance=org) formset.is_valid() formset.save() "&qu

Django unittest fails to check empty values

2009-01-26 Thread marco sedda
Hi, I've a problem with unittest in django: I've described a models.py: class Season(models.Model): name = models.CharField(max_length=30, unique=True) startDate = models.DateField("From") endDate = models.DateField("To") and the test.py: def testSeasonCreateEmp

Re: http links without using URLs.py

2009-01-27 Thread Marco Buttu
and include it in > View.py. I have many links like this and would prefer that the links > go directly to the page ignoring the django requests. If you want to bypass the view you can try direct_to_template: http://docs.djangoproject.com/en/dev/ref/gener

Re: Prepoplulate admin form with previously entered data

2009-02-10 Thread Marco Bazzani
you can open a patient modify it and save it as new On Tue, Feb 10, 2009 at 4:00 AM, Adam Woodbeck wrote: > > Would it be possible to extend the ModelForm for my encounter model, > automatically filling the form when I add a new entry? > > On Feb 9, 9:51 pm, Adam Woodbeck wrote: >> I'm building

Re: Prepoplulate admin form with previously entered data

2009-02-10 Thread Marco Bazzani
here is how http://docs.djangoproject.com/en/dev/ref/contrib/admin/#save-as On Tue, Feb 10, 2009 at 12:04 PM, Marco Bazzani wrote: > you can open a patient modify it and save it as new > > On Tue, Feb 10, 2009 at 4:00 AM, Adam Woodbeck > wrote: >> >> Would it b

Re: Automated Translation Management -- Surely someone has already done this?

2009-02-16 Thread Marco Bazzani
so seems that the answer is no, and If you would share your work I (and probably many other) will appreciate it very much :) regards On Mon, Feb 16, 2009 at 8:47 AM, DrMeers wrote: > > I have developed a Django site for an open source project, with > contributors around the globe. > > A brief as

database trigger or what ?

2009-02-25 Thread marco sedda
Hi, i'm newbie in django and i'm writing a model to record a general booking in a particular date for a particular item The booking model looks like this: class Booking(models.Model): item = models.ForeignKey(Item) startDate = models.DateField("From") endDate = models.DateField("To")

How to select a single field from database with django QuerySet API?

2009-02-26 Thread marco sedda
Hi, I want to select a "single" field from a table, i've read the QuerySet API reference but i can't find anything to solve my query. Just to explain: If i've a table like: User first_name = models.CharField(max_length=30) last_name = models.CharField(max_length=30) how i can execute

Re: How to select a single field from database with django QuerySet API?

2009-02-26 Thread marco sedda
Thanks!!! On Feb 26, 10:28 am, Eric Abrahamsen wrote: > On Feb 26, 2009, at 6:23 PM, marco sedda wrote: > > > > > Hi, > >   I want to select a "single" field from a table, i've read the > > QuerySet API reference but i can't find anything to so

using multilingual fields to slugify urls

2009-06-23 Thread Marco Bazzani
th the value of "none" I think because the value of the fields is not yet in the database moreover I should need translatable slug too so I can request the page with all its urls for example /news/hello-I-am-a-news/ -> content in english /news/s

Re: Recommendations for a Django development book?

2009-07-22 Thread Marco Buttu
t; (2nd edition): http://www.apress.com/book/view/1430219386 They are complementary. The first is a wonderful book, mainly suited for beginners, and the second is very useful for more advanced readers. -- Marco Buttu | www.pypeople.com --~--~-~--~~~---~--~~ You received this

Re: django newbie with an install problem - bad interpreter

2008-05-20 Thread Marco Buttu
I thought my symlink might be bad so I tried executing the command > using the full path to django-admin.py which gave me the same message. You can try without use env: python /usr/local/Django-0.96.2/django/bin/django-admin.py startproject

Re: Error while importing URLconf '{{ project_name }}.urls'...

2008-05-29 Thread Marco Buttu
reference: > Error while importing URLconf 'csp.urls': No module named csp.urls Why in the ROOT_URLCONF ``CSP'' is uppercase and in the error message it is lowercase? -- Marco Buttu --~--~-~--~~~---~--~~ You received this message because

Re: Django model problem

2009-04-03 Thread Marco Buttu
ls.ForeignKey(Musician) name = models.CharField(max_length=100) pub_date = models.DateField() -- Marco Buttu --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send em

Re: signals vs. save()

2009-04-16 Thread Marco Maier
On Thu, Apr 16, 2009 at 5:25 PM, koranthala wrote: > > On Apr 16, 6:41 pm, Alex Gaynor wrote: > > On Thu, Apr 16, 2009 at 6:39 AM, koranthala > wrote: > > > > > Hi, > > >I was comparing between signal and save() and came across this > > > following mail chain - > > > > >http://groups.google

Choosing database at runtime

2009-05-28 Thread Marco Louro
t. I don't want to change backends, but I need to configure at least different database names for each subscriber. My question is, is it possible right now, and worth to try and hack a solution or is this something that will be supported soon?

extending django-registration ( MixIn ModelForm and Form)

2009-06-01 Thread Marco Bazzani
ch the order of the inheritance. I've also modified some django registration to use my Model instead of User ( but shouldn't be the origin of the problem) any clue ? cheers Marco --~--~-~--~~~---~--~~ You received this message because you are subscr

Re: extending django-registration ( MixIn ModelForm and Form)

2009-06-01 Thread Marco Bazzani
On Mon, Jun 1, 2009 at 23:19, V wrote: > > On Jun 1, 6:50 pm, Marco Bazzani wrote: >> I'm trying to extends django-registration app with some more fields in >> the moment of registration >> those fields are saved in a subclass of User >> >> for ref

Re: extending django-registration ( MixIn ModelForm and Form)

2009-06-02 Thread Marco Bazzani
05:57, Rishabh Manocha wrote: > On Tue, Jun 2, 2009 at 9:10 AM, Marco Bazzani > wrote: >> >> On Mon, Jun 1, 2009 at 23:19, V wrote: >> > >> > On Jun 1, 6:50 pm, Marco Bazzani wrote: >> >> I'm trying to extends django-registration app with some m

Re: Reason for not allowing spaces in usernames?

2009-06-12 Thread Marco Louro
As long as you trim start and trailing spaces, there shouldn't be any problem, but personally I wouldn't use spaces in usernames at all. On Jun 12, 2:42 pm, Wiiboy wrote: > Do you think I would have problems if I disabled the checking for > spaces? > > When I register users, I have it done auto

Extend Admin Search Form

2009-11-25 Thread Marco Minutoli
Hi Everybody, I would like to add a complex search form in the change_list.html admin template (for example to add possibility to search something from date to date) Is there a way to do this? Thanks in advance. Marco Minutoli -- You received this message because you are subscribed to the Google

How can I retrieve the ModelAdmin given the model class or an instance?

2010-01-06 Thread Marco Rogers
I'm retrieving a model using django.db.models.get_model. The view is receiving a post from a form generated by the ModelAdmin. How can I get a hold of that ModelAdmin instance so can then get a hold of the ModelForm? This will allow me to process the post (validation, related objects, etc). The

Re: Passing a parameter into a queryset for a generic view

2010-01-07 Thread Marco Rogers
I was looking for some convenient method like this to use with the object_list generic view. But writing my own wrapper view only took 2 secs. def speaker_list(request, session_month): if not session_month in settings.SESSIONS: return HttpResponseNotFound() speake

How to get ModelAdmin given a Model

2010-01-11 Thread Marco Rogers
I'm reposting this from earlier to see if I have better luck. I need to be able to get the ModelAdmin associated with a model at runtime. Similar to how django.db.models.get_model allows you to retrieve a model. admin_class = get_admin(Model) Is this possible? The original post has more info

Re: How to get ModelAdmin given a Model

2010-01-12 Thread Marco Rogers
.site._registry return admin.site._registry[model] return None I haven't testing this because I'm doing something slightly different :Marco On Jan 11, 4:37 pm, Matt Schinckel wrote: > On Jan 12, 4:11 am, Tomasz Zieliñski > > > > wrote: > > On 1

Re: list_display functionality for inlines ?

2010-01-12 Thread Marco Rogers
I'm trying to find a solution to this very same issue. At the very least, I think inlines should support custom callables. The inline I'm displaying is an intermediary table for a ManyToMany relationship. So I have a selector for the related object, but what I would like to do in the inline is al

Re: Problem when trying to validate a field in a ModelAdmin which has inline forms

2010-01-15 Thread Marco Rogers
ur clean method you would grab the submitted inlines and check them against the is_approved field on the Clip. I'm not a django expert, but that's where I would start. Good luck. :Marco On Jan 14, 6:45 pm, Gabriel Reis wrote: > Hi people, > > I am having some problem to va

Re: Save inline instances first

2010-01-18 Thread Marco Rogers
I had a need for this at one point because my main model had an overridden save method that would modify the inlines. But it didn't work because the inlines weren't there. I had to reverse the save method and put it on the inline model. But in my case, there was no reason not to do tha

extend TimeFormat

2010-08-25 Thread marco ghidinelli
y project tree (settings.py, views.py, __init__.py ) but in vain. where should i put it? regards, marco. -- 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 unsub

Re: Initialize model's fields

2010-09-16 Thread Marco Vicario
Thanks a lot Bruno!!! 2010/9/15 bruno desthuilliers > On 15 sep, 18:35, marcovic wrote: > > Hi all, > > i'm trying to do a simple task with Django but evidently it is not so > > simple... > > It is - when you understand how things work. > > > I have my model: > > > > class Mymodel(models.Model)

Re: django-authopenid user timeout

2010-02-07 Thread Marco Barbosa
Hi Rachel, I can't help your problem but I'm curious after you said "it seems to be working just fine" - how did you manage to make it work? You just followed the site instructions and it works? I got a problem here when i click "register" it will complain that there's missing a parameter on regi

Re: about sending email

2010-02-17 Thread Marco Rogers
ou'll need to make sure your production server has access to a real mail server. :Marco On Feb 17, 6:05 am, andreas schmid wrote: > this doesnt seem a django problem but a failure in the connection to the > mailserver. > check your email setup in your settings.py > > >

Re: Downloadable CSV file of Survey?

2010-02-18 Thread Marco Rogers
Definitely use python csv and do it yourself. It's really very simple. shaner's links above should help. One thing I would add is make sure you convert all of your model values to unicode because otherwise the csv module will choke on bad characters. unicode(value, 'utf8

Re: apparent bug in QuerySet

2010-02-22 Thread Marco Rogers
han a "filter these and then filter these" type of structure. The name "update" conflicts with the api for dict.update which updates in place. Maybe that's okay or maybe it needs a new name. :Marco On Feb 22, 3:15 am, Russell Keith-Magee wrote: > On Mon, Feb 22, 2010 at

Re: Hierarchical data containing different models

2010-02-25 Thread Marco Rogers
ll not have any of the properties there were put on the Group and Item subclasses. Because the Node class doesn't know about them. This is a problem I've had with django for a while now and i would love to see a solution that addresses it. :Marco On Feb 24, 5:01 pm, bruno desthuillier

Re: problems with model inheritance if base class is not abstract

2010-11-21 Thread Marco Ferragina
Mmm yes it seems you are right. But I think this is a bit confusing thinking about object oriented programming, it is not? Then the only way to avoid this seems to be use an abstract base class or use some not so clean way to simulate this behavior. On 21 Nov, 01:36, Ramiro Morales wrote: > On

Multi-tenant Django w/ Multi-DB?

2011-01-05 Thread Marco Louro
Hey, I'm wondering if Multi-DB supports some kind of multi-tenancy on the DB level (one app instance supporting multiple databases - one per client - 2 on http://www.ibm.com/developerworks/cloud/library/cl-multitenantsaas/figure0.gif). I don't think it does, but just want to be sure. I'm thinkin

Re: Multi-tenant Django w/ Multi-DB?

2011-01-05 Thread Marco Louro
Thanks for your reply Justin, I'd like to avoid having multiple tenants in the same database, I feel multi-database is easier to scale, and simpler in a code maintenance sense. It does required to run database migrations once per tenant, but I still see it as the better solution. One solution I s

performance fields in forms.py (province/city problem)

2011-01-12 Thread marco carminati
Dear all, i'm trying to improve the performance during the modify of one of my models' I've the classic province and city structure. In the 'insert form', using jquery, I can update the city queryset after the user choice the province. In the 'update form', I would like to set the city's queryse

Re: Generate a unique username for django.contrib.auth

2011-01-12 Thread marco carminati
atabase you could put in your mail directly the user.id hello {{ user.id }} unfortunately I cannot test this solution now (sorry, i've not django in this machine) hoping this help, marco -- You received this message because you are subscribed to the Google Groups "Django users" gro

Re: Javascript Questions

2011-01-12 Thread marco carminati
> the onchange event and it does not seem to work. So is there anyway to > find out what event(s) are fired by the dropdown box so my code works? if you active the console in firebug you could see anything.. you could always put an alert('hello') in your javascript code > Is it legal to code mul

Re: performance fields in forms.py (province/city problem)

2011-01-13 Thread marco carminati
solved. thank you all On Jan 12, 8:59 pm, marco carminati wrote: > Dear all, > i'm trying to improve the performance during the modify of one of my > models' > > I've the classic province and city structure. > > In the 'insert form', using jquery, I

Re: performance fields in forms.py (province/city problem)

2011-01-13 Thread marco carminati
(or on a blog)? > > On Jan 13, 1:31 pm, marco carminati wrote: > > > solved. > > thank you all > > > On Jan 12, 8:59 pm, marco carminati wrote: > > > > Dear all, > > > i'm trying to improve the performance during the modify of one of my &

Re: inclusion_tag argument missing

2011-01-14 Thread marco carminati
see http://docs.djangoproject.com/en/dev/howto/custom-template-tags/ you should use the 'context' parameter. from link "Sometimes, your inclusion tags might require a large number of arguments, making it a pain for template authors to pass in all the arguments and remember their order. To solve t

manage.py test => FAILED (failures=4, errors=1) HELP ME!!!

2011-01-20 Thread Marco Lerco
Sorry for my bad English. I'm Italian :-) I'm starting to study Satchmo. I followed all the installation process (http:// www.satchmoproject.com/ docs/dev/new_installation.html), after which I followed the command: python manage.py satchmo_check Result? This: Checking your satchmo configuration

Caught exception bug --

2011-02-13 Thread marco giardina
hello all, django 1.2.4 with oracle_xe vrs. and debian filesystem -- i received the following error when search data on a table manytomay: Caught an exception while rendering: ORA-00932: inconsistent datatypes: expected - got NCLOB

extend TimeFormat

2011-03-02 Thread marco ghidinelli
y project tree (settings.py, views.py, __init__.py ) but in vain. where should i put it? regards, marco. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsub

Change value automatically of a widget in the Admin Interface

2012-05-14 Thread Marco Olimpi
elements that have the same model1. Which is the best way to do it? Thanks so much. Marco -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this g

dynamic, heterogeneous formset?

2012-12-27 Thread Marco G.
ty form. Is there some pre-made formset-like library to automate this kind of form generation and handling? Thanks!! Marco -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.go

Sqlite create ForeignKey problem

2013-05-27 Thread Marco Bonelli
Hi, In my models I want to have an optional field to a foreign key. I tried this: classe = models.ForeignKey('Classe', null=True) But i am getting this error: Table has no column named classe_id i am using sqlite edit -- You received this message because you are subscribed to the Google Grou

Re: Best practice: Models.py vs View.py?

2013-09-11 Thread Marco Fucci
The models module is not limited to back-end data, it can include all kinds of models so your Page class can definitely be in it. For the helpers, it really depends on your code. If they are simple enough and used only in your views, it may be OK to place them in views.py whereas if they are co

Re: error python manage.py syncdb

2013-09-11 Thread Marco Fucci
A few things might be causing the problem: - is settings.SECRET_KEY empty? If so, it's easy enough to fix - in your settings, you might be importing a custom module *before* defining the SECRET_KEY causing dependency problems - you're doing something wrong in your settings (e.g. impor

NameError: name 'reciever' is not defined

2015-06-19 Thread Marco Neumann
Hi There, Im stuck on above error. Anyone a hint? Many thanks My code in models.py: from django.db.models.signals import post_save from django.dispatch import receiver from django.db import models from django.contrib.auth.models import User class UserProfile(models.Model): user = models.One

Re: NameError: name 'reciever' is not defined

2015-06-20 Thread Marco Neumann
Need a extra pair of eyes. :-) Thanks for your answer Op zaterdag 20 juni 2015 00:43:00 UTC+2 schreef James Schneider: > > Check your spelling for receiver... > > -James > On Jun 19, 2015 3:26 PM, "Marco Neumann" > wrote: > >> Hi There, >> >> Im

Re: NameError: name 'reciever' is not defined

2015-06-20 Thread Marco Neumann
Thanks for your response. I need a extra pair of eyes. :-) Op zaterdag 20 juni 2015 00:27:07 UTC+2 schreef Marco Neumann: > > Hi There, > > Im stuck on above error. Anyone a hint? Many thanks > > My code in models.py: > > from django.db.models.signals import post_sav

Allauth: Howto registrate User with also saving data UserProfile fields

2015-07-07 Thread Marco Neumann
Hi all, I would like to make a registration form with the User SignUp form and extra UserProfile fields. So after saving the user is created and the data is saved in the UserProfile model. Can someone point me in the right direction. Thanks in advacend. Greetings Marco neumann -- You

Re: Allauth: Howto registrate User with also saving data UserProfile fields

2015-07-07 Thread Marco Neumann
Hi All, For those collegue beginners who also where searching. :-) In my search of the sollution i found this: http://www.tangowithdjango.com/book17/chapters/login.html <http://www.tangowithdjango.com/book17/chapters/login.html> Works great. Greetings marco Op dinsdag 7 juli 2015 18

help designing a fallback django paralel server

2016-08-30 Thread Marco Silva
Hello, I have several critical systems, each run a django server witch users use trough the local network(192.168.xxx.xxx) to control and monitor the system. The goal would be to create a more powerfull remote server, that could unify several local servers, so that regular use would be only tr

Re: A tricky query in one to many relationship - atleast for me:)

2016-08-30 Thread Marco Silva
Maybe this can help you https://docs.djangoproject.com/en/1.10/topics/db/aggregation/ terça-feira, 30 de Agosto de 2016 às 07:33:14 UTC+1, Web Architect escreveu: > > Hi, > > I am looking for an elegant and efficient mechanism to have a query filter > or a solution for the following one to many

How to unsubscribe?

2017-03-05 Thread Marco Miani
Hi.  can anyone please explain how I get off this list?  I have tried to click the link at the jottom of this mail, where it says 'unsubscribe' but the reply i got was that I couldnt be unsubscribe because myemail address would not belong to the list (unknown). Who is the owner of this list? who

Migrations in Django 1.9: verbose_name and verbose_name_plural

2016-02-13 Thread Marco Badan
Hello, I've upgraded a project to Django 1.9. I've: LANGUAGE_CODE = 'it' LANGUAGES = (('it', 'Italian'),) With Django 1.8 after running makemigrations I got the no changes detected message. On 1.9 makemigrations creates migrations for all of my apps and all third party apps. I had a look at

Re: Migrations in Django 1.9: verbose_name and verbose_name_plural

2016-02-14 Thread Marco Badan
ed (once) after migrating to 1.8." but you said you > upgraded from 1.8 to 1.9, so I guess it isn't relevant. > > If you could bisect Django's commit history to find where the behavior > changed, that might yield some insight. > > On Saturday, February 13, 2016 at 8:3

Re: Migrations in Django 1.9: verbose_name and verbose_name_plural

2016-02-15 Thread Marco Badan
using *django.conf.urls.patterns* For reference: the url is here <https://github.com/divio/django-cms/blob/develop/cms/wizards/urls.py> and the related view is WizardCreateView <https://github.com/divio/django-cms/blob/f1e04a539d9df7df19fc4412b8f80f3ea471ea3e/cms/wizards/views.py#L42-L171> . Cheers

Re: Migrations in Django 1.9: verbose_name and verbose_name_plural

2016-02-15 Thread Marco Badan
oh, it was you that fixed the warning in django-cms so... thanks again Il giorno lunedì 15 febbraio 2016 22:06:05 UTC+1, Marco Badan ha scritto: > > ok, > > I was able to isolate the url: it's from django cms 3.2.1. > The django cms devs have alrea

Re: How Can i get a URL like this(without '/')

2007-06-20 Thread Marco Giusti
On Thu, Jun 21, 2007 at 12:16:15AM +0800, 萧连衣 wrote: >How Can i get a URL like this(without '/'): >http://code.djangoproject.com/search?q=echo&wiki=on&changeset=on&ticket=on >http://code.djangoproject.com/wiki > >not: >http://code.djangoproject.com/search/?q=echo&wiki=on&changeset=on&ticket=on >htt

problem to save..

2007-07-25 Thread Marco A.
HI ! In model I have : from django.db import models # Create your models here. class User(models.Model): User = models.CharField(maxlength=200) Pasw = models.CharField(maxlength=16) def __unicode__(self): return self.question def was_published_today(self): return self.

Re: problem to save..

2007-07-26 Thread Marco A.
+0200, Horst Gutmann <[EMAIL PROTECTED]> > wrote: > > > > Marco A. wrote: > >> HI ! > >> In model I have : > >> > >> from django.db import models > >> > >> # Create your models here. > >> class User(mod

view and urls..

2007-08-01 Thread Marco A.
I doesnt undestand where is the problem in this code : The Application is : Cit2 !--> Utente I need to call the view Login in Utente so in the url i say : from django.conf.urls.defaults import * urlpatterns = patterns('', # Example: (r'^/?$', login), # Uncomment this for adm

templates..

2007-08-02 Thread Marco A.
quot;HI" get_template('prova.html') return HttpResponse(html) In the settings.py there is : TEMPLATE_DIRS = ( "/home/marco/cit2/templates" ) And there is a file called prova.html in the directory. Thanks --~--~-~--~~~---~--~~ You r

'_QuerySet' problem

2007-08-05 Thread Marco A.
Hi to all ! I doesnt undestand where is the problem whit Query set.. (or maybe what is query_set) If the models is : class User(models.Model): user = models.CharField(maxlength=12) passw = models.CharField(maxlength=20) I doest undestand this shell session : >>> User.objects

Django : generic view object_list

2007-08-06 Thread Marco A.
help that I received and I recive from this ML-group, Ciao Marco --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To uns

Problem whit slung filter on Object_list genric view

2007-08-07 Thread Marco A.
Hi ! I doesnt undestand why , the slug by filters doesnt run . error :NameError at /marco/ name 'user' is not defined Request Method: GET Request URL: http://127.0.0.1:8000/marco/ Exception Type: NameError Exception Value: name 'user' is not defined Exception Locati

pass a template to a genric_view

2007-08-14 Thread Marco A.
HI ! I have this urls.py (r'^10/$', 'django.views.generic.list_detail.object_list', info_dict , {'template':'cit_list10.html'}), but the genericview use the standard template ... not the template in 'cit_list10.html'. I

view to template, pass data

2007-08-17 Thread Marco A.
HI, Where I can find a sample where a view pass a query and other models to a template and the temmplate show them. I need that for undestand how this part work Thanks Marco --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

  1   2   >