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


PHP object::getAll方法代碼示例

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


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

示例1: indexAction

 public function indexAction()
 {
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     $LotoArr = $this->oLoto->getAll();
     include $this->tpl('Loto_list');
 }
開發者ID:032404cxd,項目名稱:prototype_main,代碼行數:7,代碼來源:LotoController.php

示例2: indexAction

 /**
  * 瀏覽遊戲列表
  * @return unknown_type
  */
 public function indexAction()
 {
     /**
      * 記錄日誌
      */
     $log = "遊戲管理\n\nServerIp:\n" . $this->request->getServer('SERVER_ADDR') . "\n\nGET:\n" . var_export($_GET, true) . "\n\nPOST:\n" . var_export($_POST, true);
     $this->oLogManager->push('log', $log);
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     /**
      * 遊戲類型
      * @var string
      */
     $appType = intval($this->request->appType);
     $oAppArr = array();
     $oGameClaArr = $this->oClass->getAll();
     if ($appType) {
         $oAppArr = $this->oApp->getByClass($appType);
     } else {
         $oAppArr = $this->oApp->getAll();
     }
     if (is_array($oAppArr)) {
         foreach ($oAppArr as $keyApp => $valApp) {
             $oAppArr[$keyApp]['class_name'] = $valApp['ClassId'] ? $oGameClaArr[$valApp['ClassId']]['name'] : "未分類";
             $oAppArr[$keyApp]['comment'] = json_decode($valApp['comment'], true);
         }
     }
     include $this->tpl();
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:33,代碼來源:AppController.php

示例3: indexAction

 public function indexAction()
 {
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     $SourceTypeArr = $this->oSourceType->getAll();
     include $this->tpl('Config_Source_Type_list');
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:7,代碼來源:TypeController.php

示例4: init

 /**
  * 初始化
  * (non-PHPdoc)
  * @see AbstractController#init()
  */
 public function init()
 {
     parent::init();
     $this->oResearch = new Config_Research();
     $this->oQuestion = new Config_Research_Question();
     $this->ResearchList = $this->oResearch->getAll();
     $this->AnswerTypeList = array('text' => '字符串', 'radio' => '單選', 'checkbox' => "多選", 'textarea' => "文本框");
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:13,代碼來源:QuestionController.php

示例5: modifyAction

 public function modifyAction()
 {
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_UPDATE);
     $VideoId = intval($this->request->VideoId);
     $Video = $this->oVideo->getRow($VideoId, '*');
     $VideoTypeArr = $this->oVideoType->getAll();
     include $this->tpl('Config_Video_Video_modify');
 }
開發者ID:032404cxd,項目名稱:prototype_main,代碼行數:9,代碼來源:VideoController.php

示例6: fnDBFetchCon

 function fnDBFetchCon($strSql, $hdlConfDB)
 {
     $arrResult =& $this->hdlDb->getAll($strSql, DB_FETCHMODE_ASSOC);
     if (DB::isError($arrResult)) {
         print $arrResult->getDebugInfo() . "<br>";
         die("Failed: " . $arrResult->getMessage() . "\n");
     }
     return $arrResult;
     //return the result set
 }
開發者ID:amoldclarion,項目名稱:ICRS,代碼行數:10,代碼來源:clsGlobal.php

示例7: init

 /**
  * 初始化
  * (non-PHPdoc)
  * @see AbstractController#init()
  */
 public function init()
 {
     parent::init();
     $this->oArea = new Config_Area();
     $this->Abroad = array(1 => '國內', 2 => '國外');
     $totalArea = $this->oArea->getAll();
     foreach ($totalArea as $AreaId => $value) {
         $value['abroad'] = $this->Abroad[$value['is_abroad']];
         $this->AreaList[$AreaId] = $value;
     }
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:16,代碼來源:AreaController.php

示例8: indexAction

 /**
  * 瀏覽郵箱後綴列表
  * @return unknown_type
  */
 public function indexAction()
 {
     /**
      * 記錄日誌
      */
     $log = "郵箱後綴管理\n\nServerIp:\n" . $this->request->getServer('SERVER_ADDR') . "\n\nGET:\n" . var_export($_GET, true) . "\n\nPOST:\n" . var_export($_POST, true);
     $this->oLogManager->push('log', $log);
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     $MailFixArr = $this->oMailFix->getAll();
     include $this->tpl();
 }
開發者ID:032404cxd,項目名稱:prototype_main,代碼行數:16,代碼來源:MailFixController.php

示例9: indexAction

 public function indexAction()
 {
     $FaqTypeList = $this->oFaqType->getAll('name,FaqTypeId');
     $FaqTypeId = $this->request->FaqTypeId ? abs(intval($this->request->FaqTypeId)) : 0;
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     $FaqArr = $this->oFaq->getAll($FaqTypeId);
     if ($FaqArr) {
         foreach ($FaqArr as $FaqId => $FaqData) {
             $FaqArr[$FaqId]['FaqTypeName'] = $FaqTypeList[$FaqData['FaqTypeId']]['name'];
         }
     }
     include $this->tpl('Config_Faq_list');
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:14,代碼來源:FaqController.php

示例10: getMultiy

 /**
  * 從一個表裏查詢出數據
  * @param $table
  * @param $fileds
  * @param $where
  * @param $primkey
  * @param $key
  * @return array
  */
 protected function getMultiy($table, $fileds, $where)
 {
     $sql = "SELECT {$fileds}  FROM  {$table}   " . $where;
     $finally = array();
     $rows = $this->slaveDB->getAll($sql, $primkey);
     return $finally;
 }
開發者ID:weichaoduo,項目名稱:zeromore,代碼行數:16,代碼來源:BaseDBModel.php

示例11: getListBox

 /**
  *  Method to get a sorted list of nodes with indented spaces
  * @return string
  */
 function getListBox()
 {
     //create dropdown box
     $dropdown = $this->newObject('dropdown', 'htmlelements');
     $dropdown->name = 'sourceId';
     //get the root id
     $contextCode = $this->objDBContext->getContextCode();
     if ($contextCode) {
         $id = $this->objDBContext->getField('id', $contextCode);
     } else {
         $id = Null;
     }
     $rootnodeid = $this->objDBContext->getRootNodeId($id);
     //get the list of nodes for the context
     $nodesArr = $this->objDBContentNodes->getAll("WHERE tbl_context_parentnodes_id='{$rootnodeid}' ORDER BY sortindex");
     //create a root node
     $dropdown->addOption(NULL, '[ROOT]');
     //add the nodes to the dropdown recursively
     foreach ($nodesArr as $node) {
         //start with the nodes that has no parent
         if ($node['parent_Node'] == null) {
             $text = $this->objDBContentNodes->getMenuText($node['id']);
             if ($text == '') {
                 $text = $node['title'];
             }
             $dropdown->addOption($node['id'], $text);
             $this->addNode($nodesArr, $node['id'], $dropdown, '&nbsp;&nbsp;');
         }
     }
     return $dropdown->show();
 }
開發者ID:ookwudili,項目名稱:chisimba,代碼行數:35,代碼來源:organisortree_class_inc.php

示例12: getTree

 /**
  * Method to get a tree for sharing nodes
  * @param string $contextId The Context Id
  * @param string $mode The type of tree , either DHTML or Dropdown
  * @return string 
  * @access public
  */
 function getTree($contextId, $mode = NULL, $modeParams = NULL)
 {
     $icon = 'folder_up.gif';
     $expandedIcon = 'folder-expanded.gif';
     $link = '';
     $rootnodeid = $this->objDBContext->getRootNodeId($contextId);
     $rootlabel = '';
     //Create a new menu
     $menu = new treemenu();
     $contentlink = $this->URI(array('action', 'contenthome'), $this->module);
     //create base node
     $basenode = new treenode(array('text' => $rootlabel, 'link' => $contentlink, 'icon' => 'base.gif', 'expandedIcon' => 'base.gif'));
     $this->objDBContentNodes->resetTable();
     $nodesArr = $this->objDBContentNodes->getAll("WHERE tbl_context_parentnodes_id='{$rootnodeid}'");
     $this->objDBContentNodes->changeTable('tbl_context_nodes_has_tbl_context_page_content');
     foreach ($nodesArr as $node) {
         if ($node['parent_Node'] == null) {
             $basenode->addItem($this->getChildNodes($nodesArr, $node['id'], stripslashes($this->shortenString($node['title']))));
         }
     }
     $this->objDBContentNodes->resetTable();
     $menu->addItem($basenode);
     //$menu->addItem($this->recurTree($rootnodeid,$rootlabel));
     // Create the presentation class
     $treeMenu =& new dhtml($menu, array('images' => $this->objSkin->getSkinURL() . '/treeimages/imagesAlt2', 'defaultClass' => 'treeMenuDefault'));
     if ($mode == 'listbox') {
         $listBox =& new listbox($menu, array('linkTarget' => '_self', 'submitText' => $modeParams['submitText'], 'promoText' => $modeParams['promoText']));
         return $listBox->getMenu();
     }
     return '<h5>' . $this->objDBContext->getTitle() . '</h5>' . $treeMenu->getMenu();
 }
開發者ID:ookwudili,項目名稱:chisimba,代碼行數:38,代碼來源:contenttree_class_inc.php

示例13: jsonListContext

 /**
  * Method to get a paginated
  * list of courses
  *
  * @param unknown_type $start
  * @param unknown_type $limit
  * @return unknown
  */
 public function jsonListContext($start = 0, $limit = 25)
 {
     $start = empty($start) ? 0 : $start;
     $limit = empty($limit) ? 25 : $limit;
     $contexts = $this->objDBContext->getAll("ORDER BY title limit " . $start . ", " . $limit);
     $all = $this->objDBContext->getArray("SELECT count( id ) as cnt FROM tbl_context ORDER BY title");
     $allCount = $all[0]['cnt'];
     $contextCount = count($contexts);
     $courses = array();
     if ($contextCount > 0) {
         foreach ($contexts as $context) {
             $studentCount = "";
             if (strtoupper($this->showStudentCount) == 'TRUE') {
                 $studentCount = '&nbsp;(' . count($this->objUserContext->getContextStudents($context['contextcode'])) . ')';
             }
             $arr = array();
             $arr['contextcode'] = $context['contextcode'];
             $arr['title'] = htmlentities($context['title']) . $studentCount;
             $arr['author'] = htmlentities($this->objUser->fullname($context['userid']));
             $arr['datecreated'] = $context['datecreated'];
             $arr['lastupdated'] = $context['updated'];
             $arr['status'] = $context['status'];
             $arr['expert'] = "";
             $courses[] = $arr;
         }
     }
     return json_encode(array('totalCount' => $allCount, 'courses' => $courses));
 }
開發者ID:ookwudili,項目名稱:chisimba,代碼行數:36,代碼來源:utilities_class_inc.php

示例14: indexAction

 public function indexAction()
 {
     $AppList = $this->oApp->getAll('name,AppId');
     $AppId = $this->request->AppId ? abs(intval($this->request->AppId)) : 101;
     //檢查權限
     $this->manager->checkMenuPermission($this->sign, Widget_Manager::MENU_PURVIEW_SELECT);
     $InstMapArr = $this->oInstMap->getAll($AppId);
     if ($InstMapArr) {
         foreach ($InstMapArr as $App => $AppData) {
             foreach ($AppData as $InstMapId => $InstMapData) {
                 $InstMapArr[$App][$InstMapId]['AppName'] = $AppList[$App]['name'];
             }
         }
     }
     include $this->tpl('Config_InstMap_list');
 }
開發者ID:eappl,項目名稱:prototype,代碼行數:16,代碼來源:InstmapController.php

示例15: listUsers

 function listUsers()
 {
     $err = $this->_prepare();
     if ($err !== true) {
         return PEAR::raiseError($err->getMessage(), $err->getCode());
     }
     $retVal = array();
     // Find if db_fileds contains a *, i so assume all col are selected
     if (strstr($this->options['db_fields'], '*')) {
         $sql_from = "*";
     } else {
         $sql_from = $this->options['usernamecol'] . ", " . $this->options['passwordcol'] . $this->options['db_fields'];
     }
     $query = sprintf("SELECT %s FROM %s", $sql_from, $this->options['table']);
     $res = $this->db->getAll($query, null, DB_FETCHMODE_ASSOC);
     if (DB::isError($res)) {
         return PEAR::raiseError($res->getMessage(), $res->getCode());
     } else {
         foreach ($res as $user) {
             $user['username'] = $user[$this->options['usernamecol']];
             $retVal[] = $user;
         }
     }
     return $retVal;
 }
開發者ID:richardmansfield,項目名稱:richardms-mahara,代碼行數:25,代碼來源:ADOdb.php


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