I apologize for intruding and try not to be partisan. I will not list
pros and cons since this is not the place for me to do so.
I would just like to make clarifications about things being said:
1) web2py comes with a web based IDE but you do not have to use it.
You can disabled it or can even rem
Presumably you'll eventually have enough transactions that you'll want
to start paging them. At that point, it would change how you would
arrive at the balance. If a user is looking at page 30, you shouldn't
need to retrieve the transactions from pages 1-29.
Eventually, you may want to consider so
Thanks for explanation. What if Samurai can be outside all Rooms and can
be at most at 1 Room at a time?
Regards,
Viet.
Peter Herndon wrote:
On Feb 18, 2010, at 11:47 PM, Timothy Kinney wrote:
Here's the system I'm currently using that doesn't work too well...
Samurai (id, name)
Room (
Seems like there's no good way to do this, because you can't call
methods that take > 0 arguments.
Here's an example of the sort of thing I'm trying to do. Imagine
you're trying to create a spreadsheet like view:
{% for person in people %}
{% for col in columns %}
{{ person.get(col) }}
Ok thanks,
indeed the javascript files were missing, i think i deleted the whole
javascript folder by mistake when moving.
regards,
Richard
On Feb 19, 2:34 am, Kenneth Gonsalves wrote:
> On Friday 19 Feb 2010 2:01:50 am mendes.rich...@gmail.com wrote:
>
> > Does anyone know a solution for this
On Feb 19, 8:04 am, Daniel Wong wrote:
> Seems like there's no good way to do this, because you can't call
> methods that take > 0 arguments.
>
> Here's an example of the sort of thing I'm trying to do. Imagine
> you're trying to create a spreadsheet like view:
>
> {% for person in people %}
>
I don't understand your question. The Samurai requires one room by the
declaration:
class Samurai(models.Model):
...
room = models.ForeignKey("Room")
...
Since it is a ForeignKey, it can only accept one value and the value cannot
be None. Therefore, all samurai will always be in only one room at
On Fri, Feb 19, 2010 at 1:37 PM, mdipierro wrote:
> I apologize for intruding and try not to be partisan. I will not list
> pros and cons since this is not the place for me to do so.
> I would just like to make clarifications about things being said:
And I would like to clarify some of your clari
On Thu, Feb 18, 2010 at 11:31 PM, Timothy Kinney
wrote:
> This is a fabulous response, Peter. Thank you very much for making this so
> clear. The samurai_set is a revelation for me as well. I see now that I
> should look more carefully at the methods available for the models.
>
> If I can ask anot
Okay, I'm still lacking understanding on the inventory part. Here's what I
have so far:
class Inventory(models.Model):
id = models.AutoField(primary_key=True, verbose_name="inventory")
samurai_id = models.ForeignKey('Samurai')
item_id = models.ManyToManyField(Item)
condition = mode
Hi,
On Fri, Feb 19, 2010 at 4:41 PM, Russell Keith-Magee
wrote:
> Regarding licensing: I have no desire to get into a "whose license is
> better" flamewar. You writes the code, you picks the license.
The way I see it, Massimo was just addressing the point about Django
culture and permissive lic
how do i have to deal with special characters in urls?
for example if i would have programming languages like C, C++ or C# if i
use SlugField the characters are escaped and each of the 3 slugs becomes C.
what is the way to go?
--
You received this message because you are subscribed to the Google
> Presumably you have a view which is updating this object. The view has
> access to the HttpRequest. Therefore, the easy, simple, clean and
> elegant way is... to have the view set the value of that field. So do
> that and ignore anyone who tells you otherwise --
> magically/secretly/implicitly t
As a newbie of sorts I started by trying out both Web2Py and Django at
the same time.
I found Web2Py to somehow be more elegant, and in fact liked the
coding style in the
source better that what I found in Django, or can say at least I
preferred the structure
and format of the code I saw.
The docu
As a newbie of sorts I started by trying out both Web2Py and Django at
the same time. I found Web2Py to somehow be more elegant, and in fact
liked the coding style in the source better that what I found in
Django, or can say at least I preferred the structure and format of
the code I saw.
The docu
I am restricting access to particular pages. The reports page doesn't
have a particular model. It's going to have some 'flat' content and
links to lots of other reports. So that is why I was confused. There
is no underlying data model for that page.
I was going to query rebus's suggestion. I didn'
Hi.
It's a build tool for Python:
http://en.wikipedia.org/wiki/Build_automation
http://www.buildout.org/
- Gustavo.
On Feb 18, 7:07 pm, Timothy Kinney wrote:
> Sorry for the noob question, but what is a Buildout recipe?
>
> On Thu, Feb 18, 2010 at 11:30 AM, Gustavo Narea <
>
> gustavona...@2de
On 19 February 2010 09:28, Paul Stone wrote:
>
> > Presumably you have a view which is updating this object. The view has
> > access to the HttpRequest. Therefore, the easy, simple, clean and
> > elegant way is... to have the view set the value of that field. So do
> > that and ignore anyone who
Since the official django-multilingual [1] does not support Django 1.2 (and has
some other annoying things in my opinion), I decided to create a new project
based off django-multilingual which works in 1.2 and has some other
improvements. This project is called django-multilingual-ng, it's on t
On Feb 19, 2:15 am, geraldcor wrote:
> All of your comments prompted me to start reverse engineering what
> django does and I came across the check_password method which just
> separates the algorithm, salt and hash and then sends it to the
> following method to compare the raw password to the h
Hi Tim,
Thanks for reply. I mean if I want Samurai to be out of all rooms?
ForeignKey disallows Null. Should I do like this: Create a default dummy
Room and assign it by default?
Viet.
Timothy Kinney wrote:
I don't understand your question. The Samurai requires one room by the
declaration:
At work we are planning move from Sugar CRM PRO to something else
free. I'd love moving to something python based, but it seems the only
free and reliable solution is VTiger 5 written in php.
Does anybody here know any CRM based on django?
--
You received this message because you are subscribed
El 19/02/10 06:58, Massimiliano della Rovere escribió:
> Does anybody here know any CRM based on django?
http://tinyurl.com/ygcl4fw
--
Gonzalo Delgado
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to djang
On Friday 19 February 2010 11:25:41 andreas schmid wrote:
> ve to deal with special characters in urls?
> for example if i would have programming languages like C, C++ or C# if i
> use SlugField the characters are escaped a
>
Hi Andreas,
I'd set slugs manually as "c", "cpp" and "c-sharp" respecti
Not sure if this is what you're looking for but just searching for
django-crm on google got me http://code.google.com/p/django-crm/
Massimiliano della Rovere wrote:
At work we are planning move from Sugar CRM PRO to something else
free. I'd love moving to something python based, but it seems th
> > That's fine for one or two models. But what if I want to do this for a
> > number of models, in every view? What's the best way to do that
> > without code repetition?
>
> Using a ModelForm?
>
> http://docs.djangoproject.com/en/dev/topics/forms/modelforms/
Ok, I think I understand now. ModelFo
It doesn't make sense for the Samurai to be out of all rooms. If it's
because he is dead you should create a room for that, such as "Graveyard" or
something. However, I think it would work to include "blank = True" in the
declaration. This would allow the field to have a null value.
-Tim
On Fri,
Hello everybody,
I am using Dajaxice to get my data from DB to my template.
function getParking_callBack(data){
if(data!='DAJAXICE_EXCEPTION'){
return data;
}
else{
... here's a solution I found really useful. It uses a base profile
with inheritance.
http://stackoverflow.com/questions/1796556/django-multi-table-inheritance-vs-specifying-explicit-onetoone-relationship-in-mo
ALJ
--
You received this message because you are subscribed to the Google Groups
"D
Hi Hanne,
Thanks for this and apologies for not looking at this sooner. I
thought the thread was gone dead.
I also found this thread which might be of use to some other numpties
out there.
http://groups.google.com/group/django-users/browse_thread/thread/f3f1a51bd1a465d9/df45ba7044caae41?lnk=gst&
I didn't change anything ... but today is working. Go figure
:)
Thanks for all your help!
On 18 fev, 17:57, gustavo wrote:
> Robin,
>
> I tried, but it didnt work...
>
> On 18 fev, 17:20, robin nanola wrote:
>
> > i solved it, it was just an encoding issue, i just put these
> > #!/usr/bin/
On 19/02/10 08:32, Le Quoc Viet wrote:
Hi Tim,
Thanks for reply. I mean if I want Samurai to be out of all rooms?
ForeignKey disallows Null.
minor point - ForeignKey(null=True, blank=True) will merrily allow null
if your database allows nullable foreign keys at all (chances are it
does). It
Sorry Russ,
I did not say nor implied that any of the points above were
distinctive or unique. I just tried to clarify some issues raised by
other users here.
I was careful to only make comparison that were favorable to Django
(the admin for example). I realize I am a guest here.
I do not think
Thanks for reasoning :)
Regards,
Viet.
David De La Harpe Golden wrote:
On 19/02/10 08:32, Le Quoc Viet wrote:
Hi Tim,
Thanks for reply. I mean if I want Samurai to be out of all rooms?
ForeignKey disallows Null.
minor point - ForeignKey(null=True, blank=True) will merrily allow
null if you
On 19 February 2010 10:27, Paul Stone wrote:
> > > That's fine for one or two models. But what if I want to do this for a
> > > number of models, in every view? What's the best way to do that
> > > without code repetition?
> >
> > Using a ModelForm?
> >
> > http://docs.djangoproject.com/en/dev/to
I hope that we can all learn somehow from the incident. When i reacted the
way i did, i was picking up subtle undertones of aggression which i thought
were undue. I have since spoke to Bruno and diffused the situation amicably.
I would agree with what Emily says, and the things I take away from it
Basically what you are trying to do is called a many-to-many
relationship with an intermediary table.
If it was a regular many-to-many relationship, you could just do
ManyToManyField(Item) on the samurai model, and there would be a table
with a foreign key to item, and a foreign key to samurai, an
How can I just enable anonymous user in Django?
I mean, what is the minimum I should do to be logged in as anonymous
first time I go to my site?
Regards, Arshavski Alexnder.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group,
i can't understand you well but if you enable auth system and session system
you already have anonymous user ,
for example you can find out the current user in a view with request.user .
if you did not log in then user must be anonymous
--
You received this message because you are subscribed to
It wouldn't really be a Django question, since you'd probably just do
this in JS itself.
alert(data[0].name + ' X: ' + data[0].x + ', Y: ' + data[0].y);
alert(data[1].name + ' X: ' + data[1].x + ', Y: ' + data[1].y);
If you're keen on jQuery, you could loop through the data object pretty
easily d
I've noticed that there have been a lot of things in common:
Web2py _didn't_ have very good docs, at least relative to Django's
(which are spectacular), but now that the Web2py book is available
online, that issue is kind of moot.
Admin -- Web2py has two different Admins, one which doesn't have a
OK, got it:
Rather than specifying meta/widgets, each form field has to be
specified in the ModelForm in forms.py, thus:
class CompanyContactForm(ModelForm):
contact_name =
forms.CharField(widget=forms.TextInput(attrs={'size': '20'})) #Field
name as in model
#...etc
class Meta:
Hello all, I have a really big problem with ForeignKey Models. I will
try to emplain my problem:
I have a class like this:
class Day(models.Model):
name= models.CharField(_('Name'), max_length=32,
unique=True)
description = models.TextField(_('Description'),
max_length=1024
On Fri, Feb 19, 2010 at 2:48 AM, Timothy Kinney
wrote:
> What does it mean to check about index selectivity? Sorry, my knowledge of
> databases is mostly as a user. But I am learning a lot this week.
I intentionally left it out, since i'm not the best teacher, you might
not need it (if you choose
I'd rather stay out and limit myself to rectify incorrect statements
if any. For example I'll say the documentation is not new. It has been
there for 2 years, it's just that was not free and cost $12. It is
actually old now. It still does not describe lots of new functionality
and we are trying to
I want to set a value in a parent model based on the child class. So,
in this case, I would set the ExtendedUser.usertype depending on
whether its "Teacher" or "Student".
I tried looking at using '%(class)s' to get the class name, but that
didn't work. Or can you explicitly pass values from the ch
Hi all,
I just came across a need to provide initial data for flatpages. I have
read before that people have asked to do this. It is easier than thought
:)
1. Create your content via the admin interface
2. Run 'python manage.py dumpdata flatpages > data.json'
3. When you want to provide the da
geraldcor wrote:
> and all will be good - I think. Does that sound reasonable?
Been there done that. But...
> using the given algorithm ('md5', 'sha1' or 'crypt').
^
Pick the right one wisely!
I would start with unit tests that attack
CAS sounds very interesting as a SSO. I may give that a try, as well
as maybe just perform some unit tests just to make sure I know what is
going on under the hood. Thank you all for your much needed input.
Greg
On Feb 19, 10:32 am, Phlip wrote:
> geraldcor wrote:
> > and all will be good - I th
Hey,
Do you know a Continuous Integration tool that supports Django
projects?
Thanks.
--
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
I have used a Continous Integration framework form TeamCity to auto build
and test our Delphi based product. Though it is not building and testing
Django, the TeamCity executable eventually calls python, which controls
every thing from that point on.
With python, I am sure you can auto build and
Thanks, Roseman. I was hoping I wouldn't have to resort to custom
filters or tags, because it obfuscates template code that should be
really simple. Also, I don't think filters can be applied to this
slightly modified example:
{% for person in people %}
{% for col in columns %}
too_large
I started playing with this last night and got about as far as you mentioned
here. What I want to be able to do, though, is write a python script that
writes an authentic json flatpage that I can import into the database. I
have a large textfile full of names, items, and province information (for a
No worries, I really appreciate you taking the time to explain the reason
for it. I am looking at the CommaSeparatedIntegerField (CSIF) seriously for
the exits. It seems straightforward to just use the province_id from the
exit provinces as the values in the CSIF, and then it's easy to pull the
nam
Hi Tim,
Thanks for the concrete examples. I actually had exactly what you had coded
last night, but I got rid of it because having multiple inventories for a
single samurai seemed counter-intuitive to me. But it sounds like it's the
best way to get the granularity I want.
Going back to that syste
Hi,
you could try TeamCity. I've written some short instructions (in
german) here: http://www.jan0sch.de/wissen/teamcity-django-python-tests
You'll need an extension for python, a custom test runner and the
appropriate build configuration for TeamCity.
We are using this for some months now and it
On 19 fév, 18:00, ALJ wrote:
> I want to set a value in a parent model based on the child class.
childs inherit parents attributes, so you don't have to "set a
value" (I assume you meant : "set an attribute's value") "in the
parent model" - just set it in the child.
> So,
> in this case, I would
On 19 fév, 15:38, Wiiboy wrote:
> And the explicit vs. implicit imports: Personally, I love the fact
> that the request object is available all over the place, including
> models, and that I don't have to do any importing.
As far as I'm concerned, it's a definitive No-No. The request is only
me
On 19 fév, 10:35, NoviceSortOf wrote:
(snip)
> In my opinion frameworks should be considered on a project by project
> basis
Well, if you have enough time to learn and master a dozen or more
different frameworks, that might be a sensible policy. As far as I'm
concerned, having to deal with Zo
On 18 fév, 12:03, Sithembewena Lloyd Dube wrote:
> Apologies for my handling of this matter earlier. It was not the Python way
> :)
>
> Bruno, feel welcome here.
>
Ok, I'm back then !-)
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post t
On 18 fév, 12:16, Emily Rodgers
wrote:
(snip)
> I think he stopped helping when he started using phrases like 'crystal
> ball' and 'wild-guess programming'. They are hostile responses.
>
Emily, if you manage to stick to your wishfull words for the next ten
years without even a single possibly "ho
You should be able to list all of a samurai's items by doing the
following:
samurai = Samurai.objects.get(pk=1)
for inv in samurai.inventory_set.all():
print inv.item.name
samurai.inventory_set returns a QuerySet the same way that
Inventory.objects returns a QuerySet, but it only returns inve
ok, this is the error
TypeError at /avatar/change/
function takes at most 9 arguments (11 given)
ive got a project which is a register of cars.
ive got it nearly finished and realised that i need to add a pub_date
field. so ive recreated my DB, resynced it after adding the field to
the model.
r
Okay, I spent some more time with the flatpage and it works great. I just
needed to understand the syntax a little better. I also thought that I
needed to include a lot of cruft at the beginning of the dumpdata file that
basically amounted to logs and session_ids. Taking them out worked fine. I
was
Thanks again for the help, and thank you very much for the links! I have
been looking for examples of django rpgs with little success. Once I get
something functional I plan to contribute to the open-source community as
well.
Cheers.
-Tim
On Fri, Feb 19, 2010 at 3:02 PM, Tim Shaffer wrote:
>
Bit of a python question here.
Say I have a class named MySuperClass and an extension of that class called
MySubClass. When referring to MySubClass (the class, not an instance of it),
how would I retrieve the class name of its super class.
For instance if I had:
c = MySubClass
I'd like to know if
So I have a nice little database now stocked with items and provinces.
I now want to generate random samurai and populate the database with
them. I can think of two ways to do this:
1) Through the admin interface. But how do I install a button that
will add a random samurai? Adding samurai is a bu
This is an old document, but is useful for understanding class structure in
python:
http://www.python.org/download/releases/2.2/descrintro/
I think you might want the subclass.__class__ method.
On Fri, Feb 19, 2010 at 4:51 PM, Joel Stransky wrote:
> Bit of a python question here.
> Say I have a
On Feb 19, 2010, at 5:51 PM, Timothy Kinney wrote:
> So I have a nice little database now stocked with items and provinces.
> I now want to generate random samurai and populate the database with
> them. I can think of two ways to do this:
>
> 1) Through the admin interface. But how do I install
On Feb 19, 8:58 pm, Massimiliano della Rovere
wrote:
> At work we are planning move from Sugar CRM PRO to something else
> free. I'd love moving to something python based, but it seems the only
> free and reliable solution is VTiger 5 written in php.
>
> Does anybody here know any CRM based on dja
How about:
>>> class MySuperClass: pass
...
>>> class MySubClass(MySuperClass): pass
...
>>> c = MySubClass
>>>
>>> c.__bases__[0].__name__
'MySuperClass'
>>>
What I always ask develoeprs hwo join my team is "Please read the
Language Reference!" Its a great read, I'm not joking and your answer
i
On Feb 19, 2:14 pm, bruno desthuilliers
wrote:
> On 19 fév, 15:38, Wiiboy wrote:
>
> > And the explicit vs. implicit imports: Personally, I love the fact
> > that the request object is available all over the place, including
> > models, and that I don't have to do any importing.
>
> As far as I'
As an update:
Since you can actually assign a generic relation in the admin app to a
proxy model object, when using a generic relation, the proxy objects
aren't returned because the lookup is using get_for_model which
returns an instance of the base class. (I only figured this out after
having wr
Hi guys,
What's the easiest way to make a user registration form, based on my
own Profile model and the built-in user model?
Writing my own form from scratch is looking like the most painless but
time-consuming way.
--
You received this message because you are subscribed to the Google Groups
"D
http://bitbucket.org/ubernostrum/django-registration/
--
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...@goo
That doesn't look like it helps a whole lot actually. I don't see
where I can create a registration form including my custom profile
model.
--
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...@google
On Fri, Feb 19, 2010 at 8:16 PM, mdipierro wrote:
> Sorry Russ,
>
> I did not say nor implied that any of the points above were
> distinctive or unique. I just tried to clarify some issues raised by
> other users here.
No problems - I'm not trying to accuse you of anything nefarious. I
just wante
Howdy,
Just started a new project with Django trunk (have been using Django 1.1
lately, so please bare with me).
After I got a basic setup going I installed the latest release of south, but
that bombed spectacularly with database errors in settings.py. Oh, right -
that multi-database switch! I se
78 matches
Mail list logo