mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 22:26:01 +00:00
perspective subloading works
This commit is contained in:
10
packages/datalib/src/perspectiveTools.ts
Normal file
10
packages/datalib/src/perspectiveTools.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
export function getPerspectiveParentColumnName(columnName: string) {
|
||||
const path = columnName.split('::');
|
||||
if (path.length >= 2) return path.slice(0, -1).join('::');
|
||||
return null;
|
||||
}
|
||||
|
||||
export function getPerspectiveMostNestedChildColumnName(columnName: string) {
|
||||
const path = columnName.split('::');
|
||||
return path[path.length - 1];
|
||||
}
|
||||
Reference in New Issue
Block a user