Skip to content

Instantly share code, notes, and snippets.

@mmarum-sugarcrm
Created October 16, 2015 22:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mmarum-sugarcrm/4a66dee8effe28b1016b to your computer and use it in GitHub Desktop.
Save mmarum-sugarcrm/4a66dee8effe28b1016b to your computer and use it in GitHub Desktop.
Contextual Frame Dashlet metadata
<?php
/**
* Copyright 2015 SugarCRM Inc. Licensed by SugarCRM under the Apache 2.0 license.
*/
$viewdefs['base']['view']['xyz_contextual-iframe'] = array(
//Dashlet metadata
'dashlets' => array(
array(
'label' => 'LBL_XYZ_IFRAME_DASHLET_LABEL',
'description' => 'LBL_XYZ_IFRAME_DASHLET_DESCRIPTION',
'config' => array(
// Default config values
'url' => '//httpbin.org/get',
'frameHeight' => '100%',
),
'preview' => array(),
'filter' => array(),
),
),
//View metadata for Dashlet Config page
'config' => array(
'fields' => array(
array(
'name' => 'url',
'label' => 'LBL_XYZ_IFRAME_DASHLET_URL_LABEL',
'type' => 'text',
),
array(
'name' => 'frameHeight',
'label' => 'LBL_XYZ_IFRAME_DASHLET_IFRAME_HEIGHT_LABEL',
'type' => 'text',
),
),
),
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment