Configuring Asset Download - Business Rules and Bulk Updates

When the Asset Download component is first installed, many of the configurations necessary to run the solution are installed automatically. This topic covers the pre-configured business action operation 'Create Assets from URL,' the public JavaScript API method to download assets, and the 'Create Assets from URL' bulk update operation.

Create Assets from URL – Business Action Operation

Though a business rule itself is not created when Asset Download is installed, a business action operation for asset downloads is created, called Create Assets from URL, which is located under the Assets category. This action is used for synchronous operations, meaning that each operation has to wait for another operation to complete before another can be run. The business action works on a product level and looks at a specified attribute which contains asset file URLs. If a file URL is found, the asset is downloaded, created, and an asset reference is created according to the configuration.

Create Assets From URL - Business Rule Configurations

The following configurations are required for the business action to function.

  • Product URL Attribute: This field contains the URL that exists on the product object. Click the ellipsis button () to the right of the field to browse to or search for the relevant attribute. Only one attribute can be selected.
  • Asset Reference Type: Specify the asset reference type that will be used to link the downloaded asset to the product object(s). Click the ellipsis button () to the right of the field to browse to or search for the relevant asset reference type. Only one reference type can be selected.
  • Automatically Apply Object Type: The default is for the object type to be automatically applied, based on the asset's MIME Type. To explicitly specify the asset type, use the 'Select Asset Type' option.
  • Select Asset Type: Choose a specific asset type to apply to the asset that is downloaded from the URL. When the Select Asset Type radio button is selected, the ellipsis button () to the right of the field is activated. Click the ellipsis button () to browse to or search for the relevant asset type. Only one asset type can be selected.
  • Approve created assets and references: Check this box to automatically approve the downloaded assets and their reference links.

The following is a sample configuration for this business action:

Public JavaScript API Method to Download Assets

A public API JavaScript method is also created upon installation of the Asset Download component, which is used to handle scenarios outside of those covered by the Create Assets from URL business action. This method, called downloadAssetContent, is used with the Asset Download Home bind that is found under the Assets category for Execute JavaScript business actions.

Two possible use cases for using the scripting API to create assets from a URL are:

  • Allowing for asset download actions to be performed on non-supplier products
  • Executing an asset download action on asset objects, which can be used to replace the content of these assets. This use case is described in the Using Asset Download topic here.

For more information on the STEP Scripting API, refer to the JavaScript in STEP section of the Resource Materials online help here.

Create Assets from URL – Bulk Update Operation

A category of bulk update operations named Assets is created when Asset Download is installed, which contains the asset download bulk update operation Create Assets from URL. The bulk update operation is configured and behaves in identically to the 'Create Assets from URL' business action described earlier in this topic.