DVERSION: Document Version
A document version with workflow status, file upload, review/approval panels, and comment threads.
DVERSION definition shipped with DemandFlow. Administrators can add, remove, rename, or re-type fields, change which ones are required, and alter the layout from the Definitions screen in Settings. Your tenant's current schema may differ from what is shown here. To read the current definition at any time, GET the DEFINITION object whose id matches DVERSION.Entity properties
| Property | Value |
|---|---|
| Entity code | DVERSION |
| Display name | Document Version |
| Plural | Document Versions |
| Level | 12041 |
Use cases
DVERSION represents a specific version of a document record (DRECORD), linked via comboKey SUB|DRECORD|DVERSION. The version workflow follows a QMS-compliant lifecycle: Draft > Under Review > Pending Approval > Approved > Released > Obsolete/Rejected. Status transitions are permission-controlled (controller role required), with some terminal states (Approved, Released, Rejected, Obsolete) restricted to controllers. The file upload uses singlefile mode with singlefile:true, restricted to PDF/DOC/DOCX. The setmime and setsize properties auto-populate mimetype and filesize fields from the uploaded file. Comments (DCOMMENT) are linked via the four-part comboKey SUB|DRECORD|DVERSION|DCOMMENT. The Reviews and Approvals panels use custom row types (dversionreviews, dversionapprovals) with panel-level visibility conditions that show them only when the version has reached the appropriate workflow stage. The permissionsFunc getPermissionsDversion provides version-specific access control.
Fields
Version Information
| Field | Type | Required | Notes |
|---|---|---|---|
ref | text | Version ref.. Read only. | |
name | number | Yes | e.g. 1.0, 1.1, 2.0 Read only. |
revisionNote | text (multi-line) | Revision Note. | |
status | enum | Yes | Valid ids: draft (Draft), under_review (Under Review), pending_approval (Pending Approval), approved (Approved), released (Released), rejected (Rejected), obsolete (Obsolete). |
ownerId | reference → user | Created By. Read only. | |
created | date | Created Date. Read only. | |
approvedBy | reference → USER | Approved By. Read only. | |
approvedDate | date | Approval Date. Read only. |
File Information
| Field | Type | Required | Notes |
|---|---|---|---|
mimetype | text | Mime type. Read only. | |
filesize | text | File size (bytes). Read only. |
Attachments
| Field | Type | Required | Notes |
|---|---|---|---|
attachments | file | Allowed types: any. |
Relationships
- Lookup:
approvedBy(reference →USER). - Related list:
DCOMMENT, comboKey formatSUB|DRECORD|DVERSION|DCOMMENT.
Creating a Document Version via the API
POST /v1/objects
Authorization: Bearer <your-pat>
Content-Type: application/json
{
"entity": "DVERSION",
"level": 12041,
"comboKey": "SUB:<your-sub-id>|ENT:",
"status": "draft",
"revisionNote": "Example value"
}
Listing Document Versions records
GET /v1/entities/DVERSION/SUB:<your-sub-id>