Page 1 of 1

Typo in js file breaks Supplier and Contracts Editor

Posted: 08 Jun 2023, 12:36
by liamdennehy
In the file editors/enterprise/supplier-editor/core_supplier_editor.js for EssentialCloud viewer v6.18.1, an error is thrown on loading:

Code: Select all

core_supplier_editor.js:2264 Uncaught (in promise) ReferenceError: aSupp is not defined
    at core_supplier_editor.js:2264:76
    at Array.find (<anonymous>)
    at initSupplierEditorTab (core_supplier_editor.js:2264:54)
    at core_supplier_editor.js:4082:9
line 2264 of that file contains a reference to the "aUpp" object:

Code: Select all

currentSupplier = supplierJSON[ 'suppliers'].find(aUpp => aSupp.id == initialSupplierId);
Comparing this with line 2279, it seems this should be "aSupp":

Code: Select all

currentSupplier = supplierJSON[ 'suppliers'].find(aSupp => aSupp.id == supplierId);

Re: Typo in js file breaks Supplier and Contracts Editor

Posted: 09 Jun 2023, 09:32
by jasonp
Thanks for bringing this to our attention.Looking at the location of the error, I presume that this is only causing an issue when accessing the editor from a Viewer menu.

The team have made the fix which will be available in our June monthly release.

Jason