5 include_once
"./Services/Certificate/classes/class.ilCertificateAdapter.php";
30 $lng->loadLanguageModule(
"skmg");
32 $this->skill = $a_skill;
33 $this->skill_level_id = $a_skill_level_id;
43 return CLIENT_WEB_DIR.
"/certificates/skill/".$this->skill->getId().
44 "/".$this->skill_level_id.
"/";
63 $vars[
"SKILL_TRIGGER_TITLE"] =
ilUtil::prepareFormOutput($this->skill->getTriggerTitleForCertificate($this->skill_level_id));
67 $insert_tags = array();
68 foreach($vars as $id => $caption)
70 $insert_tags[
"[".$id.
"]"] = $caption;
87 $lng->loadLanguageModule(
'certificate');
89 $user_data = $params[
"user_data"];
94 $vars[
"SKILL_TRIGGER_TITLE"] =
ilUtil::prepareFormOutput($this->skill->getTriggerTitleForCertificate($this->skill_level_id));
98 if ($achievement_date !==
false)
110 $vars[
"DATE_COMPLETED"] =
"";
111 $vars[
"DATETIME_COMPLETED"] =
"";
114 foreach($vars as $id => $caption)
116 $insert_tags[
"[".$id.
"]"] = $caption;
131 $lng->loadLanguageModule(
"skmg");
134 $vars[
"SKILL_TITLE"] = $lng->txt(
"skmg_cert_skill_title");
135 $vars[
"SKILL_LEVEL_TITLE"] = $lng->txt(
"skmg_cert_skill_level_title");
136 $vars[
"SKILL_TRIGGER_TITLE"] = $lng->txt(
"skmg_cert_skill_trigger_title");
138 $template =
new ilTemplate(
"tpl.certificate_edit.html", TRUE, TRUE,
"Services/Skill");
139 $template->setCurrentBlock(
"items");
140 foreach($vars as $id => $caption)
142 $template->setVariable(
"ID", $id);
143 $template->setVariable(
"TXT", $caption);
144 $template->parseCurrentBlock();
147 $template->setVariable(
"PH_INTRODUCTION", $lng->txt(
"certificate_ph_introduction"));
149 return $template->get();
267 $user_data = $params[
"user_data"];
268 if (!is_array($user_data))
270 $short_title = $this->skill->getShortTitleForCertificate();
271 return strftime(
"%y%m%d", time()) .
"_" . $lng->txt(
"certificate_var_user_lastname") .
"_" . $short_title .
"_" . $basename;
275 return strftime(
"%y%m%d", time()) .
"_" . $user_data[
"lastname"] .
"_" . $params[
"short_title"] .
"_" . $basename;