Announcement

An application can advertise its services to those customers who did not subscribe to the application services yet.

../../../../_images/dash-step-meta.png ../../../../_images/dash-step-presentation.png ../../../../_images/dash-step-deploy.png ../../../../_images/dash-step-provisioning.png ../../../../_images/dash-step-announce-b.png

The UX1 Home dashboard provides a service to publish application announcements inside custom tiles.

../../../../_images/app-ads.png

If a customer clicks on the button to enable a service, the system allows the customer to select a subscription period and then proceed to the order placement and processing.

Note

For this functionality, the platform must contain both parts, OSS (Operations Support System) and BSS (Business Support System).

Specifics

To place an announcement in the Home dashboard, pay attention to the following specifics:

  1. The application root service must be globally available. In its APS type definition, the access attribute grants it:

    {
        "apsVersion": "2.0",
        "name": "cloud",
        "id": "http://aps-standard.org/samples/basic1pdash/cloud/1.0",
        "access": {
            "global": true
        },
        "implements": [
            "http://aps-standard.org/types/core/application/1.0"
        ],
        ...
    }
    

    In this case, the application announcement in the Home dashboard will be available for all authenticated users.

  2. An announcement is configured inside the same view-plugin source that you used to present resource data for subscribers.

  3. In meta definition, the view-plugin must declare a variable presenting the singular subscription service resource. However, if a customer does not have a subscription with that resource, the variable is not available. That is why, the variable must be declared as not required.

  4. The subscription service can specify its own custom view style in the <presentation> section of the <service> meta definition.

  5. The view-plugin JavaScript source is similar to a basic or advanced view with the following key specifics:

    • Compared with an ordinary basic view-plugin considered earlier, the view-plugin with the application announcement also contains one more property, promoPrimaryText, for example:

      promoPrimaryText: "The Service You Know"
      
    • A view-plugin based on the advanced approach must differentiate the case, when a customer has a subscription with application resources, from the other case, when there is no such a subscription yet.

In addition to the above specifics, the provider must configure at least one service plan in the BSS to offer the application services to customers. The service plan must be marked as available in CCP.

If all of the above requirements are met, the Home dashboard will display the configured application announcement for those customers who did not subscribe to a service plan with the application resources.

Continue Your Demo

Continue your demo project from the previous step.

Note

To test application announcements you will need a lab platform containing both, Operations Support System (OSS) and Business Support System (BSS).

Meta Definition

In the view-plugin meta definition, make the context navigation variable not required by adding the required="false" attribute:

<navigation id="plugins" label="Dashboard">
   <view-plugin id="vpsDashboardPlugin" src="ui/wizard/vpsDashboardPlugin.js">
      <var name="context" type-id="http://aps-standard.org/samples/basic1pdash/context/1.0"
            required="false"/>
      <plugs-to id="http://www.parallels.com/ccp-dashboard#dashboard"/>
   </view-plugin>
</navigation>

Global Access

Ensure the application root service grants the global access, that is it is available to all authenticated users. If you use the APS PHP runtime, update the scripts/clouds.php file as follows:

  1. Allow the global access to the application root resource by adding the respective access attribute to the main class definition:

    /**
     * Class cloud presents application and its global parameters
     * @type("http://aps-standard.org/samples/basic1pdash/cloud/1.0")
     * @implements("http://aps-standard.org/types/core/application/1.0")
     * @access(global, true)
     */
    class cloud extends APS\ResourceBase {
       // .. class body
    }
    
  2. Hide the properties of the cloud type from all roles except for the owner. For this purpose, add the respective access attribute to them:

    Note

    Although this step does not affect the current demo project, it is very important for security reasons to protect the application root service properties from the global audience on a production system.

    /**
     * @type(string)
     * @title("apphost")
     * @description("Cloud management server IP or domain name")
     * @access(global,false)
     */
     public $apphost;
    
     /**
      * @type(string)
      * @title("Cloud Admin")
      * @description("Cloud administrator")
      * @access(global,false)
      */
     public $cloudadmin;
    
     /**
      * @type(string)
      * @title("Cloud Password")
      * @description("Cloud administrator password")
      * @encrypted
      * @access(global,false)
      */
      public $cloudpass;
    

View-Plugin Update

Update the basic view-plugin source ui/plugins/vpsDashboardPlugin.js with a new parameter announcing the application service. In the declare method, add the promoPrimaryText property, for example:

promoPrimaryText: "The Service You Know",

Deployment

If you use the APS application for the first time on the platform, follow the Deployment section. Otherwise, follow the Update APS Application section.

Testing in UX1

Note

Since the announcement is available only to those customers who are not subscribed to the application services, start the following steps on behalf of a test customer that do not have such a subscription.

Investigate Home Dashboard

Test the following functionality on the Home dashboard.

  1. Since your customer is not subscribed to the application services, the Home dashboard must show announcement about the application service.

    ../../../../_images/app-ads.png
  2. Click the Enable VPS Management button.

    ../../../../_images/ads-sp-select.png

    Select the 1 month trial period.

  3. The VPS management service must be available for the customer.

    ../../../../_images/ads-trial-order.png
  4. In the BSS PCP, verify if the new trial subscription is created.

    ../../../../_images/ads-trial-subscription-bss.png
  5. In the OSS PCP, verify if the new subscription is created and the VPS management service is used.

    ../../../../_images/ads-trial-subscription-oss.png
  6. In UX1, create at least one VPS:

    ../../../../_images/ads-trial-vps-used.png

Upgrade Subscription

Test the upgrade to the paid subscription period.

  1. In the Home dashboard, click the Upgrade to Paid button and review the commercial properties.

    ../../../../_images/ads-upgrade-order.png

    Click Next.

  2. Review the order details.

    ../../../../_images/ads-upgrade-order-details.png
  3. Click the Confirm button to start the order processing. During this process and after its completion the system sends respective notifications and redirects you to the Account > Subscriptions list.

    ../../../../_images/ads-upgrade-subscriptions.png
  4. Once the customer is an application subscriber now, the application tile looks a bit differently.

    ../../../../_images/ads-dash-updated.png

Conclusion

This completes the development and testing of an application closely integrated with the Home dashboard. The application home tile is pretty flexible in terms of providing necessary information about the application, starting from announcement about application services, providing access to the order placement and processing, and displaying data about resource usage. The package you developed and tested looks similar to the sample package.