Thanks James. I changed the rendering to move the fieldset inside the form
tag and it works. Thank you so much
On Wednesday, 21 October 2015 10:58:31 UTC-4, sushovan majumdar wrote:
>
> Hi James.
> I'm copying the rendered HTML from browser view source:
>
>
>
>
>
>
>
>
>
>
>
>
> rendering code in template:
>
>
> {{ formset.management_form|crispy }}
>
>
> {% for form in formset.forms %}
>
> {% crispy form formset.crispy_helper %}
>
> {% endfor %}
>
I'm trying to add dynamic forms to my inline formset using the steps
mentioned in the post: Add a dynamic form to a django formset using
javascript in a right way
<http://stackoverflow.com/questions/21260987/add-a-dynamic-form-to-a-django-formset-using-javascript-in-a-right-way>
I have
On Wed, May 8, 2013 at 6:43 PM, noodlygod wrote:
>
>
> <
> Class Level (Text field)>
> Definition.objects.filter(category__label='Skill'))> field)>
> Definition.objects.filter(category__label=Attribute'))>< Attribute score
> (Text field)>
>
> I was on my way to creating
Hello all, I'm attempting to create an RPG character generator using
Django. My models are as follows:
from django.db import models
class Character(models.Model):
name = models.CharField(null=False, blank=False, max_length=60)
age = models.IntegerField()
height =
On Wed, Sep 5, 2012 at 9:18 PM, mjh wrote:
> yes it is being passed to the template as I can access the label, choices,
> help_text, required items of the boundfield object...
>
> i.e., {{ issue.label }} {{ issue.choices }} {{ issue.help_text }}
>
> I can get
yes it is being passed to the template as I can access the label, choices,
help_text, required items of the boundfield object...
i.e., {{ issue.label }} {{ issue.choices }} {{ issue.help_text }}
I can get everything it seems apart from the form object !!!
{{ issue }} writes to the template:
check if it is being passed to template.
{% if issue %}
{{ issue }}
{% else %}
Issue was not passed #Debug
{% endif %}
On Wed, Sep 5, 2012 at 8:45 PM, Mando wrote:
> are you passing it to the template?
>
>
> On Wednesday, September 5, 2012 7:09:57 AM UTC-5, mjh wrote:
are you passing it to the template?
On Wednesday, September 5, 2012 7:09:57 AM UTC-5, mjh wrote:
>
> tried {{ issue.x }} x = 0,1,2,3 but nothing is displayed in the template
>
> any other thoughts?
>
> On Monday, 3 September 2012 22:53:03 UTC+1, somecallitblues wrote:
>>
>> Try {{ issue.0}} and
tried {{ issue.x }} x = 0,1,2,3 but nothing is displayed in the template
any other thoughts?
On Monday, 3 September 2012 22:53:03 UTC+1, somecallitblues wrote:
>
> Try {{ issue.0}} and {{ issue.1}}
> On Sep 4, 2012 5:55 AM, "mjh"
> wrote:
>
>> Hi all - not sure how to
Try {{ issue.0}} and {{ issue.1}}
On Sep 4, 2012 5:55 AM, "mjh" wrote:
> Hi all - not sure how to show the choicefield dropdown in my template?
>
> Am generating a dynamic form (note: for issue in issues in forms.py) and
> appending the fields to self.issue_list
Hi all - not sure how to show the choicefield dropdown in my template?
Am generating a dynamic form (note: for issue in issues in forms.py) and
appending the fields to self.issue_list
in the template I am looping over these fields ({% for issue in form.issue_list
%}) and can write out the
On Tue, Jul 31, 2012 at 11:59 AM, Satinder Goraya
wrote:
> Lets say that you need a form with a drop-down list that have dynamic
> values. With Django this can be done simple and fast.
> my_choice_field). With this code get_my_choices is called on every
> form load
On Tue, Jul 31, 2012 at 1:23 AM, Sandeep kaur wrote:
> I want to have a form, with drop down list and then multiple select
> checkboxes dynamically filtered based on drop down selection. I have
> searched a lot but did not find a complete solution for my
> requirement. Also
Just to be clear, sandeep, jQuery is not java, javascript is not java.
Get yourself clear on that, because it can become a big confusion.
Besides that, yes, without javascript, the only way you've got to do
that, is having the user submit a form where he selects the options,
and then return
I think that he does NOT want to use jQuery ("java Query").
Without javascript you will need to resubmit data to the server, so he
figures out what to do.
On Mon, Jul 30, 2012 at 5:58 PM, Marshel Helsper wrote:
> The only way I can think of doing it without JS would be by
The only way I can think of doing it without JS would be by having the
users select an option from the drop down and then click a next button,
submitting to the server for the server to figure out what to do next.
On Mon, Jul 30, 2012 at 4:55 PM, Nicolas Emiliani wrote:
>
>
>
On Mon, Jul 30, 2012 at 4:53 PM, Sandeep kaur wrote:
> I want to have a form, with drop down list and then multiple select
> checkboxes dynamically filtered based on drop down selection. I have
> searched a lot but did not find a complete solution for my
> requirement.
I want to have a form, with drop down list and then multiple select
checkboxes dynamically filtered based on drop down selection. I have
searched a lot but did not find a complete solution for my
requirement. Also I want to ask that can we do this without apply java
query ? Means if a browser
dynamic forms is a known solution, I am yet to figure
out how I could just render the dynamic forms with fixed answers (like
1+1=?, ans 2) with custom validation logic that runs as javascript in
the client.
Is there any good example or a best practice known for such a
functional requirement?
Some
t 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.
>
>
>
--
View this message
On Aug 19, 1:58 pm, SixDegrees wrote:
> I'm no longer at the computer where my code resides. But "you are wanting to
> call formset_factory
> and have it pass along a parameter to the Form that the formset
> contains" is pretty much what I want to know how to do.
Well,
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:/
On Aug 19, 12:41 pm, SixDegrees wrote:
> The parameter in question is a primary key that is used to generate a series
> of fields within the form. It is passed to the form __init__ routine, and
> can vary from one form to another. So, given a formset, I want to tell the
next form
you create."
SixDegrees wrote:
>
> I'm using formsets to implement a dynamic form as described
> http://www.mancoosi.org/~abate/dynamic-forms-with-django here . However,
> the forms created by the formset want a parameter passed that determines
> the contents of the f
On Aug 19, 10:44 am, SixDegrees <paulcarli...@comcast.net> wrote:
> I'm using formsets to implement a dynamic form as
> describedhttp://www.mancoosi.org/~abate/dynamic-forms-with-djangohere .
> However, the
> forms created by the formset want a parameter passed that determi
I'm using formsets to implement a dynamic form as described
http://www.mancoosi.org/~abate/dynamic-forms-with-django here . However, the
forms created by the formset want a parameter passed that determines the
contents of the form during initialization. This parameter can be passed
back through
bit complex coz the form attributes have there own attributes and
> widgets
> Kenneth
>
>
>
> On Wed, Jul 20, 2011 at 1:00 PM, NISA BALAKRISHNAN <
> snisa.balakrish...@gmail.com> wrote:
>
>> may be dis link helps u:
>>
>> http://uswaretech.com/blog/2008
ish...@gmail.com> wrote:
> may be dis link helps u:
>
> http://uswaretech.com/blog/2008/10/dynamic-forms-with-django/
>
> On Wed, Jul 20, 2011 at 12:46 PM, ken paul <kbo...@gmail.com> wrote:
>
>> hey can anyone get a way of writing dynamic form classes with
may be dis link helps u:
http://uswaretech.com/blog/2008/10/dynamic-forms-with-django/
On Wed, Jul 20, 2011 at 12:46 PM, ken paul <kbo...@gmail.com> wrote:
> hey can anyone get a way of writing dynamic form classes with django. I
> have tried but putting the attributes becam
hey can anyone get a way of writing dynamic form classes with django. I have
tried but putting the attributes became a bit hard.
Kenneth
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to
difficult to maintain.
We need the following features:
* large, multi-page form (too many fields to fit on one page)
* dynamic forms (ability to add more fields on demand)
* non-sequential entry (users can jump back and forth filling it in)
* serialization (the serialized output is sent
The information is helpful as it is helping me understand some basics
of Django. I am experienced in old web dev technologies but I am new
to both Python and Django and I see the information on the articles
and Internet targeted for experienced python / django developers.
I have a stupid
Afshin, recently i came across the same problem.
This page helped me to figure out how to do dynamic forms:
http://jacobian.org/writing/dynamic-form-generation/
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this g
On Tue, May 24, 2011 at 12:47 PM, Afshin Moshrefi
wrote:
> I want to write a form which can dynamically add fields. I can simply
> add additional fields that I need with JavaScript but am not sure if
> that is the best way to handle this with Django?
>
> What are the
You can add fields dynamically in the __init__ of your form by
processing the info passed in as the 'data' kwarg.
Parse the info and just append fields to self.fields, something like this:
self.fields['dynamic_field_' + field_num] =
forms.CharField(max_length = 10)
--
You received this
I want to write a form which can dynamically add fields. I can simply
add additional fields that I need with JavaScript but am not sure if
that is the best way to handle this with Django?
What are the best ways to handle creating and processing such dynamic
form with Django?
AM
--
You
Hi, was hoping someone could point me in a direction, I'm somewhat new
to Django. I'm trying to create a "model of a model", something like
this (mostly pseudo-code, not "real" Python):
class TheModel(Model):
name
#some other stuff
class TheModelProperties(Model):
the_model =
I think jquery may be the right way to go for this. It will allow you
to evaluate the weights in real time so you won't have to submit the
form before any validation errors would be returned.
Working it at the model level may get tricky, for ease I would handle
it at the form or view level.
On
On 8/12/2010 8:36 AM, lingrlongr wrote:
> Hi Nick,
>
> Thanks for the reply. Yes, the department weights will be used in a
> grading scheme. One department may be 25% (0.25), etc... But in the
> end, the weights should total 1.0. For example, in my Store model:
>
> class Store(models.Model):
Hi Nick,
Thanks for the reply. Yes, the department weights will be used in a
grading scheme. One department may be 25% (0.25), etc... But in the
end, the weights should total 1.0. For example, in my Store model:
class Store(models.Model):
#...etc...
def _get_total_dept_weight(self):
Are you trying to create a save function that evaluates all the
weights and returns an error if they are more than 1?
On Aug 10, 3:17 pm, lingrlongr wrote:
> I 'm trying to create a form dynamically. This works just fine, but
> there's no way for the form to offer any
I 'm trying to create a form dynamically. This works just fine, but
there's no way for the form to offer any customized validation, by way
of the clean() method.
def get_dept_weight_form(store):
fields = {}
s = Store.objects.get(pk=store.id)
for d in store.department_set.all():
I've been investigating the localflavor mod and I'm wondering how to
apply it to my situation, or at least learn *if* it can be applied.
A simplified example would be I need a user to enter an address. The
user could be from any number of countries so I want the form to to
able to validate, say,
is a client of the partner) - level Three which would
have admin/non-admin users
Company Clients - level four are accounts for the company
Each level has a ability to create dynamic forms ( Form controls and
it's value store to db for clients to use )
Our problems are:
1) one creating
Scratch that. I ended up doing it the other way. I went back and
reviewed and it seemed less ugly now than it did at midnight last
night. Funny, that. Thanks for the advice.
On Apr 10, 10:45 am, Laereom wrote:
> Honestly, I really don't like that method, mostly due to
Honestly, I really don't like that method, mostly due to ugliness.
I'm looking for a solution specifically to instantiating a form
created via a class factory, unless that is some sort of Herculean
task.
On Apr 10, 10:13 am, Daniel Roseman wrote:
> On Apr 10, 4:40 pm,
On Apr 10, 4:40 pm, Laereom wrote:
> As the title suggests, I'm creating a dynamic form via a class
> factory.
>
> Here is what I'm doing inside the class factory itself (as far as
> actually making the class goes):
> class _QuestionAnswerForm(forms.Form):
As the title suggests, I'm creating a dynamic form via a class
factory.
Here is what I'm doing inside the class factory itself (as far as
actually making the class goes):
class _QuestionAnswerForm(forms.Form):
response =
tdelam escribió:
> Hi Guys,
>
> This might get lengthy but I am trying to get some insight on the best
> way to generate some dynamic forms in a template. The project is a
> survey. Here is my questions model:
>
> class Question(models.Model):
> TRUEFALSE
Hi Guys,
This might get lengthy but I am trying to get some insight on the best
way to generate some dynamic forms in a template. The project is a
survey. Here is my questions model:
class Question(models.Model):
TRUEFALSE = 1 # a radio button yes/no question
MULTIPLEANSWER = 2
Hello,
I have been thinking about a problem a bit, found a pretty nice
solution and would like to know, what others think of it and if there
are downsides I have forgotten about.
Starting point is a form, that has dynamically generated parts. In my
example, I generate a form from a model via
Warning: New to Django so bear with me but got some really helpful
stuff
out here. Also have been using Django 0.96 so change accordingly for
version 1.0.(specifically forms.py)
Problem: Create and validate dynamic forms using Django.
1) Creation should be dynamic
2) Validation
Thanks a lot.
On Jan 7, 1:19 am, Jeff Anderson <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > The number of features can grow or decrease depending on the user type
> > so I can't create a static form class with all the features listed.
>
> > Can someone please help to do this.
>
>
[EMAIL PROTECTED] wrote:
> The number of features can grow or decrease depending on the user type
> so I can't create a static form class with all the features listed.
>
> Can someone please help to do this.
>
Sure!
I believe this will be a decent starting point for you:
Hello,
I have a database table with a list of features that a user can
enable, so I would like to create a form like:
Feature1 [ ] Enable [ ] Disable
Feature2 [ ] Enable [ ] Disable
Feature3 [ ] Enable [ ] Disable
Feature4 [ ] Enable [ ] Disable
The number of features can grow or
Hi yml,
On 9 Oct, 20:11, yml <[EMAIL PROTECTED]> wrote:
> In a very similar situation I have chosen option 2 for the following
> reasons:
> * the code was much more simple, at least simpler to maintain for me
> * Very hight control on the layout of the form.
Thanks for the reply. I think I'll
Hello Felix,
In a very similar situation I have chosen option 2 for the following
reasons:
* the code was much more simple, at least simpler to maintain for me
* Very hight control on the layout of the form.
I have taken this decision after spending several days working on a
"newform" based
Hello all,
I've been making great strides with my application since returning
from the land of Pylons. Given that the app is all about data entry
I've taken the customise-the-admin-app approach to things and made the
switch to newforms-admin this morning.
So far things are working: data is
Hi all,
Been reading this group for a while, decided to give an idea for
dynamic forms a try after reading the article on dynamicmodels
http://code.djangoproject.com/wiki/DynamicModels
I cooked up a some models and a view
see: http://statix.net/dynaform
if one creates a form with some info
60 matches
Mail list logo