5 include_once(
"./Services/Form/classes/class.ilFormPropertyGUI.php");
30 $this->lng->loadLanguageModule(
"meta");
32 parent::__construct($a_title, $a_postvar);
33 $this->
setType(
"typical_learntime");
44 $this->value = $a_value;
54 $this->lom_duration = $a_value;
57 include_once
'Services/MetaData/classes/class.ilMDUtils.php';
109 if ($this->
getRequired() && $v[0] == 0 && $v[1] == 0 &&
110 $v[2] == 0 && $v[3] == 0 && (
int) $v[4] == 0) {
111 $this->
setAlert($lng->txt(
"msg_input_is_required"));
120 for (
$i = 0;
$i <= 24;
$i++) {
129 for (
$i = 0;
$i <= 31;
$i++) {
140 $ttpl =
new ilTemplate(
"tpl.prop_typical_learning_time.html",
true,
true,
"Services/MetaData");
143 $ttpl->setVariable(
"TXT_MONTH", $this->lng->txt(
'md_months'));
147 $ttpl->setVariable(
"TXT_DAYS", $this->lng->txt(
'md_days'));
148 $ttpl->setVariable(
"TXT_TIME", $this->lng->txt(
'md_time'));
152 $val[4] ?
false :
true,
158 $ttpl->setVariable(
"TLT_HINT", $tlt[4] ?
'(hh:mm:ss)' :
'(hh:mm)');
161 $ttpl->setCurrentBlock(
"tlt_not_valid");
162 $ttpl->setVariable(
"TXT_CURRENT_VAL", $this->lng->txt(
'meta_current_value'));
163 $ttpl->setVariable(
"TLT", $this->lom_duration);
164 $ttpl->setVariable(
"INFO_TLT_NOT_VALID", $this->lng->txt(
'meta_info_tlt_not_valid'));
165 $ttpl->parseCurrentBlock();
168 $a_tpl->setCurrentBlock(
"prop_generic");
169 $a_tpl->setVariable(
"PROP_GENERIC", $ttpl->get());
170 $a_tpl->parseCurrentBlock();
static makeTimeSelect($prefix, $short=true, $hour="", $minute="", $second="", $a_use_default=true, $a_further_options=array())
Creates a combination of HTML selects for time inputs.
static _LOMDurationToArray($a_string)
LOM datatype duration is a string like P2M4DT7H18M2S (2 months 4 days 7 hours 18 minutes 2 seconds) T...
special template class to simplify handling of ITX/PEAR
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
Create styles array
The data for the language used.
static formSelect( $selected, $varname, $options, $multiple=false, $direct_text=false, $size="0", $style_class="", $attribs="", $disabled=false)
Builds a select form field with options and shows the selected option first.
if(!isset($_REQUEST['ReturnTo'])) if(!isset($_REQUEST['AuthId'])) $options