The Asset Types feature enables you to configure different groups of metadata fields for different types of asset (as many as you need) and to define complex relationships between asset records (e.g. parent/child). Some business-use cases from our clients include:
- Having a 'Producer' field for video assets, that does not appear on image assets
- Having model release forms that are uploaded as child assets, that themselves have no metadata fields (to avoid re-keying information that is inherited from the parent asset)
- Having a child asset that is a ZIP file that contains the artwork files, fonts, etc. that were used to create the parent asset, e.g. a PDF brochure.
Configuration
Most asset type configuration is accessed from the Admin > Asset Types page. Here you can add, edit, remove and reorder asset types.
Note that you will not be able to delete an asset type when there are assets of that type in the system. You will first have to delete all the assets of this type first. This can be done by searching for all such assets, then choosing the 'Export all results' option and after the export choosing to 'Delete exported files'.
Asset Types can be reordered by dragging and dropping or, in older versions, by clicking the up/down links. This will define the ordering of the asset types when they appear in a list, for example when the user is prompted to choose a type to upload or search.
The options when adding or editing asset types are detailed below.
Name
This is the name as it appears to users, e.g. Photograph in the above example.
Media Types
You can select which media types (file, image, video, audio) the asset type should accept. If you do not select any of the available options, the asset type will be 'metadata only' and will not allow file uploads. This is typically useful when a particular asset type is being used to group other assets, although in this case consider whether Asset Bank's category functionality is more suitable to your needs.
In addition to selecting the media types, you can provide a list of file formats that should be included or excluded from the asset type. The list of file formats should take the form of a comma-separated list of file extensions, without the dot (e.g. "jpg,jpeg,gif,png"). Note that you cannot specify both an included and an excluded list - when you provide an included list all other formats are implicitly excluded, and vice versa.
Once set, the included/excluded list of file extensions will (along with the media types) dictate what types of files can be uploaded to a particular asset type. If the user tries to upload a file that is not supported (or where applicable not supported by the asset type that they have chosen) they will be shown a message informing them of the problem and the file will not be uploaded.
Setting up the assets types to be as restrictive as possible in this manner has 2 advantages.
- You can ensure the suitability of the uploaded files for your organisation (e.g. make sure that all documents are in Word format).
- Uploading users will not have to choose an asset type when in fact only one type is applicable for the file they are trying to upload.
This latter advantage is due to the fact that Asset Bank will work out whether it's possible for any one file type to have more than one corresponding asset type, and only shows the choice of asset types if it is.
Note that using the included/excluded file format list in combination with the media types may result in 'nonsensical' configurations where an asset type requires a file but will not accept any particular formats (e.g. selecting only media type 'Image' but setting the included file formats to be "doc").
Attributes
You can choose which attributes are available to the asset type. If you do not choose any of the available options, and have not selected any media types, it may be that a category is a better solution than an asset type.
Note that when you add new attributes in the Admin > Attributes section they will not be selected for any asset types automatically; you will have to return here to select them. Also be aware that if you de-select an attribute from an asset type, any data associated with that attribute for any existing assets will be lost and cannot be recovered.
There is also an option to hide a particular attribute on add. This means that when a user uploads an asset of this asset type then this particular attribute will be hidden. It will be visible and editable as normal when editing the asset.
If you choose to hide an attribute on add you can also give it a default value. This will automatically set the value of the attribute for any newly uploaded assets of this type - it will not update existing assets' attribute values.
If your Asset Bank is on version 3.1574 or above, then you also have the option of defining which attributes show on the view and edit asset pages for each individual Asset Type. The attribute list on the edit Asset Type page is still used to define which attributes are available/applicable to the Asset Type but you can also selective exclude or change the order of the attributes on the view and edit pages for each individual Asset Type. For more see Manage Attribute Display and Choosing Attributes for Asset Types.
Show Attribute Labels
This option can be unselected to hide the labels of metadata attributes when viewing an asset of this type. This is typically useful when a type is set up to have a small number of attributes whose value is sufficiently clear.
Match Attribute
There are 2 scenarios where the 'match attribute' can be significant: when adding/updating files to existing assets, and when adding additional file variants to an existing asset as 'children'. These operations are described below:
1) Adding files to existing assets:
When Asset Bank is configured to allow empty asset records (i.e. setting allow-empty-assets=true) it is possible to add a number of empty assets, and then at a later stage add the asset files to those empty asset records. In order for Asset Bank to match up these empty asset records and the files, it uses the 'match attribute' that is set for the asset type in question. For example, if the match attribute for a type called Photo Shoot is set to be ID and you add some empty assets of this type, you can then (at some later time) bulk upload some files whose filename matches the ID of the empty records (ignoring the file extension, e.g. 1234.jpg) and have them attached to the empty Photo Shoot records.
2) Adding child assets:
If the asset type is configured to have parents (and at least one asset type is configured to be able to have this type as a child) then the match attribute can be used to automatically link new child assets with their parent. An example of where this is useful is when there is a requirement to have variants of a particular asset file in different file formats (say, a Word file that also has a PDF variant). In this case the parent asset will be the original file, and it will have a child asset that is the variant. If the child asset type has a match attribute selected (say, 'Original filename') then it will be possible to bulk-upload files with the option 'Add new child assets to existing parents' where any files found whose filename match the original filename of a parent asset (ignoring the extension) will be linked to the parent assets as its child. So in our example, if we bulk-upload a file called AnnualReport.pdf and there is an existing parent asset whose filename is AnnualReport.doc, the new asset for AnnualReport.pdf will be created as a child type and linked to the parent.
Default Category Id
You can provide the id of a category that will be automatically selected when adding new assets of this type. The user will be free to add other categories. If you select 'Only allow this category' then all assets of this type will automatically only be in the chosen category and users will not be able to edit the categories of the asset. Whenever a pre-existing asset of this type is edited, its categories will be changed to match the new default category. You can do this immediately by ticking 'Update existing instances' which will require a re-index of the affected assets.
Can create copies
This option allows you to choose whether it will be possible to make copies of assets of this type. This will also require setting can-create-asset-copies to be set to true.
Can download children from parent page
If this option is selected, there will be a button 'Download Children' when viewing a parent asset that has children. Clicking this button will show a page listing all the child assets, giving the choice to download them individually or together in a zip file.
Show when browsing descendant categories
If this option is selected, then whenever an instance of this asset type is created in a category X it will be browseable in the category itself as normal but will also be visible when browsing any sub category of X. Having this setting enabled is what triggers the "associated assets" section, so if you are not specifically requiring this functionality we recommend you disable it as it can otherwise case some pages to load slowly.
Searchable
If one or more of the asset types in the system have this checkbox selected, only assets of the selected types will be returned in searches. Note that if no asset types have this option selected all types will be returned in searches (but the 'Asset type' option won't be present on the advanced search page).
Quick searchable
If one or more of the asset types in the system have this checkbox selected, only assets of the selected types will be returned in quick searches (i.e. those performed from the homepage or page header). Note that if no asset types have this option selected all types will be returned in quick searches.
Article
Tick this checkbox if you want assets in this asset type to display more like articles then assets when a user views them.
Uploadable by the 'logged-in users' group?
Tick this checkbox if you want all users to immediately be able to upload assets of this type. If you want to only allow certain groups to upload assets of this type then un-tick it. You can use the 'Groups' page to manage which groups are allowed to upload assets of a particular asset type.
Run immediate reindex of instances of this entity
There are a number of options on the edit asset type page that are only reflected on the front end of Asset Bank after assets have been reindexed. Clicking this checkbox prior to saving an asset type will launch an immediate reindex after the save that just reindexes instances of the type in question. There is an info message at the top of the edit Asset Type page that explains which elements of the type require a reindex if they are changed.
Other Asset Type Settings:
maximum-parent-links-on-view - This setting in the ApplicationSettings.properties file details how many parent asset links will be shown on a child's view asset page. Setting this to 0 will hide the parent asset links section (which appears below the preview image on the view asset page) completely.
Technical Notes for our self-hosted customers:
Recent versions of Asset Bank have Asset Types enabled by default and your license will determine whether you can use the functionality or not. Older versions require the asset type functionality to be enabled via a setting change (and may require database updates if you already have some assets in your asset bank, see Enabling Asset Types when Assets Already Exist). Check whether your Asset Bank has the setting 'asset-entities-enabled' in it's setting file to determine whether you need to enable it or not. If you need to enable it then update the following setting within the ApplicationSettings.properties file:
# Is creating and managing 'types' of assets allowed?
asset-entities-enabled=true
Once the change has been made restart the application via the Apache Tomcat service for it to take effect.
Note: In either case your license has to support the use of Asset Types - if you're not sure whether it does please get in touch.
Comments
0 comments
Please sign in to leave a comment.