@itwin/grouping-mapping-widget 0.32.0 → 0.33.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/components/Groups/QueryBuilder/QueryBuilder.d.ts +7 -3
- package/lib/cjs/components/Groups/QueryBuilder/QueryBuilder.js +41 -12
- package/lib/cjs/components/Groups/QueryBuilder/QueryBuilder.js.map +1 -1
- package/lib/cjs/components/Properties/PropertyAction.js +7 -2
- package/lib/cjs/components/Properties/PropertyAction.js.map +1 -1
- package/lib/cjs/components/customUI/GroupQueryBuilderCustomUI.js +1 -1
- package/lib/cjs/components/customUI/GroupQueryBuilderCustomUI.js.map +1 -1
- package/lib/cjs/test/QueryBuilder.test.js +17 -6
- package/lib/cjs/test/QueryBuilder.test.js.map +1 -1
- package/lib/cjs/test/QueryBuilder.testdata.js +46 -0
- package/lib/cjs/test/QueryBuilder.testdata.js.map +1 -1
- package/lib/cjs/test/QueryBuilderTestData.d.ts +2 -2
- package/lib/cjs/test/QueryBuilderTestData.js.map +1 -1
- package/lib/esm/components/Groups/QueryBuilder/QueryBuilder.d.ts +7 -3
- package/lib/esm/components/Groups/QueryBuilder/QueryBuilder.js +41 -12
- package/lib/esm/components/Groups/QueryBuilder/QueryBuilder.js.map +1 -1
- package/lib/esm/components/Properties/PropertyAction.js +7 -2
- package/lib/esm/components/Properties/PropertyAction.js.map +1 -1
- package/lib/esm/components/customUI/GroupQueryBuilderCustomUI.js +1 -1
- package/lib/esm/components/customUI/GroupQueryBuilderCustomUI.js.map +1 -1
- package/lib/esm/test/QueryBuilder.test.js +17 -6
- package/lib/esm/test/QueryBuilder.test.js.map +1 -1
- package/lib/esm/test/QueryBuilder.testdata.js +46 -0
- package/lib/esm/test/QueryBuilder.testdata.js.map +1 -1
- package/lib/esm/test/QueryBuilderTestData.d.ts +2 -2
- package/lib/esm/test/QueryBuilderTestData.js.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QueryBuilder.testdata.js","sourceRoot":"","sources":["../../../src/test/QueryBuilder.testdata.ts"],"names":[],"mappings":";;;AAAA;;;gGAGgG;AAChG,oEAAiE;AAGpD,QAAA,SAAS,GAAyB;IAC7C,SAAS,EAAE;QACT;YACE,IAAI,EAAE,6EAA6E;YACnF,cAAc,EAAE,4EAA4E;YAC5F,UAAU,EAAE;gBACV;oBACE,cAAc,EAAE,IAAI;oBACpB,aAAa,EAAE,aAAa;oBAC5B,mBAAmB,EAAE,yCAAmB,CAAC,UAAU;oBACnD,cAAc,EAAE;wBACd,KAAK,EAAE;4BACL,WAAW,EAAE,CAAC;4BACd,KAAK,EAAE,CAAC;yBACT;wBACD,QAAQ,EAAE;4BACR,QAAQ,EAAE,eAAe;4BACzB,IAAI,EAAE,cAAc;4BACpB,YAAY,EAAE,sBAAsB;yBACrC;qBACF;oBACD,eAAe,EAAE;wBACf,UAAU,EAAE;4BACV;gCACE,QAAQ,EAAE;oCACR,IAAI,EAAE,cAAc;oCACpB,SAAS,EAAE;wCACT,IAAI,EAAE,KAAK;qCACZ;iCACF;6BACF;yBACF;wBACD,IAAI,EAAE;4BACJ,QAAQ,EAAE,QAAQ;yBACnB;wBACD,MAAM,EAAE;4BACN,kBAAkB,EAAE,EAAE;yBACvB;qBACF;iBACF;aACF;SACF;QACD;YACE,IAAI,EAAE,kGAAkG;YACxG,cAAc,EACZ,iUAAiU;YACnU,UAAU,EAAE;gBACV;oBACE,cAAc,EAAE,IAAI;oBACpB,aAAa,EAAE,aAAa;oBAC5B,mBAAmB,EAAE,yCAAmB,CAAC,UAAU;oBACnD,cAAc,EAAE;wBACd,KAAK,EAAE;4BACL,WAAW,EAAE,CAAC;4BACd,KAAK,EAAE,YAAY;yBACpB;wBACD,QAAQ,EAAE;4BACR,QAAQ,EAAE,eAAe;4BACzB,IAAI,EAAE,cAAc;4BACpB,YAAY,EAAE,sBAAsB;yBACrC;qBACF;oBACD,eAAe,EAAE;wBACf,UA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RAAsR;YACxR,UAAU,EAAE;gBACV;oBACE,cAAc,EAAE,IAAI;oBACpB,aAAa,EAAE,aAAa;oBAC5B,mBAAmB,EAAE,yCAAmB,CAAC,UAAU;oBACnD,cAAc,EAAE;wBACd,KAAK,EAAE;4BACL,WAAW,EAAE,CAAC;4BACd,KAAK,EAAE,YAAY;4BACnB,YAAY,EAAE,oBAAoB;yBACnC;wBACD,QAAQ,EAAE;4BACR,QAAQ,EAAE,YAAY;4BACtB,IAAI,EAAE,cAAc;4BACpB,YAAY,EAAE,sBAAsB;yBACrC;qBACF;oBACD,eAAe,EAAE;wBACf,UAAU,EAAE;4BACV;gCACE,QAAQ,EAAE;oCACR,IAAI,EAAE,cAAc;oCACpB,SAAS,EAAE;wCACT,IAAI,EAAE,WAAW;qCAClB;oCACD,sBAAsB,EAAE;wCACtB,SAAS,EAAE;4CACT,IAAI,EAAE,wCAAwC;yCAC/C;qCACF;iCACF;6BACF;yBACF;wBACD,IAAI,EAAE;4BACJ,QAAQ,EAAE,QAAQ;yBACnB;wBACD,MAAM,EAAE;4BACN,kBAAkB,EAAE,EAAE;yBACvB;qBACF;iBACF;aACF;SACF;KACF;CACF,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { FieldDescriptorType } from \"@itwin/presentation-common\";\nimport type { QueryBuilderTestData } from \"./QueryBuilderTestData\";\n\nexport const testCases: QueryBuilderTestData = {\n testCases: [\n {\n name: \"when non-relational property added, return query string with property value\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when relational property added, return query string with property value and relation chain to it\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when multiple relational properties added, return query string with property values and relation chains to them\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN G.H ON Rel.BC.TargetECInstanceId = G.H.ECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE G.H.someOtherPropName = 'someOtherString' AND A.B.somePropName = 'someString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"otherPropertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"someOtherPropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"G:H\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"G:H\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property and non-relational property from one of relational chain classes added, return query string with property values and relation chain\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString' AND A.C.SomeOtherPropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"somePropName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:C\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"SomeOtherPropName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"SomeOtherPropName\",\n classInfo: {\n name: \"A:C\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when relational and non-relational property from the same class added, return query string with property values and relation chain\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString' AND A.B.SomeOtherPropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName2\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"SomeOtherPropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when non-relational property removed, return empty string\",\n expectedResult: \"\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property removed, return empty string\",\n expectedResult: \"\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when non-relational property re-added after removing, return query string with property value\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 'someOtherString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"addProperty\",\n expectedResult: true,\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property re-added after removing, return query string with property value and relation chain to it\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someOtherString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when no properties added, return empty string\",\n expectedResult: \"\",\n operations: [],\n },\n {\n name: \"when property is float, return query string with ROUND\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE ROUND(A.B.somePropName, 4) = 3.1416\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 3.14159,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when property needsQuotes, return query string with property value in quotes\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 'https://valueThatNeedsQuotes.com'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"https://valueThatNeedsQuotes.com\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"uri\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when property is category, return a category query string\",\n expectedResult:\n \"SELECT BisCore.B.ECInstanceId, BisCore.B.ECClassId FROM BisCore.B JOIN BisCore.Category ON BisCore.Category.ECInstanceId = BisCore.GeometricElement3d.category.id WHERE ((BisCore.Category.CodeValue = 'displayValueString') OR (BisCore.Category.UserLabel = 'displayValueString'))\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n displayValue: \"displayValueString\",\n },\n property: {\n typename: \"navigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"BisCore:B\",\n },\n navigationPropertyInfo: {\n classInfo: {\n name: \"BisCore:GeometricElement3dIsInCategory\",\n },\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when category property and relational property added, return query string with property value, relational chain and with category joined\",\n expectedResult:\n \"SELECT BisCore.B.ECInstanceId, BisCore.B.ECClassId FROM BisCore.B JOIN BisCore.Category ON BisCore.Category.ECInstanceId = BisCore.GeometricElement3d.category.id WHERE ((BisCore.Category.CodeValue = 'displayValueString') OR (BisCore.Category.UserLabel = 'displayValueString'))\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n displayValue: \"displayValueString\",\n },\n property: {\n typename: \"navigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"BisCore:B\",\n },\n navigationPropertyInfo: {\n classInfo: {\n name: \"BisCore:GeometricElement3dIsInCategory\",\n },\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n ],\n};\n"]}
|
|
1
|
+
{"version":3,"file":"QueryBuilder.testdata.js","sourceRoot":"","sources":["../../../src/test/QueryBuilder.testdata.ts"],"names":[],"mappings":";;;AAAA;;;gGAGgG;AAChG,oEAAiE;AAGpD,QAAA,SAAS,GAAyB;IAC7C,SAAS,EAAE;QACT;YACE,IAAI,EAAE,6EAA6E;YACnF,cAAc,EAAE,4EAA4E;YAC5F,UAAU,EAAE;gBACV;oBACE,cAAc,EAAE,IAAI;oBACpB,aAAa,EAAE,aAAa;oBAC5B,mBAAmB,EAAE,yCAAmB,CAAC,UAAU;oBACnD,cAAc,EAAE;wBACd,KAAK,EAAE;4BACL,WAAW,EAAE,CAAC;4BACd,KAAK,EAAE,CAAC;yBACT;wBACD,QAAQ,EAAE;4BACR,QAAQ,EAAE,eAAe;4BACzB,IAAI,EAAE,cAAc;4BACpB,YAAY,EAAE,sBAAsB;yBACrC;qBACF;oBACD,eAAe,EAAE;wBACf,UAAU,EAAE;4BACV;gCACE,QAAQ,EAAE;oCACR,IAAI,EAAE,cAAc;oCACpB,SAAS,EAAE;wCACT,IAAI,EAAE,KAAK;qCACZ;iCACF;6BACF;yBACF;wBACD,IAAI,EAAE;4BACJ,QAAQ,EAAE,QAAQ;yBACnB;wBACD,MAAM,EAAE;4BACN,kBAAkB,EAAE,EAAE;yBACvB;qBACF;iBACF;aACF;SACF;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,cAAc,EAAE,IAAI;oBACpB,aAAa,EAAE,aAAa;oBAC5B,mBAAmB,EAAE,yCAAmB,CAAC,UAAU;oBACnD,cAAc,EAAE;wBACd,KAAK,EAAE;4BACL,WAAW,EAAE,CAAC;4BACd,KAAK,EAAE,YAAY;4BACnB,YAAY,EAAE,oBAAoB;yBACnC;wBACD,QAAQ,EAAE;4BACR,QAAQ,EAAE,YAAY;4BACtB,IAAI,EAAE,cAAc;4BACpB,YAAY,EAAE,sBAAsB;yBACrC;qBACF;oBACD,eAAe,EAAE;wBACf,UAAU,EAAE;4BACV;gCACE,QAAQ,EAAE;oCACR,IAAI,EAAE,cAAc;oCACpB,SAAS,EAAE;wCACT,IAAI,EAAE,WAAW;qCAClB;oCACD,sBAAsB,EAAE;wCACtB,SAAS,EAAE;4CACT,IAAI,EAAE,wCAAwC;yCAC/C;qCACF;iCACF;6BACF;yBACF;wBACD,IAAI,EAAE;4BACJ,QAAQ,EAAE,QAAQ;yBACnB;wBACD,MAAM,EAAE;4BACN,kBAAkB,EAAE,EAAE;yBACvB;qBACF;iBACF;aACF;SACF;KACF;CACF,CAAC","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport { FieldDescriptorType } from \"@itwin/presentation-common\";\nimport type { QueryBuilderTestData } from \"./QueryBuilderTestData\";\n\nexport const testCases: QueryBuilderTestData = {\n testCases: [\n {\n name: \"when non-relational property added, return query string with property value\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when relational property added, return query string with property value and relation chain to it\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when multiple relational properties added, return query string with property values and relation chains to them\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN G.H ON Rel.BC.TargetECInstanceId = G.H.ECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE G.H.someOtherPropName = 'someOtherString' AND A.B.somePropName = 'someString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"otherPropertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"someOtherPropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"G:H\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"G:H\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property and non-relational property from one of relational chain classes added, return query string with property values and relation chain\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString' AND A.C.SomeOtherPropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"somePropName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:C\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"SomeOtherPropName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"SomeOtherPropName\",\n classInfo: {\n name: \"A:C\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when relational and non-relational property from the same class added, return query string with property values and relation chain\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someString' AND A.B.SomeOtherPropName = 1\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 1,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName2\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"SomeOtherPropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when non-relational property removed, return empty string\",\n expectedResult: \"\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property removed, return empty string\",\n expectedResult: \"\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when non-relational property re-added after removing, return query string with property value\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 'someOtherString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n {\n operationType: \"addProperty\",\n expectedResult: true,\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n contentClassInfo: {\n name: \"sourceClassName\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when relational property re-added after removing, return query string with property value and relation chain to it\",\n expectedResult:\n \"SELECT Z.X.ECInstanceId, Z.X.ECClassId FROM Z.X JOIN Rel.CX ON Z.X.ECInstanceId = Rel.CX.TargetECInstanceId JOIN A.C ON Rel.CX.SourceECInstanceId = A.C.ECInstanceId JOIN Rel.BC ON A.C.ECInstanceId = Rel.BC.SourceECInstanceId JOIN A.B ON Rel.BC.TargetECInstanceId = A.B.ECInstanceId WHERE A.B.somePropName = 'someOtherString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n operationType: \"removeProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someOtherString\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [\n {\n sourceClassInfo: {\n id: \"id1\",\n name: \"A:B\",\n label: \"AB label\",\n },\n targetClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n isPolymorphicTargetClass: true,\n relationshipInfo: {\n id: \"id3\",\n name: \"Rel:BC\",\n label: \"Relationship BC label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: false,\n },\n {\n sourceClassInfo: {\n id: \"id2\",\n name: \"A:C\",\n label: \"AC label\",\n },\n targetClassInfo: {\n id: \"id4\",\n name: \"Z:X\",\n label: \"ZX label\",\n },\n isPolymorphicTargetClass: false,\n relationshipInfo: {\n id: \"id5\",\n name: \"Rel:CX\",\n label: \"Relationship CX label\",\n },\n isPolymorphicRelationship: true,\n isForwardRelationship: true,\n },\n ],\n contentClassInfo: {\n name: \"A:B\",\n },\n },\n },\n },\n ],\n },\n {\n name: \"when no properties added, return empty string\",\n expectedResult: \"\",\n operations: [],\n },\n {\n name: \"when property is float, return query string with ROUND\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE ROUND(A.B.somePropName, 4) = 3.1416\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: 3.14159,\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"number\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when property needsQuotes, return query string with property value in quotes\",\n expectedResult: \"SELECT A.B.ECInstanceId, A.B.ECClassId FROM A.B WHERE A.B.somePropName = 'https://valueThatNeedsQuotes.com'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"https://valueThatNeedsQuotes.com\",\n },\n property: {\n typename: \"notNavigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"A:B\",\n },\n },\n },\n ],\n type: {\n typeName: \"uri\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when property is category, return a category query string\",\n expectedResult:\n \"SELECT BisCore.B.ECInstanceId, BisCore.B.ECClassId FROM BisCore.B JOIN BisCore.Category ON BisCore.Category.ECInstanceId = BisCore.GeometricElement3d.category.id WHERE ((BisCore.Category.CodeValue = 'displayValueString') OR (BisCore.Category.UserLabel = 'displayValueString'))\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n displayValue: \"displayValueString\",\n },\n property: {\n typename: \"navigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"BisCore:B\",\n },\n navigationPropertyInfo: {\n classInfo: {\n name: \"BisCore:GeometricElement3dIsInCategory\",\n },\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when property is a model, return a model query string\",\n expectedResult:\n \"SELECT BisCore.B.ECInstanceId, BisCore.B.ECClassId FROM BisCore.B JOIN mockModeledElement ON mockModeledElement.ECInstanceId = BisCore.Element.Model.id WHERE mockModeledElement.UserLabel = 'displayValueString' OR mockModeledElement.CodeValue = 'displayValueString'\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: { id: \"fakeId\" },\n displayValue: \"displayValueString\",\n },\n property: {\n typename: \"navigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"BisCore:B\",\n },\n navigationPropertyInfo: {\n classInfo: {\n name: \"BisCore:ModelContainsElements\",\n },\n },\n },\n },\n ],\n type: {\n typeName: \"long\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n {\n name: \"when category property and relational property added, return query string with property value, relational chain and with category joined\",\n expectedResult:\n \"SELECT BisCore.B.ECInstanceId, BisCore.B.ECClassId FROM BisCore.B JOIN BisCore.Category ON BisCore.Category.ECInstanceId = BisCore.GeometricElement3d.category.id WHERE ((BisCore.Category.CodeValue = 'displayValueString') OR (BisCore.Category.UserLabel = 'displayValueString'))\",\n operations: [\n {\n expectedResult: true,\n operationType: \"addProperty\",\n fieldDescriptorType: FieldDescriptorType.Properties,\n propertyRecord: {\n value: {\n valueFormat: 0,\n value: \"someString\",\n displayValue: \"displayValueString\",\n },\n property: {\n typename: \"navigation\",\n name: \"propertyName\",\n displayLabel: \"propertyDisplayLabel\",\n },\n },\n propertiesField: {\n properties: [\n {\n property: {\n name: \"somePropName\",\n classInfo: {\n name: \"BisCore:B\",\n },\n navigationPropertyInfo: {\n classInfo: {\n name: \"BisCore:GeometricElement3dIsInCategory\",\n },\n },\n },\n },\n ],\n type: {\n typeName: \"string\",\n },\n parent: {\n pathToPrimaryClass: [],\n },\n },\n },\n ],\n },\n ],\n};\n"]}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { PropertyDescription, PropertyValue } from "@itwin/appui-abstract";
|
|
2
|
-
import type { FieldDescriptorType, RelationshipPath } from "@itwin/presentation-common";
|
|
2
|
+
import type { FieldDescriptorType, NavigationPropertyValue, RelationshipPath } from "@itwin/presentation-common";
|
|
3
3
|
export interface ClassInfoTestData {
|
|
4
4
|
name: string;
|
|
5
5
|
}
|
|
@@ -30,7 +30,7 @@ export interface PropertiesFieldTestData {
|
|
|
30
30
|
parent: ParentTestData;
|
|
31
31
|
}
|
|
32
32
|
export interface PropertyRecordTestData {
|
|
33
|
-
value: PropertyValue;
|
|
33
|
+
value: PropertyValue | NavigationPropertyValue;
|
|
34
34
|
property: PropertyDescription;
|
|
35
35
|
}
|
|
36
36
|
export interface OperationTestData {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QueryBuilderTestData.js","sourceRoot":"","sources":["../../../src/test/QueryBuilderTestData.ts"],"names":[],"mappings":"","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport type { PropertyDescription, PropertyValue } from \"@itwin/appui-abstract\";\nimport type { FieldDescriptorType, RelationshipPath } from \"@itwin/presentation-common\";\n\nexport interface ClassInfoTestData {\n name: string;\n}\n\nexport interface NavigationPropertyInfoTestData {\n classInfo: ClassInfoTestData;\n}\n\nexport interface PropertyTestData {\n name: string;\n classInfo: ClassInfoTestData;\n navigationPropertyInfo?: NavigationPropertyInfoTestData;\n}\n\nexport interface PropertiesTestData {\n property: PropertyTestData;\n}\n\nexport interface ContentClassInfoTestData {\n name: string;\n}\n\nexport interface ParentTestData {\n pathToPrimaryClass: RelationshipPath;\n contentClassInfo?: ContentClassInfoTestData;\n}\n\nexport interface TypeTestData {\n typeName: string;\n}\n\nexport interface PropertiesFieldTestData {\n properties: PropertiesTestData[];\n type: TypeTestData;\n parent: ParentTestData;\n}\n\nexport interface PropertyRecordTestData {\n value: PropertyValue;\n property: PropertyDescription;\n}\n\nexport interface OperationTestData {\n expectedResult?: boolean;\n operationType: string;\n fieldDescriptorType: FieldDescriptorType.Name | FieldDescriptorType.Properties;\n fieldDescriptorName?: string;\n propertyRecord: PropertyRecordTestData;\n propertiesField: PropertiesFieldTestData;\n}\n\nexport interface TestCase {\n name: string;\n expectedResult: string;\n operations: OperationTestData[];\n}\n\nexport interface QueryBuilderTestData {\n testCases: TestCase[];\n}\n"]}
|
|
1
|
+
{"version":3,"file":"QueryBuilderTestData.js","sourceRoot":"","sources":["../../../src/test/QueryBuilderTestData.ts"],"names":[],"mappings":"","sourcesContent":["/*---------------------------------------------------------------------------------------------\n * Copyright (c) Bentley Systems, Incorporated. All rights reserved.\n * See LICENSE.md in the project root for license terms and full copyright notice.\n *--------------------------------------------------------------------------------------------*/\nimport type { PropertyDescription, PropertyValue } from \"@itwin/appui-abstract\";\nimport type { FieldDescriptorType, NavigationPropertyValue, RelationshipPath } from \"@itwin/presentation-common\";\n\nexport interface ClassInfoTestData {\n name: string;\n}\n\nexport interface NavigationPropertyInfoTestData {\n classInfo: ClassInfoTestData;\n}\n\nexport interface PropertyTestData {\n name: string;\n classInfo: ClassInfoTestData;\n navigationPropertyInfo?: NavigationPropertyInfoTestData;\n}\n\nexport interface PropertiesTestData {\n property: PropertyTestData;\n}\n\nexport interface ContentClassInfoTestData {\n name: string;\n}\n\nexport interface ParentTestData {\n pathToPrimaryClass: RelationshipPath;\n contentClassInfo?: ContentClassInfoTestData;\n}\n\nexport interface TypeTestData {\n typeName: string;\n}\n\nexport interface PropertiesFieldTestData {\n properties: PropertiesTestData[];\n type: TypeTestData;\n parent: ParentTestData;\n}\n\nexport interface PropertyRecordTestData {\n value: PropertyValue | NavigationPropertyValue;\n property: PropertyDescription;\n}\n\nexport interface OperationTestData {\n expectedResult?: boolean;\n operationType: string;\n fieldDescriptorType: FieldDescriptorType.Name | FieldDescriptorType.Properties;\n fieldDescriptorName?: string;\n propertyRecord: PropertyRecordTestData;\n propertiesField: PropertiesFieldTestData;\n}\n\nexport interface TestCase {\n name: string;\n expectedResult: string;\n operations: OperationTestData[];\n}\n\nexport interface QueryBuilderTestData {\n testCases: TestCase[];\n}\n"]}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { PresentationPropertyDataProvider } from "@itwin/presentation-components";
|
|
2
2
|
import type { PropertiesField } from "@itwin/presentation-common";
|
|
3
3
|
import type { Primitives, PropertyRecord } from "@itwin/appui-abstract";
|
|
4
|
+
import type { IModelConnection } from "@itwin/core-frontend";
|
|
4
5
|
export interface Query {
|
|
5
6
|
unions: QueryUnion[];
|
|
6
7
|
}
|
|
@@ -21,6 +22,7 @@ export interface QueryProperty {
|
|
|
21
22
|
className: string;
|
|
22
23
|
classProperties: ClassProperty[];
|
|
23
24
|
isCategory: boolean;
|
|
25
|
+
modeledElementClass?: string;
|
|
24
26
|
isAspect: boolean;
|
|
25
27
|
}
|
|
26
28
|
export interface ClassProperty {
|
|
@@ -33,13 +35,15 @@ export interface AddedProperty {
|
|
|
33
35
|
propertiesField: PropertiesField;
|
|
34
36
|
}
|
|
35
37
|
export declare class QueryBuilder {
|
|
38
|
+
private readonly dataProvider;
|
|
39
|
+
private readonly iModelConnection;
|
|
36
40
|
private static readonly MULTI_ASPECT_PRIMARY_CLASS;
|
|
37
41
|
private static readonly UNIQUE_ASPECT_PRIMARY_CLASS;
|
|
38
42
|
private static readonly DEFAULT_DOUBLE_PRECISION;
|
|
39
|
-
private dataProvider;
|
|
40
43
|
private query;
|
|
41
|
-
constructor(
|
|
44
|
+
constructor(dataProvider: PresentationPropertyDataProvider, iModelConnection: IModelConnection);
|
|
42
45
|
private isCategory;
|
|
46
|
+
private getPotentialModeledElement;
|
|
43
47
|
private _propertyMap;
|
|
44
48
|
resetQueryBuilder: () => void;
|
|
45
49
|
private regenerateQuery;
|
|
@@ -50,7 +54,7 @@ export declare class QueryBuilder {
|
|
|
50
54
|
private addRelatedToQuery;
|
|
51
55
|
private addClassToQuery;
|
|
52
56
|
private addPropertyToQuery;
|
|
53
|
-
buildQueryString(): string
|
|
57
|
+
buildQueryString(): Promise<string>;
|
|
54
58
|
private selectClause;
|
|
55
59
|
private relationalJoinSegments;
|
|
56
60
|
private propertyQuerySegment;
|
|
@@ -1,16 +1,19 @@
|
|
|
1
1
|
import { PropertyValueFormat } from "@itwin/appui-abstract";
|
|
2
2
|
import { toaster } from "@itwin/itwinui-react";
|
|
3
|
+
import { QueryBinder } from "@itwin/core-common";
|
|
3
4
|
/* This class is to build adaptive and dynamic query for find similar property selections */
|
|
4
5
|
export class QueryBuilder {
|
|
5
|
-
constructor(
|
|
6
|
+
constructor(dataProvider, iModelConnection) {
|
|
7
|
+
this.dataProvider = dataProvider;
|
|
8
|
+
this.iModelConnection = iModelConnection;
|
|
6
9
|
this._propertyMap = new Map();
|
|
7
10
|
this.resetQueryBuilder = () => {
|
|
8
11
|
this._propertyMap = new Map();
|
|
9
12
|
};
|
|
10
|
-
this.regenerateQuery = () => {
|
|
13
|
+
this.regenerateQuery = async () => {
|
|
11
14
|
this.query = undefined;
|
|
12
15
|
for (const property of this._propertyMap.values()) {
|
|
13
|
-
this.buildProperty(property.propertyRecord, property.propertiesField);
|
|
16
|
+
await this.buildProperty(property.propertyRecord, property.propertiesField);
|
|
14
17
|
}
|
|
15
18
|
};
|
|
16
19
|
this.relationalJoinSegments = (classes, querySegments) => {
|
|
@@ -33,12 +36,27 @@ export class QueryBuilder {
|
|
|
33
36
|
const propertyValue = needsQuote ? `'${property.value}'` : property.value;
|
|
34
37
|
return `${className}.${property.name} = ${propertyValue}`;
|
|
35
38
|
};
|
|
36
|
-
this.dataProvider = provider;
|
|
37
39
|
}
|
|
38
40
|
isCategory(propertyField) {
|
|
39
41
|
const classInfo = propertyField.properties[0].property.navigationPropertyInfo?.classInfo;
|
|
40
42
|
return classInfo?.name === "BisCore:GeometricElement3dIsInCategory";
|
|
41
43
|
}
|
|
44
|
+
async getPotentialModeledElement(propertyField, propertyRecord) {
|
|
45
|
+
const classInfo = propertyField.properties[0].property.navigationPropertyInfo?.classInfo;
|
|
46
|
+
if (propertyRecord.value?.valueFormat !== PropertyValueFormat.Primitive)
|
|
47
|
+
return;
|
|
48
|
+
const navigationPropertyValue = propertyRecord.value.value;
|
|
49
|
+
if (classInfo?.name === "BisCore:ModelContainsElements") {
|
|
50
|
+
// https://www.itwinjs.org/bis/guide/fundamentals/model-fundamentals/#model-identity
|
|
51
|
+
// Lookup the modeled element as they share the same ECInstanceId
|
|
52
|
+
const modeledElementQuery = `SELECT ec_classname(ecclassid) FROM biscore.element WHERE ecinstanceid = ? LIMIT 1`;
|
|
53
|
+
const queryBinder = new QueryBinder();
|
|
54
|
+
queryBinder.bindString(1, navigationPropertyValue.id);
|
|
55
|
+
const modeledElement = (await this.iModelConnection.createQueryReader(modeledElementQuery, queryBinder).next()).value[0];
|
|
56
|
+
return modeledElement.replace(":", ".");
|
|
57
|
+
}
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
42
60
|
async addProperty(prop) {
|
|
43
61
|
// TODO: only handle primitive properties now
|
|
44
62
|
if (prop.value?.valueFormat !== PropertyValueFormat.Primitive) {
|
|
@@ -60,7 +78,7 @@ export class QueryBuilder {
|
|
|
60
78
|
const propertyField = (await this.dataProvider.getFieldByPropertyRecord(prop));
|
|
61
79
|
this._propertyMap.delete(JSON.stringify(propertyField.getFieldDescriptor()));
|
|
62
80
|
}
|
|
63
|
-
buildProperty(prop, propertiesField) {
|
|
81
|
+
async buildProperty(prop, propertiesField) {
|
|
64
82
|
if (prop.value?.valueFormat !== PropertyValueFormat.Primitive || prop.value.value === undefined) {
|
|
65
83
|
toaster.negative("Error. An unexpected error has occured while building a query.");
|
|
66
84
|
return;
|
|
@@ -76,17 +94,22 @@ export class QueryBuilder {
|
|
|
76
94
|
// get the special cases
|
|
77
95
|
const isNavigation = prop.property.typename.toLowerCase() === "navigation";
|
|
78
96
|
const isCategory = isNavigation && this.isCategory(propertiesField);
|
|
97
|
+
const modeledElement = await this.getPotentialModeledElement(propertiesField, prop);
|
|
79
98
|
const isAspect = pathToPrimaryClass?.find((a) => a.relationshipInfo?.name === QueryBuilder.UNIQUE_ASPECT_PRIMARY_CLASS || a.relationshipInfo?.name === QueryBuilder.MULTI_ASPECT_PRIMARY_CLASS) !== undefined;
|
|
80
99
|
for (let i = 0; i < propertiesField.properties.length; i++) {
|
|
81
100
|
const property = propertiesField.properties[i].property;
|
|
82
101
|
const className = property.classInfo.name.replace(":", ".");
|
|
83
|
-
const propertyName = isNavigation ? (isCategory ? `${property.name}.CodeValue` : `${property.name}.id`) : property.name;
|
|
84
|
-
const propertyValue = isNavigation
|
|
102
|
+
const propertyName = isNavigation ? (isCategory || modeledElement ? `${property.name}.CodeValue` : `${property.name}.id`) : property.name;
|
|
103
|
+
const propertyValue = isNavigation
|
|
104
|
+
? isCategory || modeledElement
|
|
105
|
+
? prop.value.displayValue ?? ""
|
|
106
|
+
: prop.value.value.id
|
|
107
|
+
: prop.value.value;
|
|
85
108
|
if (!isAspect && pathToPrimaryClass && pathToPrimaryClass.length > 0) {
|
|
86
109
|
this.addRelatedToQuery(i, propertiesField, propertyName, propertyValue);
|
|
87
110
|
}
|
|
88
111
|
else {
|
|
89
|
-
this.addPropertyToQuery(i, className, propertyName, propertyValue, this.needsQuote(propertiesField), isCategory, isAspect);
|
|
112
|
+
this.addPropertyToQuery(i, className, propertyName, propertyValue, this.needsQuote(propertiesField), isCategory, modeledElement, isAspect);
|
|
90
113
|
}
|
|
91
114
|
}
|
|
92
115
|
return true;
|
|
@@ -107,7 +130,7 @@ export class QueryBuilder {
|
|
|
107
130
|
this.addClassToQuery(unionIndex, targetClassName, `ECInstanceId`, relClassName, relPropertyValue);
|
|
108
131
|
this.addClassToQuery(unionIndex, relClassName, relClassProperty, sourceClassName, `ECInstanceId`);
|
|
109
132
|
if (path.sourceClassInfo?.name === propertyField.parent?.contentClassInfo.name) {
|
|
110
|
-
this.addPropertyToQuery(unionIndex, sourceClassName, propertyName, propertyValue, this.needsQuote(propertyField), false, false);
|
|
133
|
+
this.addPropertyToQuery(unionIndex, sourceClassName, propertyName, propertyValue, this.needsQuote(propertyField), false, "", false);
|
|
111
134
|
}
|
|
112
135
|
});
|
|
113
136
|
}
|
|
@@ -140,7 +163,7 @@ export class QueryBuilder {
|
|
|
140
163
|
}
|
|
141
164
|
this.query.unions[unionIndex].classes.push(queryClass);
|
|
142
165
|
}
|
|
143
|
-
addPropertyToQuery(unionIndex, className, propertyName, propertyValue, needsQuote, isCategory, isAspect) {
|
|
166
|
+
addPropertyToQuery(unionIndex, className, propertyName, propertyValue, needsQuote, isCategory, modeledElementClass, isAspect) {
|
|
144
167
|
if (this.query === undefined) {
|
|
145
168
|
this.query = { unions: [] };
|
|
146
169
|
}
|
|
@@ -152,6 +175,7 @@ export class QueryBuilder {
|
|
|
152
175
|
const queryProperty = {
|
|
153
176
|
className,
|
|
154
177
|
isCategory,
|
|
178
|
+
modeledElementClass,
|
|
155
179
|
isAspect,
|
|
156
180
|
classProperties: [queryJoin],
|
|
157
181
|
};
|
|
@@ -174,8 +198,8 @@ export class QueryBuilder {
|
|
|
174
198
|
}
|
|
175
199
|
this.query.unions[unionIndex].properties.push(queryProperty);
|
|
176
200
|
}
|
|
177
|
-
buildQueryString() {
|
|
178
|
-
this.regenerateQuery();
|
|
201
|
+
async buildQueryString() {
|
|
202
|
+
await this.regenerateQuery();
|
|
179
203
|
if (this.query === undefined || this.query.unions.find((u) => u.classes.length === 0 && u.properties.length === 0)) {
|
|
180
204
|
return "";
|
|
181
205
|
}
|
|
@@ -197,6 +221,11 @@ export class QueryBuilder {
|
|
|
197
221
|
whereSegments.push(this.categoryWhereQuery(property.classProperties[0].value.toString()));
|
|
198
222
|
continue;
|
|
199
223
|
}
|
|
224
|
+
else if (property.modeledElementClass) {
|
|
225
|
+
querySegments.set(property.modeledElementClass, [`${property.modeledElementClass}.ECInstanceId = BisCore.Element.Model.id`]);
|
|
226
|
+
whereSegments.push(`${property.modeledElementClass}.UserLabel = '${property.classProperties[0].value.toString()}' OR ${property.modeledElementClass}.CodeValue = '${property.classProperties[0].value.toString()}'`);
|
|
227
|
+
continue;
|
|
228
|
+
}
|
|
200
229
|
const joinIdName = property.isAspect ? `${property.className}.Element.id` : `${property.className}.ECInstanceId`;
|
|
201
230
|
if (!querySegments.has(property.className) && property.className !== baseClassName)
|
|
202
231
|
querySegments.set(property.className, [`${joinIdName} = ${baseIdName}`]);
|