2
<h3>$i18n.getString( "create_new_indicator" )</h3>
4
<form id="addIndicatorForm" action="addIndicator.action" method="post" onsubmit="return validateAddIndicator()">
7
<input type="hidden" id="numerator" name="numerator">
8
<input type="hidden" id="numeratorDescription" name="numeratorDescription">
9
<input type="hidden" id="numeratorAggregationOperator" name="numeratorAggregationOperator">
10
<input type="hidden" id="denominator" name="denominator">
11
<input type="hidden" id="denominatorDescription" name="denominatorDescription">
12
<input type="hidden" id="denominatorAggregationOperator" name="denominatorAggregationOperator">
17
<th colspan="2">$i18n.getString( "details" )</th>
20
<td><label for="name">$i18n.getString( "name" ) <em title="$i18n.getString( "required" )" class="required">*</em></label></td>
21
<td><input type="text" id="name" name="name" onchange="nameChanged()" style="width:20em"></td>
24
<td><label for="shortName">$i18n.getString( "short_name" ) <em title="$i18n.getString( "required" )" class="required">*</em></label></td>
25
<td><input type="text" id="shortName" name="shortName" maxlength="20" style="width:20em"></td>
28
<td><label for="alternativeName">$i18n.getString( "alternative_name" )</label></td>
29
<td><input type="text" id="alternativeName" name="alternativeName" style="width:20em"></td>
32
<td><label for="code">$i18n.getString( "code" )</label></td>
33
<td><input type="text" id="code" name="code" style="width:20em"></td>
36
<td><label for="description">$i18n.getString( "description" )</label></td>
37
<td><textarea id="description" name="description" style="width:20em; height:8em"></textarea></td>
40
<td><label for="annualized">$i18n.getString( "annualized" )</label></td>
42
<select id="annualized" name="annualized" style="width:20em">
43
<option value="false">$i18n.getString( "no" )</option>
44
<option value="true">$i18n.getString( "yes" )</option>
49
<td><label for="indicatorTypeId">$i18n.getString( "indicator_type" ) <em title="$i18n.getString( "required" )" class="required">*</em></label></td>
51
<select id="indicatorTypeId" name="indicatorTypeId" style="min-width:20em">
52
<option value="null">[$i18n.getString( "select" )]</option>
53
#foreach( $indicatorType in $indicatorTypes )
54
<option value="$indicatorType.id">$encoder.htmlEncode( $indicatorType.name )</option>
61
<td><input type="button" value="$i18n.getString( 'edit_numerator' )" onclick="showEditNumeratorForm()" style="width:10em"><input
62
type="button" value="$i18n.getString( 'edit_denominator' )" onclick="showEditDenominatorForm()" style="width:10em"></td>
66
<td><input type="submit" value="$i18n.getString( "add" )" style="width:10em"><input type="button" value="$i18n.getString( "cancel" )" onclick="window.location.href='indicator.action'" style="width:10em"></td>
72
<span id="message"></span>
74
<script type="text/javascript">
76
var previousName = '';
78
var nameField = document.getElementById( 'name' );