本文整理汇总了PHP中PearDatabase::fetch_array方法的典型用法代码示例。如果您正苦于以下问题:PHP PearDatabase::fetch_array方法的具体用法?PHP PearDatabase::fetch_array怎么用?PHP PearDatabase::fetch_array使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PearDatabase
的用法示例。
在下文中一共展示了PearDatabase::fetch_array方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: getTreeDetails
function getTreeDetails()
{
if (count(self::$treeDetails) > 0) {
return self::$treeDetails;
}
$result = $this->pearDB->pquery('SELECT module FROM vtiger_trees_templates WHERE templateid = ?', [$this->getFieldParams()]);
$module = $this->pearDB->getSingleValue($result);
$moduleName = getTabModuleName($module);
$result = $this->pearDB->pquery('SELECT tree,label FROM vtiger_trees_templates_data WHERE templateid = ?', [$this->getFieldParams()]);
while ($row = $this->pearDB->fetch_array($result)) {
self::$treeDetails[$row['tree']] = getTranslatedString($row['label'], $moduleName);
}
return self::$treeDetails;
}
示例2: getFieldTypeFromUIType
private function getFieldTypeFromUIType()
{
// Cache all the information for futher re-use
if (empty(self::$fieldTypeMapping)) {
$result = $this->pearDB->pquery("select * from vtiger_ws_fieldtype", array());
while ($resultrow = $this->pearDB->fetch_array($result)) {
self::$fieldTypeMapping[$resultrow['uitype']] = $resultrow;
}
}
if (isset(WebserviceField::$fieldTypeMapping[$this->getUIType()])) {
if (WebserviceField::$fieldTypeMapping[$this->getUIType()] === false) {
return null;
}
$row = WebserviceField::$fieldTypeMapping[$this->getUIType()];
return $row['fieldtype'];
} else {
WebserviceField::$fieldTypeMapping[$this->getUIType()] = false;
return null;
}
}