new SecOpt( [ prefix [, center [, suffix [, lblIndex ] ] ] ] )

Constructor for pdf report Section Header types

Description

Enter either a value for "center" or "data_name" NOT both. If both are entered, "center" will take precedence. If the section is part of a repeatable and "data_name" is used you must also enter the "rep_data_name" property.

Options for center value property are: 'data_name', 'center', 'rep_data_name'

Parameters
Name Type Attributes Default Description
prefix string <optional>

Prefix of section header

center string <optional>

Text for body of section header, overrides data_name and rep_data_name

suffix string <optional>

Suffix of section header

lblIndex boolean <optional>
false

Set to true and index included will be printed after prefix

Properties
Name Type Attributes Default Description
hide boolean <optional>
false

Set to true to hide section header

data_name string <optional>
''

data name of section or field LABEL() will be used as body of section header

rep_data_name string <optional>
''

data name of Repeatable, LABEL() will be used as body of section header

index number <optional>

Index of repeatable section, will be calculated automatically by other methods if section is from a repeatable

css string <optional>
'mjnt-sectionHeader spacer-top'

CSS class for section header

htmlTemplates ReportTemplateBlocks

Reference to ReportTemplateBlocks for HTML generation

Methods


getCenter() → {string}

Gets the central text to display in a section header

Returns

text() → {string}

Returns full section header text

Returns

toHtml() → {string}

Returns styled html for section header

Returns

getIndex() → {number}

Returns index number of repeatable section

Returns

c( str ) → {*}

Check if property is a function or value and return value or result of function

Parameters
Name Type Description
str string

property name

Returns