Focusing the User on Information Specific to them – Part 3

Introduction

In Part 2, I talked about the power of Snaplets.  Snaplets are self contained components that carry with them all of the business functionality of forms, displays, access to data, and end-user actions.  They can be distributed and consumed by end-users without configuration. And because they are centrally configured and managed, the application owner can make a change, and that change will automatically updated wherever the Snaplet is used. 

In part 3, I will discuss how to build a Snaplet using CorasWorks Global Links, Central Views and Actions.  We will use the My Time-Off Requests Snaplet as an example.  When added to a page within your SharePoint environment, this Snaplet will allow the logged in user to see the status of their time-off requests, create new ones, or work with existing ones:

Key Concepts

In order to being to understand how to build Snaplets, there are several key concepts you should be familiar with:

Global Links

Global links are a feature that simplifies the process of naming and maintaining a reference to a URL. It is simply an entry in a list that is comprised of a name and URL. Once created, a global link can be used whenever you want to reference a location where an application or list is located.  The global link is used to tell the Snaplet where it can find the information it needs. If the application or list is moved, simply update the Global Link with the new URL, and automatically any view or action that uses the Global Link will automatically be updated. The Time-Off Request application uses a global link called [R3 Time-Off Request] which stores the URL of where the application is located. We will be referencing the global link when building our central views and actions

Central Views

Central Views are used to create and maintain CorasWorks views that can be shared by multiple data or navigation displays throughout your environment.  They are saved to a library and then made available for use in a display.  The advantage of using central views is that when you change a central view, any display that is using that view will automatically be updated. When configuring our Central View we will be referencing the Global Link [R3 Time-Off Request].

Configuring a Snaplet

Step 1 – Creating a Global Link

The first step is to create a global link for the Time-Off application. From the Site Settings page, use the Global Links Manager to create the global link [R3 Time-Off Request] and add the URL of where the Time-Off application is located.

Once created, we will use the global link when we build our Actions and Central Views.

Step 2 – Creating our Actions

We will now use the Actions Wizard to create the Actions which will part of the Snaplet. In this example we will be creating the action to allow a user to create a new time-off request.  When creating the action, we will specify the Model List by using the Specify Site and substituting the Global Link.  The action will use the Global Link to know where the model list is located:

 

Set the Data Source Selection to Static. This means that whenever the end user works here, they will use the centrally configured actions:

From that point on, configure the action as you normally would.

Step 3 – Creating the display for the Snaplet

We will use the Central Views Wizard to create our central view.  In this case we will call it My Time-Off Request.  Select the display type as grid. Once the central view is named and the display type is selected, the View Display Wizard will appear.  It works almost exactly like a local display wizard does. When we configure the central view, we will be substituting the global link in several key places. 

For the Model List, use Specify Site and enter the Global Link:

 

When selecting the Sites, use the Other Sites and enter the global link:

 

 

When adding actions to the central view, use the global link to point to the location where the action library is stored:

 

Any other configuration options are built exactly the same way as when using the local Display Wizard.

Step 4 – Creating a display that uses the central view

Once created, the Central View can be used in any similar display.  To associate the My Time-Off Request Central View, add a grid display to a page.  Instead of creating a local view, select Attach a Central View. Specify the central view location by using the global link [R3 Time-Off Request]. Then select the My Time-Off Requests central view and click on Add Reference:

 

Once you’ve associated your central view, click Apply and then the Views.  You should see your Associated Central View:

If someone accesses the Display Wizard and tried to modify the view, they will be notified that the properties of the view are Read Only.

Step 5 – Saving the Snaplet to the Web Part Gallery

Once the grid display is configured to use the My Time-Off Requests Central View, the web part can be saved to the Web Part Gallery by clicking on the Save to Web Part Gallery link. Once the Snaplet is saved to the gallery, it is available to be added to any page within your SharePoint environment.

Conclusion

If at any point the Snaplet needs to be changed, simply open the Snaplets central view using the Central View Wizard and update the view. You can change how the display looks, or even add additional actions.

Although in the example, our Snaplet only contains a single view, it can actually contain an unlimited number of views.  The only criteria are that they all must be the same display type.

Snaplets are a great way to allow users views and work with information anywhere they wish.  And because they are centrally configured and managed, they will save you a lot of time and effort whenever you wish to make a change.

Advertisement

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.