glpi-project / glpi

GLPI is a Free Asset and IT Management Software package, Data center management, ITIL Service Desk, licenses tracking and software auditing.
https://glpi-project.org
GNU General Public License v3.0
4.14k stars 1.28k forks source link

[9.5-RC1] Empty planning when not in debug context #7393

Closed flegastelois closed 4 years ago

flegastelois commented 4 years ago

Describe the bug

Assistance > Planning view is only displayed when debug mode is active (whether the "advancedplanning" plugin is active or not doesn't change anything).

Logs

Javascript errors

fullcalendar.min.js?v=9.5.0-dev:134 Uncaught SyntaxError: Unexpected token ';'
file-type.min.js?v=9.5.0-dev:25 Uncaught SyntaxError: Missing initializer in destructuring declaration
main.js?v=0.1:630 Uncaught TypeError: Cannot read property 'Calendar' of undefined
    at main.js?v=0.1:630
    at main.js?v=0.1:10
    at main.js?v=0.1:11
(anonymous) @ main.js?v=0.1:630
(anonymous) @ main.js?v=0.1:10
(anonymous) @ main.js?v=0.1:11
main.js?v=0.1:289 Uncaught TypeError: Cannot read property 'ScrollComponent' of undefined
    at main.js?v=0.1:289
    at main.js?v=0.1:10
    at main.js?v=0.1:11
(anonymous) @ main.js?v=0.1:289
(anonymous) @ main.js?v=0.1:10
(anonymous) @ main.js?v=0.1:11
main.js?v=0.1:74 Uncaught TypeError: Cannot read property 'Component' of undefined
    at main.js?v=0.1:74
    at main.js?v=0.1:10
    at main.js?v=0.1:11
(anonymous) @ main.js?v=0.1:74
(anonymous) @ main.js?v=0.1:10
(anonymous) @ main.js?v=0.1:11
base.min.js?v=9.5.0-dev:78 jQuery.Deferred exception: FullCalendar is not defined ReferenceError: FullCalendar is not defined
    at Object.display (http://glpi.local/9.5-rc1/glpi/js/planning.min.js?v=9.5.0-dev:1:817)
    at HTMLDocument.<anonymous> (<anonymous>:5:23)
    at h (http://glpi.local/9.5-rc1/glpi/public/lib/base.min.js?v=9.5.0-dev:74:199)
    at f (http://glpi.local/9.5-rc1/glpi/public/lib/base.min.js?v=9.5.0-dev:76:81) undefined

Screenshots

image

image

trasher commented 4 years ago

As a workaround, you can remove public/lib/fullcalendar.min.js. It seems there is an issue with javascrit compression on this one.

ladenree76000 commented 4 years ago

in debug mode, export planning shows image

undefine index host in .../inc/planning.class.php at line 966