xpages view panel column multivalue separator

前端 未结 1 1951
情话喂你
情话喂你 2021-01-20 12:48

There is a column from a view which have the multi-value separator the new line.

\"enter

相关标签:
1条回答
  • 2021-01-20 13:33

    You have to use customConverter here. Because convertList takes only one character as the seperator.

    <xp:viewColumn
        columnName="SomeColumn"
        id="viewColumn1"
        contentType="html">
        <xp:this.converter>
            <xp:customConverter getAsObject="#{javascript:return value;}">
                <xp:this.getAsString>
                    <![CDATA[#{javascript:return @Implode(value, "<br/>")}]]>
                </xp:this.getAsString>
            </xp:customConverter>
        </xp:this.converter>
        <xp:viewColumnHeader
            value="Header"
            id="viewColumnHeader1">
        </xp:viewColumnHeader>
    </xp:viewColumn>
    

    We are imploding values by <br/> string and providing content type so it won't escape the html output.

    0 讨论(0)
提交回复
热议问题