Re: Multiple Templates in single list view

2021-11-21 Thread Elena Williams
Hi,

The problem is it's unclear what your question is. Can you be clearer about
what outcome you're trying to achieve?


---
Elena Williams
Github: elena <http://github.com/elena/>


On Mon, 22 Nov 2021 at 15:20, Trippy Samurai 
wrote:

> Any one plz
>
>
> On Sunday, 21 November 2021 at 15:09:39 UTC+5:30 Trippy Samurai wrote:
>
>> Hello,
>> I have different views for displaying different templates how do i write
>> them into one single Listview so that i can take care of DRY
>>
>>
>> [image: Screenshot 2021-11-21 at 3.08.58 PM.png]
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/d86e1449-a17e-4e93-9dd2-1fae9a7e91d7n%40googlegroups.com
> <https://groups.google.com/d/msgid/django-users/d86e1449-a17e-4e93-9dd2-1fae9a7e91d7n%40googlegroups.com?utm_medium=email_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMRRKVfEu7vdQsmPr7wD4Ep3j-UhUKwUQqZ5J4yVFAY2JW-TVQ%40mail.gmail.com.


Re: updating model breaks admin

2018-04-30 Thread Gloria Elena
Hi George,

Thanks for the advice. I tried both suggestions and I am still getting the
same errors.

Here is my articles app structure and admin.py:


And here is my site structure:


Thank you!!


On Sun, Apr 29, 2018 at 11:50 PM, George Lubaretsi 
wrote:

> If the data is not important, try to delete migration files from
> `migrations` package, drop the database tables and reference M2M
> relationship using strings:
>
> tags = models.ManyToManyField('Tag')
>
> Or if the Tag model is in another app:
>
> tags = models.ManyToManyField('app_name.Tag')
>
> Then run `makemigrations` and `migrate`
>
> Can you also share the `Tag` model and related `ModelAdmin` classes?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/9d251f4a-b4ea-48b0-946b-458ea6f2957d%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
-

Gloria Jimenez
Jr. Software Developer

 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CADOCafiPg0-jtFMCLOKVufth_D2_3Ttzw9xsc2OkZWP_HZ62ww%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


updating model breaks admin

2018-04-29 Thread Gloria Elena
Hi all,

I want to request your help and I am sure you can guess by the question
that I am fairly new to Django and THANK YOU IN ADVANCE, I would like to,
someday, publish this portfolio website. I am sure I am making such a
rookie mistake and will have to kick myself for making such a silly error
but I am stuck !! Hope to pay it forward.

*I have this model in the articles app that works great: *

class Article(models.Model):
title = models.CharField(max_length=120, unique=True)
body=models.TextField(max_length=600)
date=models.DateField()
created = models.DateField(auto_now_add=True)
featured=models.BooleanField(default=False)
slug = models.SlugField(blank=True)


*UNTIL I add a new class and add this field:*

tags = models.ManyToManyField(Tag)


*Error message when adding a new article in admin:*


* OperationalError at /admin/articles/article/add/cursor
"_django_curs_5508_1" does not exist Error message when adding a new tag in
admin: *


* ProgrammingError at /admin/articles/tag/add/relation "articles_tag" does
not exist LINE 1: SELECT (1) AS "a" FROM "articles_tag" WHERE
"articles_tag".".. What I have tried to no avail:1) deleting all articles2)
migrate & makemigrations 3) deleting any references to tags in my
templates4) searching these errors on stackoverflow *

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CADOCafiMBCKrFqNQdzf1teXkYO7SmjMK9kN__T3-XXdp5one%3Dw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Pony flair for upcoming PyCons/DjangoCons/events

2015-03-12 Thread Elena Williams
Heya,

As fundraising for DjangoGirls we're making available our special
djangogirls ponies (like t-shirts but better). They're pretty exclusive but
you can now get yourself one:

http://ponies.elena.net.au/

Everyone with DjangoGirls at the upcoming events and conferences will be
wearing one of these and now you can get one too. There will probably be
some extra swag thrown in (like stickers, depending on availability) and a
big pile of DjangoGirls warm-fuzzies.

