Now you're talking!!! Thanks for that, it's exactly what I was thinking.
Basically I am trying to make a system where you show a list of records,
allow the user to view the record, edit the record or add a new one.
Similar to the admin interface, but with only a view option, so in case your
a 'p
The HTML in the template is fairly easy to do:
{% if object %}
we have an object so we're updating
{% else %}
no object so we're inserting
{% endif %}
I'm not quite sure how you want to handle the viewing part though.
In the form HTML, just create your form as if you are doing an update:
{% if
you would have an html form with if's around each input if there was a
value or not or even just around the whole thing.
Now that I think about it, it might be easier to make 2 views for this
though.
--~--~-~--~~~---~--~~
You received this message because you ar
[EMAIL PROTECTED] wrote:
Create a form where if it's new, it's blank and has a "create" button
that makes the thing. If you are viewing, fill in the form with the
existing info with an "update" button. You can also add a "delete"
button to the view/update version if you want.
This is just a
Create a form where if it's new, it's blank and has a "create" button
that makes the thing. If you are viewing, fill in the form with the
existing info with an "update" button. You can also add a "delete"
button to the view/update version if you want.
This is just a couple of conditionals real
Still a newbie so bear with me..
I'm starting to get into forms, which are pretty easy with
manipulators.
I'm wondering though, would it be possible to use ONE form for add,
view and update? If so, what would I need to do, meaning, obviously
two of them have a post, the others dont.
Is this a
6 matches
Mail list logo