当前位置: 首页>>代码示例>>PHP>>正文


PHP ilPropertyFormGUI::setTitleIcon方法代码示例

本文整理汇总了PHP中ilPropertyFormGUI::setTitleIcon方法的典型用法代码示例。如果您正苦于以下问题:PHP ilPropertyFormGUI::setTitleIcon方法的具体用法?PHP ilPropertyFormGUI::setTitleIcon怎么用?PHP ilPropertyFormGUI::setTitleIcon使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ilPropertyFormGUI的用法示例。


在下文中一共展示了ilPropertyFormGUI::setTitleIcon方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: initUploadForm

 public function initUploadForm()
 {
     global $ilCtrl, $lng;
     include_once "./Services/Form/classes/class.ilDragDropFileInputGUI.php";
     include_once "./Services/jQuery/classes/class.iljQueryUtil.php";
     $this->form = new ilPropertyFormGUI();
     $this->form->setId("upload");
     $this->form->setMultipart(true);
     $this->form->setHideLabels();
     $file = new ilDragDropFileInputGUI($lng->txt("cld_upload_flies"), "upload_files");
     $file->setRequired(true);
     $this->form->addItem($file);
     $this->form->addCommandButton("uploadFiles", $lng->txt("upload"));
     $this->form->addCommandButton("cancelAll", $lng->txt("cancel"));
     $this->form->setTableWidth("100%");
     $this->form->setTitle($lng->txt("upload_files_title"));
     $this->form->setTitleIcon(ilUtil::getImagePath('icon_file.gif'), $lng->txt('obj_file'));
     $this->form->setTitle($lng->txt("upload_files"));
     $this->form->setFormAction($ilCtrl->getFormAction($this, "uploadFiles"));
     $this->form->setTarget("cld_blank_target");
 }
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:21,代码来源:class.ilCloudPluginUploadGUI.php

示例2: initNewAccountMailForm

 protected function initNewAccountMailForm()
 {
     global $lng, $ilCtrl;
     $lng->loadLanguageModule("meta");
     $lng->loadLanguageModule("mail");
     include_once "./Services/Form/classes/class.ilPropertyFormGUI.php";
     $form = new ilPropertyFormGUI();
     $form->setFormAction($ilCtrl->getFormAction($this));
     $form->setTitleIcon(ilUtil::getImagePath("icon_mail.png"));
     $form->setTitle($lng->txt("user_new_account_mail"));
     $form->setDescription($lng->txt("user_new_account_mail_desc"));
     $langs = $lng->getInstalledLanguages();
     foreach ($langs as $lang_key) {
         $amail = $this->object->_lookupNewAccountMail($lang_key);
         $title = $lng->txt("meta_l_" . $lang_key);
         if ($lang_key == $lng->getDefaultLanguage()) {
             $title .= " (" . $lng->txt("default") . ")";
         }
         $header = new ilFormSectionHeaderGUI();
         $header->setTitle($title);
         $form->addItem($header);
         $subj = new ilTextInputGUI($lng->txt("subject"), "subject_" . $lang_key);
         // $subj->setRequired(true);
         $subj->setValue($amail["subject"]);
         $form->addItem($subj);
         $salg = new ilTextInputGUI($lng->txt("mail_salutation_general"), "sal_g_" . $lang_key);
         // $salg->setRequired(true);
         $salg->setValue($amail["sal_g"]);
         $form->addItem($salg);
         $salf = new ilTextInputGUI($lng->txt("mail_salutation_female"), "sal_f_" . $lang_key);
         // $salf->setRequired(true);
         $salf->setValue($amail["sal_f"]);
         $form->addItem($salf);
         $salm = new ilTextInputGUI($lng->txt("mail_salutation_male"), "sal_m_" . $lang_key);
         // $salm->setRequired(true);
         $salm->setValue($amail["sal_m"]);
         $form->addItem($salm);
         $body = new ilTextAreaInputGUI($lng->txt("message_content"), "body_" . $lang_key);
         // $body->setRequired(true);
         $body->setValue($amail["body"]);
         $body->setRows(10);
         $body->setCols(100);
         $form->addItem($body);
         $att = new ilFileInputGUI($lng->txt("attachment"), "att_" . $lang_key);
         $att->setAllowDeletion(true);
         if ($amail["att_file"]) {
             $att->setValue($amail["att_file"]);
         }
         $form->addItem($att);
     }
     $form->addCommandButton("saveNewAccountMail", $lng->txt("save"));
     $form->addCommandButton("cancelNewAccountMail", $lng->txt("cancel"));
     return $form;
 }
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:54,代码来源:class.ilObjUserFolderGUI.php

