mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Move "stock" part view
This commit is contained in:
parent
0667857754
commit
2d2ad91545
@ -7,8 +7,7 @@
|
|||||||
{% load markdownify %}
|
{% load markdownify %}
|
||||||
|
|
||||||
{% block menubar %}
|
{% block menubar %}
|
||||||
{% include 'order/po_navbar.html' with tab='details' %}
|
{% include 'order/po_navbar.html' %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block page_content %}
|
{% block page_content %}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
{% load markdownify %}
|
{% load markdownify %}
|
||||||
|
|
||||||
{% block menubar %}
|
{% block menubar %}
|
||||||
{% include "order/so_navbar.html" with tab='details' %}
|
{% include "order/so_navbar.html" %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block page_content %}
|
{% block page_content %}
|
||||||
|
@ -5,58 +5,47 @@
|
|||||||
|
|
||||||
|
|
||||||
{% block menubar %}
|
{% block menubar %}
|
||||||
{% include 'part/navbar.html' with tab='details' %}
|
{% include 'part/navbar.html' %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block heading %}
|
{% block page_content %}
|
||||||
{% trans "Part Details" %}
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block details %}
|
<div class='panel panel-default panel-inventree panel-hidden' id='panel-part-stock'>
|
||||||
|
<div class='panel-heading'>
|
||||||
|
<h4>{% trans "Part Stock" %}</h4>
|
||||||
|
</div>
|
||||||
|
<div class='panel-content'>
|
||||||
|
{% if part.is_template %}
|
||||||
|
<div class='alert alert-info alert-block'>
|
||||||
|
{% blocktrans with full_name=part.full_name%}Showing stock for all variants of <i>{{full_name}}</i>{% endblocktrans %}
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
{% include "stock_table.html" %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class='panel panel-default panel-inventree panel-hidden' id='panel-part-notes'>
|
||||||
|
<div class='panel-heading'>
|
||||||
<div class='row'>
|
<div class='row'>
|
||||||
<div class='col-sm-6'>
|
<div class='col-sm-6'>
|
||||||
<table class='table table-striped'>
|
<h4>{% trans "Notes" %}</h4>
|
||||||
<col width='25'>
|
</div>
|
||||||
|
<div class='col-sm-6'>
|
||||||
<tr>
|
|
||||||
<td><span class='fas fa-sticky-note'></span></td>
|
|
||||||
<td>
|
|
||||||
<strong>{% trans "Notes" %}</strong>
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<div class='btn-group float-right'>
|
<div class='btn-group float-right'>
|
||||||
<button type='button' id='edit-notes' title='{% trans "Edit Notes" %}' class='btn btn-small btn-default'>
|
<button type='button' id='edit-notes' title='{% trans "Edit Notes" %}' class='btn btn-small btn-default'>
|
||||||
<span class='fas fa-edit'>
|
<span class='fas fa-edit'>
|
||||||
</span>
|
</span>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</div>
|
||||||
</tr>
|
</div>
|
||||||
<tr>
|
</div>
|
||||||
<td colspan='3'>
|
<div class='panel-content'>
|
||||||
{% if part.notes %}
|
|
||||||
<div class='notes'>
|
|
||||||
{{ part.notes | markdownify }}
|
{{ part.notes | markdownify }}
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<div class='col-sm-6'>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% endblock %}
|
<div class='panel panel-default panel-inventree panel-hidden' id='panel-part-parameters'>
|
||||||
|
|
||||||
{% block post_content_panel %}
|
|
||||||
|
|
||||||
<div class='row'>
|
|
||||||
<div class='col-sm-6'>
|
|
||||||
<div class='panel panel-default panel-inventree'>
|
|
||||||
<div class='panel-heading'>
|
<div class='panel-heading'>
|
||||||
<h4>{% trans "Parameters" %}</h4>
|
<h4>{% trans "Parameters" %}</h4>
|
||||||
</div>
|
</div>
|
||||||
@ -73,9 +62,8 @@
|
|||||||
<table id='parameter-table' class='table table-condensed table-striped' data-toolbar="#param-button-toolbar"></table>
|
<table id='parameter-table' class='table table-condensed table-striped' data-toolbar="#param-button-toolbar"></table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
<div class='col-sm-6'>
|
<div class='panel panel-default panel-inventree panel-hidden' id='panel-part-attachments'>
|
||||||
<div class='panel panel-default panel-inventree'>
|
|
||||||
<div class='panel-heading'>
|
<div class='panel-heading'>
|
||||||
<h4>{% trans "Attachments" %}</h4>
|
<h4>{% trans "Attachments" %}</h4>
|
||||||
</div>
|
</div>
|
||||||
@ -83,8 +71,6 @@
|
|||||||
{% include "attachment_table.html" %}
|
{% include "attachment_table.html" %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
@ -95,6 +81,53 @@
|
|||||||
{% block js_ready %}
|
{% block js_ready %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
|
|
||||||
|
$('#add-stock-item').click(function () {
|
||||||
|
createNewStockItem({
|
||||||
|
reload: true,
|
||||||
|
data: {
|
||||||
|
part: {{ part.id }},
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
loadStockTable($("#stock-table"), {
|
||||||
|
params: {
|
||||||
|
part: {{ part.id }},
|
||||||
|
location_detail: true,
|
||||||
|
part_detail: true,
|
||||||
|
supplier_part_detail: true,
|
||||||
|
},
|
||||||
|
groupByField: 'location',
|
||||||
|
buttons: [
|
||||||
|
'#stock-options',
|
||||||
|
],
|
||||||
|
url: "{% url 'api-stock-list' %}",
|
||||||
|
});
|
||||||
|
|
||||||
|
$("#stock-export").click(function() {
|
||||||
|
launchModalForm("{% url 'stock-export-options' %}", {
|
||||||
|
submit_text: "{% trans 'Export' %}",
|
||||||
|
success: function(response) {
|
||||||
|
var url = "{% url 'stock-export' %}";
|
||||||
|
|
||||||
|
url += "?format=" + response.format;
|
||||||
|
url += "&cascade=" + response.cascade;
|
||||||
|
url += "&part={{ part.id }}";
|
||||||
|
|
||||||
|
location.href = url;
|
||||||
|
},
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#item-create').click(function () {
|
||||||
|
createNewStockItem({
|
||||||
|
reload: true,
|
||||||
|
data: {
|
||||||
|
part: {{ part.id }},
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
$('#edit-notes').click(function() {
|
$('#edit-notes').click(function() {
|
||||||
constructForm('{% url "api-part-detail" part.pk %}', {
|
constructForm('{% url "api-part-detail" part.pk %}', {
|
||||||
fields: {
|
fields: {
|
||||||
@ -239,4 +272,9 @@
|
|||||||
)
|
)
|
||||||
});
|
});
|
||||||
|
|
||||||
|
attachNavCallbacks({
|
||||||
|
name: 'part',
|
||||||
|
default: 'part-stock'
|
||||||
|
});
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
@ -11,46 +11,44 @@
|
|||||||
<span class='menu-tab-icon fas fa-expand-arrows-alt'></span>
|
<span class='menu-tab-icon fas fa-expand-arrows-alt'></span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class='list-group-item {% if tab == "details" %}active{% endif %}' title='{% trans "Part Details" %}'>
|
<li class='list-group-item' title='{% trans "Parameters" %}'>
|
||||||
<a href='{% url "part-detail" part.id %}'>
|
<a href='#' id='select-part-parameters' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-info-circle sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-th-list sidebar-icon'></span>
|
||||||
<span class='tab-text'>
|
{% trans "Parameters" %}
|
||||||
{% trans "Details" %}
|
|
||||||
</span>
|
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% if part.is_template %}
|
{% if part.is_template %}
|
||||||
<li class='list-group-item {% if tab == "variants" %}active{% endif %}' title='{% trans "Part Variants" %}'>
|
<li class='list-group-item' title='{% trans "Part Variants" %}'>
|
||||||
<a href='{% url "part-variants" part.id %}'>
|
<a href='#' id='select-part-variants' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-shapes sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-shapes sidebar-icon'></span>
|
||||||
{% trans "Variants" %}
|
{% trans "Variants" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<li class='list-group-item {% if tab == "stock" %}active{% endif %}' title='{% trans "Stock Items" %}'>
|
<li class='list-group-item' title='{% trans "Stock Items" %}'>
|
||||||
<a href='{% url "part-stock" part.id %}'>
|
<a href='#' id='select-part-stock' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-boxes sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-boxes sidebar-icon'></span>
|
||||||
{% trans "Stock" %}
|
{% trans "Stock" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% if part.component or part.salable %}
|
{% if part.component or part.salable %}
|
||||||
<li class='list-group-item {% if tab == "allocation" %}active{% endif %}' title='{% trans "Allocated Stock" %}'>
|
<li class='list-group-item' title='{% trans "Allocated Stock" %}'>
|
||||||
<a href='{% url "part-allocation" part.id %}'>
|
<a href='#' id='select-part-allocations' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-sign-out-alt sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-sign-out-alt sidebar-icon'></span>
|
||||||
{% trans "Allocations" %}
|
{% trans "Allocations" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if part.assembly %}
|
{% if part.assembly %}
|
||||||
<li class='list-group-item {% if tab == "bom" %}active{% endif %}' title='{% trans "Bill of Materials" %}'>
|
<li class='list-group-item' title='{% trans "Bill of Materials" %}'>
|
||||||
<a href='{% url "part-bom" part.id %}'>
|
<a href='#' id='select-part-bom' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-list sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-list sidebar-icon'></span>
|
||||||
{% trans "Bill of Materials" %}
|
{% trans "Bill of Materials" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% if roles.build.view %}
|
{% if roles.build.view %}
|
||||||
<li class='list-group-item {% if tab == "build" %}active{% endif %}' title='{% trans "Build Orders" %}'>
|
<li class='list-group-item ' title='{% trans "Build Orders" %}'>
|
||||||
<a href='{% url "part-build" part.id %}'>
|
<a href='#' id='select-build-orders' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-tools sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-tools sidebar-icon'></span>
|
||||||
{% trans "Build Orders" %}
|
{% trans "Build Orders" %}
|
||||||
</a>
|
</a>
|
||||||
@ -58,55 +56,73 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if part.component %}
|
{% if part.component %}
|
||||||
<li class='list-group-item {% if tab == "used" %}active{% endif %}' title='{% trans "Used In" %}'>
|
<li class='list-group-item ' title='{% trans "Used In" %}'>
|
||||||
<a href='{% url "part-used-in" part.id %}'>
|
<a href='#' id='select-used-in' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-layer-group sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-layer-group sidebar-icon'></span>
|
||||||
{% trans "Used In" %}
|
{% trans "Used In" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<li class='list-group-item {% if tab == "prices" %}active{% endif %}' title='{% trans "Pricing Information" %}'>
|
<li class='list-group-item' title='{% trans "Pricing Information" %}'>
|
||||||
<a href='{% url "part-prices" part.id %}'>
|
<a href='#' id='select-part-pricing' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-dollar-sign sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-dollar-sign sidebar-icon'></span>
|
||||||
{% trans "Prices" %}
|
{% trans "Prices" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% if part.purchaseable and roles.purchase_order.view %}
|
{% if part.purchaseable and roles.purchase_order.view %}
|
||||||
<li class='list-group-item {% if tab == "suppliers" %}active{% endif %}' title='{% trans "Suppliers" %}'>
|
<li class='list-group-item' title='{% trans "Suppliers" %}'>
|
||||||
<a href='{% url "part-suppliers" part.id %}'>
|
<a href='#' id='select-part-suppliers' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-building sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-building sidebar-icon'></span>
|
||||||
{% trans "Suppliers" %}
|
{% trans "Suppliers" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li class='list-group-item {% if tab == "orders" %}active{% endif %}' title='{% trans "Purchase Orders" %}'>
|
<li class='list-group-item' title='{% trans "Manufacturers" %}'>
|
||||||
<a href='{% url "part-orders" part.id %}'>
|
<a href='#' id='select-part-manufacturers' class='nav-toggle'>
|
||||||
|
<span class='menu-tab-icon fas fa-tools sidebar-icon'></span>
|
||||||
|
{% trans "Manufacturers" %}
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class='list-group-item' title='{% trans "Purchase Orders" %}'>
|
||||||
|
<a href='#' id='select-purchase-orders' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-shopping-cart sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-shopping-cart sidebar-icon'></span>
|
||||||
{% trans "Purchase Orders" %}
|
{% trans "Purchase Orders" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if roles.sales_order.view %}
|
{% if roles.sales_order.view %}
|
||||||
<li class='list-group-item {% if tab == "sales-orders" %}active{% endif %}' title='{% trans "Sales Orders" %}'>
|
<li class='list-group-item' title='{% trans "Sales Orders" %}'>
|
||||||
<a href='{% url "part-sales-orders" part.id %}'>
|
<a href='#' id='select-sales-orders' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-truck sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-truck sidebar-icon'></span>
|
||||||
{% trans "Sales Orders" %}
|
{% trans "Sales Orders" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if part.trackable %}
|
{% if part.trackable %}
|
||||||
<li class='list-group-item {% if tab == "tests" %}active{% endif %}' title='{% trans "Part Test Templates" %}'>
|
<li class='list-group-item' title='{% trans "Part Test Templates" %}'>
|
||||||
<a href='{% url "part-test-templates" part.id %}'>
|
<a href='#' id='select-test-templates' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-vial sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-vial sidebar-icon'></span>
|
||||||
{% trans "Test Templates" %}
|
{% trans "Test Templates" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if show_related %}
|
{% if show_related %}
|
||||||
<li class='list-group-item {% if tab == "related" %}active{% endif %}' title='{% trans "Related Parts" %}'>
|
<li class='list-group-item' title='{% trans "Related Parts" %}'>
|
||||||
<a href='{% url "part-related" part.id %}'>
|
<a href='#' id='select-related-parts' class='nav-toggle'>
|
||||||
<span class='menu-tab-icon fas fa-random sidebar-icon'></span>
|
<span class='menu-tab-icon fas fa-random sidebar-icon'></span>
|
||||||
{% trans "Related Parts" %}
|
{% trans "Related Parts" %}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
<li class='list-group-item' title='{% trans "Attachments" %}'>
|
||||||
|
<a href='#' id='select-part-attachments' class='nav-toggle'>
|
||||||
|
<span class='fas fa-paperclip side-icon'></span>
|
||||||
|
{% trans "Attachments" %}
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
|
<li class='list-group-item' title='{% trans "Notes" %}'>
|
||||||
|
<a href='#' id='select-part-notes' class='nav-toggle'>
|
||||||
|
<span class='fas fa-clipboard side-icon'></span>
|
||||||
|
{% trans "Notes" %}
|
||||||
|
</a>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
@ -245,30 +245,7 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{% block pre_content_panel %}
|
{% block page_content %}
|
||||||
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
<div class='panel panel-default panel-inventree'>
|
|
||||||
|
|
||||||
|
|
||||||
<div class='panel-heading'>
|
|
||||||
<h4>
|
|
||||||
{% block heading %}
|
|
||||||
<!-- Heading goes here -->
|
|
||||||
{% endblock %}
|
|
||||||
</h4>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class='panel-content'>
|
|
||||||
{% block details %}
|
|
||||||
<!-- Specific part details go here... -->
|
|
||||||
{% endblock %}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
|
||||||
{% block post_content_panel %}
|
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
@ -1,77 +0,0 @@
|
|||||||
{% extends "part/part_base.html" %}
|
|
||||||
{% load static %}
|
|
||||||
{% load i18n %}
|
|
||||||
|
|
||||||
{% block menubar %}
|
|
||||||
{% include 'part/navbar.html' with tab='stock' %}
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block heading %}
|
|
||||||
{% trans "Part Stock" %}
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block details %}
|
|
||||||
{% if part.is_template %}
|
|
||||||
<div class='alert alert-info alert-block'>
|
|
||||||
{% blocktrans with full_name=part.full_name%}Showing stock for all variants of <i>{{full_name}}</i>{% endblocktrans %}
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% include "stock_table.html" %}
|
|
||||||
|
|
||||||
{% endblock %}
|
|
||||||
|
|
||||||
{% block js_load %}
|
|
||||||
{{ block.super }}
|
|
||||||
{% endblock %}
|
|
||||||
{% block js_ready %}
|
|
||||||
{{ block.super }}
|
|
||||||
|
|
||||||
$('#add-stock-item').click(function () {
|
|
||||||
createNewStockItem({
|
|
||||||
reload: true,
|
|
||||||
data: {
|
|
||||||
part: {{ part.id }},
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
loadStockTable($("#stock-table"), {
|
|
||||||
params: {
|
|
||||||
part: {{ part.id }},
|
|
||||||
location_detail: true,
|
|
||||||
part_detail: true,
|
|
||||||
supplier_part_detail: true,
|
|
||||||
},
|
|
||||||
groupByField: 'location',
|
|
||||||
buttons: [
|
|
||||||
'#stock-options',
|
|
||||||
],
|
|
||||||
url: "{% url 'api-stock-list' %}",
|
|
||||||
});
|
|
||||||
|
|
||||||
$("#stock-export").click(function() {
|
|
||||||
launchModalForm("{% url 'stock-export-options' %}", {
|
|
||||||
submit_text: "{% trans 'Export' %}",
|
|
||||||
success: function(response) {
|
|
||||||
var url = "{% url 'stock-export' %}";
|
|
||||||
|
|
||||||
url += "?format=" + response.format;
|
|
||||||
url += "&cascade=" + response.cascade;
|
|
||||||
url += "&part={{ part.id }}";
|
|
||||||
|
|
||||||
location.href = url;
|
|
||||||
},
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
$('#item-create').click(function () {
|
|
||||||
createNewStockItem({
|
|
||||||
reload: true,
|
|
||||||
data: {
|
|
||||||
part: {{ part.id }},
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
{% endblock %}
|
|
@ -49,7 +49,6 @@ part_detail_urls = [
|
|||||||
url(r'^bom-duplicate/?', views.BomDuplicate.as_view(), name='duplicate-bom'),
|
url(r'^bom-duplicate/?', views.BomDuplicate.as_view(), name='duplicate-bom'),
|
||||||
|
|
||||||
url(r'^variants/?', views.PartDetail.as_view(template_name='part/variants.html'), name='part-variants'),
|
url(r'^variants/?', views.PartDetail.as_view(template_name='part/variants.html'), name='part-variants'),
|
||||||
url(r'^stock/?', views.PartDetail.as_view(template_name='part/stock.html'), name='part-stock'),
|
|
||||||
url(r'^allocation/?', views.PartDetail.as_view(template_name='part/allocation.html'), name='part-allocation'),
|
url(r'^allocation/?', views.PartDetail.as_view(template_name='part/allocation.html'), name='part-allocation'),
|
||||||
url(r'^bom/?', views.PartDetail.as_view(template_name='part/bom.html'), name='part-bom'),
|
url(r'^bom/?', views.PartDetail.as_view(template_name='part/bom.html'), name='part-bom'),
|
||||||
url(r'^build/?', views.PartDetail.as_view(template_name='part/build.html'), name='part-build'),
|
url(r'^build/?', views.PartDetail.as_view(template_name='part/build.html'), name='part-build'),
|
||||||
|
@ -235,7 +235,7 @@
|
|||||||
<td>{% trans "Base Part" %}</td>
|
<td>{% trans "Base Part" %}</td>
|
||||||
<td>
|
<td>
|
||||||
{% if roles.part.view %}
|
{% if roles.part.view %}
|
||||||
<a href="{% url 'part-stock' item.part.id %}">
|
<a href="{% url 'part-detail' item.part.id %}">
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{{ item.part.full_name }}
|
{{ item.part.full_name }}
|
||||||
{% if roles.part.view %}
|
{% if roles.part.view %}
|
||||||
@ -561,7 +561,7 @@ $("#stock-delete").click(function () {
|
|||||||
launchModalForm(
|
launchModalForm(
|
||||||
"{% url 'stock-item-delete' item.id %}",
|
"{% url 'stock-item-delete' item.id %}",
|
||||||
{
|
{
|
||||||
redirect: "{% url 'part-stock' item.part.id %}"
|
redirect: "{% url 'part-detail' item.part.id %}"
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user