I try to enable vertical resource view in Odoo 16 calendar.
I did:
npm install --save @fullcalendar/core @fullcalendar/resource @fullcalendar/resource-timegrid`
and put an import statement in web/static/src/views/calendar/hooks.js like
async function loadJsFiles() {
const files = \[
"/web/static/lib/fullcalendar/core/main.js",
"/web/static/lib/fullcalendar/interaction/main.js",
"/web/static/lib/fullcalendar/daygrid/main.js",
"/web/static/lib/fullcalendar/luxon/main.js",
"/web/static/lib/fullcalendar/timegrid/main.js",
"/web/static/lib/fullcalendar/list/main.js",
"/web/static/lib/fullcalendar/node_modules/@fullcalendar/resource-daygrid/index.js",
\];
for (const file of files) {
await loadJS(file);
}
}
When I run this, I always get
SyntaxError: Cannot use import statement outside a module
I don't know what I'm doing wrong. Does anyone know what is wrong or can anyone explain how to implement fullcalender vertical resource view in Odoo 16? I know that I have to call the resource plugin with options in "web/static/src/views/calendar/calendar_common/calendar_common_renderer.js", but at the moment I can't even load the js file.
sorry, i just saw that odoo 16 comes with fullcalendar 4.4.0. i did
npm install --save @fullcalendar/core @fullcalendar/resource @fullcalendar/resource-timegrid` and fullcalendar premium 6.x.x was installed.So it could not work. now i have another problem: the daily resources are displayed correctly but i can see now time values or a grid