2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-05-03 13:58:47 +00:00

Prevent newline chars from breaking part detail page (#3245)

This commit is contained in:
Oliver 2022-06-23 14:23:07 +10:00 committed by GitHub
parent f9aa5a60fd
commit 5196fd5546
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -966,7 +966,7 @@
{% if bom_parts %} {% if bom_parts %}
var bom_colors = randomColor({hue: 'green', count: {{ bom_parts|length }} }) var bom_colors = randomColor({hue: 'green', count: {{ bom_parts|length }} })
var bomdata = { var bomdata = {
labels: [{% for line in bom_parts %}'{{ line.name }}',{% endfor %}], labels: [{% for line in bom_parts %}'{{ line.name|escapejs }}',{% endfor %}],
datasets: [ datasets: [
{ {
label: 'Price', label: 'Price',