{"id":58,"date":"2014-09-02T13:32:17","date_gmt":"2014-09-02T08:32:17","guid":{"rendered":"http:\/\/developer.uz\/blog\/?p=58"},"modified":"2014-09-03T11:03:47","modified_gmt":"2014-09-03T06:03:47","slug":"yii-cgridview-part1","status":"publish","type":"post","link":"https:\/\/developer.uz\/blog\/yii-cgridview-part1\/","title":{"rendered":"\u041e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044f\u0445 Yii CGridView \u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0430\u0445. \u0427\u0430\u0441\u0442\u044c 1: \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u043e\u0435 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435"},"content":{"rendered":"<p><strong>CGridView<\/strong> &#8212; \u043e\u0434\u0438\u043d \u0438\u0437 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432 Yii-framework. \u041e\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u043c\u043e\u0434\u0435\u043b\u0438 \u0432 \u0432\u0438\u0434\u0435 \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b, \u0441 \u043a\u043d\u043e\u043f\u043a\u0430\u043c\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0438\u0441\u044f\u043c\u0438.<\/p>\n<pre class=\"brush: php; title: \u041f\u0440\u0438\u043c\u0435\u0440 \u0431\u0430\u0437\u043e\u0432\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f CGridView; notranslate\" title=\"\u041f\u0440\u0438\u043c\u0435\u0440 \u0431\u0430\u0437\u043e\u0432\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f CGridView\">\r\n&lt;?php $this-&gt;widget('zii.widgets.grid.CGridView', array(\r\n    'id'=&gt;'country-grid',\r\n    'dataProvider'=&gt;$model-&gt;search(),\r\n    'filter'=&gt;$model,\r\n    'columns'=&gt;array(\r\n        'id',\r\n        'name',\r\n        'region',\r\n        array(\r\n            'class'=&gt;'CButtonColumn',\r\n        ),\r\n    ),\r\n)); ?&gt;\r\n<\/pre>\n<p>\u042d\u0442\u043e \u043d\u0435\u0437\u0430\u043c\u0435\u043d\u0438\u043c\u044b\u0439 \u0432\u0438\u0434\u0436\u0435\u0442 \u0434\u043b\u044f \u043b\u044e\u0431\u043e\u0439 \u0430\u0434\u043c\u0438\u043d\u043a\u0438. \u0415\u0441\u043b\u0438 \u043b\u0435\u043d\u044c \u043f\u0438\u0441\u0430\u0442\u044c \u0440\u0443\u043a\u0430\u043c\u0438, \u0435\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e gii. \u041d\u043e \u0442\u043e, \u0447\u0442\u043e \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043f\u043e\u0442\u0440\u0435\u0431\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430. \u0412 \u043c\u043e\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 CGridView \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0441\u043f\u0438\u0441\u043a\u043e\u043c \u0441\u0442\u0440\u0430\u043d. \u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 CGridView \u043d\u0430 \u044d\u0442\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435.<\/p>\n<h2>\u041a\u0430\u043a \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u043a\u043d\u043e\u043f\u043a\u0438 \u0432 CGridView<\/h2>\n<p>\u041a\u0430\u043a \u0432\u044b \u043d\u0430\u0432\u0435\u0440\u043d\u043e\u0435 \u0443\u0436\u0435 \u0434\u043e\u0433\u0430\u0434\u0430\u043b\u0438\u0441\u044c, \u0437\u0430 \u043a\u043d\u043e\u043f\u043a\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u043a\u0443\u0441\u043e\u043a \u043a\u043e\u0434\u0430<\/p>\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\narray(\r\n  'class'=&gt;'CButtonColumn',\r\n),\r\n<\/pre>\n<p>\u0427\u0442\u043e \u0431\u0443\u0434\u0435\u0442, \u0435\u0441\u043b\u0438 \u0440\u0430\u0437\u043c\u0435\u0441\u0442\u0438\u043c \u0435\u0433\u043e \u043d\u0435 \u0432 \u043a\u043e\u043d\u0446\u0435 \u0441\u043f\u0438\u0441\u043a\u0430 \u043a\u043e\u043b\u043e\u043d\u043e\u043a, \u0430 \u0432 \u043d\u0430\u0447\u0430\u043b\u0435? \u041f\u0440\u0430\u0432\u0438\u043b\u044c\u043d\u043e: \u043a\u043d\u043e\u043f\u043a\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0431\u0443\u0434\u0443\u0442 \u0434\u043e \u043a\u043e\u043b\u043e\u043d\u043e\u043a \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438 \ud83d\ude42<br \/>\n\u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u043a\u043d\u043e\u043f\u043e\u043a \u0431\u044b\u0432\u0430\u0435\u0442 3 (\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435). \u0421\u0441\u044b\u043b\u0430\u044e\u0442\u0441\u044f \u043e\u043d\u0438 \u043d\u0430 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440, \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u044e\u0449\u0438\u0439 \u0441 \u0438\u043c\u0435\u043d\u0435\u043c \u043c\u043e\u0434\u0435\u043b\u0438.<\/p>\n<ul>\n<li>\u0427\u0442\u043e\u0431\u044b <strong>\u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u043e\u0440\u044f\u0434\u043e\u043a \u0438 \u0432\u044b\u0432\u043e\u0434 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0445 \u043a\u043d\u043e\u043f\u043e\u043a<\/strong> \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0430\u0442\u0440\u0438\u0431\u0443\u0442 template\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\narray(\r\n  'class'=&gt;'CButtonColumn',\r\n  'template'=&gt;'{view}&lt;div class=&quot;button&quot;&gt;{update}&lt;\/div&gt;{delete}',\r\n),\r\n<\/pre>\n<p>\u0418\u0437 \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u0432\u0438\u0434\u043d\u043e, \u0447\u0442\u043e \u0441\u0430\u043c\u0438 \u043a\u043d\u043e\u043f\u043a\u0438 \u043e\u0431\u043e\u0437\u043d\u0430\u0447\u0430\u044e\u0442\u0441\u044f \u043a\u0430\u043a {view}, {update} \u0438 {delete}. \u0418\u0445 \u043c\u043e\u0436\u043d\u043e \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u0432 \u043b\u044e\u0431\u043e\u0439 html-\u043a\u043e\u0434. \u0422\u0430\u043a\u0438\u043c \u0436\u0435 \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043c\u043e\u0436\u043d\u043e <strong>\u0438\u0437\u0431\u0430\u0432\u0438\u0442\u044c\u0441\u044f \u043e\u0442 &#171;\u043b\u0438\u0448\u043d\u0438\u0445&#187; \u043a\u043d\u043e\u043f\u043e\u043a<\/strong>, \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0435 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u044f \u0438\u0445 \u0432 \u0434\u0430\u043d\u043d\u043e\u043c \u0431\u043b\u043e\u043a\u0435.<\/p>\n<pre class=\"brush: php; title: \u0422\u043e\u043b\u044c\u043a\u043e \u043a\u043d\u043e\u043f\u043a\u0430 \u0443\u0434\u0430\u043b\u0438\u0442\u044c; notranslate\" title=\"\u0422\u043e\u043b\u044c\u043a\u043e \u043a\u043d\u043e\u043f\u043a\u0430 \u0443\u0434\u0430\u043b\u0438\u0442\u044c\">\r\narray(\r\n  'class'=&gt;'CButtonColumn',\r\n  'template'=&gt;'{delete}',\r\n),\r\n<\/pre>\n<\/li>\n<li>\u0427\u0442\u043e\u0431\u044b <strong>\u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0441\u0441\u044b\u043b\u043a\u0443 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u043e\u0439 \u043a\u043d\u043e\u043f\u043a\u0438<\/strong> \u043d\u0443\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c xxxButtonUrl (viewButtonUrl, updateButtonUrl, deleteButtonUrl \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e)\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\narray(\r\n'class'=&gt;'CButtonColumn',\r\n'template'=&gt;'{update}{delete}',\r\n'updateButtonUrl'=&gt;'Yii::app()-&gt;getUrlManager()-&gt;createUrl(&quot;\/admin\/editCountry\/&quot;, array(&quot;id&quot; =&gt; $data-&gt;id))',\r\n'deleteButtonUrl'=&gt;'Yii::app()-&gt;getUrlManager()-&gt;createUrl(&quot;\/admin\/delCountry\/&quot;, array(&quot;id&quot; =&gt; $data-&gt;id))'\r\n        )\r\n<\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435: <span style=\"color: #ff0000;\"><strong>\u043c\u0435\u0442\u043e\u0434, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u044e\u0449\u0438\u0439 \u0441\u0441\u044b\u043b\u043a\u0443 \u0437\u0430\u043f\u0438\u0441\u0430\u043d \u0432 \u043e\u0434\u0438\u043d\u0430\u0440\u043d\u044b\u0435 \u043a\u0430\u0432\u044b\u0447\u043a\u0438<\/strong><\/span>! \u042d\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u0430\u044f \u0441\u0442\u0440\u043e\u043a\u0430. \u041e\u043d \u043d\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0442\u044c\u0441\u044f \u043d\u0430 \u044d\u0442\u0430\u043f\u0435 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u0434\u0430\u043d\u043d\u043e\u0433\u043e php-\u0441\u043a\u0440\u0438\u043f\u0442\u0430. \u0422\u0435\u043a\u0443\u0449\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0447\u0435\u0440\u0435\u0437 \u043e\u0431\u044a\u0435\u043a\u0442 $data.\n<\/li>\n<li>\n\u0427\u0442\u043e\u0431\u044b <strong>\u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u0432\u043e\u044e \u043a\u043d\u043e\u043f\u043a\u0443<\/strong> \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u0435\u0439 \u0438\u043c\u044f \u0432 template \u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u0432\u0441\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u043a\u043d\u043e\u043f\u043a\u0438 \u0432 buttons<\/p>\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\n'class'=&gt;'CButtonColumn',\r\n'template'=&gt;'{moderation}&amp;nbsp;&amp;nbsp;{delete}',\r\n'buttons'=&gt;array\r\n(\r\n  'moderation' =&gt; array\r\n  (\r\n    'label'=&gt;'\u041e\u0434\u043e\u0431\u0440\u0438\u0442\u044c',   \r\n    'url'=&gt;'Yii::app()-&gt;getUrlManager()-&gt;createUrl(&quot;admin\/moderation\/&quot;, array(&quot;id&quot; =&gt; $data-&gt;id))',\r\n'imageUrl' =&gt; '\/img\/moderation.png',\r\n   ),\r\n),\r\n'deleteButtonUrl'=&gt;'Yii::app()-&gt;getUrlManager()-&gt;createUrl(&quot;\/admin\/delCountry\/&quot;, array(&quot;id&quot; =&gt; $data-&gt;id))'\r\n)\r\n<\/pre>\n<p>\u0415\u0441\u043b\u0438 \u043d\u0435 \u0437\u0430\u0434\u0430\u043d imageUrl, \u0441\u0441\u044b\u043b\u043a\u0430 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0441\u0442\u043e \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u0430\u044f.\n<\/li>\n<li>\u041a\u0430\u043a <strong>\u0441\u043f\u0440\u044f\u0442\u0430\u0442\u044c \u043a\u043d\u043e\u043f\u043a\u0443, \u043f\u0440\u0438 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0445 \u0443\u0441\u043b\u043e\u0432\u0438\u044f\u0445<\/strong>. \u041c\u043d\u0435 \u043d\u0435 \u043d\u0443\u0436\u043d\u0430 \u043a\u043d\u043e\u043f\u043a\u0430 &#171;\u043c\u043e\u0434\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f&#187; \u0434\u043b\u044f \u0443\u0436\u0435 \u043f\u0440\u043e\u043c\u043e\u0434\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0437\u0430\u043f\u0438\u0441\u0435\u0439. \u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u043e visible\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\n'buttons'=&gt;array\r\n(\r\n  'moderation' =&gt; array\r\n  (\r\n    'label'=&gt;'\u041e\u0434\u043e\u0431\u0440\u0438\u0442\u044c',   \r\n    'visible' =&gt; '$data-&gt;moderation == 0'\r\n    'url'=&gt;'Yii::app()-&gt;getUrlManager()-&gt;createUrl(&quot;admin\/moderation\/&quot;, array(&quot;id&quot; =&gt; $data-&gt;id))',\r\n'imageUrl' =&gt; '\/img\/moderation.png',\r\n   ),\r\n),\r\n<\/pre>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043a\u043d\u043e\u043f\u043a\u0430 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 \u0442\u0435\u0445 \u0441\u0442\u0440\u043e\u043a\u0430\u0445, \u0433\u0434\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u0442\u0441\u044f \u0443\u0441\u043b\u043e\u0432\u0438\u0435 visible. \u0412 visible \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u0442\u044c \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0435, \u043d\u043e \u0438 \u0432\u044b\u0437\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u044e\u0449\u0438\u0439 true \u0438\u043b\u0438 false. \u0422\u043e\u043b\u044c\u043a\u043e \u0443\u0447\u0442\u0438\u0442\u0435, \u0447\u0442\u043e \u044d\u0442\u043e\u0442 \u0432\u044b\u0437\u043e\u0432 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043f\u0435\u0440\u0435\u0434\u0430\u043d \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438.<br \/>\n\u041f\u043e\u043c\u0438\u043c\u043e \u044d\u0442\u043e\u0433\u043e, \u043a\u043d\u043e\u043f\u043a\u0435 \u043c\u043e\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u043e\u0431\u044b\u0442\u0438\u0435 \u043f\u043e \u043a\u043b\u0438\u043a\u0443, \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u0432 \u0432\u044b\u0437\u043e\u0432 JS-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0432 \u0432\u0438\u0434\u0435 \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 &#8216;click&#8217;. \u0421\u043e\u0431\u044b\u0442\u0438\u0435 \u0442\u0430\u043a-\u0436\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438.\n<\/li>\n<\/ul>\n<h2>\u041a\u0430\u043a \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 \u043a\u043e\u043b\u043e\u043d\u043a\u0430\u0445 CGridView<\/h2>\n<ul>\n<li>\u0427\u0442\u043e\u0431\u044b<strong> \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 \u043a\u043e\u043b\u043e\u043d\u043a\u0435 CGridView \u0432 \u0432\u0438\u0434\u0435<\/strong> html-\u043a\u043e\u0434\u0430, \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u0438, \u0441\u0441\u044b\u043b\u043a\u0438 \u0438 \u0442\u043f \u043d\u0443\u0436\u043d\u043e \u0432 \u0441\u043f\u0438\u0441\u043a\u0435 \u043a\u043e\u043b\u043e\u043d\u043e\u043a \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u043c\u0430\u0441\u0441\u0438\u0432 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432\n<pre class=\"brush: php; title: \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434; notranslate\" title=\"\u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434\">\r\n'columns'=&gt;array(\r\n        'name',\r\n         array(\r\n           'name'  =&gt; 'flag',\r\n           'value' =&gt; '&quot;\/images\/&quot;.$data-&gt;flag',\r\n           'type'  =&gt; 'image',\r\n           'filter' =&gt; false\r\n        ),\r\n        region,\r\n<\/pre>\n<p>\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 name \u0432\u043b\u0438\u044f\u0435\u0442 \u043d\u0430 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043a\u0430\u043a \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0430, \u0442\u0430\u043a \u0438 \u0430\u0442\u0440\u0438\u0431\u0443\u0442 \u043c\u043e\u0434\u0435\u043b\u0438. \u0412\u043e \u0432\u0442\u043e\u0440\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0438 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435\u043c \u043a\u043e\u043b\u043e\u043d\u043a\u0438 \u0431\u0443\u0434\u0435\u0442 \u0442\u043e, \u0447\u0442\u043e \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u043d\u043e \u0434\u043b\u044f \u0430\u0442\u0440\u0438\u0431\u0443\u0442\u0430 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 attributeLabels \u043c\u043e\u0434\u0435\u043b\u0438 Country.<br \/>\nfilter &#8212; \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u0437\u0430 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044e \u0434\u0430\u043d\u043d\u044b\u0445. \u041e \u043d\u0435\u043c \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c \u0432 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435.<br \/>\nValue &#8212; \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438. \u0414\u0430\u043d\u043d\u044b\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0432\u0441\u0435 \u0442\u0430\u043a \u0436\u0435 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0447\u0435\u0440\u0435\u0437 \u043e\u0431\u044a\u0435\u043a\u0442 $data. \u0422\u0443\u0442 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043a\u0430\u043a \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u0442\u0440\u043e\u043a\u0430, \u0442\u0430\u043a \u0438 \u0432\u044b\u0437\u043e\u0432 \u043c\u0435\u0442\u043e\u0434\u0430. \u0415\u0434\u0438\u043d\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u0435 \u043e \u0447\u0435\u043c \u043d\u0443\u0436\u043d\u043e \u043f\u043e\u043c\u043d\u0438\u0442\u044c &#8212; \u0432\u044b\u0437\u043e\u0432 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043e\u0444\u043e\u0440\u043c\u043b\u0435\u043d \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u0430 \u043f\u043e\u0437\u0436\u0435.<br \/>\ntype &#8212; \u0442\u0438\u043f \u0441\u0442\u0440\u043e\u043a\u0438. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0432\u0441\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0441\u0447\u0438\u0442\u0430\u044e\u0442\u0441\u044f \u0442\u0435\u043a\u0441\u0442\u043e\u0432\u044b\u043c\u0438. \u0422\u0438\u043f\u044b \u043c\u043e\u0433\u0443 \u0431\u044b\u0442\u044c:<\/p>\n<ul>\n<li><strong>text<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u044b \u0441 \u0434\u0435\u043a\u043e\u0434\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435\u043c \u0432\u0441\u0435\u0445 html \u0442\u0435\u0433\u043e\u0432 (html-encode)<\/li>\n<li><strong>raw<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u044b &#171;\u043a\u0430\u043a \u0435\u0441\u0442\u044c&#187; \u0431\u0435\u0437 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439<\/li>\n<li><strong>ntext<\/strong> &#8212; \u0432\u0441\u0435 \u043f\u0435\u0440\u0435\u043d\u043e\u0441\u044b \u0441\u0442\u0440\u043e\u043a\u0438 \u0431\u0443\u0434\u0443\u0442 \u0437\u0430\u043c\u0435\u043d\u0435\u043d\u044b \u043d\u0430 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 html-\u0442\u0435\u0433\u0438<\/li>\n<li><strong>html<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u044b \u0432 \u0432\u0438\u0434\u0435 html-\u043a\u043e\u0434\u0430<\/li>\n<li><strong>date<\/strong>, <strong>time<\/strong>, datetime &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u043e\u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b \u0432 \u0432\u0438\u0434\u0435 \u0434\u0430\u0442\u044b\/\u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e. \u0424\u043e\u0440\u043c\u0430\u0442 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0434\u043b\u044f \u0434\u0430\u0442\u044b &#8216;Y\/m\/d&#8217;, \u0434\u043b\u044f \u0432\u0440\u0435\u043c\u0435\u043d\u0438 &#8216;h:i:s A&#8217;, \u0434\u043b\u044f datetime &#8212; &#8216;Y\/m\/d h:i:s A&#8217;. \u0415\u0441\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 value &#8212; \u0441\u0442\u0440\u043e\u043a\u0430, \u043e\u043d\u0430 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u0442\u0441\u044f \u0432 timestamp \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043c\u0435\u0442\u043e\u0434\u0430 strtotime. \u0415\u0441\u043b\u0438 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 value &#8212; \u0447\u0438\u0441\u043b\u043e, \u0442\u043e \u043e\u043d\u043e \u0441\u0447\u0438\u0442\u0430\u0435\u0442\u0441\u044f \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435\u043c timestamp<\/li>\n<li><strong>boolean<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u044b \u0432 \u0432\u0438\u0434\u0435 \u043b\u043e\u0433\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f &#8216;No&#8217; \/ &#8216;Yes&#8217; <\/li>\n<li><strong>number<\/strong> &#8212; \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 value \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0444\u0443\u043d\u043a\u0446\u0438\u0438 number_format \u0438 \u0438\u043c\u0435\u0435\u0442 \u0441\u043c\u044b\u0441\u043b \u0442\u043e\u043b\u044c\u043a\u043e \u0435\u0441\u043b\u0438 \u0435\u0441\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 $numberFormat. \u041e \u0442\u0430\u043a\u043e\u0432\u043e\u0439 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u043c\u043d\u0435 \u043f\u043e\u043a\u0430 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0447\u0438\u0441\u043b\u043e \u0434\u0435\u043b\u0438\u0442\u044c\u0441\u044f \u043d\u0430 \u0431\u043b\u043e\u043a\u0438 \u043f\u043e 3 \u0441\u0438\u043c\u0432\u043e\u043b\u0430, \u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u0435 \u0437\u0430\u043f\u044f\u0442\u043e\u0439<\/li>\n<li><strong>email<\/strong> &#8212; \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 value \u043e\u0431\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0442\u0435\u0433\u043e\u043c mailto <\/li>\n<li><strong>image<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0431\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0442\u0435\u0433\u043e\u043c img, \u0433\u0434\u0435 value \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 src<\/li>\n<li><strong>url<\/strong> &#8212; \u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0431\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0442\u0435\u0433\u043e\u043c a, \u0433\u0434\u0435 value \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 href <\/li>\n<li><strong>size<\/strong> &#8212; \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0438\u043d\u0442\u0435\u0440\u043f\u0440\u0435\u0442\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0447\u0438\u0441\u043b\u043e \u0432 \u0431\u0430\u0439\u0442\u0430\u0445, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u0442\u0441\u044f \u0432 \u043a\u0438\u043b\u043e\u0431\u0430\u0439\u0442\u044b, \u043c\u0435\u0433\u0430\u0431\u0430\u0439\u0442\u044b, \u0433\u0438\u0433\u043e\u0431\u0430\u0439\u0442\u044b \u0438 \u0442\u0435\u0440\u043e\u0431\u0430\u0439\u0442\u044b \u0441\u043e\u043e\u0442\u0432\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u043f\u043e\u043b\u0443\u0447\u0438\u0432 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 value=10000023 \u0432 \u044f\u0447\u0435\u0439\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0441 \u0442\u0430\u043a\u0438\u043c \u0442\u0438\u043f\u043e\u0432 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u043e 9.54 \u041c\u0411<\/li>\n<\/ul>\n<\/li>\n<li>\u0427\u0442\u043e\u0431\u044b <strong>\u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 CGridView<\/strong>, \u043d\u0443\u0436\u043d\u043e \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f value \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0442\u044c \u043c\u0435\u0442\u043e\u0434, \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u044e\u0449\u0438\u0439 \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435\n<pre class=\"brush: php; title: \u041f\u0440\u0438\u043c\u0435\u0440 1; notranslate\" title=\"\u041f\u0440\u0438\u043c\u0435\u0440 1\">\r\narray(\r\n  'name'   =&gt; 'region',\r\n  'filter' =&gt; Region::getAll(),\r\n  'value'  =&gt; 'Region::getNameByID($data-&gt;region)',\r\n),\r\n<\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0432 \u0444\u0438\u043b\u044c\u0442\u0440\u0435 \u043c\u0435\u0442\u043e\u0434 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441\u0440\u0430\u0437\u0443, \u0430 \u0432 value \u0437\u0430\u043f\u0438\u0441\u0430\u043d \u0432 \u0432\u0438\u0434\u0435 \u0441\u0442\u0440\u043e\u043a\u0438 \u0438 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0435 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043c\u0435\u0442\u043e\u0434\u0430\u043c\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 CGridView. \u0412 \u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0438 \u043c\u0435\u0442\u043e\u0434 getNameByID \u043a\u043b\u0430\u0441\u0441\u0430 Region \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u0442 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u0440\u0435\u0433\u0438\u043e\u043d\u0430 \u043f\u043e \u043f\u0435\u0440\u0432\u0438\u0447\u043d\u043e\u043c\u0443 \u043a\u043b\u044e\u0447\u0443.<br \/>\n\u0415\u0441\u043b\u0438 \u0432\u044b \u0443\u0432\u0435\u0440\u0435\u043d\u044b, \u0447\u0442\u043e \u043e\u0431\u044a\u0435\u043a\u0442, \u043f\u0435\u0440\u0435\u0434\u0430\u043d\u043d\u044b\u0439 \u0432 dataProvider \u0431\u0443\u0434\u0435\u0442 \u0438\u043c\u0435\u0442\u044c \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b (\u043a\u0430\u043a \u044d\u0442\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u0432\u043e \u0432\u0442\u043e\u0440\u043e\u0439 \u0447\u0430\u0441\u0442\u0438, \u043f\u043e\u0441\u0432\u044f\u0449\u0435\u043d\u043d\u043e\u0439 CGridView), \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0430\u043a\u0443\u044e \u0437\u0430\u043f\u0438\u0441\u044c<\/p>\n<pre class=\"brush: php; title: \u041f\u0440\u0438\u043c\u0435\u0440 2; notranslate\" title=\"\u041f\u0440\u0438\u043c\u0435\u0440 2\">\r\narray(\r\n  'name'   =&gt; 'region',\r\n  'filter' =&gt; Region::getAll(),\r\n  'value'  =&gt; '$data-&gt;region-&gt;title',\r\n),\r\n<\/pre>\n<p>\u0412 \u043c\u043e\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 &#171;region&#187; &#8212; \u044d\u0442\u043e \u0438\u043c\u044f \u0441\u0432\u044f\u0437\u0438 \u043c\u043e\u0434\u0435\u043b\u0438 Country, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u043f\u0440\u0438 \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u0438 CActiveDataProvider \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e with().\n<\/li>\n<\/ul>\n<h2>\u0418\u0437\u043c\u0435\u043d\u044f\u0435\u043c \u043f\u0435\u0439\u0434\u0436\u0438\u043d\u0430\u0446\u0438\u044e \u0432 CGridView<\/h2>\n<ul>\n<li>\u041a\u0430\u043a<strong> \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u043f\u0435\u0439\u0434\u0436\u0438\u043d\u0430\u0446\u0438\u044e CGridView \u0432 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u043c<\/strong> \u0434\u0438\u0432\u0435. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0443\u043a\u0430\u0437\u0430\u0442\u044c \u0448\u0430\u0431\u043b\u043e\u043d \u0432\u044b\u0432\u043e\u0434\u0430 template\n<pre class=\"brush: php; title: \u041f\u0440\u0438\u043c\u0435\u0440 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 CGridView; notranslate\" title=\"\u041f\u0440\u0438\u043c\u0435\u0440 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 CGridView\">\r\n&lt;?php $this-&gt;widget('zii.widgets.grid.CGridView', array(\r\n    'id'=&gt;'country-grid',\r\n    'dataProvider'=&gt;$model-&gt;search(),\r\n    'filter'=&gt;$model,\r\n    'template' =&gt; '&lt;div&gt;{pager}&lt;\/div&gt;{summary}{items}&lt;div&gt;{pager}&lt;\/div&gt;',\r\n    'columns'=&gt;array(\r\n        'id',\r\n        'name',\r\n        'region',\r\n        array(\r\n            'class'=&gt;'CButtonColumn',\r\n        ),\r\n    ),\r\n)); ?&gt;\r\n<\/pre>\n<p>\u0412 \u0448\u0430\u0431\u043b\u043e\u043d\u0435 \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 html-\u043a\u043e\u0434. <\/li>\n<li>\u041a\u0430\u043a <strong>\u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0441\u0442\u0438\u043b\u0438 \u043f\u0435\u0439\u0434\u0436\u0438\u043d\u0430\u0446\u0438\u0438 \u0432 CGridView<\/strong><\/li>\n<p>\u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0430\u0442\u0442\u0440\u0438\u0431\u0443\u0442 pager<\/p>\n<pre class=\"brush: php; title: \u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u043e\u0433\u043e pagination \u0432 CGridView; notranslate\" title=\"\u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u043e\u0433\u043e pagination \u0432 CGridView\">\r\n&lt;?php $this-&gt;widget('zii.widgets.grid.CGridView', array(\r\n    'id'=&gt;'country-grid',\r\n    'dataProvider'=&gt;$model-&gt;search(),\r\n    'filter'=&gt;$model,\r\n    'pager'=&gt;array(\r\n        'header'         =&gt; '',\r\n        'firstPageLabel' =&gt; '&amp;lt;&amp;lt;',\r\n        'prevPageLabel'  =&gt; '&lt;img src=&quot;images\/pagination\/left.png&quot;&gt;',\r\n        'nextPageLabel'  =&gt; '&lt;img src=&quot;images\/pagination\/right.png&quot;&gt;',\r\n        'lastPageLabel'  =&gt; '&amp;gt;&amp;gt;',\r\n    ),\r\n    'columns'=&gt;array(\r\n        'id',\r\n        'name',\r\n        'region',\r\n        array(\r\n            'class'=&gt;'CButtonColumn',\r\n        ),\r\n    ),\r\n)); ?&gt;\r\n<\/pre>\n<\/li>\n<\/ul>\n<p>\u0412\u043e\u0442 \u0442\u0430\u043a\u0430\u044f \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0430\u044f \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044f \u0443 \u043c\u0435\u043d\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c. \u041d\u0430\u0434\u0435\u044e\u0441\u044c \u043a\u043e\u043c\u0443-\u043d\u0438\u0431\u0443\u0434\u044c \u0434\u0430 \u043f\u0440\u0438\u0433\u043e\u0434\u0438\u0442\u044c\u0441\u044f. \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0432\u043e\u0437\u043d\u0438\u043a\u043b\u0438 \u0432\u043e\u043f\u0440\u043e\u0441\u044b &#8212; \u043f\u0438\u0448\u0438\u0442\u0435 \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445, \u043f\u043e\u043c\u043e\u0433\u0443 \u0447\u0435\u043c \u0441\u043c\u043e\u0433\u0443.<br \/>\n\u0412 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u043f\u043e\u0433\u043e\u0432\u043e\u0440\u0438\u043c \u043e\u0431 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430\u0445 \u0434\u044b\u043d\u043d\u044b\u0445 \u0434\u043b\u044f CGridView. \u041a\u0430\u043a \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0443\u0441\u043b\u043e\u0432\u0438\u044f, \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0438 \u0441\u0431\u0440\u043e\u0441\u0438\u0442\u044c \u0444\u0438\u043b\u044c\u0442\u0440\u044b.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>CGridView &#8212; \u043e\u0434\u0438\u043d \u0438\u0437 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432 Yii-framework. \u041e\u043d \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0431\u044a\u0435\u043a\u0442\u043e\u0432 \u043c\u043e\u0434\u0435\u043b\u0438 \u0432 \u0432\u0438\u0434\u0435 \u0443\u0434\u043e\u0431\u043d\u043e\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b, \u0441 \u043a\u043d\u043e\u043f\u043a\u0430\u043c\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0438\u0441\u044f\u043c\u0438. \u042d\u0442\u043e \u043d\u0435\u0437\u0430\u043c\u0435\u043d\u0438\u043c\u044b\u0439 \u0432\u0438\u0434\u0436\u0435\u0442 \u0434\u043b\u044f \u043b\u044e\u0431\u043e\u0439 \u0430\u0434\u043c\u0438\u043d\u043a\u0438. \u0415\u0441\u043b\u0438 \u043b\u0435\u043d\u044c \u043f\u0438\u0441\u0430\u0442\u044c \u0440\u0443\u043a\u0430\u043c\u0438, \u0435\u0433\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e gii. \u041d\u043e \u0442\u043e, \u0447\u0442\u043e \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u0441\u043e\u0432\u043f\u0430\u0434\u0430\u0435\u0442 \u0441 \u043f\u043e\u0442\u0440\u0435\u0431\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430. \u0412 \u043c\u043e\u0435\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 CGridView \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[9],"tags":[12],"_links":{"self":[{"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/posts\/58"}],"collection":[{"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/comments?post=58"}],"version-history":[{"count":12,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/posts\/58\/revisions"}],"predecessor-version":[{"id":78,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/posts\/58\/revisions\/78"}],"wp:attachment":[{"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/media?parent=58"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/categories?post=58"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/developer.uz\/blog\/wp-json\/wp\/v2\/tags?post=58"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}