示例3: showDetails

 public function showDetails()
 {
     global $ilMainMenu, $ilTabs, $ilToolbar, $ilUser;
     $this->__initPaymentObject();
     $this->__initPricesObject();
     $this->__initShoppingCartObject();
     $ilToolbar->addButton($this->lng->txt('payment_back_to_shop'), 'ilias.php?baseClass=ilShopController');
     $this->tpl->getStandardTemplate();
     $ilTabs->setTabActive('buy');
     $ilMainMenu->setActive('shop');
     if ($this->pobject->getStatus() == $this->pobject->STATUS_EXPIRES) {
         ilUtil::sendInfo($this->lng->txt('pay_expires_info'));
         return false;
     }
     $extension_prices = array();
     if ($ilUser->getId() != ANONYMOUS_USER_ID) {
         include_once './Services/Payment/classes/class.ilPaymentBookings.php';
         $has_extension_price = ilPaymentBookings::_hasAccesstoExtensionPrice($ilUser->getId(), $this->pobject->getPobjectId());
         if ($has_extension_price) {
             $extension_prices = $this->price_obj->getExtensionPrices();
         }
     }
     $org_prices = $this->price_obj->getPrices();
     $tmp_prices = array_merge($org_prices, $extension_prices);
     $prices = array();
     foreach ($tmp_prices as $price) {
         // expired prices must be filtered out
         if ($price['price_type'] == ilPaymentPrices::TYPE_DURATION_DATE && $price['duration_until'] < date('Y-m-d')) {
             //do nothing
         } else {
             $prices[] = $price;
         }
     }
     include_once './Services/Form/classes/class.ilPropertyFormGUI.php';
     $form = new ilPropertyFormGUI();
     $form->setFormAction($this->ctrl->getFormAction($this));
     $buyedObject = "";
     if ($this->sc_obj->isInShoppingCart($this->pobject->getPobjectId())) {
         $buyedObject = $this->sc_obj->getEntry($this->pobject->getPobjectId());
         if (is_array($prices) && count($prices) > 1) {
             ilUtil::sendInfo($this->lng->txt('pay_item_already_in_sc_choose_another'));
         } else {
             ilUtil::sendInfo($this->lng->txt('pay_item_already_in_sc'));
         }
     }
     $this->ctrl->setParameter($this, "ref_id", $this->pobject->getRefId());
     $subtype = '';
     if ($this->object) {
         if ($this->object->getType() == 'exc') {
             $subtype = ' (' . $this->lng->txt($this->pobject->getSubtype()) . ')';
         }
         $form->setTitle($this->object->getTitle() . ' ' . $subtype);
         $form->setTitleIcon(ilObject::_getIcon($this->object->getId()));
     } else {
         ilUtil::sendFailure($this->lng->txt('object_not_found'));
     }
     // payment infos
     $info = new ilNonEditableValueGUI($this->lng->txt('info'));
     $info->setValue($this->lng->txt('pay_info'));
     $form->addItem($info);
     if (is_array($buyedObject)) {
         if (is_array($prices) && count($prices) > 1) {
             $button_txt = $this->lng->txt('pay_change_price');
         } else {
             $button_txt = $this->lng->txt('pay_add_to_shopping_cart');
         }
     } else {
         $button_txt = $this->lng->txt('pay_add_to_shopping_cart');
     }
     $rg_prices = new ilRadioGroupInputGUI($this->lng->txt('prices'), 'price_id');
     if (is_array($prices)) {
         foreach ($prices as $price) {
             if (is_array($buyedObject) && $buyedObject["price_id"] == $price['price_id']) {
                 $rg_prices->setValue($price['price_id']);
             } else {
                 if (count($prices) == 1) {
                     $rg_prices->setValue($price['price_id']);
                 }
             }
             switch ($price['price_type']) {
                 case ilPaymentPrices::TYPE_DURATION_MONTH:
                     $txt_price = $price['duration'] . ' ' . $this->lng->txt('paya_months') . ': ';
                     break;
                 case ilPaymentPrices::TYPE_DURATION_DATE:
                     $txt_price = ilDatePresentation::formatDate(new ilDate($price['duration_from'], IL_CAL_DATE)) . ' - ' . ilDatePresentation::formatDate(new ilDate($price['duration_until'], IL_CAL_DATE)) . ':  ';
                     break;
                 case ilPaymentPrices::TYPE_UNLIMITED_DURATION:
                     $txt_price = $this->lng->txt('unlimited_duration') . ': ';
                     break;
             }
             $tmp_price = $price['price'];
             $extension_txt = '';
             if ($price['extension'] == 1) {
                 $extension_txt = '(' . $this->lng->txt('extension_price') . ')';
             }
             $price_row = new ilRadioOption($txt_price . ' ' . ilPaymentPrices::_formatPriceToString((double) $tmp_price) . ' ' . $extension_txt, $price['price_id']);
             $price_row->setInfo($price['description']);
             $rg_prices->addOption($price_row);
         }
         $form->addItem($rg_prices);
//.........这里部分代码省略.........
开发者ID:arlendotcn,项目名称:ilias,代码行数:101,代码来源:class.ilShopPurchaseGUI.php

示例4: initMultiUploadForm

 /**
  * Initializes the upload form for multiple files.
  *
  * @return object The created property form.
  */
 public function initMultiUploadForm()
 {
     include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
     $dnd_form_gui = new ilPropertyFormGUI();
     $dnd_form_gui->setMultipart(true);
     $dnd_form_gui->setHideLabels();
     // file input
     include_once "Services/Form/classes/class.ilDragDropFileInputGUI.php";
     $dnd_input = new ilDragDropFileInputGUI($this->lng->txt("files"), "upload_files");
     $dnd_input->setArchiveSuffixes(array("zip"));
     $dnd_input->setCommandButtonNames("uploadFiles", "cancel");
     $dnd_form_gui->addItem($dnd_input);
     // add commands
     $dnd_form_gui->addCommandButton("uploadFiles", $this->lng->txt("upload_files"));
     $dnd_form_gui->addCommandButton("cancel", $this->lng->txt("cancel"));
     $dnd_form_gui->setTableWidth("100%");
     $dnd_form_gui->setTarget($this->getTargetFrame("save"));
     $dnd_form_gui->setTitle($this->lng->txt("upload_files_title"));
     $dnd_form_gui->setTitleIcon(ilUtil::getImagePath('icon_file.gif'), $this->lng->txt('obj_file'));
     $this->ctrl->setParameter($this, "new_type", "file");
     $dnd_form_gui->setFormAction($this->ctrl->getFormAction($this, "uploadFiles"));
     return $dnd_form_gui;
 }
开发者ID:arlendotcn,项目名称:ilias,代码行数:28,代码来源:class.ilObjFileGUI.php

示例5: editStatisticObject

 public function editStatisticObject($a_show_confirm_delete = false)
 {
     global $ilToolbar;
     include_once './Services/Payment/classes/class.ilPayMethods.php';
     if (!isset($_GET['booking_id'])) {
         ilUtil::sendInfo($this->lng->txt('paya_no_booking_id_given'));
         $this->showStatistics();
         return true;
     }
     $ilToolbar->addButton($this->lng->txt('back'), $this->ctrl->getLinkTarget($this, 'statistic'));
     $this->tpl->addBlockfile('ADM_CONTENT', 'adm_content', 'tpl.main_view.html', 'Services/Payment');
     $this->ctrl->setParameter($this, 'booking_id', (int) $_GET['booking_id']);
     // confirm delete
     if ($a_show_confirm_delete) {
         $oConfirmationGUI = new ilConfirmationGUI();
         // set confirm/cancel commands
         $oConfirmationGUI->setFormAction($this->ctrl->getFormAction($this, "performDelete"));
         $oConfirmationGUI->setHeaderText($this->lng->txt("paya_sure_delete_stat"));
         $oConfirmationGUI->setCancel($this->lng->txt("cancel"), "statistic");
         $oConfirmationGUI->setConfirm($this->lng->txt("confirm"), "performDelete");
         $this->tpl->setVariable('CONFIRMATION', $oConfirmationGUI->getHTML());
         return true;
     }
     $this->__initBookingObject();
     $bookings = $this->booking_obj->getBookings();
     $booking = $bookings[(int) $_GET['booking_id']];
     // get customer_obj
     $tmp_user = ilObjectFactory::getInstanceByObjId($booking['customer_id'], false);
     $oForm = new ilPropertyFormGUI();
     $oForm->setFormAction($this->ctrl->getFormAction($this));
     $oForm->setId('stat_form');
     $oForm->setTableWidth('50 %');
     $oForm->setTitleIcon(ilUtil::getImagePath('icon_usr.png'));
     if (is_object($tmp_user)) {
         $frm_user = $tmp_user->getFullname() . ' [' . $tmp_user->getLogin() . ']';
     } else {
         $frm_user = $this->lng->txt('user_deleted');
     }
     $oForm->setTitle($frm_user);
     $pObj = new ilPaymentObject($this->user_obj, $booking['pobject_id']);
     $tmp_obj = ilObject::_lookupTitle(ilObject::_lookupObjId($pObj->getRefId()));
     // object_title
     $oTitleGUI = new ilNonEditableValueGUI($this->lng->txt('title'));
     $oTitleGUI->setValue($tmp_obj != '' ? $tmp_obj : $this->lng->txt('object_deleted'));
     $oForm->addItem($oTitleGUI);
     // transaction
     $oTransactionGUI = new ilNonEditableValueGUI($this->lng->txt('paya_transaction'));
     $oTransactionGUI->setValue($booking['transaction']);
     $oForm->addItem($oTransactionGUI);
     //vendor
     $oVendorGUI = new ilNonEditableValueGUI($this->lng->txt('paya_vendor'));
     $tmp_vendor = ilObjectFactory::getInstanceByObjId($booking['b_vendor_id'], false);
     if (is_object($tmp_vendor)) {
         $frm_vendor = $tmp_vendor->getFullname() . ' [' . $tmp_vendor->getLogin() . ']';
     } else {
         $frm_vendor = $this->lng->txt('user_deleted');
     }
     $oVendorGUI->setValue($frm_vendor);
     $oForm->addItem($oVendorGUI);
     // paymethod
     $oPaymethodGUI = new ilNonEditableValueGUI($this->lng->txt('paya_pay_method'));
     $oPaymethodGUI->setValue(ilPayMethods::getStringByPaymethod($booking['b_pay_method']));
     $oForm->addItem($oPaymethodGUI);
     // order_date
     $oOrderdateGUI = new ilNonEditableValueGUI($this->lng->txt('paya_order_date'));
     $oOrderdateGUI->setValue(ilDatePresentation::formatDate(new ilDate($booking['order_date'], IL_CAL_UNIX)));
     $oForm->addItem($oOrderdateGUI);
     // duration
     $oDurationGUI = new ilNonEditableValueGUI($this->lng->txt('duration'));
     if ($booking['duration'] == 0 && $booking['access_enddate'] == NULL) {
         $frm_duration = $this->lng->txt("unlimited_duration");
     } else {
         if ($booking['duration'] > 0) {
             $frm_duration = $booking['duration'] . ' ' . $this->lng->txt('paya_months') . '</br>';
         }
         $frm_duration .= ilDatePresentation::formatDate(new ilDate($booking['access_startdate'], IL_CAL_DATETIME)) . ' - ' . ilDatePresentation::formatDate(new ilDate($booking['access_enddate'], IL_CAL_DATETIME));
     }
     $oDurationGUI->setValue($frm_duration);
     $oForm->addItem($oDurationGUI);
     // price
     $oPriceGUI = new ilNonEditableValueGUI($this->lng->txt('price_a'));
     $oPriceGUI->setValue($booking['price'] . ' ' . $booking['currency_unit']);
     $oForm->addItem($oPriceGUI);
     //discount
     $oDiscountGUI = new ilNonEditableValueGUI($this->lng->txt('paya_coupons_coupon'));
     $oDiscountGUI->setValue($booking['discount'] . ' ' . $booking['currency_unit']);
     $oForm->addItem($oDiscountGUI);
     // payed
     $oPayedGUI = new ilSelectInputGUI();
     $payed_option = array(0 => $this->lng->txt('no'), 1 => $this->lng->txt('yes'));
     $oPayedGUI->setTitle($this->lng->txt('paya_payed'));
     $oPayedGUI->setOptions($payed_option);
     $oPayedGUI->setValue($booking['payed']);
     $oPayedGUI->setPostVar('payed');
     $oForm->addItem($oPayedGUI);
     // access
     $oAccessGUI = new ilSelectInputGUI();
     $access_option = array(0 => $this->lng->txt('no'), 1 => $this->lng->txt('yes'));
     $oAccessGUI->setTitle($this->lng->txt('paya_access'));
     $oAccessGUI->setOptions($access_option);
//.........这里部分代码省略.........
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:101,代码来源:class.ilObjPaymentSettingsGUI.php

示例6: initTopicCreateForm

 private function initTopicCreateForm()
 {
     /**
      * @var $ilUser ilObjUser
      * @var $rbacsystem ilRbacSystem
      * @var $ilias ILIAS
      * @var $ilSetting ilSetting
      */
     global $ilUser, $rbacsystem, $ilias, $ilSetting;
     $this->create_topic_form_gui = new ilPropertyFormGUI();
     $this->create_topic_form_gui->setTitle($this->lng->txt('forums_new_thread'));
     $this->create_topic_form_gui->setTitleIcon(ilUtil::getImagePath('icon_frm.svg'));
     $this->create_topic_form_gui->setTableWidth('100%');
     // form action
     $this->create_topic_form_gui->setFormAction($this->ctrl->getFormAction($this, 'addThread'));
     if ($this->objProperties->isAnonymized() == 1) {
         $alias_gui = new ilTextInputGUI($this->lng->txt('forums_your_name'), 'alias');
         $alias_gui->setInfo($this->lng->txt('forums_use_alias'));
         $alias_gui->setMaxLength(255);
         $alias_gui->setSize(50);
         $this->create_topic_form_gui->addItem($alias_gui);
     } else {
         $alias_gui = new ilNonEditableValueGUI($this->lng->txt('forums_your_name'), 'alias');
         $alias_gui->setValue($ilUser->getLogin());
         $this->create_topic_form_gui->addItem($alias_gui);
     }
     // topic
     $subject_gui = new ilTextInputGUI($this->lng->txt('forums_thread'), 'subject');
     $subject_gui->setMaxLength(255);
     $subject_gui->setSize(50);
     $subject_gui->setRequired(true);
     $this->create_topic_form_gui->addItem($subject_gui);
     // message
     $post_gui = new ilTextAreaInputGUI($this->lng->txt('forums_the_post'), 'message');
     $post_gui->setCols(50);
     $post_gui->setRows(15);
     $post_gui->setRequired(true);
     $post_gui->setUseRte(true);
     $post_gui->addPlugin('latex');
     $post_gui->addButton('latex');
     $post_gui->addButton('pastelatex');
     $post_gui->addPlugin('ilfrmquote');
     //$post_gui->addPlugin('code');
     $post_gui->removePlugin('advlink');
     $post_gui->usePurifier(true);
     $post_gui->setRTERootBlockElement('');
     $post_gui->setRTESupport($ilUser->getId(), 'frm~', 'frm_post', 'tpl.tinymce_frm_post.html', false, '3.4.7');
     $post_gui->disableButtons(array('charmap', 'undo', 'redo', 'justifyleft', 'justifycenter', 'justifyright', 'justifyfull', 'anchor', 'fullscreen', 'cut', 'copy', 'paste', 'pastetext', 'formatselect'));
     // purifier
     require_once 'Services/Html/classes/class.ilHtmlPurifierFactory.php';
     $post_gui->setPurifier(ilHtmlPurifierFactory::_getInstanceByType('frm_post'));
     $this->create_topic_form_gui->addItem($post_gui);
     // file
     $fi = new ilFileWizardInputGUI($this->lng->txt('forums_attachments_add'), 'userfile');
     $fi->setFilenames(array(0 => ''));
     $this->create_topic_form_gui->addItem($fi);
     include_once 'Services/Mail/classes/class.ilMail.php';
     $umail = new ilMail($ilUser->getId());
     // catch hack attempts
     if ($rbacsystem->checkAccess('internal_mail', $umail->getMailObjectReferenceId()) && !$this->objProperties->isAnonymized()) {
         // direct notification
         $dir_notification_gui = new ilCheckboxInputGUI($this->lng->txt('forum_direct_notification'), 'notify');
         $dir_notification_gui->setInfo($this->lng->txt('forum_notify_me_directly'));
         $dir_notification_gui->setValue(1);
         $this->create_topic_form_gui->addItem($dir_notification_gui);
         if ($ilias->getSetting('forum_notification') != 0) {
             // gen. notification
             $gen_notification_gui = new ilCheckboxInputGUI($this->lng->txt('forum_general_notification'), 'notify_posts');
             $gen_notification_gui->setInfo($this->lng->txt('forum_notify_me_generally'));
             $gen_notification_gui->setValue(1);
             $this->create_topic_form_gui->addItem($gen_notification_gui);
         }
     }
     require_once 'Services/Captcha/classes/class.ilCaptchaUtil.php';
     if ($ilUser->isAnonymous() && !$ilUser->isCaptchaVerified() && ilCaptchaUtil::isActiveForForum()) {
         require_once 'Services/Captcha/classes/class.ilCaptchaInputGUI.php';
         $captcha = new ilCaptchaInputGUI($this->lng->txt('cont_captcha_code'), 'captcha_code');
         $captcha->setRequired(true);
         $this->create_topic_form_gui->addItem($captcha);
     }
     $this->create_topic_form_gui->addCommandButton('addThread', $this->lng->txt('create'));
     $this->create_topic_form_gui->addCommandButton('showThreads', $this->lng->txt('cancel'));
 }
开发者ID:bheyser,项目名称:qplskl,代码行数:83,代码来源:class.ilObjForumGUI.php

示例7: initEditForm

 /**
  * init form
  *
  * @access protected
  * @param
  * @return
  */
 protected function initEditForm()
 {
     include_once './Services/Form/classes/class.ilPropertyFormGUI.php';
     include_once './Services/Calendar/classes/class.ilDateTime.php';
     $form = new ilPropertyFormGUI();
     $form->setTitle($this->lng->txt('crs_edit'));
     $form->setTitleIcon(ilUtil::getImagePath('icon_crs_s.png'));
     $form->addCommandButton('update', $this->lng->txt('save'));
     $form->addCommandButton('cancel', $this->lng->txt('cancel'));
     $form->setFormAction($this->ctrl->getFormAction($this, 'update'));
     // title
     $title = new ilTextInputGUI($this->lng->txt('title'), 'title');
     $title->setSubmitFormOnEnter(true);
     $title->setValue($this->object->getTitle());
     $title->setSize(40);
     $title->setMaxLength(128);
     $title->setRequired(true);
     $form->addItem($title);
     // desc
     $desc = new ilTextAreaInputGUI($this->lng->txt('description'), 'desc');
     $desc->setValue($this->object->getLongDescription());
     $desc->setRows(2);
     $desc->setCols(40);
     $form->addItem($desc);
     // Show didactic template type
     $this->initDidacticTemplate($form);
     // activation/availability
     $this->lng->loadLanguageModule('rep');
     $section = new ilFormSectionHeaderGUI();
     $section->setTitle($this->lng->txt('rep_activation_availability'));
     $form->addItem($section);
     $online = new ilCheckboxInputGUI($this->lng->txt('rep_activation_online'), 'activation_online');
     $online->setChecked(!$this->object->getOfflineStatus());
     $online->setInfo($this->lng->txt('crs_activation_online_info'));
     $form->addItem($online);
     $act_type = new ilRadioGroupInputGUI($this->lng->txt('rep_activation_access'), 'activation_type');
     $act_type->setValue($this->object->getActivationType());
     $opt = new ilRadioOption($this->lng->txt('crs_visibility_limitless'), IL_CRS_ACTIVATION_UNLIMITED);
     $opt->setInfo($this->lng->txt('crs_availability_limitless_info'));
     $act_type->addOption($opt);
     $opt = new ilRadioOption($this->lng->txt('crs_visibility_until'), IL_CRS_ACTIVATION_LIMITED);
     $opt->setInfo($this->lng->txt('crs_availability_until_info'));
     $start = new ilDateTimeInputGUI($this->lng->txt('rep_activation_limited_start'), 'activation_start');
     #$start->setMode(ilDateTimeInputGUI::MODE_INPUT);
     $start->setShowTime(true);
     $start_date = new ilDateTime($this->object->getActivationStart(), IL_CAL_UNIX);
     $start->setDate($start_date);
     $opt->addSubItem($start);
     $end = new ilDateTimeInputGUI($this->lng->txt('rep_activation_limited_end'), 'activation_end');
     #$end->setMode(ilDateTimeInputGUI::MODE_INPUT);
     $end->setShowTime(true);
     $end_date = new ilDateTime($this->object->getActivationEnd(), IL_CAL_UNIX);
     $end->setDate($end_date);
     $opt->addSubItem($end);
     $visible = new ilCheckboxInputGUI($this->lng->txt('rep_activation_limited_visibility'), 'activation_visibility');
     $visible->setInfo($this->lng->txt('crs_activation_limited_visibility_info'));
     $visible->setChecked($this->object->getActivationVisibility());
     $opt->addSubItem($visible);
     $act_type->addOption($opt);
     $form->addItem($act_type);
     $section = new ilFormSectionHeaderGUI();
     $section->setTitle($this->lng->txt('crs_reg'));
     $form->addItem($section);
     $reg_type = new ilRadioGroupInputGUI($this->lng->txt('crs_reg_period'), 'subscription_limitation_type');
     $reg_type->setValue($this->object->getSubscriptionLimitationType());
     $opt = new ilRadioOption($this->lng->txt('crs_reg_deactivated'), IL_CRS_SUBSCRIPTION_DEACTIVATED);
     $opt->setInfo($this->lng->txt('crs_registration_deactivated'));
     $reg_type->addOption($opt);
     $opt = new ilRadioOption($this->lng->txt('crs_registration_unlimited'), IL_CRS_SUBSCRIPTION_UNLIMITED);
     $opt->setInfo($this->lng->txt('crs_reg_unlim_info'));
     $reg_type->addOption($opt);
     $opt = new ilRadioOption($this->lng->txt('crs_registration_limited'), IL_CRS_SUBSCRIPTION_LIMITED);
     $opt->setInfo($this->lng->txt('crs_reg_lim_info'));
     $start = new ilDateTimeInputGUI($this->lng->txt('crs_start'), 'subscription_start');
     $start->setShowTime(true);
     $start_date = new ilDateTime($this->object->getSubscriptionStart(), IL_CAL_UNIX);
     $start->setDate($start_date);
     $opt->addSubItem($start);
     $end = new ilDateTimeInputGUI($this->lng->txt('crs_end'), 'subscription_end');
     $end->setShowTime(true);
     $end_date = new ilDateTime($this->object->getSubscriptionEnd(), IL_CAL_UNIX);
     $end->setDate($end_date);
     $opt->addSubItem($end);
     $reg_type->addOption($opt);
     $form->addItem($reg_type);
     $reg_proc = new ilRadioGroupInputGUI($this->lng->txt('crs_registration_type'), 'subscription_type');
     $reg_proc->setValue($this->object->getSubscriptionType());
     $reg_proc->setInfo($this->lng->txt('crs_reg_type_info'));
     $opt = new ilRadioOption($this->lng->txt('crs_subscription_options_confirmation'), IL_CRS_SUBSCRIPTION_CONFIRMATION);
     $reg_proc->addOption($opt);
     $opt = new ilRadioOption($this->lng->txt('crs_subscription_options_direct'), IL_CRS_SUBSCRIPTION_DIRECT);
     $reg_proc->addOption($opt);
     $opt = new ilRadioOption($this->lng->txt('crs_subscription_options_password'), IL_CRS_SUBSCRIPTION_PASSWORD);
//.........这里部分代码省略.........
开发者ID:khanhnnvn,项目名称:ilias_E-learning,代码行数:101,代码来源:class.ilObjCourseGUI.php

示例8: showSelectedObject

 public function showSelectedObject()
 {
     global $ilToolbar;
     if (!(int) $_GET['sell_id']) {
         ilUtil::sendInfo($this->lng->txt('paya_no_object_selected'));
         return $this->showObjectSelector();
     }
     $ilToolbar->addButton($this->lng->txt('back'), $this->ctrl->getLinkTarget($this, 'showObjectSelector'));
     // save ref_id of selected object
     $this->ctrl->setParameter($this, 'sell_id', (int) $_GET['sell_id']);
     include_once 'Services/Form/classes/class.ilPropertyFormGUI.php';
     $oForm = new ilPropertyFormGUI();
     $oForm->setFormAction($this->ctrl->getFormAction($this, 'updateDetails'));
     $oForm->setTitle($this->lng->txt('details'));
     $oForm->setTitleIcon(ilUtil::getImagePath('icon_pays.png', false));
     $tmp_obj = ilObjectFactory::getInstanceByRefId($_GET['sell_id'], false);
     if (is_object($tmp_obj)) {
         $tmp_object['title'] = $tmp_obj->getTitle();
         $tmp_object['description'] = $tmp_obj->getDescription();
         $tmp_object['owner'] = $tmp_obj->getOwnerName();
         $tmp_object['path'] = $this->__getHTMLPath((int) $_GET['sell_id']);
     } else {
         $tmp_object['title'] = $this->lng->txt('object_not_found');
         $tmp_object['description'] = '';
         $tmp_object['owner'] = '';
         $tmp_object['path'] = '';
     }
     // title
     $oTitleGUI = new ilNonEditableValueGUI($this->lng->txt('title'));
     $oTitleGUI->setValue($tmp_object['title']);
     $oForm->addItem($oTitleGUI);
     // description
     $oDescriptionGUI = new ilNonEditableValueGUI($this->lng->txt('description'));
     $oDescriptionGUI->setValue($tmp_object['description']);
     $oForm->addItem($oDescriptionGUI);
     // owner
     $oOwnerGUI = new ilNonEditableValueGUI($this->lng->txt('owner'));
     $oOwnerGUI->setValue($tmp_object['owner']);
     $oForm->addItem($oOwnerGUI);
     // repository path
     $oPathGUI = new ilNonEditableValueGUI($this->lng->txt('path'));
     $oPathGUI->setValue($tmp_object['path']);
     $oForm->addItem($oPathGUI);
     // vendors
     $oVendorsGUI = new ilSelectInputGUI($this->lng->txt('paya_vendor'), 'vendor');
     $oVendorsGUI->setOptions($this->__getVendors());
     $oForm->addItem($oVendorsGUI);
     // buttons
     $oForm->addCommandButton('addObject', $this->lng->txt('next'));
     $oForm->addCommandButton('showObjects', $this->lng->txt('cancel'));
     $this->tpl->setVariable('ADM_CONTENT', $oForm->getHTML());
     return true;
 }
开发者ID:khanhnnvn,项目名称:ilias_E-learning,代码行数:53,代码来源:class.ilPaymentObjectGUI.php

示例9: initZipUploadForm

 /**
  * FORM: Init zip upload form.
  */
 public function initZipUploadForm($a_mode = "create")
 {
     global $lng;
     include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
     $zip_form_gui = new ilPropertyFormGUI();
     $zip_form_gui->setMultipart(true);
     // File
     $in_file = new ilFileInputGUI($lng->txt("file"), "zip_file");
     $in_file->setRequired(true);
     $in_file->setSuffixes(array("zip"));
     $zip_form_gui->addItem($in_file);
     // Take over structure
     $in_str = new ilCheckboxInputGUI($this->lng->txt("take_over_structure"), "adopt_structure");
     $in_str->setInfo($this->lng->txt("take_over_structure_info"));
     $zip_form_gui->addItem($in_str);
     $zip_form_gui->addCommandButton("saveUnzip", $this->lng->txt($this->type . "_add"));
     $zip_form_gui->addCommandButton("cancel", $lng->txt("cancel"));
     $zip_form_gui->setTableWidth("600px");
     $zip_form_gui->setTarget($this->getTargetFrame("save"));
     $zip_form_gui->setTitle($this->lng->txt("header_zip"));
     $zip_form_gui->setTitleIcon(ilUtil::getImagePath('icon_file.png'), $this->lng->txt('obj_file'));
     $this->ctrl->setParameter($this, "new_type", "file");
     $zip_form_gui->setFormAction($this->ctrl->getFormAction($this, "saveUnzip"));
     return $zip_form_gui;
 }
开发者ID:khanhnnvn,项目名称:ilias_E-learning,代码行数:28,代码来源:class.ilObjFileGUI.php

示例10: editSettings

 /**
  * Show settings screen.
  */
 function editSettings()
 {
     global $ilUser, $lng, $ilCtrl, $ilSetting;
     $news_set = new ilSetting("news");
     $enable_internal_rss = $news_set->get("enable_rss_for_internal");
     $allow_shorter_periods = $news_set->get("allow_shorter_periods");
     $allow_longer_periods = $news_set->get("allow_longer_periods");
     $enable_private_feed = $news_set->get("enable_private_feed");
     include_once "./Services/Form/classes/class.ilPropertyFormGUI.php";
     if ($allow_shorter_periods || $allow_longer_periods) {
         $form = new ilPropertyFormGUI();
         include_once "./Services/News/classes/class.ilNewsItem.php";
         $default_per = ilNewsItem::_lookupDefaultPDPeriod();
         $per = ilNewsItem::_lookupUserPDPeriod($ilUser->getId());
         $form->setTitle($lng->txt("news_settings"));
         $form->setTitleIcon(ilUtil::getImagePath("icon_news.png"));
         $form->setTableWidth("100%");
         $per_opts = array(2 => "2 " . $lng->txt("days"), 3 => "3 " . $lng->txt("days"), 5 => "5 " . $lng->txt("days"), 7 => "1 " . $lng->txt("week"), 14 => "2 " . $lng->txt("weeks"), 30 => "1 " . $lng->txt("month"), 60 => "2 " . $lng->txt("months"), 120 => "4 " . $lng->txt("months"), 180 => "6 " . $lng->txt("months"), 366 => "1 " . $lng->txt("year"));
         $unset = array();
         foreach ($per_opts as $k => $opt) {
             if (!$allow_shorter_periods && $k < $default_per) {
                 $unset[$k] = $k;
             }
             if (!$allow_longer_periods && $k > $default_per) {
                 $unset[$k] = $k;
             }
         }
         foreach ($unset as $k) {
             unset($per_opts[$k]);
         }
         $per_sel = new ilSelectInputGUI($lng->txt("news_pd_period"), "news_pd_period");
         //$per_sel->setInfo($lng->txt("news_pd_period_info"));
         $per_sel->setOptions($per_opts);
         $per_sel->setValue((int) $per);
         $form->addItem($per_sel);
         //$form->addCheckboxProperty($lng->txt("news_public_feed"), "notifications_public_feed",
         //	"1", $public_feed, $lng->txt("news_public_feed_info"));
         //if ($this->getProperty("public_notifications_option"))
         //{
         //	$form->addCheckboxProperty($lng->txt("news_notifications_public"), "notifications_public",
         //		"1", $public, $lng->txt("news_notifications_public_info"));
         //}
         $form->addCommandButton("saveSettings", $lng->txt("save"));
         $form->addCommandButton("cancelSettings", $lng->txt("cancel"));
         $form->setFormAction($ilCtrl->getFormaction($this));
         $returnForm = $form->getHTML();
     }
     if ($enable_private_feed) {
         $feed_form = new ilPropertyFormGUI();
         $feed_form->setTitle($lng->txt("priv_feed_settings"));
         $feed_form->setTitleIcon(ilUtil::getImagePath("privrss.png"));
         $feed_form->setTableWidth("100%");
         $enable_private_feed = new ilCheckboxInputGUI($lng->txt("news_enable_private_feed"), "enable_private_feed");
         $retype_pass = new ilTextInputGUI($lng->txt("retype_password"), "retype_password");
         $desired_pass = new ilTextInputGUI($lng->txt("desired_password"), "desired_password");
         // user has already valid password
         if (ilObjUser::_getFeedPass($_SESSION[AccountId]) != false) {
             $enable_private_feed->setChecked(true);
             $desired_pass->setValue("******");
         }
         $desired_pass->setInputType("password");
         $retype_pass->setInputType("password");
         $feed_form->addItem($enable_private_feed);
         $feed_form->addItem($desired_pass);
         $feed_form->addItem($retype_pass);
         $feed_form->addCommandButton("changeFeedSettings", $lng->txt("save"));
         $feed_form->addCommandButton("cancelSettings", $lng->txt("cancel"));
         $feed_form->setFormAction($ilCtrl->getFormaction($this));
         $returnForm .= $returnForm == "" ? $feed_form->getHTML() : "<br>" . $feed_form->getHTML();
     }
     return $returnForm;
 }
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:75,代码来源:class.ilPDNewsBlockGUI.php


注:本文中的ilPropertyFormGUI::setTitleIcon方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。