Commit d6044b9027558d5a43b2ad746ce6f7752623fc8e

Authored by mykhaly
1 parent ff39624d

Add `Отримати internal id по UAid для скарги` keyword

... ... @@ -351,6 +351,11 @@ Library openprocurement_client_helper.py
351 351 ##############################################################################
352 352 # Claims
353 353 ##############################################################################
  354 +Отримати internal id по UAid для скарги
  355 + [Arguments] ${tender} ${complaintID}
  356 + ${complaint_internal_id}= get_complaint_internal_id ${tender} ${complaintID}
  357 + [Return] ${complaint_internal_id}
  358 +
354 359
355 360 Створити вимогу
356 361 [Documentation] Створює вимогу у статусі "draft"
... ...
1 1 from openprocurement_client.client import Client
2 2 from openprocurement_client.utils import get_tender_id_by_uaid
  3 +from openprocurement_client.exceptions import IdNotFound
3 4
4 5
5 6 def prepare_api_wrapper(key, host_url, api_version):
6 7 return Client(key, host_url, api_version)
  8 +
  9 +def get_complaint_internal_id(tender, complaintID):
  10 + for complaint in tender.data.complaints:
  11 + if complaint.complaintID == complaintID:
  12 + return complaint.id
  13 + raise IdNotFound
  14 +
... ...
Please register or login to post a comment