Difference between revisions of "OHSU Navigation Install v1.0"

From ADF Docs
Jump to: navigation, search
(CCAPI Configuration)
(Site Configuration)
 
Line 10: Line 10:
 
* Make sure the ADF is setup and running on the site. If the ADF is not setup, then follow the instructions for ADF [[Installation]].
 
* Make sure the ADF is setup and running on the site. If the ADF is not setup, then follow the instructions for ADF [[Installation]].
 
* Open the sites 'ADF.cfc' ([[Site Configuration (ADF.cfc)|See Site Configuration (ADF.cfc) for more info]]) file (located in your site's /_cs_apps/ directory) in a text editor. Locate the ''Load the ADF Application into application space'' comment in the file. Add (or uncomment) the following command under the comment section:
 
* Open the sites 'ADF.cfc' ([[Site Configuration (ADF.cfc)|See Site Configuration (ADF.cfc) for more info]]) file (located in your site's /_cs_apps/ directory) in a text editor. Locate the ''Load the ADF Application into application space'' comment in the file. Add (or uncomment) the following command under the comment section:
<source lang="java">
+
 
loadApp("ohsuNav");
+
loadApp("ohsuNav");
</source>
+
 
 
* [[Reset ADF|Reset the ADF]] for the server and site.
 
* [[Reset ADF|Reset the ADF]] for the server and site.
  

Latest revision as of 21:54, 6 May 2016

Download

Download the OHSU Navigation Application from the Community Site or from the SVN Repository.

Extract the zip files into the following directory: /ADF/apps/ohsu_nav/

Site Configuration

The OHSU Navigation Application is built within the ADF. The ADF must be installed in the site to run the OHSU Nav, follow the ADF Installation instructions.

  • Make sure the ADF is setup and running on the site. If the ADF is not setup, then follow the instructions for ADF Installation.
  • Open the sites 'ADF.cfc' (See Site Configuration (ADF.cfc) for more info) file (located in your site's /_cs_apps/ directory) in a text editor. Locate the Load the ADF Application into application space comment in the file. Add (or uncomment) the following command under the comment section:
loadApp("ohsuNav");

Import Custom Elements

The OHSU Navigation Application has a couple Custom Components defined within CommonSpot. The components have been exported and are available in the OHSU Navigation's "exported-objects" folder located at the root of the OHSU Nav application directory (e.g. /ADF/apps/ohsu_nav/exported-objects/)

Optional: You may want to create a new category within the CommonSpot Element Gallery for 'OHSU Navigation Elements'.

To import these objects, you will need to be an administrator for your site. If you are not a site administrator, consult your Server administrator for more information

Import

Import Custom Element:

  1. Nav Element (Nav-Element-Custom-Element.zip)

Import the Custom Field Type:

  1. Navigation (Navigation-Custom-Field-Type.zip)

Subsites

It is highly recommended that a Navigation webadmin subsite is created for Administrators. This configuration allows subsite security to be used to allow only Administrators access to the webadmin subsite. A forms subsite is also created to store the pages for the administrator forms.

Your site may already have a webadmin subsite. The steps below will add a navigation subsite under the webadmin subsite.

Web Admin

  1. Create a new subsite under the site root called webadmin.
  2. Create a new subsite under webadmin called navigation.
  3. Configure the /webadmin/navigation/ subsite Content Security to give 'No Rights' to 'Anonymous Users' and 'Authenticated Users'.
  4. Configure the /webadmin/navigation/ subsite Content Security to give permissions to the group of administrators who will manage the Photos.

CCAPI Configuration

The Photo Gallery Application uses the ADF CCAPI to populate profile records and create profile pages. The CCAPI needs to be configured for the site and photo gallery application.

First, follow the steps to set up the CCAPI Config file for the site. Once that configuration is complete, follow the steps below to set up the CCAPI config for the Photo Gallery application. Make sure to update the wsVars section with the correct URLs and username/password.

  1. Create a new page called 'ccapiNav'. Recommend creating this page in the root subsite.
  2. Add the 'Nav Element' element to the page.
  3. Select the 'Photo' element indicator and go to 'more...'. Select 'Name' from the menu.
  4. In the Element Name field, enter the text 'navElement'.
  5. Publish this page and view in read mode.
  6. Edit the 'ccapi.xml' file for the site and add the following xml block into the <elements> section:
<navigation>
  <pageID>#####</pageID>
  <subsiteID>##</subsiteID>
  <elementType>custom</elementType>
  <controlName>navElement</controlName>
</navigation>

To populate the <pageID> and <subsiteID> tags, view the source code for the 'ccapiPhoto' page that was just created.

Identify the following line in the source code and enter this numeric value into the <subsiteID> tag:

var jsSubSiteID = ##;

Identify the following line in the source code and enter this numeric value into the <pageID> tag:

var jsPageID = ####;

Reset the ADF for the server and site.

Management Page

  • Create a CS page called "Manage Navigation"
  • Place the Datasheet element on this page
  • Configure a Datasheet View to display the Nav Element with the following columns in this order:
    • Parent
    • SubsiteID
    • StartPointPageID
    • ChildList
    • ChildStartPoints
  • Update the Parent column to use the /ADF/apps/ohsu_nav/datasheet-modules/is_promoted_parent.cfm column render handler
  • Update the SubsiteID column to use the /ADF/extensions/datasheet-modules/subsiteURL.cfm column render handler
  • Update the StartPointPageID column to use the /ADF/apps/ohsu_nav/datasheet-modules/pageIDlist-to-linkList.cfm column render handler
  • Update the ChildList column to use the /ADF/apps/ohsu_nav/datasheet-modules/pageIDlist-to-linkList.cfm column render handler
  • Update the ChildStartPoints column to use the /ADF/apps/ohsu_nav/datasheet-modules/pageIDlist-to-linkList.cfm column render handler
  • Add edit/delete action columns
  • Publish page

Navigation Element Configuration

Option 1: Add directly to Base Template

  • Edit your Base Template and add the following code into either your right or left column:
<cfmodule template="/commonspot/utilities/ct-render-named-element.cfm"
   elementName="subNav"
   elementType="custom:Nav Element">
  • Navigate to your Base Plus One
  • Modify the Nav Element by clicking on the Element Indicator and selecting Render Mode
  • Choose the option "Display existing element data (content reuse)"
  • In the "Filter" tab add the following filter
    • Field: SubsiteID
    • Operator: Equals
    • Value: {request.subsite.id} - using the ColdFusion Expression option (you can also check Force Cache)
  • Select the "Left Navigation" Render Handler

Option 2: Add directly to Base Plus One Template

  • Navigate to your Base Plus One
  • Add the Nav Element into the page using the Element Gallery
  • Modify the Nav Element by clicking on the Element Indicator and selecting Render Mode
  • Choose the option "Display existing element data (content reuse)"
  • In the "Filter" tab add the following filter
    • Field: SubsiteID
    • Operator: Equals
    • Value: {request.subsite.id} - using the ColdFusion Expression option (you can also check Force Cache)
  • Select the "Left Navigation" Render Handler

Navigation Custom Field Type

  • Create a Metadata form called Navigation (or use an existing metadata form)
  • Add a Field called "Navigation" using the "Navigation" field type
  • Bind the Metadata field to your Base Template

Reset the ADF

Reset the ADF for the server and site.