RE: Calendar Portlet Customization

تم تعديل Mohamed Saleem منذ 2 سنوات من الدقائق. Junior Member المشاركات: 40 تاريخ الإنضمام: 16‏/12‏/15 المشاركات الحديثة

Hi,

I have written code for Calendar portlet customization is working in 7.2 but not working in 7.4. 

@Component(property = { "javax.portlet.name=com_liferay_calendar_web_portlet_CalendarPortlet",
    "mvc.command.name=updateFormCalendarBooking", "service.ranking:Integer=101" }, service = MVCActionCommand.class)
public class CalendarUpdateAction extends BaseMVCActionCommand {

 

  @Override
  protected void doProcessAction(ActionRequest actionRequest, ActionResponse actionResponse) throws Exception {

        System.out.println("my customization");

}

 if anyone knows please help me.

Thanks,

Saleem.

 

thumbnail
تم تعديل Roselaine Marques منذ 2 سنوات من الدقائق. New Member المشاركات: 13 تاريخ الإنضمام: 13‏/4‏/20 المشاركات الحديثة

Hi Mohamed, 

Here as you can see the "updateFormCalendarBooking" is implemented inside the Portlet component, not as MVCActionCommand, which means you can't override as MVCActionCommand + service ranking. 

I was wondering, don't you have the JSP Fragment invoking this MVCActionCommand in 7.2?

thumbnail
تم تعديل Olaf Kock منذ 2 سنوات من الدقائق. Liferay Legend المشاركات: 6441 تاريخ الإنضمام: 23‏/9‏/08 المشاركات الحديثة

I'm not confident that it shouldn't be possible: It has always been implemented this way (e.g. here the 7.2 implementation), and MVCActionCommands should have precedence if I'm not mistaken...

Check if your plugin is actually deployed (use Gogo shell)

Also, I see that the 7.4 calendar portlet opts for portletspec 3. Maybe this is the reason for changed behavior... If that was the case, I'd call it a bug. But as of now it's only a guess to check.

تم تعديل Mohamed Saleem منذ 2 سنوات من الدقائق. Junior Member المشاركات: 40 تاريخ الإنضمام: 16‏/12‏/15 المشاركات الحديثة

 Hi,

Both the modules are deployed, but not invoking the service in 7.4 only

can you please tell me is there other way to customize this calendar portlet component?

 

Thanks,

Saleem.