1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
textfield.php
См. документацию.
1<?php
8
9namespace Bitrix\Main\ORM\Fields;
10
11use Bitrix\Main\DB\SqlExpression;
12
20{
22 protected $long = false;
23
32 function __construct($name, $parameters = array())
33 {
34 parent::__construct($name, $parameters);
35
36 $this->long = isset($parameters['long']) && (bool)$parameters['long'];
37 }
38
44 public function configureLong($long = true)
45 {
46 $this->long = (bool)$long;
47 return $this;
48 }
49
53 public function isLong()
54 {
55 return $this->long;
56 }
57
64 public function convertValueFromDb($value)
65 {
66 return $this->getConnection()->getSqlHelper()->convertFromDbText($value);
67 }
68
75 public function convertValueToDb($value)
76 {
77 if ($value instanceof SqlExpression)
78 {
79 return $value;
80 }
81
82 return $value === null && $this->is_nullable
83 ? $value
84 : $this->getConnection()->getSqlHelper()->convertToDbText($value);
85 }
86
87 public function isValueEmpty($value)
88 {
89 if ($this->isSerialized() && is_array($value))
90 {
91 return false;
92 }
93
94 return parent::isValueEmpty($value);
95 }
96}
isSerialized()
Определения field.php:463
getConnection()
Определения field.php:638
configureLong($long=true)
Определения textfield.php:44
__construct($name, $parameters=array())
Определения textfield.php:32
convertValueFromDb($value)
Определения textfield.php:64
isValueEmpty($value)
Определения textfield.php:87
convertValueToDb($value)
Определения textfield.php:75
</td ></tr ></table ></td ></tr >< tr >< td class="bx-popup-label bx-width30"><?=GetMessage("PAGE_NEW_TAGS")?> array( $site)
Определения file_new.php:804