mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-10-31 13:15:43 +00:00 
			
		
		
		
	JS translation fix (#6288)
* Implement {% jstrans %} template
- Forces string escaping in translated text
- Required for js written in templates
* Fix part_base.html
* Update .html files
- Change any templated javascript code to use {% jstrans %}
* Update .js files
- Explicitly use {% jstrans %}
* Update CI checks
			
			
This commit is contained in:
		| @@ -270,7 +270,7 @@ src="{% static 'img/blank_image.png' %}" | ||||
|             '{% url "api-build-detail" build.pk %}', | ||||
|             { | ||||
|                 method: 'DELETE', | ||||
|                 title: '{% trans "Delete Build Order" %}', | ||||
|                 title: '{% jstrans "Delete Build Order" %}', | ||||
|                 redirect: "{% url 'build-index' %}", | ||||
|             } | ||||
|         ); | ||||
| @@ -280,7 +280,7 @@ src="{% static 'img/blank_image.png' %}" | ||||
|     <!-- Barcode functionality callbacks --> | ||||
|     $('#show-qr-code').click(function() { | ||||
|         showQRDialog( | ||||
|             '{% trans "Build Order QR Code" %}', | ||||
|             '{% jstrans "Build Order QR Code" %}', | ||||
|             '{"build": {{ build.pk }} }' | ||||
|         ); | ||||
|     }); | ||||
| @@ -292,7 +292,7 @@ src="{% static 'img/blank_image.png' %}" | ||||
|                 build: {{ build.pk }}, | ||||
|             }, | ||||
|             { | ||||
|                 title: '{% trans "Link Barcode to Build Order" %}', | ||||
|                 title: '{% jstrans "Link Barcode to Build Order" %}', | ||||
|             } | ||||
|         ); | ||||
|     }); | ||||
|   | ||||
| @@ -419,8 +419,8 @@ function allocateSelectedLines() { | ||||
|  | ||||
|     if (unallocated_lines.length == 0) { | ||||
|         showAlertDialog( | ||||
|             '{% trans "Allocation Complete" %}', | ||||
|             '{% trans "All lines have been fully allocated" %}', | ||||
|             '{% jstrans "Allocation Complete" %}', | ||||
|             '{% jstrans "All lines have been fully allocated" %}', | ||||
|         ); | ||||
|     } else { | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user