mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-05-07 22:49:26 +08:00
Merge branch 'main' into next
This commit is contained in:
commit
654a0b0ce2
@ -278,21 +278,21 @@ describe('tree path test', () => {
|
|||||||
for (const node of allNodes) {
|
for (const node of allNodes) {
|
||||||
expect(nodeA1.get(treeCollection.filterTargetKey) === node.get('rootPk')).toBeTruthy();
|
expect(nodeA1.get(treeCollection.filterTargetKey) === node.get('rootPk')).toBeTruthy();
|
||||||
}
|
}
|
||||||
await treeCollection.repository.update({
|
// await treeCollection.repository.update({
|
||||||
values: {
|
// values: {
|
||||||
parentId: nodeA4.get(treeCollection.filterTargetKey),
|
// parentId: nodeA4.get(treeCollection.filterTargetKey),
|
||||||
},
|
// },
|
||||||
filter: {
|
// filter: {
|
||||||
name: 'a4',
|
// name: 'a4',
|
||||||
},
|
// },
|
||||||
});
|
// });
|
||||||
const pathDataA4New = await db.getCollection(name).repository.findOne({
|
// const pathDataA4New = await db.getCollection(name).repository.findOne({
|
||||||
filter: {
|
// filter: {
|
||||||
[nodePkColumnName]: nodeA4.get(treeCollection.filterTargetKey),
|
// [nodePkColumnName]: nodeA4.get(treeCollection.filterTargetKey),
|
||||||
},
|
// },
|
||||||
});
|
// });
|
||||||
// node primary key shoud be equal to root primary key to avoid infinite loop
|
// // node primary key shoud be equal to root primary key to avoid infinite loop
|
||||||
expect(pathDataA4New.get('nodePk') === pathDataA4New.get('rootPk')).toBeTruthy();
|
// expect(pathDataA4New.get('nodePk') === pathDataA4New.get('rootPk')).toBeTruthy();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('test tree find one', async () => {
|
it('test tree find one', async () => {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user