Openbravo Issue Tracking System - POS2
View Issue Details
0049534POS2POSpublic2022-06-10 15:002022-06-10 15:03
adrianromero 
Retail 
normalminorhave not tried
newopen 
5
 
 
No
0049534: Errors in console when opening the application story book
When opening storybook for POS2, the console shows the following errors:

https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/?path=/story/platform-app--show-app [^]

vendors~main.11471469.iframe.bundle.js:2 Unexpected error while loading ./components/SafeboxHistory/SafeboxHistoryPrintButton/stories/SafeboxHistoryPrintButton.stories.jsx: jest is not defined
 ReferenceError: jest is not defined
    at ../../../org.openbravo.pos2/web-jspack/org.openbravo.pos2/src/components/SafeboxHistory/SafeboxHistoryPrintButton/stories/SafeboxHistoryPrintButton.stories.jsx (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/main.19bd8cd8.iframe.bundle.js:1:1919382 [^])
    at __webpack_require__ (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/runtime~main.0d092830.iframe.bundle.js:1:1301 [^])
    at webpackContext (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/main.19bd8cd8.iframe.bundle.js:1:339111 [^])
    at https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/vendors~main.11471469.iframe.bundle.js:2:984958 [^]
    at Array.forEach (<anonymous>)
    at https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/vendors~main.11471469.iframe.bundle.js:2:984910 [^]
    at Array.forEach (<anonymous>)
    at executeLoadable (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/vendors~main.11471469.iframe.bundle.js:2:984876 [^])
    at executeLoadableForChanges (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/vendors~main.11471469.iframe.bundle.js:2:985718 [^])
    at Object.getProjectAnnotations [as nextFn] (https://livebuilds.openbravo.com/retail_pos2_modules_pgsql/web/storybook/vendors~main.11471469.iframe.bundle.js:2:990177 [^])
error @ vendors~main.11471469.iframe.bundle.js:2
main.19bd8cd8.iframe.bundle.js:1 Uncaught (in promise) Error: Cannot find module './org.openbravo.retail.multiupc/web-jspack/org.openbravo.retail.multiupc/src/assets/style/main.scss'
    at main.19bd8cd8.iframe.bundle.js:1:1948
main.19bd8cd8.iframe.bundle.js:1 Uncaught (in promise) Error: Cannot find module './org.openbravo.certification.france/web-jspack/org.openbravo.certification.france/src/assets/style/main.scss'
    at main.19bd8cd8.iframe.bundle.js:1:1948
In description
In SafeboxHistoryPrintButton.stories.jsx

replace

 const mockPrintSafeboxCashupHistory = jest.fn();

by
 
 const mockPrintSafeboxCashupHistory = () => {};

In org.openbravo.retail.multiupc and org.openbravo.certification.france add a new file src/assets/style/main.scss
No tags attached.
Issue History
2022-06-10 15:00adrianromeroNew Issue
2022-06-10 15:00adrianromeroAssigned To => Retail
2022-06-10 15:00adrianromeroTriggers an Emergency Pack => No
2022-06-10 15:03adrianromeroProposed Solution updated

There are no notes attached to this issue.