Commit 89dea5685e5d1117616352e24a0fe88a1c669043
1 parent
7195f126
Change the status of the complaint + getTenderDataByTenderComplaintsUaId
Showing
4 changed files
with
50 additions
and
2 deletions
| @@ -647,6 +647,12 @@ Resource playtender_agree | @@ -647,6 +647,12 @@ Resource playtender_agree | ||
| 647 | 647 | ||
| 648 | Run Keyword And Return Створити вимогу ${username} ${tender_uaid} tender null ${claim} null | 648 | Run Keyword And Return Створити вимогу ${username} ${tender_uaid} tender null ${claim} null |
| 649 | 649 | ||
| 650 | +Змінити статус скарги | ||
| 651 | + [Arguments] ${username} ${tender_uaid} ${complaintID} ${confirmation_data} | ||
| 652 | + [Documentation] Змінює статус скарги complaintID | ||
| 653 | + | ||
| 654 | + Run Keyword And Return Change the status of the complaint ${username} ${tender_uaid} ${complaintID} ${confirmation_data} | ||
| 655 | + | ||
| 650 | 656 | ||
| 651 | ######################################################################################################################## | 657 | ######################################################################################################################## |
| 652 | ################################################### END CLAIM KEYWORDS ############################################# | 658 | ################################################### END CLAIM KEYWORDS ############################################# |
| @@ -47,6 +47,18 @@ Resource playtender_claim | @@ -47,6 +47,18 @@ Resource playtender_claim | ||
| 47 | wait until page contains element with reloading ${claim_uaid_text_locator} | 47 | wait until page contains element with reloading ${claim_uaid_text_locator} |
| 48 | ${return_value}= get text ${claim_uaid_text_locator} | 48 | ${return_value}= get text ${claim_uaid_text_locator} |
| 49 | ${return_value}= Convert To String ${return_value} | 49 | ${return_value}= Convert To String ${return_value} |
| 50 | + | ||
| 51 | +# ${tender_с}= getTenderDataByTenderComplaintsUaId ${API_HOST_URL}/api/${API_VERSION} ${tender_uaid} | ||
| 52 | +# ${tender_с}= op_robot_tests.tests_files.service_keywords.Munchify ${tender_с} | ||
| 53 | + | ||
| 54 | +# Log ${tender_с} | ||
| 55 | + # bof - fix # | ||
| 56 | + ${tender_cdb_data}= getTenderDataByTenderComplaintsUaId ${API_HOST_URL}/api/${API_VERSION} ${tender_uaid} | ||
| 57 | + ${tender_cdb_data}= op_robot_tests.tests_files.service_keywords.Munchify ${tender_cdb_data} | ||
| 58 | + Set To Dictionary ${USERS.users['${username}']} tender_data=${tender_cdb_data} | ||
| 59 | + Log ${USERS.users['${username}']}.tender_data} | ||
| 60 | + # eof - fix # | ||
| 61 | + | ||
| 50 | [return] ${return_value} | 62 | [return] ${return_value} |
| 51 | 63 | ||
| 52 | Скасувати вимогу | 64 | Скасувати вимогу |
| @@ -286,3 +298,27 @@ Wait For Declined | @@ -286,3 +298,27 @@ Wait For Declined | ||
| 286 | Page Should Contain Element ${claim_status_value_locator} | 298 | Page Should Contain Element ${claim_status_value_locator} |
| 287 | 299 | ||
| 288 | 300 | ||
| 301 | +Change the status of the complaint | ||
| 302 | + [Arguments] ${username} ${tender_uaid} ${complaintID} ${confirmation_data} | ||
| 303 | + [Documentation] Змінює статус скарги complaintID | ||
| 304 | + | ||
| 305 | + open tender page by uaid ${tender_uaid} | ||
| 306 | + log many ${confirmation_data} | ||
| 307 | + capture page screenshot | ||
| 308 | + click visible element ${claim_page_open_btn_locator} | ||
| 309 | + capture page screenshot | ||
| 310 | + ${claim_open_form_answer_locator} = replace string ${claim_open_form_answer_btn_locator_tpl} %title% ${complaintID} | ||
| 311 | + capture page screenshot | ||
| 312 | + wait until page contains element with reloading ${claim_open_form_answer_locator} | ||
| 313 | + capture page screenshot | ||
| 314 | + ${claim_form_open_form_change_status_btn_locator} = replace string ${claim_form_open_form_change_status_btn_locator_tpl} %title% ${complaintID} | ||
| 315 | + capture page screenshot | ||
| 316 | + wait until page contains element with reloading ${claim_form_open_form_change_status_btn_locator} | ||
| 317 | + capture page screenshot | ||
| 318 | + open popup by btn locator ${claim_form_open_form_change_status_btn_locator} | ||
| 319 | + capture page screenshot | ||
| 320 | + input text to exist visible input ${claim_form_change_status_resolution_value_locator} ${confirmation_data.data.tendererAction} | ||
| 321 | + capture page screenshot | ||
| 322 | + submit form and check result ${claim_form_change_status_success_btn_locator} ${claim_form_change_status_submit_success_msg} | ||
| 323 | + capture page screenshot | ||
| 324 | + |
| @@ -53,3 +53,9 @@ ${claim_form_answer_success_btn_locator} = jquery=#tend | @@ -53,3 +53,9 @@ ${claim_form_answer_success_btn_locator} = jquery=#tend | ||
| 53 | ${claim_form_answer_submit_success_msg} = Відповідь на вимогу надана, дочекайтесь опублікування на сайті уповноваженого органу. | 53 | ${claim_form_answer_submit_success_msg} = Відповідь на вимогу надана, дочекайтесь опублікування на сайті уповноваженого органу. |
| 54 | ${claim_form_status_locator_tpl} = .complaint-info-wrapper .info-row.status-source.hidden:contains(%query%) | 54 | ${claim_form_status_locator_tpl} = .complaint-info-wrapper .info-row.status-source.hidden:contains(%query%) |
| 55 | ${claim_form_satisfied_value_locator_tpl} = .complaint-info-wrapper .info-row.satisfied .value:contains(%query%) | 55 | ${claim_form_satisfied_value_locator_tpl} = .complaint-info-wrapper .info-row.satisfied .value:contains(%query%) |
| 56 | + | ||
| 57 | +${claim_form_open_form_change_status_btn_locator_tpl} = jquery=#tender-complaint-list .js-item div[data-complaint-id*="%title%"] div.actions-wrapper a[href*="/tender-complaint/resolve"] | ||
| 58 | +${claim_form_change_status_resolution_value_locator} = jquery=#complaint-resolve-form .field-complaintresolveform-tenderer_action #complaintresolveform-tenderer_action | ||
| 59 | +${claim_form_change_status_submit_success_msg} = Підтведження вирішення скарги успішно надане. | ||
| 60 | +${claim_form_change_status_success_btn_locator} = jquery=#complaint-resolve-form .js-submit-btn | ||
| 61 | + |
| @@ -464,7 +464,7 @@ def prepare_tender_data_cancellation(data_original): | @@ -464,7 +464,7 @@ def prepare_tender_data_cancellation(data_original): | ||
| 464 | 464 | ||
| 465 | return b | 465 | return b |
| 466 | 466 | ||
| 467 | -def getTenderDataByTenderCancellationsUaId(apiBaseUrl, tenderUaId): | 467 | +def getTenderDataByTenderComplaintsUaId(apiBaseUrl, tenderUaId): |
| 468 | requestData = {"opt_fields": "tenderID", "descending": "1", "mode": "_all_"} | 468 | requestData = {"opt_fields": "tenderID", "descending": "1", "mode": "_all_"} |
| 469 | updatesResponse = doGetRequest(apiBaseUrl.strip("/") + "/tenders", data=requestData) | 469 | updatesResponse = doGetRequest(apiBaseUrl.strip("/") + "/tenders", data=requestData) |
| 470 | if "json" not in updatesResponse: | 470 | if "json" not in updatesResponse: |
| @@ -479,7 +479,7 @@ def getTenderDataByTenderCancellationsUaId(apiBaseUrl, tenderUaId): | @@ -479,7 +479,7 @@ def getTenderDataByTenderCancellationsUaId(apiBaseUrl, tenderUaId): | ||
| 479 | break | 479 | break |
| 480 | if tenderId is None: | 480 | if tenderId is None: |
| 481 | return {} | 481 | return {} |
| 482 | - tenderDataResponse = doGetRequest(apiBaseUrl.strip("/") + "/tenders/" + tenderId + "/cancellations", data={}) | 482 | + tenderDataResponse = doGetRequest(apiBaseUrl.strip("/") + "/tenders/" + tenderId + "/complaints", data={}) |
| 483 | tenderDataJson = tenderDataResponse['json'] | 483 | tenderDataJson = tenderDataResponse['json'] |
| 484 | return tenderDataJson | 484 | return tenderDataJson |
| 485 | 485 |
Please
register
or
login
to post a comment