mirror of
https://github.com/inventree/InvenTree.git
synced 2025-08-14 07:31:10 +00:00
Merge pull request #2477 from SchrodingersGat/duplicate-bom-form
Duplicate bom form
This commit is contained in:
@@ -1,17 +0,0 @@
|
||||
{% extends "modal_form.html" %}
|
||||
{% load i18n %}
|
||||
|
||||
{% block pre_form_content %}
|
||||
|
||||
<p>
|
||||
{% trans "Select parent part to copy BOM from" %}
|
||||
</p>
|
||||
|
||||
{% if part.has_bom %}
|
||||
<div class='alert alert-block alert-danger'>
|
||||
<strong>{% trans "Warning" %}</strong><br>
|
||||
{% trans "This part already has a Bill of Materials" %}<br>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% endblock %}
|
@@ -1,12 +0,0 @@
|
||||
{% extends "modal_form.html" %}
|
||||
|
||||
{% load i18n %}
|
||||
|
||||
{% block pre_form_content %}
|
||||
{% blocktrans with part.full_name as part %}Confirm that the Bill of Materials (BOM) is valid for:<br><em>{{ part }}</em>{% endblocktrans %}
|
||||
|
||||
<div class='alert alert-warning alert-block'>
|
||||
{% trans 'This will validate each line in the BOM.' %}
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
@@ -585,14 +585,12 @@
|
||||
});
|
||||
|
||||
$('#bom-duplicate').click(function() {
|
||||
launchModalForm(
|
||||
"{% url 'duplicate-bom' part.id %}",
|
||||
{
|
||||
success: function() {
|
||||
$('#bom-table').bootstrapTable('refresh');
|
||||
}
|
||||
|
||||
duplicateBom({{ part.pk }}, {
|
||||
success: function(response) {
|
||||
$('#bom-table').bootstrapTable('refresh');
|
||||
}
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
$("#bom-item-new").click(function () {
|
||||
@@ -616,12 +614,10 @@
|
||||
});
|
||||
|
||||
$("#validate-bom").click(function() {
|
||||
launchModalForm(
|
||||
"{% url 'bom-validate' part.id %}",
|
||||
{
|
||||
reload: true,
|
||||
}
|
||||
);
|
||||
|
||||
validateBom({{ part.id }}, {
|
||||
reload: true
|
||||
});
|
||||
});
|
||||
|
||||
$("#download-bom").click(function () {
|
||||
|
Reference in New Issue
Block a user