52 $this->
lng = $DIC[
'lng'];
53 $this->glyph_factory = $DIC->ui()->factory()->symbol()->glyph();
54 $this->renderer = $DIC[
'ui.renderer'];
55 $this->tpl = $DIC[
'tpl'];
57 $this->validationRegexp =
"";
101 $submittedElements = $this->
getInput();
103 if ($submittedElements === [] && $this->
getRequired()) {
108 foreach ($submittedElements as $submittedValue) {
111 if ($this->
getRequired() && trim((
string) $submittedContentText) ===
"") {
131 public function render(
string $a_mode =
""): string
133 $tpl =
new ilTemplate(
"tpl.prop_multi_text_inp.html",
true,
true,
"Modules/TestQuestionPool");
146 $tpl->
setVariable(
"UP_BUTTON", $this->renderer->render(
147 $this->glyph_factory->up()->withAction(
'#')
149 $tpl->
setVariable(
"DOWN_BUTTON", $this->renderer->render(
150 $this->glyph_factory->down()->withAction(
'#')
163 " disabled=\"disabled\"" 168 $tpl->
setVariable(
"ADD_BUTTON", $this->renderer->render(
169 $this->glyph_factory->add()->withAction(
'#')
171 $tpl->
setVariable(
"REMOVE_BUTTON", $this->renderer->render(
172 $this->glyph_factory->remove()->withAction(
'#')
183 .
'"fieldContainerSelector": ".ilWzdContainerText", ' 184 .
'"reindexingRequiredElementsSelectors": ["input:text", "button"], ' 185 .
'"handleRowCleanUpCallback": function(rowElem) {$(rowElem).find("input:text").val("")}' 187 $this->tpl->addJavascript(
"./Modules/TestQuestionPool/templates/default/answerwizardinput.js");
188 $this->tpl->addJavascript(
"./Modules/TestQuestionPool/templates/default/identifiedwizardinput.js");
189 $this->tpl->addOnLoadCode(
"$.extend({}, AnswerWizardInput, IdentifiedWizardInput).init({$config});");
205 return (
bool) strlen(
$value);
render(string $a_mode="")
An entity that renders components to a string output.
fetchContentTextFromValue($value)
__construct($a_title="", $a_postvar="")
Constructor.
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
ilGlobalTemplateInterface $tpl
onCheckInput()
Check input, strip slashes etc.
valueHasContentText($value)
This is how a factory for glyphs looks like.
get(string $part=self::DEFAULT_BLOCK)
Renders the given block and returns the html string.
setVariable(string $variable, $value='')
Sets the given variable to the given value.
isEditElementOrderEnabled()
GlyphFactory $glyph_factory
isEditElementOccuranceEnabled()
setCurrentBlock(string $part=self::DEFAULT_BLOCK)
Sets the template to the given block.
$editElementOccuranceEnabled
setEditElementOrderEnabled($editElementOrderEnabled)
parseCurrentBlock(string $block_name=self::DEFAULT_BLOCK)
Parses the given block.
setEditElementOccuranceEnabled($editElementOccuranceEnabled)