If you could help out by *retweeting* the above link that would be awesome
too :) Thank you!
---
Elena :)
@elequ
austra...@djangogirls.org
https://twitter.com/djangogirlsau

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMRRKVdBJoV%2B6fE%2BcXbfh9ruL2u08we%2B-BM3tRLtOO4PZTomwg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Python 3 Usage

2014-07-07 Thread Elena Williams
Hi Richard,

Django has fully supported Python 3 for a while now, see this talk:
http://pyvideo.org/video/2242/porting-django-apps-to-python-3-0

Also IMHO it's less a matter of which users use Python 3 (I'd say it's
likely most serious Python users mix-and-match on a project-to-project
basis, depending on the age of the original code, but use Python 3 where
they can).

I'd say it's a case of which hosting servers are running Python 3 at the
time of deployment.

Often the default version of Python supported by hosts is 2.7 or even 2.6,
so it's a matter of whether the costs outweigh the benefits of installing
and maintaining your own versions of Python 3.

---
Elena :)
@elequ


On Tue, Jul 8, 2014 at 10:17 AM, Timothy W. Cook <t...@mlhim.org> wrote:

> I've been using Python 3 with Django for about 8 months.  No real
> problems.  Early on I had to patch a couple of add-ons.
>
>
>
> On Mon, Jul 7, 2014 at 9:10 PM, Richard Eng <horrido.hobb...@gmail.com>
> wrote:
>
>> I was wondering how many Django users have switched to Python 3. Are the
>> majority of users still on Python 2? I'm looking for rough
>> proportion/percentage.
>>
>> I also read that Django and Python 3 have some problems or issues. Is
>> there any truth to this?
>>
>> Thanks.
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at http://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/d2ac4e23-471a-4c11-a16d-54a11b7bef33%40googlegroups.com
>> <https://groups.google.com/d/msgid/django-users/d2ac4e23-471a-4c11-a16d-54a11b7bef33%40googlegroups.com?utm_medium=email_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
>
> 
> Timothy Cook
> LinkedIn Profile:http://www.linkedin.com/in/timothywaynecook
> MLHIM http://www.mlhim.org
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CA%2B%3DOU3Xt8gzVQSBUqnyTKm3ij%2BqbV_3YJr5x5XQ8ALrQA4g7cQ%40mail.gmail.com
> <https://groups.google.com/d/msgid/django-users/CA%2B%3DOU3Xt8gzVQSBUqnyTKm3ij%2BqbV_3YJr5x5XQ8ALrQA4g7cQ%40mail.gmail.com?utm_medium=email_source=footer>
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMRRKVcB%2BNwSUeKQ2C8MTxd16Fh8DXQGXL3fhxNhi0aVtjxbCA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Journalists in the Django community, journalism advice

2014-07-04 Thread Elena Williams
Hey everybody,

 Looking for Journalists/former-Journalists/Journalism grads in the
community for any advice they might have.

I'm giving a talk at DjangoConAU more-or-less about communicating news in
community.

Django has a proud journalistic tradition and as such it seems remiss to
*not* at least ask around amongst the actual news-communications trained
people in the community for any advice or pointers they may have for this
presentation (I need all the help I can get).

I know our erstwhile-BDFLs were both journalism graduates, but:

 * Does anyone know of any other journalist/news types in our community I
should contact?

 * Anyone have any notable news/journalism advice I should be passing along?

Or, just contact me if you think there's anything I should mention, or have
any friendly advice, thank you!
---
Elena Williams :)
@elequ

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAMRRKVd3GxcbgRLpzEhmwLQwD6f%3D_Mvt8hAiYbN1Gk91JCZTSg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How do I create a script to fill in django admin login form and submit?

2013-08-14 Thread Elena Williams
Have you explored the packages "selenium" or "sikuli" these are both great
fun for front-end testing.

