Skip to content

Commit

Permalink
Issue 49964: Experiment database: parent id is not populating
Browse files Browse the repository at this point in the history
  • Loading branch information
labkey-jeckels committed Mar 21, 2024
1 parent e59f201 commit bb5dde8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ public void addColumns()
//UserSchema targetSchema = getUserSchema().getContainer().isWorkbook() ? new OConnorExperimentsUserSchema(getUserSchema().getUser(), getUserSchema().getContainer().getParent()) : getUserSchema();
MultiValuedForeignKey parentExperimentsFk = new MultiValuedForeignKey(
QueryForeignKey
.from(getUserSchema(), getContainerFilter())
.from(getUserSchema(), getContainer().isWorkbook() ? ContainerFilter.Type.CurrentAndFirstChildren.create(getContainer().getParent(), getUserSchema().getUser()) : getContainerFilter())
.schema(OConnorExperimentsUserSchema.NAME, getContainer().isWorkbook() ? getContainer().getParent() : getContainer())
.to(OConnorExperimentsUserSchema.Table.ParentExperiments.name(), "Container", null),
"ParentExperiment");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,10 @@ public void testSteps()
updateViaExperimentWebpart(0, null, "type3", "1,2");
verifyExperimentWebpart(0, "updated description 3", "type3", 1, 2);

// Make sure the values round-trip if they're not explicitly set
updateViaExperimentWebpart(0, null, null, null);
verifyExperimentWebpart(0, "updated description 3", "type3", 1, 2);

testBulkUpdate();

// delete via the webpart
Expand Down

0 comments on commit bb5dde8

Please sign in to comment.