Customizing Open in Source

OnePart allows you to customize the Open in Source feature for your data sources. This feature allows users to open the file directly in the Filesystem.

This task shows you how to:

Use this feature

You must define the list of connector specific rules and set the path rewrite rules for this list of connectors. You can enable the feature for each connector. The user can override this setting in the Preferences > Source tab. With the feature enabled, the button will display for each part that matches a source rule for a connector.

Note: For specific PDM connector requirements, see the OnePart Connectors Guide

Enable this feature

To enable this feature, you must override the default connectors key values. You can edit the XML configuration files manually as described below or use the API Console available at http://<HOSTNAME>:<BASEPORT+1>/api-ui

  1. Edit the file <ONEPART_INSTALLDIR>\datadir\config\CustomConfigs.xml
  2. Define the list of connectors and their rewritten paths in the section:
    • <ns2:KeyValue key="connectors" description="The list of connector specific rules">
    • See the sample configuration file below. Replace the paths in italics with your required file paths.
  3. Manually apply the product configuration.
<CustomConfig name="openInSource">
<ns2:KeyValue key="PDM" value="true" description="The rule used for PDM connectors"/>
<ns2:KeyValue key="connectors" description="The list of connector specific rules">
<!-- An example of configuration for the ExampleAppConnector connector -->
<ns2:KeyValue key="ExampleAppConnector" description="A connector specific rule">
<ns2:KeyValue key="active" value="true" />
<ns2:KeyValue key="rewrite" description="A list of rewritten paths">
<ns2:KeyValue key="0">
<ns2:KeyValue key="source" value="c:\your\indexed\folder"/>
<ns2:KeyValue key="destination" value="S:\shared_folder"/>
</ns2:KeyValue>
</ns2:KeyValue>
</ns2:KeyValue>
</ns2:KeyValue>
</CustomConfig>
Important: The source path matching is case sensitive.