Commit 6dcdcd9fd3417d504af1842691c768ee75507c0c
1 parent
3921043a
add cancel complaint keywords/cancel qualification complaint id search to api user
Showing
2 changed files
with
41 additions
and
5 deletions
| @@ -992,9 +992,9 @@ Library openprocurement_client.utils | @@ -992,9 +992,9 @@ Library openprocurement_client.utils | ||
| 992 | [return] ${reply.data.complaintID} | 992 | [return] ${reply.data.complaintID} |
| 993 | 993 | ||
| 994 | 994 | ||
| 995 | -Створити чернетку вимоги/скарги на скасування лота | ||
| 996 | - [Documentation] Створює вимогу/скаргу на скасування лота у статусі "draft" | ||
| 997 | - [Arguments] ${username} ${tender_uaid} ${data} ${canellations_index} | 995 | +Створити чернетку вимоги/скарги на скасування |
| 996 | + [Documentation] Створює вимогу/скаргу на скасування у статусі "draft" | ||
| 997 | + [Arguments] ${username} ${tender_uaid} ${data} ${cancellations_index} | ||
| 998 | Log ${data} | 998 | Log ${data} |
| 999 | ${tender}= openprocurement_client.Пошук тендера по ідентифікатору | 999 | ${tender}= openprocurement_client.Пошук тендера по ідентифікатору |
| 1000 | ... ${username} | 1000 | ... ${username} |
| @@ -1005,7 +1005,7 @@ Library openprocurement_client.utils | @@ -1005,7 +1005,7 @@ Library openprocurement_client.utils | ||
| 1005 | ... create_cancellations_complaint | 1005 | ... create_cancellations_complaint |
| 1006 | ... ${tender.data.id} | 1006 | ... ${tender.data.id} |
| 1007 | ... ${data} | 1007 | ... ${data} |
| 1008 | - ... ${tender.data.canellations[${canellations_index}].id} | 1008 | + ... ${tender.data.cancellations[${canсellations_index}].id} |
| 1009 | ... access_token=${tender.access.token} | 1009 | ... access_token=${tender.access.token} |
| 1010 | Log ${reply} | 1010 | Log ${reply} |
| 1011 | Set To Dictionary ${USERS.users['${username}']} complaint_access_token=${reply.access.token} | 1011 | Set To Dictionary ${USERS.users['${username}']} complaint_access_token=${reply.access.token} |
| @@ -1265,7 +1265,7 @@ Library openprocurement_client.utils | @@ -1265,7 +1265,7 @@ Library openprocurement_client.utils | ||
| 1265 | ... ELSE set_access_key ${tender} ${USERS.users['${username}'].complaint_access_token} | 1265 | ... ELSE set_access_key ${tender} ${USERS.users['${username}'].complaint_access_token} |
| 1266 | ${complaint_internal_id}= openprocurement_client.Отримати internal id по UAid для скарги ${tender} ${complaintID} | 1266 | ${complaint_internal_id}= openprocurement_client.Отримати internal id по UAid для скарги ${tender} ${complaintID} |
| 1267 | Set To Dictionary ${confirmation_data.data} id=${complaint_internal_id} | 1267 | Set To Dictionary ${confirmation_data.data} id=${complaint_internal_id} |
| 1268 | - ${reply}= Call Method ${USERS.users['${username}'].client} patch_award_complaint | 1268 | + ${reply}= Call Method ${USERS.users['${username}'].client} patch_qualification_complaint |
| 1269 | ... ${tender.data.id} | 1269 | ... ${tender.data.id} |
| 1270 | ... ${confirmation_data} | 1270 | ... ${confirmation_data} |
| 1271 | ... ${tender.data.qualifications[${qualification_index}].id} | 1271 | ... ${tender.data.qualifications[${qualification_index}].id} |
| @@ -1296,6 +1296,28 @@ Library openprocurement_client.utils | @@ -1296,6 +1296,28 @@ Library openprocurement_client.utils | ||
| 1296 | Log ${tender} | 1296 | Log ${tender} |
| 1297 | Log ${reply} | 1297 | Log ${reply} |
| 1298 | 1298 | ||
| 1299 | + | ||
| 1300 | +Змінити статус скарги на скасування | ||
| 1301 | + [Documentation] Переводить скаргу в cancellations тендера в інший статус | ||
| 1302 | + [Arguments] ${username} ${tender_uaid} ${complaintID} ${cancellations_index} ${confirmation_data} | ||
| 1303 | + ${tender}= openprocurement_client.Пошук тендера по ідентифікатору | ||
| 1304 | + ... ${username} | ||
| 1305 | + ... ${tender_uaid} | ||
| 1306 | + run keyword if '${username}' == 'Tender_Owner' set_access_key ${tender} ${USERS.users['${username}'].access_token} | ||
| 1307 | + ... ELSE IF '${username}' == 'Amcu_User' set_access_key ${tender} ${None} | ||
| 1308 | + ... ELSE IF '${username}' == 'Payment_User' set_access_key ${tender} ${None} | ||
| 1309 | + ... ELSE set_access_key ${tender} ${USERS.users['${username}'].complaint_access_token} | ||
| 1310 | + ${complaint_internal_id}= openprocurement_client.Отримати internal id по UAid для скарги ${tender} ${complaintID} | ||
| 1311 | + Set To Dictionary ${confirmation_data.data} id=${complaint_internal_id} | ||
| 1312 | + ${reply}= Call Method ${USERS.users['${username}'].client} patch_cancellation_complaint | ||
| 1313 | + ... ${tender.data.id} | ||
| 1314 | + ... ${confirmation_data} | ||
| 1315 | + ... ${tender.data.cancellations[${cancellations_index}].id} | ||
| 1316 | + ... ${complaint_internal_id} | ||
| 1317 | + ... access_token=${tender.access.token} | ||
| 1318 | + Log ${tender} | ||
| 1319 | + Log ${reply} | ||
| 1320 | + | ||
| 1299 | ################################################################## | 1321 | ################################################################## |
| 1300 | # OLD VERSION CLAIMS/COMPLAINTS | 1322 | # OLD VERSION CLAIMS/COMPLAINTS |
| 1301 | ################################################################## | 1323 | ################################################################## |
| @@ -100,6 +100,20 @@ def get_complaint_internal_id(tender, complaintID): | @@ -100,6 +100,20 @@ def get_complaint_internal_id(tender, complaintID): | ||
| 100 | return complaint.id | 100 | return complaint.id |
| 101 | except AttributeError: | 101 | except AttributeError: |
| 102 | pass | 102 | pass |
| 103 | + try: | ||
| 104 | + for qualification in tender.data.qualifications: | ||
| 105 | + for complaint in qualification.complaints: | ||
| 106 | + if complaint.complaintID == complaintID: | ||
| 107 | + return complaint.id | ||
| 108 | + except AttributeError: | ||
| 109 | + pass | ||
| 110 | + try: | ||
| 111 | + for cancellation in tender.data.cancellations: | ||
| 112 | + for complaint in cancellation.complaints: | ||
| 113 | + if complaint.complaintID == complaintID: | ||
| 114 | + return complaint.id | ||
| 115 | + except AttributeError: | ||
| 116 | + pass | ||
| 103 | raise IdNotFound | 117 | raise IdNotFound |
| 104 | 118 | ||
| 105 | 119 |
Please
register
or
login
to post a comment