Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Bo Jacobsen 597 posts 2395 karma points
    Sep 29, 2023 @ 11:40
    Bo Jacobsen
    0

    umb-table column value fallback to another property value

    Hi all.

    We are trying to manipulate with the value shown in the columns in a node list view.

    We want to show a custom date from the property with alias altCreatedDate, but if that date is empty ro not selected, then we wanna show the createDate property value.

    enter image description here

    The above do not work, and the createDate is not ment to be shown on the list, but is only a reference to easier understand what we are trying to achieve.

    The list view uses umb-table and inside the umb-table.htlm is the umb-table-cel rendering:

     <div class="umb-table-cell" ng-repeat="column in vm.itemProperties track by column.alias">
                        <span title="{{column.header}}: {{item[column.alias].expression ? item[column.alias].expression({value: item[column.alias].value}) : item[column.alias]}}">
    
                            <div ng-if="!column.isSensitive">
                                {{item[column.alias].expression ? item[column.alias].expression({value: item[column.alias].value}) : item[column.alias]}}
                            </div>
    
                            <em ng-show="column.isSensitive" class="muted">
                                <localize key="content_isSensitiveValue_short">This value is hidden.</localize>
                            </em>
    
                        </span>
                    </div>
    

    The expression is checked with this:

    {{item[column.alias].expression ? item[column.alias].expression({value: item[column.alias].value}) : item[column.alias]}}
    

    But we are wondering if its possible somehow to do what we wanna do?

Please Sign in or register to post replies

Write your reply to:

Draft