Skip to content

Commit 88179c6

Browse files
authored
Merge pull request #119 from itk-dev-rpa/hotfix/missing-approve-all-button
changed approve buttons to use find elements, allowing a check if we …
2 parents f5edc57 + b894996 commit 88179c6

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

changelog.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [2.14.1] - 2025-09-05
11+
12+
### Fixed
13+
14+
- In case the "Godkend Alle" button does not exist, the robot will now correctly progress.
15+
1016
## [2.14.0] - 2025-08-22
1117

1218
### Changed

itk_dev_shared_components/eflyt/eflyt_case.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,9 +144,9 @@ def approve_case(browser: webdriver.Chrome):
144144
browser.find_element(By.ID, "ctl00_ContentPlaceHolder2_ptFanePerson_stcPersonTab1_btnGodkend").click()
145145
browser.find_element(By.ID, "ctl00_ContentPlaceHolder2_ptFanePerson_stcPersonTab1_btnApproveYes").click()
146146

147-
approve_persons_button = browser.find_element(By.ID, "ctl00_ContentPlaceHolder2_ptFanePerson_stcPersonTab1_btnGodkendAlle")
148-
if approve_persons_button.is_enabled():
149-
approve_persons_button.click()
147+
approve_persons_button = browser.find_elements(By.ID, "ctl00_ContentPlaceHolder2_ptFanePerson_stcPersonTab1_btnGodkendAlle")
148+
if any(approve_persons_button) and approve_persons_button[0].is_enabled():
149+
approve_persons_button[0].click()
150150
else:
151151
# Approve each person individually
152152
person_count = len(browser.find_elements(By.XPATH, '//table[@id="ctl00_ContentPlaceHolder2_GridViewMovingPersons"]//tr')) - 1

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "itk_dev_shared_components"
7-
version = "2.14.0"
7+
version = "2.14.1"
88
authors = [
99
{ name="ITK Development", email="itk-rpa@mkb.aarhus.dk" },
1010
]

0 commit comments

Comments
 (0)