[ 
https://issues.apache.org/jira/browse/OFBIZ-13150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17890849#comment-17890849
 ] 

Jacques Le Roux edited comment on OFBIZ-13150 at 10/18/24 8:04 AM:
-------------------------------------------------------------------

I found at least 
myportal/control/ManagePortalPages?parentPortalPageId=PartyProfile. I guess 
there could be more.

[~nmalin] here is  [^OFBIZ-13150.patch]  that fixes the problem. Maybe rather a 
workaround, that's why I did not push. I prefer your review since you made the 
migration and are more knowing the whole thing around PortalPage migration.

The error message says that there is no copyIfRequiredSystemPage() in 
PortalPageMethods. That's right, copyIfRequiredSystemPage() is in 
PortalPageServices. Both are in org.apache.ofbiz.common. I believe because 
PortalPageServices is not a class, only methods, you can"t use private methods 
there, same in PortalPageMethods. It even seems that you need to declare a 
[Groovy trait to allow use of private 
methods|https://groovy-lang.org/objectorientation.html#_private_methods].

I don't know why PortalPageMethods was "preferred" by Groovy, maybe because it 
appears before when compiling Groovy? Anyway,  I moved both "private" methods  
to PortalPageMethods and make some modifications for the whole to work.

TIA for your review, please take it easy, no hurry, not a big deal as it works 
anyway :)


was (Author: jacques.le.roux):
I found at least 
myportal/control/ManagePortalPages?parentPortalPageId=PartyProfile. I guess 
there could be more.

[~nmalin] here is a patch that fixes the problem. Maybe rather a workaround, 
that's why I did not push. I prefer your review since you made the migration 
and are more knowing the whole thing around PortalPage migration.

The error message says that there is no copyIfRequiredSystemPage() in 
PortalPageMethods. That's right, copyIfRequiredSystemPage() is in 
PortalPageServices. Both are in org.apache.ofbiz.common. I believe because 
PortalPageServices is not a class, only methods, you can"t use private methods 
there, same in PortalPageMethods. It even seems that you need to declare a 
[Groovy trait to allow use of private 
methods|https://groovy-lang.org/objectorientation.html#_private_methods].

I don't know why PortalPageMethods was "preferred" by Groovy, maybe because it 
appears before when compiling Groovy? Anyway,  I moved both "private" methods  
to PortalPageMethods and make some modifications for the whole to work.

TIA for your review, please take it easy, no hurry, not a big deal as it works 
anyway :)

> example/control/ManagePortalPages?parentPortalPageId=EXAMPLE works but 
> reports an error
> ---------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-13150
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-13150
>             Project: OFBiz
>          Issue Type: Bug
>          Components: example
>    Affects Versions: Upcoming Branch, 24.09
>            Reporter: Jacques Le Roux
>            Priority: Major
>         Attachments: OFBIZ-13150.patch
>
>
> The error is
> {quote}No signature of method: 
> org.apache.ofbiz.common.PortalPageMethods.copyIfRequiredSystemPage() is 
> applicable for argument types: () values: []
> {quote}
> It's part of PortalPageServices.groovy and could be a consequence of  
> OFBIZ-13091



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to