Calling inplace_edit tag you can inplace edit any data from the database. It is important to clarify that the inline edition is not only for text fields, although it may be the more common usage. You can also have inline edition for choices, boolean fields, date and datetime fields, foreing keys, many to many, file and image fields.
{% inplace_edit "OBJ.FIELD_NAME" %}
{% inplace_edit "OBJ.FIELD_NAME|FILTER1|FILTER2|...|FILTERN" %}
{% load inplace_edit %}
<html>
<head>
...
<script src="{{ STATIC_URL }}js/jquery.min.js" type="text/javascript"></script>
{% inplace_toolbar %} {% comment %} or inplace_static {% endcomment %}
</head>
<body>
...
<div id="content">
...
{% inplace_edit "content.name" %}
...
<div class="description">
{% inplace_edit "content.date_initial|date:'d m Y'" %}
{% inplace_edit "content.description|safe" %}
</div>
<div class="body">
{% inplace_edit "content.body|safe|truncatewords_html:15" %}
</div>
</div>
...
</body>
</html>
- If you use inplace_static: Just pass the cursor above the field and double click (this is customizable), authenticated with a super user (this is also customizable)
- If you use inplace_toolbar: Enable a edit inline and just pass the cursor above the field and double click (this is customizable), authenticated with a super user (this is also customizable)