Am 05.02.2013 um 22:16 schrieb Conor Pollock:
> I'm currently trying to figure this out as well... I can pass a page query
> in the url and everything works as expected, but I can't figure out how to
> render the pagination controls in my template file.
>
> Did you ever get this to work?
No,
1) please provide your model Poll
2) are you run syncdb ?
Many thanks,
Serge
+380 636150445
skype: skhohlov
2013/2/6 Avnesh Shakya :
>
> Here i want to explore database API but it's generating error..
> C:\mysite>python manage.py shell
> Python 2.7.3 (default, Apr 10 2012, 23:31:26) [M
thanks. i m adding my polls file...
On Wed, Feb 6, 2013 at 2:20 PM, Sergiy Khohlov wrote:
> 1) please provide your model Poll
> 2) are you run syncdb ?
> Many thanks,
>
> Serge
>
>
> +380 636150445
> skype: skhohlov
>
>
> 2013/2/6 Avnesh Shakya :
> >
> > Here i want to explore database API b
thanks.. i have added my polls.models file
On Wed, Feb 6, 2013 at 2:20 PM, Sergiy Khohlov wrote:
> 1) please provide your model Poll
> 2) are you run syncdb ?
> Many thanks,
>
> Serge
>
>
> +380 636150445
> skype: skhohlov
>
>
> 2013/2/6 Avnesh Shakya :
> >
> > Here i want to explore database AP
Now look your Poll model and try to find field "pub_date" there...
:)
6.2.2013 11:03, Avnesh Shakya kirjoitti:
thanks.. i have added my polls.models file
On Wed, Feb 6, 2013 at 2:20 PM, Sergiy Khohlov mailto:skhoh...@gmail.com>> wrote:
1) please provide your model Poll
2) are you run
Hi everyone,
We've been having this miscellaneous error with the default test runner in
Django. We had a forms.py that was something like this:
class SomeForm(forms.ModelForm):
some_field =
some_custom_fields.SomeCustomField(choices=get_some_queryset_and_evaluate_it())
# Actually, we're
thanks alot... but i have set it but again it's showing new error..
like...
C:\mysite>python manage.py shell
Python 2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)]
on win32
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> fr
Hi Timster,
thanks for pointing to the right method. Now it works like a charm.
Cheers,
Michele
On Mon, Feb 4, 2013 at 3:56 PM, Timster wrote:
> By setting "initial" on a field, you are not changing the list of
> available options. Setting the initial like this determines which of all
> the l
Django doesn't touch tables that already exists in database.
So if you had model Poll run syncdb and then change, add or remove
fields Django doesn't modify underlying table.
There is few options that resolves your problem:
- Manually migrate your database using plain SQL.
- Recreate table or
Hi,
i have this code:
#Model
class Client(models.Model):
name= models.CharField(max_length=25)
...
class Docs(models.Model):
name= models.CharField(max_length=25)
...
client = models.ForeignKey(Client)
#Admin
class Detail_Doc(admin.StackedInline):
model = Docs
class De
On Wed, Feb 6, 2013 at 8:48 AM, Daniel Roseman wrote:
> On Tuesday, 5 February 2013 22:39:30 UTC-8, vijay shanker wrote:
>
>> Hi
>> I have two models, a Customer model and a WishListItem model (which
>> stores products). I have option of either having a ManyToManyField in
>> Customer to WishListIt
I have checked many time, even i have deleted my project n i have created
new project again and create new model but error is occurred again n
again.. i m beginner so plz help me
C:\mysite>python manage.py shell
Python 2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)]
on w
Have you executed python manage.py syncdb?
Thomas
On Wed, Feb 6, 2013 at 2:22 PM, Avnesh Shakya wrote:
>
> I have checked many time, even i have deleted my project n i have created
> new project again and create new model but error is occurred again n again..
> i m beginner so plz help me
>
Hey guys,
I need a little bit help with a custom manage.py command called *test*
I am using it in a virtualenv on a shell script *script.sh*,
The script.sh works well out of the cron and Wihiout activate the
virtualenv also works well.
but if the script is on the crontab give a *Unknown com
ya i have executed python manage.py syncdb...but still it's giving
error...
On Wed, Feb 6, 2013 at 7:01 PM, Thomas Weholt wrote:
> Have you executed python manage.py syncdb?
>
> Thomas
>
> On Wed, Feb 6, 2013 at 2:22 PM, Avnesh Shakya
> wrote:
> >
> > I have checked many time, even i hav
I see more than one problem with your code. StackedInline is only used for
models that have a one to many relationship and not the otherway around, in
other words, you can have Docs stacked in line on the Client page but not
the other way around, because only ONE client owns the document. You wi
Hi all,
I am working on implementing the US PhoneNumberField and currently as long
as I pass in the expected phone number length (10 digits) the number is
formatting numbers just as I expect. However, if I dont put enough numbers
in the form field, I get a Key Error.
I can't for the life of
Do you see polls_poll table in your database? How does your db settings
looks?
On Wednesday, February 6, 2013 9:02:53 AM UTC-5, Avnesh Shakya wrote:
>
> ya i have executed python manage.py syncdb...but still it's giving
> error...
>
> On Wed, Feb 6, 2013 at 7:01 PM, Thomas Weholt
>
> >
Depending on your project structure You may want to try adding the project name
before polls_poll such as. Project_name_polls_poll.
I hope that helps.
Parker
On Feb 6, 2013, at 5:22 AM, Avnesh Shakya wrote:
>
> I have checked many time, even i have deleted my project n i have created new
>
I'm not sure this is the best way to do it, but for what I think is a
similar situation, I created a template tag and a model instance method.
The template tag asks the model instance method whether the user has
permission.
Here's the template tag:
https://github.com/bhaugen/localecon/blob/mast
Does manage.py dbshell shows the tables?
are you sure syncdb worked? what output did it give?
settings.py have the database configured properly?
sorry, I'm a django newb too.
On 06/02/13 15:42, Black9design.com wrote:
Depending on your project structure You may want to try adding the
project na
On Wed, 6 Feb 2013 05:39:55 -0800 (PST)
Jesús Lucas Flores wrote:
> Hey guys,
>
> I need a little bit help with a custom manage.py command called *test*
>
>
> I am using it in a virtualenv on a shell script *script.sh*,
>
> The script.sh works well out of the cron and Wihiout activate the
I think this has to do with not mentioning the proper settings file.
manage.py goes to the settings and checks all the installed apps for any
custom commands, but if you haven't set proper settings file then it would
not recognize those commands. You can either set the environment variable
to D
Hello,
What is the best way to track down these types of errors?
in ntw.urls I have: (r'^checkout/', include('checkout.urls')),
in checkout I have:
urlpatterns = patterns('checkout.views',
#(r'^$', 'show_checkout', {'template_name': 'checkout/checkout.html' },
'checkout'),
(r'^receipt/$
Hi folks,
We've scheduled maintenance operations on djangoproject.com tomorrow, starting
at 09:00 UTC.
The website and the docs may be temporarily unavailable.
Please use the mirror of the docs at Read The Docs in the meantime:
http://django.readthedocs.org/
Thanks,
--
Aymeric.
--
You r
On Wed, 2013-02-06 at 10:31 -0800, frocco wrote:
> Exception Location:C:\ndsutil\Menus\CTD-NDSUser\PycharmProjects\ntw
> \checkout\views.py in , line 5
Django gives you the line in the file where the error occurs so you
don't need to track it down ;-)
It's probably failing when you try to import s
Line 22 does not make any sense to me as to why it is failing.
If I remove receipt, it runs fine
On Wednesday, February 6, 2013 1:31:59 PM UTC-5, frocco wrote:
>
> Hello,
>
> What is the best way to track down these types of errors?
>
> in ntw.urls I have: (r'^checkout/', include('checkout.urls'))
On Wed, 2013-02-06 at 11:49 -0800, frocco wrote:
> Line 22 does not make any sense to me as to why it is failing.
> If I remove receipt, it runs fine
It can be surprising sometimes what code can cause other code to get
imported and run. My guess is, in trying to find your url route there,
Django l
Hi fellow Django devs,
I have been going around and around trying to figure this out for 2 days,
without success. I am trying to serve two Django sites from one webserver using
Apache's virtual hosts. The first works, the second doesn't. (Note that I have
been happily serving Django content via
Why doesn't the form_valid() (and for that matter the form_invalid())
method in the FormView generic class based view take a request argument?
I've found that if you have a form which requires you to override the
form_valid() method because you need to do custom logic before you save
the model
Hi,
is it a smell of next RC in the air? :)
regards,
Sergei
On Wednesday, February 6, 2013 8:43:38 PM UTC+2, Aymeric Augustin wrote:
>
> Hi folks,
>
> We've scheduled maintenance operations on djangoproject.com tomorrow,
> starting at 09:00 UTC.
>
> The website and the docs may be temporarily
On 7/02/2013 12:39am, Jesús Lucas Flores wrote:
Hey guys,
I need a little bit help with a custom manage.py command called *test*
There is already a manage.py subcommand called test. Might be an idea to
rename your custom command and try again.
Just a thought ...
I am using it in a vi
Hi guys,
Thanks everybody for all the answers, really helped me.
I *SOLVED the problem.*
The problem was I was calling custom enviroment variables into my
settings.py . So that enviroments variables exists on bash (thanks to
.bashrc) but not in cron ( thanks Branko Majic ) so manage.py failed
Maintaining that many static files has really got to suck, this is where
Django is going to help you a lot. First step for you because you are just
starting out it to play around with Django, build some base templates and
try extending them until you get your templates looking how you want. The
On Wednesday, February 6, 2013 3:09:39 PM UTC-5, Some Developer wrote:
>
> Why doesn't the form_valid() (and for that matter the form_invalid())
> method in the FormView generic class based view take a request argument?
>
> I've found that if you have a form which requires you to override the
I've got SaltStack setup to deploy Ubuntu+Nginx+uWSGI+Postgresql+memcache
pretty easily. Pulls Django projects from Git, pip installs from
requirements file.
It is a lot less complicated than Puppet/Chef in my opinion.
Just my $.03 cents
On Friday, February 1, 2013 4:28:45 PM UTC-8, Marc A
I found the answer.
in my app directory called checkout, I also have a checkout.py file.
from checkout.models import Order in views.py had to be changed to from
models import Order
On Wednesday, February 6, 2013 3:02:57 PM UTC-5, Brad Pitcher wrote:
>
> On Wed, 2013-02-06 at 11:49 -0800, frocco w
I am trying to access the field(s) of a Child table while still inside
the save method of the Parent table.
Assuming that the many-to-many field in the Parent table is called
`m2m_field`, and the field I need to access in the Child table is
called `child_field`, what I have tried is this:
def sav
That's something I had in mind also.
And I think that is quite a best thing to do.
6.2.2013 18:09, bobhaugen kirjoitti:
I'm not sure this is the best way to do it, but for what I think is a
similar situation, I created a template tag and a model instance method.
The template tag asks the model
On 7/02/2013 5:04pm, Derek wrote:
I am trying to access the field(s) of a Child table while still inside
the save method of the Parent table.
Assuming that the many-to-many field in the Parent table is called
`m2m_field`, and the field I need to access in the Child table is
called `child_field`,
40 matches
Mail list logo