This repository has been archived by the owner on Sep 29, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added secure file media type and config files
- Loading branch information
1 parent
3feaf0f
commit 79da431
Showing
11 changed files
with
231 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
config/install/core.entity_form_display.media.secure_file.default.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.field.media.secure_file.field_secure_file | ||
- media.type.secure_file | ||
module: | ||
- file | ||
- path | ||
id: media.secure_file.default | ||
targetEntityType: media | ||
bundle: secure_file | ||
mode: default | ||
content: | ||
created: | ||
type: datetime_timestamp | ||
weight: 10 | ||
region: content | ||
settings: { } | ||
third_party_settings: { } | ||
field_secure_file: | ||
type: file_generic | ||
weight: 0 | ||
region: content | ||
settings: | ||
progress_indicator: throbber | ||
third_party_settings: { } | ||
name: | ||
type: string_textfield | ||
weight: -5 | ||
region: content | ||
settings: | ||
size: 60 | ||
placeholder: '' | ||
third_party_settings: { } | ||
path: | ||
type: path | ||
weight: 30 | ||
region: content | ||
settings: { } | ||
third_party_settings: { } | ||
status: | ||
type: boolean_checkbox | ||
weight: 100 | ||
region: content | ||
settings: | ||
display_label: true | ||
third_party_settings: { } | ||
uid: | ||
type: entity_reference_autocomplete | ||
weight: 5 | ||
region: content | ||
settings: | ||
match_operator: CONTAINS | ||
match_limit: 10 | ||
size: 60 | ||
placeholder: '' | ||
third_party_settings: { } | ||
hidden: { } |
26 changes: 26 additions & 0 deletions
26
config/install/core.entity_view_display.media.secure_file.default.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.field.media.secure_file.field_secure_file | ||
- media.type.secure_file | ||
module: | ||
- file | ||
id: media.secure_file.default | ||
targetEntityType: media | ||
bundle: secure_file | ||
mode: default | ||
content: | ||
field_secure_file: | ||
type: file_default | ||
label: visually_hidden | ||
settings: | ||
use_description_as_link_text: true | ||
third_party_settings: { } | ||
weight: 0 | ||
region: content | ||
hidden: | ||
created: true | ||
name: true | ||
thumbnail: true | ||
uid: true |
26 changes: 26 additions & 0 deletions
26
config/install/field.field.media.secure_file.field_secure_file.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- field.storage.media.field_secure_file | ||
- media.type.secure_file | ||
module: | ||
- file | ||
id: media.secure_file.field_secure_file | ||
field_name: field_secure_file | ||
entity_type: media | ||
bundle: secure_file | ||
label: File | ||
description: '' | ||
required: true | ||
translatable: true | ||
default_value: { } | ||
default_value_callback: '' | ||
settings: | ||
handler: 'default:file' | ||
handler_settings: { } | ||
file_directory: 'secure/[date:custom:Y]-[date:custom:m]' | ||
file_extensions: 'xls xlsx csv xlsm doc docx dotx pdf ppt pptx' | ||
max_filesize: '' | ||
description_field: true | ||
field_type: file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
module: | ||
- field_permissions | ||
- file | ||
- media | ||
third_party_settings: | ||
field_permissions: | ||
permission_type: custom | ||
id: media.field_secure_file | ||
field_name: field_secure_file | ||
entity_type: media | ||
type: file | ||
settings: | ||
target_type: file | ||
display_field: false | ||
display_default: false | ||
uri_scheme: private | ||
module: file | ||
locked: false | ||
cardinality: 1 | ||
translatable: true | ||
indexes: { } | ||
persist_with_no_fields: false | ||
custom_storage: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
langcode: en | ||
status: true | ||
dependencies: { } | ||
id: secure_file | ||
label: 'Secure File' | ||
description: '' | ||
source: file | ||
queue_thumbnail_downloads: false | ||
new_revision: false | ||
source_configuration: | ||
source_field: field_secure_file | ||
field_map: { } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
langcode: en | ||
status: true | ||
dependencies: { } | ||
id: secure | ||
path: /secure | ||
bypass: false | ||
grant_file_owners: false | ||
users: { } | ||
roles: | ||
dtf_secure_file_user: dtf_secure_file_user | ||
anonymous: '0' | ||
authenticated: '0' | ||
administrator: '0' | ||
approver: '0' | ||
site_admin: '0' | ||
editor: '0' | ||
previewer: '0' | ||
contributor: '0' | ||
site_auditor: '0' |
13 changes: 13 additions & 0 deletions
13
config/install/system.action.user_add_role_action.dtf_secure_file_user.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- user.role.dtf_secure_file_user | ||
module: | ||
- user | ||
id: user_add_role_action.dtf_secure_file_user | ||
label: 'Add the DTF Secure File User role to the selected user(s)' | ||
type: user | ||
plugin: user_add_role_action | ||
configuration: | ||
rid: dtf_secure_file_user |
13 changes: 13 additions & 0 deletions
13
config/install/system.action.user_remove_role_action.dtf_secure_file_user.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- user.role.dtf_secure_file_user | ||
module: | ||
- user | ||
id: user_remove_role_action.dtf_secure_file_user | ||
label: 'Remove the DTF Secure File User role from the selected user(s)' | ||
type: user | ||
plugin: user_remove_role_action | ||
configuration: | ||
rid: dtf_secure_file_user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
langcode: en | ||
status: true | ||
dependencies: | ||
config: | ||
- media.type.secure_file | ||
module: | ||
- field_permissions | ||
- media | ||
id: dtf_secure_file_user | ||
label: 'DTF Secure File User' | ||
weight: 102 | ||
is_admin: null | ||
permissions: | ||
- 'create field_secure_file' | ||
- 'create secure_file media' | ||
- 'delete any secure_file media' | ||
- 'delete any secure_file media revisions' | ||
- 'delete own secure_file media' | ||
- 'edit any secure_file media' | ||
- 'edit field_secure_file' | ||
- 'edit own field_secure_file' | ||
- 'edit own secure_file media' | ||
- 'revert any secure_file media revisions' | ||
- 'view any secure_file media revisions' | ||
- 'view field_secure_file' | ||
- 'view own field_secure_file' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters