Self Service-Specific Setup

The JustOn Self-Service Extension provides common self service-specific components as well as a number of specific self-service features, including

  • Subscription overview
  • Product overview and shopping cart
  • Invoice overview
  • Account statement display
  • CSV data upload

Info

Technically, these feature scopes - primarily exposed as Visualforce pages - work separately. You combine and enable the features to fit your business needs.

Enabling Product Page and Shopping Cart
Enabling Subscription Display
Enabling Invoice Display
Enabling Account Statement Display
Enabling CSV Upload
Enabling Profile View

The common self service-specific setup tasks, which are required for any of the specific features, include:

Note

Once the page assignment and access settings are complete, make sure to define a value for the Redirect after login global setting.

Assigning Self Service-Specific Pages

You must add a number of Visualforce pages to expose the self service-specific functionality.

  1. Open the Site Details of your site.

    Type Sites in the Quick Find box, or navigate to User Interface > Sites and Domains > Sites. In the Sites list, click the label of the site to open its details.

  2. In the Site Visualforce Pages section, click Edit.

  3. Add the following common pages.

    • ONB2.InvoicePDF
    • ONBSE1.Login
  4. Depending on the way you choose to authenticate users, you may have to add provider-specific login handler pages.

    Provider Page
    Amazon ONBSE1.AmazonLoginHandler
    Google ONBSE1.GoogleLoginHandler
    PayPal ONBSE1.PaypalLoginHandler
    Salesforce ONBSE1.SalesforceLoginHandler

    Info

    Using the password-based authentication does not require an external identity provider, and hence, you do not need a specific login handler page.

  5. Click Save.

Configuring Public Access Settings

The extension needs access to a number of standard objects and custom objects in order to work correctly. To this end, you must allow/restrict access both on object and field level.

Note

Make sure to grant the access rights as restrictive as possible to avoid inadvertent information disclosure or modification.

Configuring General Object Permissions

  1. Open the Site Details of your site.

    Type Sites in the Quick Find box, or navigate to User Interface > Sites and Domains > Sites. In the Sites list, click the label of the site to open its details.

  2. Click Public Access Settings to open the site profile.

  3. In the Original Profile User Interface, click Edit.

    If you use the Enhanced Profile User Interface, click Object Settings > Object > Edit.

  4. Apply the following object permission settings.

    Standard Object Permissions

    Object Permissions Notes
    Account Read
    Create
    Contact Read
    Create
    Price Book Read Required when using master products.
    Price Book Entry Read Required when using master products.
    Product Read Required when using master products.

    Custom Object Permissions

    Object Permissions
    Invoice Read
    Invoice Line Item Read
    Item Read
    Create
    Number Range Read
    Create
    Edit
    Payment Entry Read
    Script Read
    Create
    Edit
    Delete
    View All
    Modify All
    Session Read
    Create
    Edit
    Delete
    View All
    Modify All
    Style Read
    Subscription Read
    Create
    Template Read
    Tier Read
    Create
    Trigger Helper Read
    Create
    Edit
    Delete
    View All
    Modify All
  5. Click Save.

Note

All other objects must not be selected.

Configuring Field-Level Security

  1. Open the Site Details of your site.

    Type Sites in the Quick Find box, or navigate to User Interface > Sites and Domains > Sites. In the Sites list, click the label of the site to open its details.

  2. Click Public Access Settings to open the site profile.

  3. In the Original Profile User Interface, scroll to the Field-Level Security section, click View next to the object you want to modify, and then click Edit.

    If you use the Enhanced Profile User Interface, click Object Settings > Object > Edit.

  4. Specify the required access levels.

    Field-Level Security for Standard Objects

    Object Permissions
    Account Edit access for Billing Address and all fields to be modified by users, no access for other fields
    Contact Edit access for Account Name, Email, External User Id, Identity Provider, Phone and all fields to be modified by users, no access for other fields
    Price Book Read access for all fields
    Required when using master products.
    Price Book Entry Read access for all fields
    Required when using master products.
    Product Read access for all fields
    Required when using master products.

    Field-Level Security for Custom Objects

    Object Permissions
    Invoice Controlled by the general object permissions
    Invoice Line Item Controlled by the general object permissions
    Item Controlled by the general object permissions
    Number Range Controlled by the general object permissions
    Payment Entry Controlled by the general object permissions
    Session Controlled by the general object permissions
    Script Controlled by the general object permissions
    Style Controlled by the general object permissions
    Subscription Controlled by the general object permissions
    Template Controlled by the general object permissions
    Tier Controlled by the general object permissions
    Trigger Helper Controlled by the general object permissions
  5. Click Save.

Defining Redirect After Login

For the self-service functionality to work as intended, you must set a redirection target. This is the page to which the site guest users are redirected after they have logged in. The redirection target is set in the Redirect after login global setting.

  1. In Setup, open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Global Settings.

  3. Click Edit in the row of Default.
  4. In Redirect after login, specify the intended URL.

    The URL must begin with a slash (/) and include the namespace prefix, like /ONBSE1__Products.

  5. Click Save.

    This forces the JustOn Self-Service Extension to open the specified URL after a user has successfully logged in.

Note

The Redirect after login setting must not be empty.

Defining Site Navigation

The header component as shipped with the JustOn Self-Service Extension includes a pre-defined site navigation. It includes the product page, the subscription page and the invoice page.

Using the custom setting Navigation, you define your custom navigation as required by your business needs. You can add the account statement or CSV upload page, hide a default page, or change the display order.

The available pages include

  • Products
  • Subscriptions
  • Invoices
  • StatementOfAccount
  • UploadCSV
Field Data Type Description
Name Text (255) The unique name for the custom setting record. Must match the API name of the target page, like UploadCSV.
Active Checkbox Only active navigation elements are rendered.
Group Text (255) Navigation elements of the same group are combined into the same <ul> element.
Label Text (255) The link text.
Sequence Number (3,0) Elements are sorted by sequence.
Style class Text (255) The style class of the link.
URL Text (255) The URL of the page. Must include the namespace prefix, like ONBSE1__UploadCSV.

Note

Create a Navigation record for each page that you want to be accessible through the navigation. Be aware that as soon as you create one Navigation record, the built-in, pre-defined site navigation is disabled.

  1. In Setup, open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Navigation.

  3. Click New.
  4. Specify the information as necessary.
  5. Click Save.

The header component is used on every self service-specific page. It displays a logo and the site name, as well as the site navigation.

Note

The image file that you intend to use as the site logo must be stored as a file in the Salesforce Documents tab and selected as Externally Available Image.

The logo file is enabled in the global setting Logo Name:

  1. In Setup, open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Global Settings.

  3. Click Edit in the row of Default.
  4. In Logo Name, specify the name of the logo image file.
  5. Click Save.

    This includes the specified file as the logo in the page header.

You can specify a URL that is to be opened when a user clicks the site logo or site name - usually, the site home page. The link target is defined in the global setting Home URL:

  1. In Setup, open Custom Settings.

    In Salesforce Lightning, navigate to Custom Code > Custom Settings.

    In Salesforce Classic, navigate to Develop > Custom Settings.

  2. Click Manage in the row of Global Settings.

  3. Click Edit in the row of Default.
  4. In Home URL, specify the intended URL.
  5. Click Save.

    This opens the specified URL when a user clicks the site logo or site name.

Info

If there is no URL configured, clicking the site logo or site name has no effect.

The Visualforce pages packaged with the JustOn Self-Service Extension make use of custom labels. The custom labels can contain up to 1000 characters and can include HTML markup.

You can overwrite the custom labels to adjust them to the needs of your business use cases.

Note

To modify custom labels, you must enable the Translation Workbench. For details, see Enable and Disable the Translation Workbench in the Salesforce Help.

The header, footer and logout components use the following custom labels:

Component Label
Header SiteName
SiteDescription
Footer Footer
Footer2
Footer3
Logout Footer

To modify them:

  1. In Setup, open the Custom Labels list.

    In Salesforce Lightning, navigate to User Interface > Custom Labels.

    In Salesforce Classic, navigate to Create > Custom Labels.

  2. Click the name of the label you want to modify.

    To better find the relevant labels, create a filter for the namespace ONBSE1.

  3. Click New Local Translations/Overrides.

  4. Select the target language and specify the text as required.
  5. Click Save.

Info

For help about modifying custom labels, see Create and Edit Custom Labels in the Salesforce Help.

Note

Set the locale in the global settings in order to select the intended translation.