You could intercept the RFID tag using python and feed it through one of
the above tools, or something like this perhaps (if I've understood what
you're trying to do correctly).

Elena :)


On 14 August 2013 13:23, <7equivale...@gmail.com> wrote:

> Here is what I'm doing. I have written a script the runs and monitors a
> serial connection for incoming data. The data comes from an RFID tag
> reader. I have that working. What I'd like to do is use this rfid tag
> number to fill in the password feild and  submit the django Admin login form.
> I'm still a novice and Any advise is appreciated... Thanks!
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Happy new year

2013-01-01 Thread Elena Williams
Happy New Year from to all the Djangonauts from stonking hot Australia!

I hope everyone's Django projects are awesome and plentiful this year!

Go you smart, creative Django folk!
---
Elena :)
@elequ

On Wed, Jan 2, 2013 at 4:30 AM, Sultan Imanhodjaev <
sultan.imanhodj...@gmail.com> wrote:

> Жаңы жылыңыздар менен!
>
>
>
> Sultan, Bishkek Kyrgyzstan.
>
>
> On Tue, Jan 1, 2013 at 10:33 PM, Mark Phillips <m...@phillipsmarketing.biz
> > wrote:
>
>> Happy New Year from Arizona!
>>
>> Mark
>> On Jan 1, 2013 9:25 AM, "Amirouche" <amirouche.boube...@gmail.com> wrote:
>>
>>> Bonne année, paix et prosperités!
>>>
>>> Amirouche from Paris, FRANCE.
>>>
>>> On Monday, December 31, 2012 10:42:13 PM UTC+1, cingusoft wrote:
>>>>
>>>> Happy new year from spain to all django lovers.
>>>> I wish you a new year with tons of django projects.
>>>>
>>>> Cheers
>>>> Cingusoft
>>>> BlackBerry de movistar, allí donde estés está tu oficin@
>>>
>>>  --
>>> 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.google.com/d/msg/django-users/-/He2t7vHzrBAJ.
>>> To post to this group, send email to django-users@googlegroups.com.
>>> To unsubscribe from this group, send email to
>>> django-users+unsubscr...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/django-users?hl=en.
>>>
>>  --
>> 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, send email to
>> django-users+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/django-users?hl=en.
>>
>
>
>
> --
> Kind regards,
> Sultan Imanhodjaev
> +996 559 06 76 06
> PGP 0x4E357296
> http://imanhodjaev.com
>
> --
> 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, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Reason for not allowing spaces in usernames?

2012-11-18 Thread Elena Williams
Apparently some weirdness can be caused by having email addresses as
usernames in django, though I'm not sure specifically what this is.

Does anyone know these cases?

---
Elena :)
@elequ



On Mon, Nov 19, 2012 at 4:05 PM, Cal Leeming [Simplicity Media Ltd] <
cal.leem...@simplicitymedialtd.co.uk> wrote:

> (imo) Allowing spaces in username just isn't a very sane approach.
>
> Rather than telling the user to choose a username, why not make them login
> with their email address instead? Users are less likely to forget their
> email address, and if anything, it would be less error prone than a
> username would, especially one with spaces.
>
> By all means, you can allow users to have spaces in their alias / nickname
> field, but allowing them to login with it might not be the best approach.
>
> Hope this helps!
>
> Cal
>
> On Sat, Nov 17, 2012 at 8:14 AM, Paul von Hoesslin <
> paulvonhoess...@gmail.com> wrote:
>
>> I'm puzzled with this too. Did anyone manage to find a solution to
>> resolving spaces in usernames.
>>
>> Generally a user, these days logs in with their email - that's
>> predominately how I've setup all my django projects. People don't remember
>> usernames. It is legacy, facebook connects with emails, so does gmail and
>> the rest of the world. Username really has fallen back to a NickName /
>> Alternative / Alias kind of field. You'd use it if you knew that in your
>> application people wouldn't want their real, full names to be displayed.
>>
>>
>> On Friday, June 12, 2009 4:08:12 PM UTC+2, Wiiboy wrote:
>>>
>>>
>>>
>>> On Jun 12, 6:55 am, Marco Louro <mlo...@gmail.com> wrote:
>>> > 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.
>>>
>>>  Why not?
>>
>>  --
>> 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.google.com/d/msg/django-users/-/UGdOmEepavIJ.
>> To post to this group, send email to django-users@googlegroups.com.
>> To unsubscribe from this group, send email to
>> django-users+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/django-users?hl=en.
>>
>
>  --
> 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, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: tutorial first step. -ImportError: No module named django.core-

