Re: forms.form_for_model

2007-12-27 Thread mike
rEntryForm = forms.form_for_model(Customer) form = CustomerEntryForm() return render_to_response('add_edit_customer.html', {'form': form}) else: IssueEntryForm = forms.form_for_model(Issue) entry = get_object_or_404(Customer, pk=id) issu

Re: forms.form_for_model

2007-12-27 Thread mike
Yes, I found your post a while back, that is where I am learning most of this, great post. I tried this and got 'ModPythonRequest' object has no attribute 'customer' I think i am close though, here is my code: else: IssueEntryForm = forms.form_for_model(I

Re: forms.form_for_model

2007-12-26 Thread Empty
> Thanks for the reply I tried using the method you described and > searched the __init__.py, but just couldnt make any sense of it, > > def my_callback(field, **kwargs): > if f.name == 'customer': >return f.formfield(formfclass=forms.HiddenInput) Since you're receiving the fi

Re: forms.form_for_model

2007-12-26 Thread mike
m Tredinnick <[EMAIL PROTECTED]> wrote: > On Fri, 2007-12-21 at 06:48 -0800, mike wrote: > > Sorry if I was unclean, I just discovered this and I am still learning > > newforms, I am using forms.form_for_model and trying to get two form > > to display in my template, only 1 i

Re: forms.form_for_model

2007-12-21 Thread Malcolm Tredinnick
On Fri, 2007-12-21 at 06:48 -0800, mike wrote: > Sorry if I was unclean, I just discovered this and I am still learning > newforms, I am using forms.form_for_model and trying to get two form > to display in my template, only 1 is a foreign key that I used > edit_inline with my model,

Re: forms.form_for_model

2007-12-21 Thread mike
> form instance. Corrections embedded below. > > > On Dec 21, 8:48 am, mike <[EMAIL PROTECTED]> wrote: > > > > Sorry if I was unclean, I just discovered this and I am still learning > > > newforms, I am using forms.form_for_model and trying to get two form > &

Re: forms.form_for_model

2007-12-21 Thread mike
> form instance. Corrections embedded below. > > > On Dec 21, 8:48 am, mike <[EMAIL PROTECTED]> wrote: > > > > Sorry if I was unclean, I just discovered this and I am still learning > > > newforms, I am using forms.form_for_model and trying to get two form > &

Re: forms.form_for_model

2007-12-21 Thread mike
n't recognize that IssueEntryForm in the original post was NOT a > form instance. Corrections embedded below. > > On Dec 21, 8:48 am, mike <[EMAIL PROTECTED]> wrote: > > > > > Sorry if I was unclean, I just discovered this and I am still learning > > new

Re: forms.form_for_model

2007-12-21 Thread rskm1
this and I am still learning > newforms, I am using forms.form_for_model and trying to get two form > to display in my template, only 1 is a foreign key that I used > edit_inline with my model, I am trying to get the 'customer' field of > my issue to be hidden and automa

Re: forms.form_for_model

2007-12-21 Thread mike
Sorry if I was unclean, I just discovered this and I am still learning newforms, I am using forms.form_for_model and trying to get two form to display in my template, only 1 is a foreign key that I used edit_inline with my model, I am trying to get the 'customer' field of my issue to

Re: forms.form_for_model

2007-12-20 Thread rskm1
On Dec 20, 2:58 pm, mike <[EMAIL PROTECTED]> wrote: > anyone know how to auto assign a variable to my form field? > > IssueEntryForm.base_fields['customer'].widget = widgets.HiddenInput() > IssueEntryForm.base_fields['customer'].widget = HELP I'm not sure I understand the question; what exactly d

forms.form_for_model

2007-12-20 Thread mike
anyone know how to auto assign a variable to my form field? IssueEntryForm.base_fields['customer'].widget = widgets.HiddenInput() IssueEntryForm.base_fields['customer'].widget = HELP --~--~-~--~~~---~--~~ You received this message because you are subscribed to th