Bitrix-D7 23.9
 
Загрузка...
Поиск...
Не найдено
applang.php
1<?php
2namespace Bitrix\Im\Model;
3
5
35class AppLangTable extends Main\Entity\DataManager
36{
42 public static function getTableName()
43 {
44 return 'b_im_app_lang';
45 }
46
52 public static function getMap()
53 {
54 return array(
55 'ID' => array(
56 'data_type' => 'integer',
57 'primary' => true,
58 'autocomplete' => true,
59 ),
60 'APP_ID' => array(
61 'data_type' => 'integer',
62 'required' => true,
63 ),
64 'LANGUAGE_ID' => array(
65 'data_type' => 'string',
66 'required' => true,
67 'validation' => array(__CLASS__, 'validateLanguageId'),
68 ),
69 'TITLE' => array(
70 'data_type' => 'string',
71 'validation' => array(__CLASS__, 'validateTitle'),
72 'save_data_modification' => array('\Bitrix\Main\Text\Emoji', 'getSaveModificator'),
73 'fetch_data_modification' => array('\Bitrix\Main\Text\Emoji', 'getFetchModificator'),
74 ),
75 'DESCRIPTION' => array(
76 'data_type' => 'string',
77 'validation' => array(__CLASS__, 'validateDescription'),
78 'save_data_modification' => array('\Bitrix\Main\Text\Emoji', 'getSaveModificator'),
79 'fetch_data_modification' => array('\Bitrix\Main\Text\Emoji', 'getFetchModificator'),
80 ),
81 'COPYRIGHT' => array(
82 'data_type' => 'string',
83 'validation' => array(__CLASS__, 'validateCopyright'),
84 ),
85 );
86 }
92 public static function validateLanguageId()
93 {
94 return array(
95 new Main\Entity\Validator\Length(null, 2),
96 );
97 }
103 public static function validateTitle()
104 {
105 return array(
106 new Main\Entity\Validator\Length(null, 255),
107 );
108 }
114 public static function validateDescription()
115 {
116 return array(
117 new Main\Entity\Validator\Length(null, 255),
118 );
119 }
125 public static function validateCopyright()
126 {
127 return array(
128 new Main\Entity\Validator\Length(null, 255),
129 );
130 }
131}