mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Remove REPORT_ENABLE_TEST_REPORT setting
This commit is contained in:
parent
0ee8560eff
commit
6d8620c427
@ -1704,12 +1704,6 @@ class InvenTreeSetting(BaseInvenTreeSetting):
|
|||||||
'default': 'A4',
|
'default': 'A4',
|
||||||
'choices': report.helpers.report_page_size_options,
|
'choices': report.helpers.report_page_size_options,
|
||||||
},
|
},
|
||||||
'REPORT_ENABLE_TEST_REPORT': {
|
|
||||||
'name': _('Enable Test Reports'),
|
|
||||||
'description': _('Enable generation of test reports'),
|
|
||||||
'default': True,
|
|
||||||
'validator': bool,
|
|
||||||
},
|
|
||||||
'SERIAL_NUMBER_GLOBALLY_UNIQUE': {
|
'SERIAL_NUMBER_GLOBALLY_UNIQUE': {
|
||||||
'name': _('Globally Unique Serials'),
|
'name': _('Globally Unique Serials'),
|
||||||
'description': _('Serial numbers for stock items must be globally unique'),
|
'description': _('Serial numbers for stock items must be globally unique'),
|
||||||
|
@ -228,9 +228,6 @@ class SettingsTest(InvenTreeTestCase):
|
|||||||
report_size_obj = InvenTreeSetting.get_setting_object(
|
report_size_obj = InvenTreeSetting.get_setting_object(
|
||||||
'REPORT_DEFAULT_PAGE_SIZE'
|
'REPORT_DEFAULT_PAGE_SIZE'
|
||||||
)
|
)
|
||||||
report_test_obj = InvenTreeSetting.get_setting_object(
|
|
||||||
'REPORT_ENABLE_TEST_REPORT'
|
|
||||||
)
|
|
||||||
|
|
||||||
# check settings base fields
|
# check settings base fields
|
||||||
self.assertEqual(instance_obj.name, 'Server Instance Name')
|
self.assertEqual(instance_obj.name, 'Server Instance Name')
|
||||||
@ -260,7 +257,6 @@ class SettingsTest(InvenTreeTestCase):
|
|||||||
|
|
||||||
# check setting_type
|
# check setting_type
|
||||||
self.assertEqual(instance_obj.setting_type(), 'string')
|
self.assertEqual(instance_obj.setting_type(), 'string')
|
||||||
self.assertEqual(report_test_obj.setting_type(), 'boolean')
|
|
||||||
self.assertEqual(stale_days.setting_type(), 'integer')
|
self.assertEqual(stale_days.setting_type(), 'integer')
|
||||||
|
|
||||||
# check as_int
|
# check as_int
|
||||||
@ -269,9 +265,6 @@ class SettingsTest(InvenTreeTestCase):
|
|||||||
instance_obj.as_int(), 'InvenTree'
|
instance_obj.as_int(), 'InvenTree'
|
||||||
) # not an int -> return default
|
) # not an int -> return default
|
||||||
|
|
||||||
# check as_bool
|
|
||||||
self.assertEqual(report_test_obj.as_bool(), True)
|
|
||||||
|
|
||||||
# check to_native_value
|
# check to_native_value
|
||||||
self.assertEqual(stale_days.to_native_value(), 0)
|
self.assertEqual(stale_days.to_native_value(), 0)
|
||||||
|
|
||||||
|
@ -54,19 +54,15 @@
|
|||||||
</div>
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<!-- Document / label menu -->
|
<!-- Document / label menu -->
|
||||||
{% if test_report_enabled or labels_enabled %}
|
|
||||||
<div class='btn-group' role='group'>
|
<div class='btn-group' role='group'>
|
||||||
<button id='document-options' title='{% trans "Printing actions" %}' class='btn btn-outline-secondary dropdown-toggle' type='button' data-bs-toggle='dropdown'><span class='fas fa-print'></span> <span class='caret'></span></button>
|
<button id='document-options' title='{% trans "Printing actions" %}' class='btn btn-outline-secondary dropdown-toggle' type='button' data-bs-toggle='dropdown'><span class='fas fa-print'></span> <span class='caret'></span></button>
|
||||||
<ul class='dropdown-menu' role='menu'>
|
<ul class='dropdown-menu' role='menu'>
|
||||||
{% if labels_enabled %}
|
{% if labels_enabled %}
|
||||||
<li><a class='dropdown-item' href='#' id='print-label'><span class='fas fa-tag'></span> {% trans "Print Label" %}</a></li>
|
<li><a class='dropdown-item' href='#' id='print-label'><span class='fas fa-tag'></span> {% trans "Print Label" %}</a></li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if test_report_enabled %}
|
<li><a class='dropdown-item' href='#' id='stock-test-report'><span class='fas fa-file-pdf'></span> {% trans "Print Report" %}</a></li>
|
||||||
<li><a class='dropdown-item' href='#' id='stock-test-report'><span class='fas fa-file-pdf'></span> {% trans "Test Report" %}</a></li>
|
|
||||||
{% endif %}
|
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
<!-- Stock adjustment menu -->
|
<!-- Stock adjustment menu -->
|
||||||
{% if user_owns_item %}
|
{% if user_owns_item %}
|
||||||
|
@ -18,7 +18,6 @@
|
|||||||
{% include "InvenTree/settings/setting.html" with key="REPORT_DEFAULT_PAGE_SIZE" icon="fa-print" %}
|
{% include "InvenTree/settings/setting.html" with key="REPORT_DEFAULT_PAGE_SIZE" icon="fa-print" %}
|
||||||
{% include "InvenTree/settings/setting.html" with key="REPORT_DEBUG_MODE" icon="fa-laptop-code" %}
|
{% include "InvenTree/settings/setting.html" with key="REPORT_DEBUG_MODE" icon="fa-laptop-code" %}
|
||||||
{% include "InvenTree/settings/setting.html" with key="REPORT_LOG_ERRORS" icon="fa-exclamation-circle" %}
|
{% include "InvenTree/settings/setting.html" with key="REPORT_LOG_ERRORS" icon="fa-exclamation-circle" %}
|
||||||
{% include "InvenTree/settings/setting.html" with key="REPORT_ENABLE_TEST_REPORT" icon="fa-vial" %}
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
@ -161,8 +161,7 @@ export default function SystemSettings() {
|
|||||||
'REPORT_ENABLE',
|
'REPORT_ENABLE',
|
||||||
'REPORT_DEFAULT_PAGE_SIZE',
|
'REPORT_DEFAULT_PAGE_SIZE',
|
||||||
'REPORT_DEBUG_MODE',
|
'REPORT_DEBUG_MODE',
|
||||||
'REPORT_LOG_ERRORS',
|
'REPORT_LOG_ERRORS'
|
||||||
'REPORT_ENABLE_TEST_REPORT'
|
|
||||||
]}
|
]}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user