當前位置: 首頁>>代碼示例>>PHP>>正文


PHP ilCourseParticipants::_deleteAllEntries方法代碼示例

本文整理匯總了PHP中ilCourseParticipants::_deleteAllEntries方法的典型用法代碼示例。如果您正苦於以下問題:PHP ilCourseParticipants::_deleteAllEntries方法的具體用法?PHP ilCourseParticipants::_deleteAllEntries怎麽用?PHP ilCourseParticipants::_deleteAllEntries使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在ilCourseParticipants的用法示例。


在下文中一共展示了ilCourseParticipants::_deleteAllEntries方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: delete

 /**
  * delete course and all related data	
  *
  * @access	public
  * @return	boolean	true if all object data were removed; false if only a references were removed
  */
 function delete()
 {
     global $ilAppEventHandler;
     // always call parent delete function first!!
     if (!parent::delete()) {
         return false;
     }
     // delete meta data
     $this->deleteMetaData();
     // put here course specific stuff
     $this->__deleteSettings();
     include_once 'Modules/Course/classes/class.ilCourseParticipants.php';
     ilCourseParticipants::_deleteAllEntries($this->getId());
     $this->initCourseArchiveObject();
     $this->archives_obj->deleteAll();
     include_once './Modules/Course/classes/class.ilCourseObjective.php';
     ilCourseObjective::_deleteAll($this->getId());
     include_once './Modules/Course/classes/class.ilObjCourseGrouping.php';
     ilObjCourseGrouping::_deleteAll($this->getId());
     include_once './Modules/Course/classes/class.ilCourseFile.php';
     ilCourseFile::_deleteByCourse($this->getId());
     include_once 'Modules/Course/classes/Export/class.ilCourseDefinedFieldDefinition.php';
     ilCourseDefinedFieldDefinition::_deleteByContainer($this->getId());
     $ilAppEventHandler->raise('Modules/Course', 'delete', array('object' => $this, 'obj_id' => $this->getId(), 'appointments' => $this->prepareAppointments('delete')));
     return true;
 }
開發者ID:arlendotcn,項目名稱:ilias,代碼行數:32,代碼來源:class.ilObjCourse.php

示例2: updateCourse

 function updateCourse($sid, $course_id, $xml)
 {
     $this->initAuth($sid);
     $this->initIlias();
     if (!$this->__checkSession($sid)) {
         return $this->__raiseError($this->__getMessage(), $this->__getMessageCode());
     }
     if (!is_numeric($course_id)) {
         return $this->__raiseError('No valid course id given. Please choose an existing reference id of an ILIAS course', 'Client');
     }
     global $rbacsystem;
     if (($obj_type = ilObject::_lookupType(ilObject::_lookupObjId($course_id))) != 'crs') {
         $course_id = end($ref_ids = ilObject::_getAllReferences($course_id));
         if (ilObject::_lookupType(ilObject::_lookupObjId($course_id)) != 'crs') {
             return $this->__raiseError('Invalid course id. Object with id "' . $course_id . '" is not of type "course"', 'Client');
         }
     }
     if (!($tmp_course = ilObjectFactory::getInstanceByRefId($course_id, false))) {
         return $this->__raiseError('Cannot create course instance!', 'Server');
     }
     if (!$rbacsystem->checkAccess('write', $course_id)) {
         return $this->__raiseError('Check access failed. No permission to write course', 'Server');
     }
     // First delete old meta data
     include_once 'Services/MetaData/classes/class.ilMD.php';
     $md = new ilMD($tmp_course->getId(), 0, 'crs');
     $md->deleteAll();
     include_once 'Modules/Course/classes/class.ilCourseParticipants.php';
     ilCourseParticipants::_deleteAllEntries($tmp_course->getId());
     include_once 'Modules/Course/classes/class.ilCourseWaitingList.php';
     ilCourseWaitingList::_deleteAll($tmp_course->getId());
     include_once 'Modules/Course/classes/class.ilCourseXMLParser.php';
     $xml_parser = new ilCourseXMLParser($tmp_course);
     $xml_parser->setXMLContent($xml);
     $xml_parser->startParsing();
     $tmp_course->MDUpdateListener('General');
     return true;
 }
開發者ID:khanhnnvn,項目名稱:ilias_E-learning,代碼行數:38,代碼來源:class.ilSoapCourseAdministration.php


注:本文中的ilCourseParticipants::_deleteAllEntries方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。