Serial Number Input State Variable Reference

Table of contents


Introduction

Serial Number Input state variables represent an aircraft serial number entered by the user. The state variable is defined by the aircraft application (source/app/common/aero/serialNumSv.js), not by the base MVCS. It depends on the aircraft type data in acData, and the rendered input monitors sv.ac_data so it updates when the selected aircraft model changes.

The value is a string of digits. The number of digits is set by acData.serialWidth. Whether the value is displayed with leading zeros depends on acData.serialFixedWidth:

Constructor

Syntax

ctl.createPage({
	...,
	stateVarInfo:[
		{type:'serialNumInput', ...},
	],
})

Parameters


Instance methods

Inherited methods

Note: The component() method returns a component that renders an <input type="text"> (see Component attributes).


fmtVal()

Syntax

fmtVal()

Returns the displayed form of the value. If the value is an Error, returns the Error text. If isFixedWidth is true, returns the value padded (or truncated) to acData.serialWidth digits. Otherwise returns the value with leading zeros removed.

Return value

A String.


Instance properties

Inherited properties


isFixedWidth (read only)

True if the current aircraft model's serial numbers are fixed width (acData.serialFixedWidth is set).

Value

A Boolean.


Component attributes

Inherited attributes

The component behaves as follows:


DOM element properties