diff --git a/ehr/test/src/org/labkey/test/util/ehr/EHRTestHelper.java b/ehr/test/src/org/labkey/test/util/ehr/EHRTestHelper.java index 6d8e036a8..052d0e2f5 100644 --- a/ehr/test/src/org/labkey/test/util/ehr/EHRTestHelper.java +++ b/ehr/test/src/org/labkey/test/util/ehr/EHRTestHelper.java @@ -230,6 +230,16 @@ public void applyTemplate(Ext4GridRef grid, String templateName, boolean bulkEdi } } + public Locator.XPathLocator openBulkEdit(Ext4GridRef grid) + { + grid.clickTbarButton("More Actions"); + _test.waitAndClick(Locator.tag("span").withText("Bulk Edit")); + Locator.XPathLocator bulkEditWindow = Ext4Helper.Locators.window("Bulk Edit"); + _test.waitForElement(bulkEditWindow); + return bulkEditWindow; + } + + // This method toggles the bulk edit field that CONTAINS the label parameter in the label public void toggleBulkEditField(String label) { Locator.XPathLocator l = Ext4Helper.Locators.window("Bulk Edit").append(Locator.tagContainingText("label", label + ":").withClass("x4-form-item-label")); @@ -237,6 +247,14 @@ public void toggleBulkEditField(String label) _test.waitForElement(l.enabled()); } + // This method toggles the bulk edit field that has the exact label + public void toggleBulkEditExactField(String label) + { + Locator.XPathLocator l = Ext4Helper.Locators.window("Bulk Edit").append(Locator.tagWithText("label", label + ":").withClass("x4-form-item-label")); + _test.shortWait().until(ExpectedConditions.numberOfElementsToBe(l, 1)).get(0).click(); + _test.waitForElement(l.enabled()); + } + public void discardForm() { WebElement dataEntryButton = getDataEntryButton("More Actions").findElement(_test.getDriver());