Fluidic (Piping/HVAC) BOM Table Template Business Rule (Piping_Entity_Category)

An opening ID is an entry point used to customize business logic. The Piping_Entity_Category business rule opening ID is used to group piping entities by categories: such as Category Branches, Category Fittings, Category Flanges.

Note: For more information about customization by business rules, see Installation and Setup: Customize: Behavior: Data Setup: Customization by Business Rules.

This page discusses:

General Information

This opening ID is invoked during the creation of a Piping or a HVAC BOM table template.

It creates an arbitrary classification of parts in Branches, Fittings, Flanges, Valves, Instruments, Legacy (old V5 data model), Welds.

Customizing this rule lets you to implement different grouping rule for parts, or to do grouping of pipes (rigid or flexible).

Sample

Result = NULL

let PipingPartObject(Piping_Part)
let PipingPipeObject(Piping_Pipe)
let PipingSpoolObject(Piping_Spool)
set PipingPartObject  = ThisObject.Reference
set PipingPipeObject  = ThisObject.Reference
set PipingSpoolObject = ThisObject.Reference

if (PipingPartObject <> NULL)
{
  // Categories depends on the object type
  let TypeName(String)
  TypeName = PipingPartObject.PrimaryType.Name
  
  // Branches
  if (TypeName == "Piping_Tee" OR TypeName == "Piping_Cross" OR TypeName == "Piping_Olet") 
  {
    Result = "Category_Branches"
  }
  // Fittings
  else if (TypeName == "Piping_Elbow" OR TypeName == "Piping_Cap" OR TypeName == "Piping_Reducer" OR 
    TypeName == "Piping_Union" OR TypeName == "Piping_Coupling" OR TypeName == "Piping_Gasket")
  {
    Result = "Category_Fittings"
  }
  // Flanges
  else if (TypeName == "Piping_Flange")
  {
    Result = "Category_Flanges"
  }
  // Valves
  else if (TypeName == "Piping_Valve")
  {
    Result = "Category_Valves"
  }
  // Instruments
  else if (TypeName == "Piping_Instrument")
  {
    Result = "Category_Instruments"
  }
  // Legacy
  else if (TypeName == "Piping_PartV1")
  {
    Result = "Category_Legacy"
  }
  // If type is not known, put it into Fittings
  else
  {
    Result = "Category_Fittings"
  }
  
  // Be sure to have setup the correct NLS for categories
}
else if (PipingPipeObject <> NULL)
{
  // In case it is a Piping pipe, the category is simply "Piping_Pipe"
  Result = "Category_Pipes"
  
  // Here it is possible to make distinctions. For example to make distinction between Rigid Pipes and Flexible Pipes
}
else if (PipingSpoolObject <> NULL)
{
  // In case it is a Piping spool, the category is simply "Piping_Spool"
  Result = "Category_Spools"
  
}

//Message("Result: ", Result)