Let's view transfer example for tender.
At first let's create a tender:
.. http:example:: tutorial/create-tender.http :code:
broker is current tender's owner
.
Note that response's access section contains a transfer
key which is used to change tender ownership.
After tender's registration in CDB broker has to provide its customer with transfer
key.
Broker that is going to become new tender owner should create a Transfer.
.. http:example:: tutorial/create-tender-transfer.http :code:
Transfer object contains new access token
and new transfer
token for the object that will be transferred to new broker.
Transfer can be retrieved by id:
.. http:example:: tutorial/get-tender-transfer.http :code:
An ability to change tender's ownership depends on tender's status:
Allowed | Not Alowwed |
belowThreshold | |
active.enquiries active.tendering active.auction active.qualification active.awarded |
complete cancelled unsuccessful |
aboveThresholdUA | |
active.tendering active.auction active.qualification active.awarded |
complete cancelled unsuccessful |
aboveThresholdEU | |
active.tendering active.pre-qualification active.pre-qualification.stand-still active.auction active.qualification active.awarded |
complete cancelled unsuccessful |
aboveThresholdUA.defense | |
active.tendering active.auction active.qualification active.awarded |
complete cancelled unsuccessful |
competitiveDialogueUA | |
active.tendering active.pre-qualification active.pre-qualification.stand-still active.stage2.pending |
active.stage2.waiting complete unsuccessful cancelled |
competitiveDialogueUA.stage2 | |
draft.stage2 active.tendering active.auction active.qualification active.awarded |
complete unsuccessful cancelled |
competitiveDialogueEU | |
active.tendering active.pre-qualification active.pre-qualification.stand-still active.stage2.pending |
active.stage2.waiting complete unsuccessful cancelled |
competitiveDialogueEU.stage2 | |
draft.stage2 active.tendering active.pre-qualification active.pre-qualification.stand-still active.auction active.qualification active.awarded |
complete unsuccessful cancelled |
esco | |
active.tendering active.pre-qualification active.pre-qualification.stand-still active.auction active.qualification active.awarded |
complete unsuccessful cancelled |
closeFrameworkAgreementUA | |
active.tendering active.pre-qualification active.pre-qualification.stand-still active.auction active.qualification active.qualification.stand-still active.awarded |
complete unsuccessful cancelled |
closeFrameworkAgreementSelectionUA | |
draftactive.enquiries active.tendering active.auction active.qualification active.awarded |
draft.pending draft.unsuccessful complete unsuccessful cancelled |
reporting | |
active | complete cancelled |
negotiation | |
active | complete cancelled |
negotiation.quick | |
active | complete |
To change tender's ownership new broker should send POST request to appropriate /tenders/id/ with data section containing id
of Transfer and transfer
token received from customer:
.. http:example:: tutorial/change-tender-ownership.http :code:
Updated owner
value indicates that ownership is successfully changed.
Note that new broker has to provide its customer with new transfer
key (generated in Transfer object).
After Transfer is applied it stores tender path in usedFor
property:
.. http:example:: tutorial/get-used-tender-transfer.http :code:
'Used' Transfer can't be applied to any other object.
Let's try to change the tender using token
received on Transfer creation:
.. http:example:: tutorial/modify-tender.http :code:
Pay attention that only broker with appropriate accreditation level can become new owner. Otherwise broker will be forbidden from this action.
.. http:example:: tutorial/change-tender-ownership-forbidden.http :code:
Also ownership change is allowed only if current owner has a special accreditation level that allows ownership change:
.. http:example:: tutorial/change-tender-ownership-forbidden-owner.http :code: