Hello,
I believe its a simple typo!
authenticate(user=usuario, password=clave)
should be
authenticate(username=usuario, password=clave)
Regards
On Sun, Aug 19, 2012 at 3:35 PM, Jorge Garcia wrote:
> Hi there. Im doing my first login form for an existing Django application.
> The thing is tha
Hello,
Could you post the VirtualHost configuration for Apache?
That would greatly help us help you.
Regards
On Mon, Aug 20, 2012 at 12:30 AM, Seyfullah Tıkıç wrote:
> Hello,
>
> I read the article below.
> https://docs.djangoproject.com/en/1.3/howto/deployment/modwsgi/
>
> But still http://lo
Hello,
I have a model that has a foreign key field that I want to use in a form as
a select box.
That particular field at times appears multiple times in the database. How
do I make it
only have distinct values?
This is a snippet, drop down will have repeated values if same color is
entered:
cla
0, 2012 11:30:49 AM UTC+2, stikic wrote:
>
>> httpd.conf file is in the attachment.
>>
>> 2012/8/20, Joseph Mutumi :
>> > Hello,
>> >
>> > Could you post the VirtualHost configuration for Apache?
>> > That would greatly help us help you.
>&
@Melvyn Thank you. It actually worked out as you said. It needed a redesign.
On Wed, Aug 22, 2012 at 1:44 PM, Sithembewena Lloyd Dube
wrote:
> @Melvyn, thanks - that makes sense.
>
>
> On Wed, Aug 22, 2012 at 3:18 AM, Melvyn Sopacua wrote:
>
>> On 22-8-2012 3:04, Sithembewena Lloyd Dube wrote:
>>
I'm not sure but you can look at the generated query and post it to the
relevant database mailing list?
Go in through: manage.py shell then follow instructions in FAQ
https://docs.djangoproject.com/en/dev/faq/models/#how-can-i-see-the-raw-sql-queries-django-is-running
On Mon, Aug 20, 2012 at 6:0
Disclaimer - I have never done this before!
>From what I see I reckon you will need to create both a custom field and a
custom widget!
I think so because if you have TextInputs validation may fail on the
ModelMultipleChoiceField?
I would think you need to override the methods: __init__, clean, to
Hello,
If A is a model with ForeignKey relationships to B. What would be the best
way of rendering two
selectboxes, A and B. The values of B are the values filtered through using
the relationship with
the selected value of A via an AJAX call.
I need to get these values from the DB as well as have
Thank you for the help!
On 8/27/12, Jani Tiainen wrote:
> 26.8.2012 21:54, Joseph Mutumi kirjoitti:
>> Hello,
>>
>> If A is a model with ForeignKey relationships to B. What would be the
>> best way of rendering two
>> selectboxes, A and B. The values of B are the
Hi, Django isn't responsible for serving any kind of static files in
production.
It is not a web server ! You need to configure the web server you are using
to serve the files in that folder.
The documentation has a good example conf for Apache:
https://docs.djangoproject.com/en/1.4/howto/deployme
I'm assuming you are using the forms.ModelForm for your model? Say
LicenceForm?
class LicenseForm(forms.ModelForm):
class Meta:
model = License
According to the doc you have to pass all relevant QueryDicts to the form
__init__
when you are creating a bound instance. In a nutshell make
Hi,
Let me give you a code sample that would be hopefully a push in the right
direction.
Simply follow these steps:
1. Create your model. Its the code interface to your data source
(database)
2. Create your form. Forms are used for processing input data
(validation, error reporting et
I believe default permissions created are: add_*, change_* and delete_*.
And the format for a permission would be something like: *app_name*.add_*
model_name*
So what happens when you try:
user.has_perm('structures.add_post')
user.has_perm('structures.change_post')
If you are registering your ow
I think to escape a % use %%
On Sun, Dec 2, 2012 at 1:16 PM, Martin Svoboda wrote:
> Hi,
> I want use postgresql pg_trgm module in django. pg_trgm defines special
> operator percent sign. How should I escape it in django query extra method?
>
> # Pure SQL
> SELECT content, similarity(content, 'te
Sorry I hadn't seen your comment, have you tried %%% ?
On Mon, Dec 3, 2012 at 7:28 AM, Joseph Mutumi wrote:
> I think to escape a % use %%
>
>
> On Sun, Dec 2, 2012 at 1:16 PM, Martin Svoboda
> wrote:
>
>> Hi,
>> I want use postgresql pg_trgm module
Hello,
I think you should also check the 'Content-Type' being received client-side
in the HTTP headers. You can use something curl or Firebug.
On Sun, Jan 6, 2013 at 1:40 PM, Ryoichiro Kamiya wrote:
> Hi,
>
> I'm testing Django template rendering in development environment, but one
> of the pag
If they are requesting urls that do not exist why are you worried? Just
block that IP address in the
vhost configuration and continuously monitor the server for strange or
unexpected traffic.
You can look into something like munin or graphite.
On Tue, Jun 18, 2013 at 8:26 PM, MattDale wrote:
>
Don't use Satchmo but looks like `shop_config` is not defined when you
context_processors are called?
This is because from it looks like it gets the shop_config based on the
current site based on the host. If the domain name saved in the admin for
the site corresponding to the SITE_ID in your sett
Should get the flow instance from the form.save() so:
user = User.objects.get(pk=self.request.user.id)
flow = form.save()
log = Log(user=user, flow=flow, state=1)
On Mon, Oct 13, 2014 at 4:13 PM, Daniel Grace wrote:
> Hi,
> I have problem when getting the ID of the record just created.
>
> clas
That could work but isn't it a bit insecure? I think it will be susceptible
to a header injection(http://en.wikipedia.org/wiki/HTTP_header_injection).
I would rather create a setting with the domain name in settings.py and
then call it from the template or write a custom template tag.
On Fri, Nov
I think the model is not being saved because no instance is being
constructed by the form. Either make call to event_form.is_valid() of
event_form.full_clean(), the former being preferred.
On Tue, Nov 26, 2013 at 8:30 PM, Leonardo Giordani <
giordani.leona...@gmail.com> wrote:
> Are you sure tha
gt; generated and sent in a view function I have. So, how will the http header
> get inserted in this flow ?
>
> Vibhu
>
>
>
> On Fri, Nov 29, 2013 at 7:39 PM, Joseph Mutumi wrote:
>
>> That could work but isn't it a bit insecure? I think it will be
>> suscepti
Some of the options you have are:
1) CBVs
2) custom template tags:
https://docs.djangoproject.com/en/1.5/howto/custom-template-tags/
3) template preprocessors:
https://docs.djangoproject.com/en/1.5/ref/settings/#template-context-processors
On 12/2/13, Drew Ferguson wrote:
> Hi
>
> I am not really
You could try using $("form").serialize() to get the form inputs in
the ajax data. But from the URL it looks like your HTML is somehow
rendering badly. The form action is coming out as '/newmarkets/search/
method='
Kind regards
On 4/17/14, willyhakim wrote:
> Hi everyone?
>
> I am trying to use
Just wondering why not cases = cases.order_by('case_number') ?
On 4/24/14, Shawn H wrote:
> I've a search page that allows users to search for a "ZoningCase" by many
> different parameters, some from the ZoningCase object and some from several
>
> related objects. The user can combine 1 or more
Hi there, I think your problem is you have not initialized attendance
that you use at `instance = attendance`. So it is just using the name
of your view function which also happens to be 'attendance' and
showing you that error.
Initialize to model object with the usual:
Attendence_data.objects.get
Hello,
That's strange what does your people model look like? Notice it
will only populate the fields you have defined in the model not
the columns of the table in the database.
Did you run migrations after adding new fields to the model?
$ python manage.py migrate
Kind regards
On Sat, May 12, 2
> >>> d[0]
>
> >>> d[0].document_id
> 2
> >>> d[0].title
> 'a new title 2'
> >>> d[0].description
> 'a new description 2'
> >>> d[0].document_state
> 1
> >>> d[0].storage_file_name
>
> >&
Hello,
You'll first need to create a custom admin page. Create your view and add
it to the urls.py like normal.
Then you extend the admin base template and display your aggregation in
there:
{% extends "admin/base_site.html" %} {% block title %}Stats title{%
endblock %} {% block content %}Stats
Hello,
May be you want to subclass GenericForeignKey:
class GenericOneToOne(GenericForeignKey):
many_to_one = False
one_to_many = False
one_to_one = True
Though have not tried it so YMMV.
Kind regards
On Thu, May 31, 2018 at 8:59 PM, Vitor Barbosa wrote:
> Hello! This is my first
Hello,
Check Django formset documentation:
https://docs.djangoproject.com/en/2.0/topics/forms/formsets/
For Flask, if you are using WTForms check the using the combination
of FieldList with FormField:
http://wtforms.simplecodes.com/docs/0.6/fields.html#field-enclosures
Though this is a Django di
Hello,
Check
https://help.pythonanywhere.com/pages/DebuggingImportError/#django-specific-issues
And make sure your directory structure is as recommended:
/home/myusername
`-- myproject/
|-- __init__.py
`-- myproject/
|-- __init__.py
`-- settings.py
If it is not, then cor
32 matches
Mail list logo