Cập nhật quy trình chứng từ
Ngày cập nhật: 09 tháng 01, 2025
Người cập nhật: VNPT eContract's team
Mục đích
Hàm thực hiện cập nhật thông tin quy trình xử lý chứng từ, bao gồm thông tin: người xử lý, vị trí / tọa độ, quyền xử lý trên chứng từ đó.
- Request URL:
/api/documents/update-process
- HTTP method:
POST
- HTTP content-type:
application/json
- Authorize:
Bearer token
- Parameter:
Key | Type | Description |
---|---|---|
id | string | [Bắt buộc] Id chứng từ cần cập nhật quy trình |
processInOrder | boolean | Cấu hình mẫu chứng từ là tuần tự hay không tuần tự: true: quy trình xử lý tuần tự false: quy trình xử lý không tuần tự |
processes | Array[object] | Mảng thông tin người tham gia và xử lý chứng từ trong quy trình: { "orderNo": Số thứ tự xử lý trong quy trình, "processedByUserCode": Mã của người xử lý trong quy trình, "accessPermissionCode": Mã quyền xử lý chứng từ trong quy trình, "position": Vị trí tọa độ của khung chữ ký, "pageSign": Trang đặt khung chữ ký } |
mẹo
accessPermissionCode là các quyền truy cập xử lý chứng từ:
- V là chỉ xem
- D là ký số
- E là ký điện tử
- EKYC là ký eKYC
- DR là ký nháy
- A là phê duyệt
- F là điền dữ liệu
- C là điều phối
Caution
F luôn được xếp trước D, E, EKYC và DR trong quy trình xử lý tuần tự.
Mẫu request
{
"id": "73f4e64c-521e-457f-013f-08dad829ec1c",
"processInOrder": true,
"processes": [
{
"orderNo": 1,
"processedByUserCode": "baoth",
"accessPermissionCode": "DR",
"position": "20,750,150,820",
"pageSign": 1
},
{
"orderNo": 2,
"processedByUserCode": "phannhan",
"accessPermissionCode": "D",
"position": "440,750,570,820",
"pageSign": 1
},
{
"orderNo": 3,
"processedByUserCode": "usercode",
"accessPermissionCode": "A"
}
]
}
Mẫu response body
{
"data": {
"id": "73f4e64c-521e-457f-013f-08dad829ec1c",
"createdDate": "2022-12-07T15:06:17.9285943",
"lastModifiedDate": "2022-12-07T15:07:33.5124703+07:00",
"no": "Test0.6228890976236303",
"subject": "Test0.6228890976236303",
"hasVerified": false,
"fileType": 0,
"status": {
"value": 1,
"description": "New document"
},
"contractStatus": {
"value": 0,
"description": "Undefined"
},
"description": "Test tạo mới chứng từ bằng API",
"createdByUserId": 2341,
"processRecipientCount": 2,
"processInOrder": false,
"isWaitToSignDraw": false,
"isWaitToSignDigital": false,
"isWaitToApprove": false,
"isCancelable": true,
"isEditable": true,
"isShareable": false,
"isAccessable": false,
"isExpired": false,
"canDownload": false,
"processes": [
{
"id": "9ba763ea-e6f2-4dfb-b6de-08dad82a185b",
"createdDate": "2022-12-07T15:07:33.5122804+07:00",
"comId": 164,
"isOrder": false,
"orderNo": 1,
"pageSign": 0,
"displayType": {
"value": 0,
"description": "0"
},
"accessPermission": {
"value": 1,
"description": "View only"
},
"status": {
"value": 1,
"description": "Waiting"
},
"processedByUserId": 2341,
"documentId": "73f4e64c-521e-457f-013f-08dad829ec1c"
},
{
"id": "04434de3-4bd4-4576-b6df-08dad82a185b",
"createdDate": "2022-12-07T15:07:33.5124667+07:00",
"comId": 164,
"isOrder": false,
"orderNo": 2,
"pageSign": 0,
"displayType": {
"value": 0,
"description": "0"
},
"accessPermission": {
"value": 2,
"description": "Sign draw"
},
"status": {
"value": 1,
"description": "Waiting"
},
"processedByUserId": 2341,
"documentId": "73f4e64c-521e-457f-013f-08dad829ec1c"
},
{
"id": "40259656-d5fb-4a3b-b6e0-08dad82a185b",
"createdDate": "2022-12-07T15:07:33.5124699+07:00",
"comId": 164,
"isOrder": false,
"orderNo": 3,
"pageSign": 0,
"displayType": {
"value": 0,
"description": "0"
},
"accessPermission": {
"value": 3,
"description": "Approve"
},
"status": {
"value": 1,
"description": "Waiting"
},
"processedByUserId": 2341,
"documentId": "73f4e64c-521e-457f-013f-08dad829ec1c"
}
],
"histories": [
{
"createdDate": "2022-12-07T15:07:33.5125307+07:00",
"requestType": {
"value": 0,
"description": "Web"
},
"ipAddress": "10.70.39.66",
"activity": {
"value": 2,
"description": "Update document"
}
}
],
"messages": [],
"downloadUrl": "{HOST}/Api/Download?token=..."
},
"success": true,
"code": 0,
"messages": [
"Update document success"
]
}