Skip to content

Commit

Permalink
Merge pull request #5441 from thehyve/remove_whats_new
Browse files Browse the repository at this point in the history
Add parameter to remove What's New section
  • Loading branch information
alisman authored Jan 4, 2019
2 parents f9f1d4e + 68fd88d commit c0e12b2
Show file tree
Hide file tree
Showing 4 changed files with 66 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ public class GlobalProperties {
public static final String SKIN_RIGHT_NAV_SHOW_DATA_SETS = "skin.right_nav.show_data_sets";
public static final String SKIN_RIGHT_NAV_SHOW_EXAMPLES = "skin.right_nav.show_examples";
public static final String SKIN_RIGHT_NAV_SHOW_TESTIMONIALS = "skin.right_nav.show_testimonials";
public static final String SKIN_RIGHT_NAV_SHOW_WHATS_NEW = "skin.right_nav.show_whats_new";
private static String skinAuthorizationMessage;
@Value("${skin.authorization_message:Access to this portal is only available to authorized users.}")
public void setSkinAuthorizationMessage(String property) { skinAuthorizationMessage = property; }
Expand Down Expand Up @@ -717,6 +718,12 @@ public static boolean showRightNavTestimonials()
return showFlag == null || Boolean.parseBoolean(showFlag);
}

public static boolean showRightNavWhatsNew()
{
String showFlag = portalProperties.getProperty(SKIN_RIGHT_NAV_SHOW_WHATS_NEW);
return showFlag == null || Boolean.parseBoolean(showFlag);
}

public static String getAuthorizationMessage()
{
return skinAuthorizationMessage;
Expand Down
57 changes: 57 additions & 0 deletions docs/portal.properties-Reference.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
This page describes the main properties within portal.properties.

- [Database Settings](#database-settings)
- [cBioPortal Customization](#cbioportal-customization)
- [Segment File URL](#segment-file-url)
- [Bitly API Username and Key](#bitly-api-username-and-key)
- [Google Analytics](#google-analytics)
Expand Down Expand Up @@ -34,6 +35,62 @@ db.tomcat_resource_name is required in order to work with the tomcat database co
db.tomcat_resource_name=jdbc/cbioportal
```

# cBioPortal Customization

## Hide tabs (pages)
Settings controlling which tabs (pages) to hide. Set them to `false` if you want to hide those tabs, otherwise set the properties to `true`.

```
skin.show_data_tab=
skin.show_web_api_tab=
skin.show_r_matlab_tab=
skin.show_tutorials_tab=
skin.show_faqs_tab=
skin.show_news_tab=
skin.show_tools_tab=
skin.show_about_tab=
```
*Note: `skin.show_tools_tab` refers to the `Visualize Your Data` tab, while `skin.show_data_tab` refers to the `Data Sets` tab.

## Hide sections in the right navigation bar
Settings controlling what to show in the right navigation bar. Set them to `false` if you want to hide those sections, otherwise set the properties to `true`.

```
#Cancer Studies section:
skin.right_nav.show_data_sets=
#Example Queries section:
skin.right_nav.show_examples=
#Testimonials section:
skin.right_nav.show_testimonials=
#What's New section
skin.right_nav.show_whats_new=
```

## Control the content of specific sections
Setting controlling the blurb: you can add any HTML code here that you want to visualize. This will be shown between the cBioPortal menu and the Query selector in the main page.
```
skin.blurb=
```

Setting controlling the footer: you can add any HTML code here that you want to visualize. If the field is left empty, the default footer (from www.cbioportal.org) will be shown.
```
skin.footer=
```

Settings controlling the "What's New" blurb in the right navigation bar: you can add any HTML code here that you want to visualize. If the field is left empty, the Twitter timeline will be shown (as long as `skin.right_nav.show_whats_new` is `true`, otherwise this section will not be displayed).

```
skin.right_nav.whats_new_blurb=
```

Add a custom logo in the right side of the menu. Place here the full name of the logo file (e.g. `logo.png`). This file should be saved in `$PORTAL_HOME/portal/images/`.
```
skin.right_logo=
```

# Segment File URL

This is a root URL to where segment files can be found. This is used when you want to provide segment file viewing via external tools such as [IGV](http://www.broadinstitute.org/igv/).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ window.legacySupportFrontendConfig = {
skinRightNavShowDatasets : <%=GlobalProperties.showRightNavDataSets()%>,
skinRightNavShowExamples : <%=GlobalProperties.showRightNavExamples()%>,
skinRightNavShowTestimonials : <%=GlobalProperties.showRightNavTestimonials()%>,
skinRightNavShowWhatsNew : <%=GlobalProperties.showRightNavWhatsNew()%>,
skinRightNavExamplesHTML : '<%=GlobalProperties.getExamplesRightColumnHtml()%>',
skinRightNavExamplesHTML : '<%=GlobalProperties.getExamplesRightColumnHtml()%>',
skinRightNavWhatsNewBlurb : '<%=GlobalProperties.getRightNavWhatsNewBlurb()%>',
Expand Down
1 change: 1 addition & 0 deletions src/main/resources/portal.properties.EXAMPLE
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ skin.login.saml.registration_html=Sign in with MSK
skin.right_nav.show_data_sets=true
skin.right_nav.show_examples=true
skin.right_nav.show_testimonials=true
skin.right_nav.show_whats_new=true

# settings controlling what to show in the right navigation bar
skin.study_view.link_text=To build your own case set, try out our enhanced Study View.
Expand Down

0 comments on commit c0e12b2

Please sign in to comment.