"No", 1 => "Yes"];
}
/**
* Get an array of options available for a privilege value.The array keys are
* values for the form and the values are the labels for the form.
* @return array array of privilege options
*/
function GetPrivilegeOptions()
{
$PrivilegeFactory = new PrivilegeFactory();
return ["--" => "--"] + $PrivilegeFactory->GetPrivileges(true, false);
}
/**
* Get an array of options available for SearchGroupLogic.
* @return array of options
*/
function GetSearchGroupLogicOptions()
{
return [
SearchEngine::LOGIC_OR => "OR",
SearchEngine::LOGIC_AND => "AND"
];
}
/**
* Get the escaped option text and value for a flag value.
* @param int $State TRUE if the flag is on and FALSE if the flag is OFF
* @return array the first value is the text, the second is the value
*/
function GetSafeFlagOption($State)
{
return [
defaulthtmlentities(StdLib::getArrayValue(GetFlagOptions(), $State ? 1 : 0)),
defaulthtmlentities($State ? 1 : 0)
];
}
/**
* Print the type field for the given metadata field data.
* @param array $Data metadata field data
* @param string|null $Error field error, if one exists
* @return void
*/
function PrintTypeField(array $Data, $Error)
{
$AllowedTypes = MakeTypesHumanReadable($Data["AllowedTypes"]);
$HasNoAllowedTypes = !count($AllowedTypes);
$SafeType = defaulthtmlentities($Data["Type"]);
$SafeTypeName = defaulthtmlentities(MetadataField::$FieldTypeHumanEnums[$Data["Type"]]);
?>
= $SafeTypeName; ?>
PrintHtml(); ?>
All fields.
Schema
= $Schema->Name() ?>
All fields.
All fields.
= $SafeValue; ?>
All fields.
All fields.
All fields.
All fields.
= $SafeText; ?>
PrintHtml(); ?>
All fields.
= $SafeText; ?>
PrintHtml(); ?>
All fields.
= $SafeText; ?>
PrintHtml(); ?>
Text, Paragraph, Number, Date,
Timestamp, Flag, Tree, Controlled Name,
Option, User, Image, File, URL, and
Point fields.
= $SafeText; ?>
PrintHtml(); ?>
Text, Paragraph, Number, Date,
Timestamp, Flag, Tree, Controlled Name,
Option, Image, File, URL, and Point
fields.
= $SafeText; ?>
PrintHtml(); ?>
Text, Paragraph, Number, Date,
Timestamp, Flag, Tree, Controlled Name,
Option, Image, File, URL, Email, and Point
fields.
PrintHtml(); ?>
All fields.
PrintHtml(); ?>
Email fields.
"--"] + $Options;
?>
PrintHtml(); ?>
Text, Paragraph, Number, Date,
Timestamp, Flag, Tree, Controlled Name,
Option, Image, File, URL, and Point
fields.
PrintHtml(); ?>
(determines how multiple selections for this field are combined)
Tree, Controlled Name, and Option fields.
PrintHtml(); ?>
(determines if search facets will show all top-level terms for the given field rather
than only those associated with the current set of search results)
Tree, Controlled Name, and Option fields.
(1 or more)
Tree and Controlled Name fields.
(1 or more)
Tree, Controlled Name, and Reference fields.
(10 or more)
Tree, Controlled Name, and Reference fields.
PrintHtml(); ?>
Tree, Controlled Name, and Option fields.
PrintHtml(); ?>
Tree fields.
(1 or more) When Display As List For Advanced Search is enabled, this sets the maximum
number of levels of a Tree field to include in the list
(e.g., 1 to only list top-level classifications).
Tree fields.
characters
Text, Number, Date, and Point fields.
= $SafeValue; ?> characters
characters
(Note: making this value smaller will not truncate any
existing field values)