[MGNLUI-6044] LinkField to M5 app not working in detail sub apps Created: 14/Jul/20  Updated: 21/Sep/20  Resolved: 29/Jul/20

Status: Closed
Project: Magnolia UI
Component/s: None
Affects Version/s: None
Fix Version/s: 6.2.2

Type: Bug Priority: Neutral
Reporter: Adam Siska Assignee: Adam Siska
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File link-field-configuration.png    
Issue Links:
Issue split
split from MGNLUI-5919 linkField from M6 to M5 app too compl... Closed
causality
relation
is related to MGNLCT-156 M6 contentTypes can reference M5 cont... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Sprint: UI FW 6
Story Points: 0

 Description   

Related to MGNLUI-5919

definitions with old apps in appName parameter should work with provided fix:

    article:
      $type: linkField
      chooser:
        workbenchChooser:          
          appName: categories


 Comments   
Comment by Adam Siska [ 27/Jul/20 ]

It's here: https://jira.magnolia-cms.com/browse/MGNLUI-5919?focusedCommentId=225493&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-225493, copied to the description, too.

Comment by Christopher Zimmermann [ 28/Jul/20 ]

I guess there is a default 'class' under the workbenchChooser node? What is it?

Comment by Christopher Zimmermann [ 28/Jul/20 ]

I am getting exception when I click the "Select" button to launch the chooser in my app.

It is an M6 app. It has the following configuration for the field:

 

 

2020-07-28 14:24:52,998 WARN  uddyMutableWrapperHelper$BeanPropertyMethodInvoker: Failed to invoke a fallback getDatasource call due to a reflection operation problem: null, returning null
java.lang.reflect.InvocationTargetException: null
	at sun.reflect.GeneratedMethodAccessor814.invoke(Unknown Source) ~[?:?]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_151]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_151]
	at info.magnolia.config.ByteBuddyMutableWrapperHelper$BeanPropertyMethodInvoker.invokeGetter(ByteBuddyMutableWrapperHelper.java:308) ~[magnolia-configuration-6.2.2.jar:?]
	at info.magnolia.config.ByteBuddyMutableWrapperHelper$BeanPropertyMethodInvoker.invoke(ByteBuddyMutableWrapperHelper.java:263) ~[magnolia-configuration-6.2.2.jar:?]
	at info.magnolia.config.ByteBuddyMutableWrapperHelper$DefaultInterceptor.intercept(ByteBuddyMutableWrapperHelper.java:213) ~[magnolia-configuration-6.2.2.jar:?]
Comment by Christopher Zimmermann [ 28/Jul/20 ]

Hmm, it does work when I apply it on Contacts-v8, but not when I try to apply it to a content-types based tours app.

Comment by Christopher Zimmermann [ 28/Jul/20 ]

Nevermind. Strange it is working now after a reboot. I used this in the app definition to get the link field working in a content-type generated app:

subApps:
  detail:
    form:
      properties:        
        link2:
          chooser:
            workbenchChooser: !override
              appName: categories
              #class: info.magnolia.ui.contenttype.chooser.ContentTypeAppAwareWorkbenchChooserDefinition

Generated at Mon Feb 12 09:32:36 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.