2012-11-08 Thread Elena Williams
Francesco and Daniel,

This is an interesting problem with the tutorial! We will have to make sure
that it's changed -- obviously the tutorial needs to be clearer!

Any suggestions you guys have about how/where we could insert some
information that could make this clearer *please* point out where it'd be
helpful or better yet write some words (community for-the-win! :)

Daniel: in response to what you were saying about the location of
`django-admin.py` being a hassle I remember when I was learning be
concerned by this also! But turns out that nowadays actually I rarely use
`django-admin.py` but usually in my set-up keep a copy of it at
`~/code/bin/` with a bunch of other useful bits-and-pieces (though this
approach is a bit out-dated with virtualenv). Besides starting a new whole
project is a pretty big deal (compared to most dev work) and personally I
think needing to find django-admin.py for it makes it seem as special as it
is.

---
Elena :)
@elequ


On Thu, Nov 8, 2012 at 7:29 PM, Francescos <serafini.france...@gmail.com>wrote:

> Good good!
> So, this means I was executing the wrong django-admin.py file.
> Daniel, I'm curious about your question, too. Because I though that
> activating virtualenv the path is automatically set to the specified
> environment and then no need to include the right django-admin.py file into
> some environment variable...
> Anyway, maybe a solution for you is to put, possibly at the beginning,
> your django-admin.py path into the PATH variable.
> Elena we need you... :D
>
> Francesco
>
> On Thursday, November 8, 2012 3:26:36 AM UTC, Daniel wrote:
>>
>> Hi Elena, I actually had the exact same problem Francesco was having.  I
>> wasn't able to start a project, and then I tried your question.  The cmd
>> line went something like this:
>>
>> (env) path/to/directory/python env/Scripts/django-admin.py startproject
>> newproject
>>
>> It worked!  While I'm happy with the result, I'd like to keep projects in
>> the root folder, and typing out the path to django-admin.py every time
>> seems like quite a hassle.  Is there a way to point to the file without
>> having to specify its location?  All the tutorials and such that I've seen
>> online simply use the django-admin.py startproject (name) convention and it
>> works fine.
>>
>> Dan
>>
>> On Monday, November 5, 2012 6:54:18 AM UTC-6, elena wrote:
>>>
>>> Hi Francesco,
>>>
>>> What happens when you try:
>>>
>>> $ cd C:\Python27\fra_env\
>>>
>>> (or whatever the equivalent of this might be in the shell you are using)
>>>
>>> $ python Scripts\django-admin.py startproject mysite
>>>
>>> Regards,
>>> Elena :)
>>>
>>>
>>>
>>> On Mon, Nov 5, 2012 at 1:19 AM, Francescos <serafini@gmail.com>wrote:
>>>
>>>> Hi Elena,
>>>>
>>>> Thanks for replying.
>>>> I guess the PATH var is well set. In fact, if I hit python into
>>>> cmd.exe and then import django everything work (I can print the django
>>>> version, as well).
>>>> So, Django is installed and reachable apparently. At this point I guess
>>>> there is a problem in looking for the modules..
>>>> I also guess is important to consider that I am using 
>>>> virtualenv<http://www.virtualenv.org/en/latest/> that,
>>>> once activated, it adds to the PATH this: 
>>>> C:\Python27\fran_env\Scriptswhere is located django-admin.py. This file is 
>>>> also located here:
>>>> C:\Python27\fra_env\Lib\site-packages\django\bin
>>>>
>>>> Francesco
>>>>
>>>> On Sunday, November 4, 2012 2:07:53 AM UTC, elena wrote:
>>>>
>>>>> Hi Francesco,
>>>>>
>>>>> What you're seeing is the most basic django/python error. It means
>>>>> that your python can't find django from your current path.
>>>>>
>>>>> You should start by checking for the simple things.
>>>>>
>>>>> What happens when you try putting the following in your terminal?:
>>>>> $ python
>>>>>
>>>>> and then:
>>>>> >>> import django
>>>>>
>>>>> Also where is your django-admin.py file located?
>>>>>
>>>>> Elena :)
>>>>>
>>>>>
>>>>> ---
>>>>> Elena :)
>>>>> @elequ
>>>>> 04022 90172
>>>>>
>>>>>
>>>>>
>>>>> On Sun

