In a script, I call:
def currentUser = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser()
Seems to work just fine in:
def eitherRequestTypes = requestTypeService.getRequestTypes(currentUser, requestTypeQuery)
But, later on, I call:
def portal = portalService.getPortalForProject(currentUser, portalId)
This gives me an error:
No signature of method: com.atlassian.servicedesk.internal.feature.customer.portal.PortalServiceImpl.getPortalForProject() is applicable for argument types: (com.atlassian.jira.user.DelegatingApplicationUser, java.lang.Integer)
What? :) Do I cast it? Should I have used another way to get an ApplicationUser? Why does it work in one method that has the same signature as another in the same software?
Hello @Paul Tiseo
There is problem not in ApplicationUser.
getPortalForProject need AplicationUser and Project object, but you input Integer.
Yes! You got it. The error was misleading me. I was calling getPortalForProject() instead of getPortalForId().
(You are making lots of points off of me this week! :) )
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hehe :) feel free to ask! Did my answer about get transition ids and names help you?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I haven't had the time to drill down on that one yet. Probably this week.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey Paul,
How do you get the portalService ?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think you were on the right track. I was using the wrong method by mistake, but the error was taking me elsewhere.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.