Add MR Approvers to Project Export/Import
ZD Ticket that spawned this: https://gitlab.zendesk.com/agent/tickets/103135
Repro Steps:
- Create a repo.
- Turn on project approvers.
- Turn on self-approvers.
- Add a readme.
- Create a new branch "test-mr".
- Create an update to readme.
- Create MR named "Update Readme."
- Approve MR.
- Export Project.
- Review project.json and see there is no data to correlate approver.
Notes:
Literally, we store a note that shows who approved it, but the UI on an imported instance will still ask for approvers.
"notes": [
{
"attachment": {
"url": null
},
"author": {
"name": "Lee Matos"
},
"author_id": 695248,
"change_position": null,
"commit_id": null,
"created_at": "2018-09-19T18:14:02.868Z",
"discussion_id": "1a025866d818688034204dcb97cd2c8fbaa02a41",
"events": [],
"id": 102805157,
"line_code": null,
"note": "approved this merge request",
"noteable_id": 16614825,
"noteable_type": "MergeRequest",
"original_position": null,
"position": null,
"project_id": 8461019,
"resolved_at": null,
"resolved_by_id": null,
"resolved_by_push": null,
"st_diff": null,
"system": true,
"updated_at": "2018-09-19T18:14:02.868Z",
"updated_by_id": null
}
],
See my sample project here with project.json output:
Edited by Haris Delalić