Re: configure url

2012-11-06 Thread Elena Williams
Hi Luca,

Is the answer you're looking for something like this?:

(r'^scarico/(?P\w+)/(?P\w+)/(?P\w+)/(?P\w+)/$
','prova.views.scarico')


Where \w+ is regex for anything except white-space ()
(more options: http://docs.python.org/2/library/re.html )

If you're using functional views the def would look as follows:

def scarico(request, var1, var2, var3, myvar4):
...
return HttpResponse(...)

or alternatively if the variables are optional:

def scarico(request, var1=None, var2=None, var3=None, myvar4=None):
...


Regards,
Elena :)



On Wed, Nov 7, 2012 at 1:36 AM, luca72 <lucabe...@libero.it> wrote:

> Hello
> I have to take a page with 4 variable that can be string number or mixed
> including point how i have to configure the url:
>
> (r'^scarico/./././.','prova.views.scarico')
>
> How i have to do it?
>
> Thanks
>
> Luca
>
>  --
> 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.google.com/d/msg/django-users/-/NSXBecUi1m4J.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: tutorial first step. -ImportError: No module named django.core-

2012-11-05 Thread Elena Williams
Hi Francesco,

What happens when you try:

$ cd C:\Python27\fra_env\

(or whatever the equivalent of this might be in the shell you are using)

$ python Scripts\django-admin.py startproject mysite

Regards,
Elena :)



On Mon, Nov 5, 2012 at 1:19 AM, Francescos <serafini.france...@gmail.com>wrote:

