mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Update delete form for Company objects
This commit is contained in:
parent
a78106526a
commit
0e0096467c
@ -1,3 +1,7 @@
|
||||
{% extends "modal_delete_form.html" %}
|
||||
|
||||
{% block pre_form_content %}
|
||||
|
||||
Are you sure you want to delete company '{{ company.name }}'?
|
||||
|
||||
<br>
|
||||
@ -11,3 +15,5 @@ If this supplier is deleted, these supplier part entries will also be deleted.</
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
@ -54,7 +54,7 @@
|
||||
});
|
||||
|
||||
$('#delete-company').click(function() {
|
||||
launchDeleteForm(
|
||||
launchModalForm(
|
||||
"{% url 'company-delete' company.id %}",
|
||||
{
|
||||
redirect: "{% url 'company-index' %}"
|
||||
|
@ -93,10 +93,12 @@ class CompanyCreate(AjaxCreateView):
|
||||
|
||||
class CompanyDelete(AjaxDeleteView):
|
||||
""" View for deleting a Company object """
|
||||
|
||||
model = Company
|
||||
success_url = '/company/'
|
||||
ajax_template_name = 'company/delete.html'
|
||||
ajax_form_title = 'Delete Company'
|
||||
context_object_name = 'company'
|
||||
|
||||
def get_data(self):
|
||||
return {
|
||||
|
Loading…
Reference in New Issue
Block a user