Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

For Guilin inventory tree view extension (ODLUX Inventory enhancement with treeview) the data-provider (Data-Provider) is getting a new extension.

Goal:

  • Provide a function to analyse a database with inventory entries
  • Provide filter function to filter on device level or inside device at different tree-level
  • The function provides back tree lists of inventory id's  according to given filter
  • Additionally a correlation to equipment alarm severity is provided.
  • The id's of the result can be used for data-provider's request to get the concrete data

Characteristics:

  • Additional URL "/tree/read-inventory-tree"
  • The request provides back a list of equipment id's according to the request filter
  • Two filter levels:
    1. URL path : Points to a subtree of elements that are search by filter in query-body
    2. query-body with textual or field specific search.
  • Delivers back all inventory id's for the given URL/path query-body filter
  • Use data-provider api "inventoryequipment" to get inventory data for an id

Extension of data-provider Web-API in Guilin:

POST tree level entryScope
/tree/read-inventory-tree/

...

All equipment entries in the database
/tree/read-inventory-tree/{nodeId}

...

All Equipment under node with "nodeId"
/tree

...

/read-inventory-tree/{nodeId}/{uuid-level-0}/...All Equipment under node "nodeId" and next level equipment with "uuid-level-0"

Example 1: Query with text

Code Block
{
    "query":"2143524123"
    
}

=> Elasticsearch Example 2: Converted to an database (Elasticsearch) query (search through all properties)

Code Block
POST /alias/doctype/_search
{
  "query": {
    "query_string": {
      "default_field": "*",
      "query": "*searchfor*"
    }
  }
}

Example 3: Response:

key-level-n => databaseId

Code Block
languagejs
linenumberstrue
{
     "{key-level-0}":{
         "label":"1.0 Shelf",
         "children?":{
             "{key-level-1}": {
                 ...
             }
         },
         "isMatch":true,
         "ownSeverity?":"major",
         "childrenSeveritySummary?":"minor"
     }
}
  • "{key-level-0}" : databaseId to be used for data-provider api "inventoryequipment" to get all information
  • "isMatch" : ??
  • "{key-level-0}": Actual severity of this piece of matching equipment
  • "childrenSeveritySummary?": Actual severity level of child equipment