Hi,
I am newbe to web programming,
I have tried to import primeng 4.x and change dependencies to this version in Omega Layout, and I have got a compilation problem.
In menu.component.ts, there is a class named AppSubMenu, who has a MunuItem attribute called item.
In version 2.x MenuItem had an attribute called eventEmitter of type EventEmitter that DOES NOT exists in version 4.x
How can I migrate Omega Layout to primeng version 4.X?
Thanks
Eduard Escrihuela
Migrating Omega Layout to primeng version 4.x
Forum rules
Please note that response time for technical support is within 3-5 business days.
Please note that response time for technical support is within 3-5 business days.
-
- Posts: 2
- Joined: 30 Jun 2017, 14:06
Hi,
maybe this is not the correct answer, but changing this code I have run out of compilation problems.
The file is menu-component.ts and the class is AppSubmenu and the changed method is itemClick
OLD CODE:
===================================================
if(!item.eventEmitter) {
item.eventEmitter = new EventEmitter();
item.eventEmitter.subscribe(item.command);
}
item.eventEmitter.emit({
originalEvent: event,
item: item
});
NEW CODE:
====================
let eventEmitter = new EventEmitter();
eventEmitter.subscribe(item.command);
eventEmitter.emit({
originalEvent: event,
item: item
});
====================
As the new MenuItem definition has not an eventEmitter included, I presume defining an EventEmitter object out of the MenuDefinition.
I don't know if it is ok or not .
Thanks
Eduard Escrihuela
maybe this is not the correct answer, but changing this code I have run out of compilation problems.
The file is menu-component.ts and the class is AppSubmenu and the changed method is itemClick
OLD CODE:
===================================================
if(!item.eventEmitter) {
item.eventEmitter = new EventEmitter();
item.eventEmitter.subscribe(item.command);
}
item.eventEmitter.emit({
originalEvent: event,
item: item
});
NEW CODE:
====================
let eventEmitter = new EventEmitter();
eventEmitter.subscribe(item.command);
eventEmitter.emit({
originalEvent: event,
item: item
});
====================
As the new MenuItem definition has not an eventEmitter included, I presume defining an EventEmitter object out of the MenuDefinition.
I don't know if it is ok or not .
Thanks
Eduard Escrihuela
Hi ,
We will update all layouts to 4.2.x of angular and 4.1.x of primeng soon.
Regards
We will update all layouts to 4.2.x of angular and 4.1.x of primeng soon.
Regards
-
- Information
-
Who is online
Users browsing this forum: No registered users and 1 guest