← Shopware 6.3.2.0

Shopware 6.3.2.0 document

Generated documents (invoices, credit notes, delivery notes, cancellations) linked to orders.

Columns

14 columns

Column Type Nullable Additional
id binary(16) NO Primary Key
document_type_id binary(16) NO Index Foreign Key → document_type.id
referenced_document_id binary(16) YES Index Foreign Key → document.id
file_type varchar(255) NO
order_id binary(16) NO Index Foreign Key → order.id
order_version_id binary(16) NO Foreign Key → order.version_id
config longtext YES
sent tinyint(1) NO Default: 0
static tinyint(1) NO Default: 0
deep_link_code varchar(32) NO Unique
document_media_file_id binary(16) YES Index Foreign Key → media.id
custom_fields longtext YES
created_at datetime(3) NO
updated_at datetime(3) YES

Indexes

6 indexes

Index Name Columns Unique
fk.document.document_media_file_id document_media_file_id No
fk.document.document_type_id document_type_id No
fk.document.order_id order_id,order_version_id No
fk.document.referenced_document_id referenced_document_id No
PRIMARY id Yes
uniq.deep_link_code deep_link_code Yes

Relations (from this table)

5 relations

Local Field Foreign Table Foreign Field
document_media_file_id media id
document_type_id document_type id
order_id order id
order_version_id order version_id
referenced_document_id document id

Relations (to this table)

1 relations

Local Field Foreign Table Foreign Field
id document referenced_document_id