Changeset 7774


Ignore:
Timestamp:
Feb 17, 2020, 1:41:34 PM (22 months ago)
Author:
Nicklas Nordborg
Message:

References #2202: Include information from parent items in list pages

Implemented nice formatting of parent item filtering in item list synchronization filters.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/core/net/sf/basedb/util/formatter/PropertyFilterFormatter.java

    r7565 r7774  
    8383   
    8484    StringBuilder sb = new StringBuilder();
     85   
     86    if (property.startsWith("/"))
     87    {
     88      // Parent item filter
     89      String[] tmp = property.split("/");
     90      int subtypeId = Values.getInt(tmp[2]);
     91      property = tmp[3];
     92      sb.append(function("parent")).append("(");
     93      sb.append(value(nameOfItem(dc, Item.ITEMSUBTYPE, subtypeId, false)));
     94      sb.append(")");
     95      if (!property.startsWith("#")) sb.append(".");
     96    }
     97   
    8598    if (property.startsWith("#"))
    8699    {
Note: See TracChangeset for help on using the changeset viewer.