cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

SAPUI5 - Controller function not call after change the view setting of macros table

linlin1
Associate
Associate
0 Likes
452

I have create a fragment.xml file to config my macros table like this:

<core:FragmentDefinition
xmlns="sap.m"
xmlns:core="sap.ui.core"
xmlns:macros="sap.fe.macros"
xmlns:macrosTable="sap.fe.macros.table"
>
<Dialog title="Dialog" id="idDialog">
<macros:FilterBar
metaPath="@com.sap.vocabularies.UI.v1.SelectionFields"
id="FilterBar"
liveMode="true"
/>
<macros:Table
id="DialogTable"
metaPath="changes/@UI.PresentationVariant#Dialog"
personalization="true"
readOnly="true"
isSearchable="true"
enableExport="true"
disableCopyToClipboard="true"
enableAutoColumnWidth="true"
headerVisible="false"
filterBar="FilterBar"
ignoredFields="up__ID"
>
<macros:columns>
<macrosTable:Column
header="Link"
id="link"
importance="High"
width="auto"
horizontalAlign="Begin"
key="link_id"
>
<Link
text="Currency"
press="onLinkPress"
/>
</macrosTable:Column>
</macros:columns>
</macros:Table>

</Dialog>
</core:FragmentDefinition>


The function onLinkPress is define in a controller which load this fragment. It still call onLinkPress success when open, reset or search in the dialog
 
But when I try to remove this link column from the dialog using column setting in personalization dialog and then add it again, the link not working, it not call the controller function
 loio33103ebf91424ae99f4a367dee83ddd0_LowRes.png

 

Accepted Solutions (0)

Answers (1)

Answers (1)

junwu
SAP Champion
SAP Champion
0 Likes

can you give it an id? not sure if it is going to help.

<Link
text="Currency"
press="onLinkPress"
/>

 

linlin1
Associate
Associate
0 Likes
I've added it but still have the same problem