Forum Discussion

Bhushan_Wankhede's avatar
2 years ago

Hi All, I am trying to get level from Xclassification tree can you suggest any way to get that whole path.

please find attached screenshot for your reference i need to get the whole path under level tag from classification tree,
 

5 Replies

  • Hi

    You want to create a classification for Itemtype in this manner or you need this way of heirarchy in Relationship Tab?

    Thanks

    Abhishek 

    • srmorrison's avatar
      srmorrison
      Ideator I

      Hi,

      You are asking a good question and I'm not sure how to do it yet.

      xClassifcationTree does not use relationship to manage the structure.

      The challenge here is to be able to access and filter the data in the property;

           xClassifcationTree.classification_hierarchy.

           ?? Is there a Utility or code set available to manage this??

      This would be need to be accessed/used if you want to:

        1) Change the xClass Tree order; as you develop the tree.

        2) Programmatically get the path

        >>> I tried re-setting the xClass.sort_order in the SQL tables but it did not work.

      What I am trying to get around this complication is to set the name of the xClass nodes as the path.

      "Packaging"

         "Packaging_Carton"

              "Packaging_Carton_Tube"

      I'm also setting the leaf node label "Packaging \ Carton \ Tube"

           This also makes the selected class easier to read when set on Part, Document, CAD, etc

      Both cases the there is a delimiter: "_" (Hierarchy) and " \ " (Hierarchy)

      The Data model allows 128 characters for the Label and 64 for the name.

      To support the discussion I have added 2 snaps below. (I think they are pretty close)

      Data Model:

      Javascript Model:

      I hope this helps to support the conversation.

      Regards

      Scott

      • srmorrison's avatar
        srmorrison
        Ideator I

        Here is a corrected data model.

        Also. I proved out, manually, that the order of the presentation of the xClass is managed by the classification_hierarchy property values.