> Hi Elena,
>
> Thanks for replying.
> I guess the PATH var is well set. In fact, if I hit python into cmd.exe
> and then import django everything work (I can print the django version,
> as well).
> So, Django is installed and reachable apparently. At this point I guess
> there is a problem in looking for the modules..
> I also guess is important to consider that I am using 
> virtualenv<http://www.virtualenv.org/en/latest/> that,
> once activated, it adds to the PATH this: C:\Python27\fran_env\Scriptswhere 
> is located django-admin.py. This file is also located here:
> C:\Python27\fra_env\Lib\**site-packages\django\bin
>
> Francesco
>
> On Sunday, November 4, 2012 2:07:53 AM UTC, elena wrote:
>
>> Hi Francesco,
>>
>> What you're seeing is the most basic django/python error. It means that
>> your python can't find django from your current path.
>>
>> You should start by checking for the simple things.
>>
>> What happens when you try putting the following in your terminal?:
>> $ python
>>
>> and then:
>> >>> import django
>>
>> Also where is your django-admin.py file located?
>>
>> Elena :)
>>
>>
>> ---
>> Elena :)
>> @elequ
>> 04022 90172
>>
>>
>>
>> On Sun, Nov 4, 2012 at 6:24 AM, Francescos <serafini@gmail.com>wrote:
>>
>>>  Hello everyone,
>>> Following the django tut I've sat up all the installation and reached
>>> the step where I had to run the command: django-admin.py startproject
>>> mysite
>>> result: I receive the error specified in the subject.
>>> I installed virtualenv (as said 
>>> here<http://www.pip-installer.org/en/latest/installing.html#installation-instructions>)
>>> and activate it before running the command django-admin.py startproject
>>> mysite.
>>> Any suggestion for this problem? Thanks everyone.
>>> Configuration:
>>> - Windows 7 & cmd.exe
>>> - Python2.7
>>> - virtualenviroment at: C:\Python27\fra_env\
>>> - PATH contains: C:\Python27\fra_env\**Scripts
>>> - django-admin.py is in C:\Python27\fra_env\Scripts AND
>>> C:\Python27\fra_env\Lib\**site-packages\django\bin
>>>
>>> I hope someone can help me!
>>> Francesco
>>>
>>> --
>>> 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.google.com/d/**
>>> msg/django-users/-/v_**l9HV306cIJ<https://groups.google.com/d/msg/django-users/-/v_l9HV306cIJ>
>>> .
>>> To post to this group, send email to django...@googlegroups.com.
>>> To unsubscribe from this group, send email to django-users...@**
>>> googlegroups.com.
>>>
>>> For more options, visit this group at http://groups.google.com/**
>>> group/django-users?hl=en<http://groups.google.com/group/django-users?hl=en>
>>> .
>>>
>>
>>  --
> 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.google.com/d/msg/django-users/-/kmyIAnk7cYcJ.
>
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Location of non-app-specific static files?

2012-11-03 Thread Elena Williams
Hi Ryan,

I'm not sure if it helps but not long ago I found this by Simon Willison on
Quora:
http://www.quora.com/Django/How-do-you-organize-the-code-in-your-Django-project

Cheers,
Elena :)

---
Elena :)
@elequ
04022 90172



On Sun, Nov 4, 2012 at 10:23 AM, Ryan <ryan.osborn...@gmail.com> wrote:

> Hi,
>
> I have been wondering where people put their non-app-specific static files
> in their django projects?  For example, the base css file that applies to
> all pages across the project or perhaps the jquery file?
>
> Currently I have the following structure:
>
> .
> ├── app
> │   ├── __init__.py
> │   ├── models.py
> │   ├── static
> │   │   └── app
> │   │   ├── css
> │   │   ├── img
> │   │   └── js
> │   ├── templates
> │   │   └── app
> │   ├── tests.py
> │   └── views.py
> ├── manage.py
> └── mysite
> ├── __init__.py
> ├── settings.py
> ├── static
> ├── templates
> ├── urls.py
> └── wsgi.py
>
> My STATIC_ROOT setting points to the ./mysite/static directory as this is
> where I would like collectstatic to dump all the static files for
> deployment, however this is also the obvious place (for me anyway) to place
> non-app-specific static files as they apply to the project as a whole like
> the templates directory at this level.
>
> Does any one have any input on this?
>
> Thanks,
>
> Ryan
>
> --
> 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.google.com/d/msg/django-users/-/4H39KqmnTugJ.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: tutorial first step. -ImportError: No module named django.core-

2012-11-03 Thread Elena Williams
Hi Francesco,

What you're seeing is the most basic django/python error. It means that
your python can't find django from your current path.

You should start by checking for the simple things.

What happens when you try putting the following in your terminal?:
$ python

and then:
>>> import django

Also where is your django-admin.py file located?

Elena :)


---
Elena :)
@elequ
04022 90172



On Sun, Nov 4, 2012 at 6:24 AM, Francescos <serafini.france...@gmail.com>wrote:

> Hello everyone,
> Following the django tut I've sat up all the installation and reached the
> step where I had to run the command: django-admin.py startproject mysite
> result: I receive the error specified in the subject.
> I installed virtualenv (as said 
> here<http://www.pip-installer.org/en/latest/installing.html#installation-instructions>)
> and activate it before running the command django-admin.py startproject
> mysite.
> Any suggestion for this problem? Thanks everyone.
> Configuration:
> - Windows 7 & cmd.exe
> - Python2.7
> - virtualenviroment at: C:\Python27\fra_env\
> - PATH contains: C:\Python27\fra_env\Scripts
> - django-admin.py is in C:\Python27\fra_env\Scripts AND
> C:\Python27\fra_env\Lib\site-packages\django\bin
>
> I hope someone can help me!
> Francesco
>
> --
> 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.google.com/d/msg/django-users/-/v_l9HV306cIJ.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Django Development Model

2012-11-02 Thread Elena Williams
Smriti,

If you're really interested from the "horse's mouth" -- I'd suggest
googling DjangoCon and DjangoCon EU recordings (they are often on
blip.tvbut the most recent ones were put up by
youtube.com/jessenoller.

Most DjangoCon have a core-team sit-down and/or fireside chat with BDFL/s
and this is really informative on how the Django internal design/decision
making processes really work.

Also Russell Keith-Magee's "No, Bad Pony" talk which he re-gave recently at
PyCon AU, but had previously given at DjangoCon would probably answer some
of your questions also.

Regards.



---
Elena :)
@elequ
04022 90172



On Sat, Nov 3, 2012 at 10:58 AM, Smriti Patodi <smritipat...@gmail.com>wrote:

> Hello Dennis,
>
> Yes you are right..I am looking for how the Django effort itself is
> managed by the developers and the Django community in general?
>
> I want to get more information on:
>
> - how Django team gathers requirements for each release
>
> - how does the planning go on for each enhancement/release
>
> - how the team members communicate about their progress(are their any
> formal checkpoints within a release?)
>
> -what is the process of code review and approval, who all are involved
>
> - how about the test planning, are the test plans developed prior to the
> implementation or are they done simultaneously
>
> - and about the estimate of time and resource for the release, do you use
> any estimation techniques or how is it done
> If you could some insight on these area or you could let me know of any
> documents/websites where I can find this information.
>
> Thanks
> Smriti
> On Sunday, October 28, 2012 8:26:33 PM UTC-7, Dennis Lee Bieber wrote:
>>
>> On Sun, 28 Oct 2012 13:39:52 -0700 (PDT), Smriti Patodi
>> <smriti...@gmail.com> declaimed the following in
>> gmane.comp.python.django.user:
>>
>> > I am a MSIS student at Santa Clara University, CA. My team has chosen
>> > Django to work on for our Software Project Management course.
>>
>> Your inquiry is slightly ambiguous.
>>
>> Are you intending to /implement/ some "software project
>> management"
>> application /using/ Django?
>>
>> > I was wondering if there is some place where I can find documentation
>> > related to Django's Software Development process/model.
>>
>> Or are you, instead, asking how the Django effort itself is
>> managed
>> by the developers? Which is how I interpret the above statement.
>>
>> {I believe the other two responses currently extant interpreted
>> your
>> request as the former -- you wish to implement a project management
>> application using Django. [I'd also hope that a candidate in a Master's
>> degree program in IS would have encountered relational databases by now
>> ]}
>> --
>> Wulfraed Dennis Lee Bieber AF6VN
>> wlf...@ix.netcom.com
>> HTTP://wlfraed.home.netcom.**com/
>>
>>  --
> 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.google.com/d/msg/django-users/-/9rVD2a5r74QJ.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: no Polls in the admin page

2012-11-02 Thread Elena Williams
Actually the minimum requirement for the application to appear in admin is
this (here in docs:
https://docs.djangoproject.com/en/dev/intro/tutorial02/#make-the-poll-app-modifiable-in-the-admin):


admin.py:

from django.contrib import admin
from mysite.polls.models import Poll, Choice

# `register()` optionally takes a second argument of a `admin.ModelAdmin`
object
admin.site.register(Poll)
admin.site.register(Choice)


Though as Sandeep put in this code --  in this case you probably would like
the `polls.Choice` inline, which would look like this:

admin.py:

from django.contrib import admin
from mysite.polls.models import Poll, Choice

class ChoiceInline(admin.TabularInline):
model = Choice
extra = 1

class PollAdmin(admin.ModelAdmin):
inlines = [ChoiceInline]

admin.site.register(Poll, PollAdmin)



---
Elena :)
@elequ
04022 90172



On Fri, Nov 2, 2012 at 2:42 PM, Sandeep kaur <mkaurkha...@gmail.com> wrote:

> On Fri, Nov 2, 2012 at 12:29 AM, Mihail Mihalache
> <mihalache_mih...@yahoo.com> wrote:
> > I have followed the django tutorial up to part 2 -
> > https://docs.djangoproject.com/en/1.4/intro/tutorial02/ .
> > Everything worked fine, until I couldn't see the Polls entry on the admin
> > page. I have checked that I have done everything mentioned in the
> tutorial.
> > I get no error whatsoever. I have no idea what's wrong.
> > There is a polls entry INSTALLED_APPS.
> >
> Your admin.py file should have this code :
> -
> from mysite.polls.models import Poll
> from django.contrib import admin
> from mysite.polls.models import Choice
>
>
> class ChoiceInline(admin.TabularInline):
> model = Choice
> extra = 3
>
> class PollAdmin(admin.ModelAdmin):
> fieldsets = [
> (None,   {'fields': ['question']}),
> ('Date information', {'fields': ['pub_date']}),
> ]
> inlines = [ChoiceInline]
> list_display = ('question', 'pub_date')
> list_filter = ['pub_date']
> search_fields = ['question']
>
> admin.site.register(Poll, PollAdmin)
>
> -
>
> --
> Sandeep Kaur
> E-Mail: mkaurkha...@gmail.com
> Blog: sandymadaan.wordpress.com
>
> --
> 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, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Easy way to make all form fields read only?

2012-10-31 Thread Elena Williams
I was also going to suggest using crispy forms -- having used it on a
recent project I'd strongly recommend it (it's great when it's plugged in
to  existing stylings such as: uni-form or bootstrap).

I've used it with ModelForm using Layout() and Field() and it works a treat.

---
Elena :)
@elequ
04022 90172



On Thu, Nov 1, 2012 at 7:29 AM, Paul <pee...@gmail.com> wrote:

> I used to invest something similar; i wanted to to built a read view next
> to an update view that looks identical except for that read is obviously
> read-only. I used crispy-forms to do just that; recently an UneditableField
> (Layout) was added next to Field.
> You do however either need to enumerate the model fields in a layout
> Paul Bormans
>
>  --
> 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.google.com/d/msg/django-users/-/5av7W0YQoS8J.
>
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/django-users?hl=en.
>

-- 
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, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.



Re: Easy way to make all form fields read only?

2012-10-30 Thread elena
Hiya Matt,

As you already noticed yourself there are lots of different possible 
approaches to what you're talking about.

But it depends on where/how the form is getting to the page.

How are you rendering the form? Are you using `forms.Form`?

Do you mean "user's credentials" from `django.contrib.auth`?

Regards,
Elena


On Tuesday, October 30, 2012 11:04:55 AM UTC+11, Matt Woodward wrote:
>
> Semi-new to Django and working on my first "real" app, and I have a need 
> based on the user's credentials to display forms as either editable or 
> read-only. (Note this doesn't have anything to do with the Django admin in 
> case that has any bearing on the discussion.)
>
> Is there some fancy whiz-bang filter or middleware-type doo-dad (you can 
> tell I'm still learning all the terminology) that would easily make all 
> form fields read only?
>
> I thought about using javascript (this is an internal app so we can 
> mandate javascript be enabled) but before I went that route figured I'd ask 
> if anyone has had to do this and how they approached it.
>
> Personally I think it's weird to show someone a form they can't edit as 
> opposed to just dumping them to a static display page, but wasn't my call.
>
> Thanks!
>
> -- 
> Matthew Woodward
> ma...@mattwoodward.com 
> http://blog.mattwoodward.com
> identi.ca / Twitter: @mpwoodward
>
> Please do not send me proprietary file formats such as Word, PowerPoint, 
> etc. as attachments.
> http://www.gnu.org/philosophy/no-word-attachments.html
>  

-- 
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.google.com/d/msg/django-users/-/wliSPC0e0Z0J.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.