On Fri, Nov 23, 2012 at 7:25 PM, Victor Rocha <vicoro...@gmail.com> wrote:
> For starters, I see more than one thing wrong with your code. I hope thats
> not the one your actually using and it was just a typo when you asked the
> question.
> + jform = editJobForm(request.POST, instance=job) # job has not being
> defined.
> Also when you instantiate your form, you want to use and instance of the
> class your want to use, for instance. gi

>     clientjob = ClientEditJob.objects.get(job_id =query)
>     job = EditJob.objects.get(job_id=query)
>
If I do this I won't get previously filled values of ClientJob table
which I need for editing. ClientEditJob table is empty.

> Right now you using this: clientjob = ClientJob.objects.get(job_id = query).
> ClientJob is not a model for any of the two forms you are using.
>
I think you haven't understood what I want. I don't say my code is
correct, Because if it would be, I would have got my results. Please
help me change it to correct one.
What I want to do :
Get instance of one table, which after editing get saved to some other table.
What I get :
I get values of one table and after editing it get saved to the same table. :(

-- 
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.

Reply via email to