@@ -14,6 +14,9 @@ discard block |
||
| 14 | 14 | * ****************************************************************************** */ |
| 15 | 15 | |
| 16 | 16 | //Fix postgres queries |
| 17 | +/** |
|
| 18 | + * @param integer $debug |
|
| 19 | + */ |
|
| 17 | 20 | function fixPostgresQuery($query, $log, $debug) |
| 18 | 21 | { |
| 19 | 22 | // First select the query fields from the remaining query |
@@ -115,6 +118,9 @@ discard block |
||
| 115 | 118 | } |
| 116 | 119 | |
| 117 | 120 | //return an expanded table field list |
| 121 | +/** |
|
| 122 | + * @param string $table |
|
| 123 | + */ |
|
| 118 | 124 | function expandRecord($table, $log) |
| 119 | 125 | { |
| 120 | 126 | $result = ""; |
@@ -390,6 +390,9 @@ discard block |
||
| 390 | 390 | return false; |
| 391 | 391 | } |
| 392 | 392 | |
| 393 | + /** |
|
| 394 | + * @param string[] $names |
|
| 395 | + */ |
|
| 393 | 396 | public function focusColumnValues($names, $delimeter = "\n") |
| 394 | 397 | { |
| 395 | 398 | if (!is_array($names)) { |
@@ -414,6 +417,9 @@ discard block |
||
| 414 | 417 | return $defvalue; |
| 415 | 418 | } |
| 416 | 419 | |
| 420 | + /** |
|
| 421 | + * @param string $id |
|
| 422 | + */ |
|
| 417 | 423 | public function resolveReferenceLabel($id, $module = false) |
| 418 | 424 | { |
| 419 | 425 | if (empty($id)) { |
@@ -448,6 +454,9 @@ discard block |
||
| 448 | 454 | return $currencyField->getDisplayValue(null, true); |
| 449 | 455 | } |
| 450 | 456 | |
| 457 | + /** |
|
| 458 | + * @param string $value |
|
| 459 | + */ |
|
| 451 | 460 | public function formatDate($value) |
| 452 | 461 | { |
| 453 | 462 | return DateTimeField::convertToUserFormat($value); |
@@ -98,7 +98,7 @@ |
||
| 98 | 98 | |
| 99 | 99 | /** |
| 100 | 100 | * Function to get the class name of a given Component, of given Type, for a given Module |
| 101 | - * @param <String> $componentType |
|
| 101 | + * @param string $componentType |
|
| 102 | 102 | * @param <String> $componentName |
| 103 | 103 | * @param <String> $moduleName |
| 104 | 104 | * @return <String> Required Class Name |
@@ -31,6 +31,9 @@ |
||
| 31 | 31 | file_put_contents(self::$usersFile, '<?php return ' . \vtlib\Functions::varExportMin($users) . ';'); |
| 32 | 32 | } |
| 33 | 33 | |
| 34 | + /** |
|
| 35 | + * @param string $type |
|
| 36 | + */ |
|
| 34 | 37 | public static function getUser($type) |
| 35 | 38 | { |
| 36 | 39 | if (self::$usersFileCache === false) { |
@@ -153,6 +153,9 @@ discard block |
||
| 153 | 153 | return $this->whereFields; |
| 154 | 154 | } |
| 155 | 155 | |
| 156 | + /** |
|
| 157 | + * @param string $columns |
|
| 158 | + */ |
|
| 156 | 159 | public function setCustomColumn($columns) |
| 157 | 160 | { |
| 158 | 161 | $this->columnsCustom[] = $columns; |
@@ -193,6 +196,9 @@ discard block |
||
| 193 | 196 | return $this->ownerFields; |
| 194 | 197 | } |
| 195 | 198 | |
| 199 | + /** |
|
| 200 | + * @return string |
|
| 201 | + */ |
|
| 196 | 202 | public function getModuleNameFields($module) |
| 197 | 203 | { |
| 198 | 204 | return $this->moduleNameFields[$module]; |
@@ -1249,6 +1255,9 @@ discard block |
||
| 1249 | 1255 | return $sql; |
| 1250 | 1256 | } |
| 1251 | 1257 | |
| 1258 | + /** |
|
| 1259 | + * @param string $groupSql |
|
| 1260 | + */ |
|
| 1252 | 1261 | private function makeGroupSqlReplacements($fieldSqlList, $groupSql) |
| 1253 | 1262 | { |
| 1254 | 1263 | $pos = 0; |
@@ -1286,6 +1295,9 @@ discard block |
||
| 1286 | 1295 | return ($type == 'date' || $type == 'datetime'); |
| 1287 | 1296 | } |
| 1288 | 1297 | |
| 1298 | + /** |
|
| 1299 | + * @return string |
|
| 1300 | + */ |
|
| 1289 | 1301 | public function fixDateTimeValue($name, $value, $first = true) |
| 1290 | 1302 | { |
| 1291 | 1303 | $moduleFields = $this->getModuleFields(); |
@@ -1303,6 +1315,9 @@ discard block |
||
| 1303 | 1315 | return $value; |
| 1304 | 1316 | } |
| 1305 | 1317 | |
| 1318 | + /** |
|
| 1319 | + * @param string $glue |
|
| 1320 | + */ |
|
| 1306 | 1321 | public function addCondition($fieldname, $value, $operator, $glue = null, $custom = false, $newGroupType = null, $ignoreComma = false) |
| 1307 | 1322 | { |
| 1308 | 1323 | $conditionNumber = $this->conditionInstanceCount++; |
@@ -1346,6 +1361,9 @@ discard block |
||
| 1346 | 1361 | return array('name' => $fieldname, 'value' => $value, 'operator' => $operator, 'custom' => $custom); |
| 1347 | 1362 | } |
| 1348 | 1363 | |
| 1364 | + /** |
|
| 1365 | + * @param string $groupType |
|
| 1366 | + */ |
|
| 1349 | 1367 | public function startGroup($groupType) |
| 1350 | 1368 | { |
| 1351 | 1369 | $this->groupInfo .= " $groupType ("; |
@@ -120,6 +120,9 @@ discard block |
||
| 120 | 120 | public $tag_start = 0; |
| 121 | 121 | private $dom = null; |
| 122 | 122 | |
| 123 | + /** |
|
| 124 | + * @param simple_html_dom $dom |
|
| 125 | + */ |
|
| 123 | 126 | public function __construct($dom) |
| 124 | 127 | { |
| 125 | 128 | $this->dom = $dom; |
@@ -1553,6 +1556,10 @@ discard block |
||
| 1553 | 1556 | } |
| 1554 | 1557 | |
| 1555 | 1558 | // parse attributes |
| 1559 | +/** |
|
| 1560 | + * @param simple_html_dom_node $node |
|
| 1561 | + * @param string[] $space |
|
| 1562 | + */ |
|
| 1556 | 1563 | protected function parse_attr($node, $name, &$space) |
| 1557 | 1564 | { |
| 1558 | 1565 | // Per sourceforge: http://sourceforge.net/tracker/?func=detail&aid=3061408&group_id=218559&atid=1044037 |
@@ -1589,6 +1596,10 @@ discard block |
||
| 1589 | 1596 | } |
| 1590 | 1597 | |
| 1591 | 1598 | // link node's parent |
| 1599 | +/** |
|
| 1600 | + * @param simple_html_dom_node $node |
|
| 1601 | + * @param boolean $is_child |
|
| 1602 | + */ |
|
| 1592 | 1603 | protected function link_nodes(&$node, $is_child) |
| 1593 | 1604 | { |
| 1594 | 1605 | $node->parent = $this->parent; |
@@ -1599,6 +1610,9 @@ discard block |
||
| 1599 | 1610 | } |
| 1600 | 1611 | |
| 1601 | 1612 | // as a text node |
| 1613 | +/** |
|
| 1614 | + * @param string $tag |
|
| 1615 | + */ |
|
| 1602 | 1616 | protected function as_text_node($tag) |
| 1603 | 1617 | { |
| 1604 | 1618 | $node = new simple_html_dom_node($this); |
@@ -1609,12 +1623,18 @@ discard block |
||
| 1609 | 1623 | return true; |
| 1610 | 1624 | } |
| 1611 | 1625 | |
| 1626 | +/** |
|
| 1627 | + * @param string $chars |
|
| 1628 | + */ |
|
| 1612 | 1629 | protected function skip($chars) |
| 1613 | 1630 | { |
| 1614 | 1631 | $this->pos += strspn($this->doc, $chars, $this->pos); |
| 1615 | 1632 | $this->char = ($this->pos < $this->size) ? $this->doc[$this->pos] : null; // next |
| 1616 | 1633 | } |
| 1617 | 1634 | |
| 1635 | +/** |
|
| 1636 | + * @param string $chars |
|
| 1637 | + */ |
|
| 1618 | 1638 | protected function copy_skip($chars) |
| 1619 | 1639 | { |
| 1620 | 1640 | $pos = $this->pos; |
@@ -1626,6 +1646,9 @@ discard block |
||
| 1626 | 1646 | return substr($this->doc, $pos, $len); |
| 1627 | 1647 | } |
| 1628 | 1648 | |
| 1649 | +/** |
|
| 1650 | + * @param string $chars |
|
| 1651 | + */ |
|
| 1629 | 1652 | protected function copy_until($chars) |
| 1630 | 1653 | { |
| 1631 | 1654 | $pos = $this->pos; |
@@ -1635,6 +1658,9 @@ discard block |
||
| 1635 | 1658 | return substr($this->doc, $pos, $len); |
| 1636 | 1659 | } |
| 1637 | 1660 | |
| 1661 | +/** |
|
| 1662 | + * @param string $char |
|
| 1663 | + */ |
|
| 1638 | 1664 | protected function copy_until_char($char) |
| 1639 | 1665 | { |
| 1640 | 1666 | if ($this->char === null) |
@@ -1655,6 +1681,9 @@ discard block |
||
| 1655 | 1681 | return substr($this->doc, $pos_old, $pos - $pos_old); |
| 1656 | 1682 | } |
| 1657 | 1683 | |
| 1684 | +/** |
|
| 1685 | + * @param string $char |
|
| 1686 | + */ |
|
| 1658 | 1687 | protected function copy_until_char_escape($char) |
| 1659 | 1688 | { |
| 1660 | 1689 | if ($this->char === null) |
@@ -1686,6 +1715,9 @@ discard block |
||
| 1686 | 1715 | |
| 1687 | 1716 | // remove noise from html content |
| 1688 | 1717 | // save the noise in the $this->noise array. |
| 1718 | +/** |
|
| 1719 | + * @param string $pattern |
|
| 1720 | + */ |
|
| 1689 | 1721 | protected function remove_noise($pattern, $remove_tag = false) |
| 1690 | 1722 | { |
| 1691 | 1723 | global $debugObject; |
@@ -1713,6 +1745,9 @@ discard block |
||
| 1713 | 1745 | } |
| 1714 | 1746 | |
| 1715 | 1747 | // restore noise to html content |
| 1748 | +/** |
|
| 1749 | + * @param string|null $text |
|
| 1750 | + */ |
|
| 1716 | 1751 | function restore_noise($text) |
| 1717 | 1752 | { |
| 1718 | 1753 | global $debugObject; |
@@ -378,6 +378,11 @@ |
||
| 378 | 378 | * Returns an string value |
| 379 | 379 | */ |
| 380 | 380 | |
| 381 | +/** |
|
| 382 | + * @param string $url_qry |
|
| 383 | + * @param string $module |
|
| 384 | + * @param string $related_module |
|
| 385 | + */ |
|
| 381 | 386 | function getRelatedTableHeaderNavigation($navigation_array, $url_qry, $module, $related_module, $recordid) |
| 382 | 387 | { |
| 383 | 388 | $log = LoggerManager::getInstance(); |
@@ -18,6 +18,9 @@ discard block |
||
| 18 | 18 | $__cache_vtiger_imagepath = []; |
| 19 | 19 | } |
| 20 | 20 | |
| 21 | +/** |
|
| 22 | + * @param string $imagename |
|
| 23 | + */ |
|
| 21 | 24 | function vtiger_imageurl($imagename, $themename) |
| 22 | 25 | { |
| 23 | 26 | global $__cache_vtiger_imagepath; |
@@ -200,6 +203,9 @@ discard block |
||
| 200 | 203 | } |
| 201 | 204 | } |
| 202 | 205 | |
| 206 | +/** |
|
| 207 | + * @param string $varname |
|
| 208 | + */ |
|
| 203 | 209 | function __vtlib_get_modulevar_value($module, $varname) |
| 204 | 210 | { |
| 205 | 211 | $mod_var_mapping = Array( |
@@ -497,7 +503,6 @@ discard block |
||
| 497 | 503 | /** |
| 498 | 504 | * Purify (Cleanup) malicious snippets of code from the input |
| 499 | 505 | * |
| 500 | - * @param String $value |
|
| 501 | 506 | * @param Boolean $ignore Skip cleaning of the input |
| 502 | 507 | * @return String |
| 503 | 508 | */ |
@@ -48,6 +48,9 @@ |
||
| 48 | 48 | return $row; |
| 49 | 49 | } |
| 50 | 50 | |
| 51 | + /** |
|
| 52 | + * @param boolean $t |
|
| 53 | + */ |
|
| 51 | 54 | public static function sanitizeData($newRow, $meta, $t = null) |
| 52 | 55 | { |
| 53 | 56 | |