{"id":344855,"date":"2023-02-01T21:01:26","date_gmt":"2023-02-01T21:01:26","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=344855"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=344855","title":{"rendered":"<span>\u0418\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u044f Primefaces \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 Spring Boot. \u0427\u0430\u0441\u0442\u044c 4 \u2014 \u0412\u044b\u0432\u043e\u0434 \u0441\u043f\u0438\u0441\u043a\u0430 \u0434\u0430\u043d\u043d\u044b\u0445 \u0432 \u0432\u0438\u0434\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b<\/span>"},"content":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/0ef\/66f\/fea\/0ef66ffeacda720c948b261adc958bae.png\" width=\"780\" height=\"439\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/0ef\/66f\/fea\/0ef66ffeacda720c948b261adc958bae.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u0412\u043e\u00a0\u0432\u0442\u043e\u0440\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u043c\u044b \u043d\u0430\u0443\u0447\u0438\u043b\u0438\u0441\u044c \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0432\u00a0\u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c <code>ui:include<\/code> \u043f\u043e\u00a0\u043a\u043b\u0438\u043a\u0443 \u043d\u0430\u00a0\u043f\u0443\u043d\u043a\u0442\u0435 \u043c\u0435\u043d\u044e. \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0437\u0430\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0438\u043d\u043a\u043b\u0443\u0434\u044b \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439. \u0412\u00a0\u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0432\u00a0\u0441\u0435\u0431\u044f \u0434\u0430\u043d\u043d\u044b\u0435, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c\u044b\u0435 \u0438\u0437\u00a0\u0441\u043f\u0438\u0441\u043a\u0430, \u043f\u0440\u0438\u0447\u0435\u043c \u043f\u043e\u00a0\u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0438\u0437\u00a0\u043f\u043e\u043b\u0435\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043c\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0435\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044e \u043f\u043e\u00a0\u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u043c\u0443 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u044e \u043f\u043e\u043b\u044f.<\/p>\n<p>\u041f\u043e\u0436\u0430\u043b\u0443\u0439, \u0442\u0440\u0443\u0434\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432\u00a0\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 PrimeFaces \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442, \u0443\u00a0\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e\u00a0\u0431\u044b\u043b\u043e\u00a0\u0431\u044b \u0431\u043e\u043b\u044c\u0448\u0435 \u0440\u0430\u0437\u043d\u043e\u043e\u0431\u0440\u0430\u0437\u043d\u044b\u0445 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u0447\u0435\u043c \u0443\u00a0\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 Data Table! \u041d\u0430\u00a0\u043c\u043e\u043c\u0435\u043d\u0442, \u043a\u043e\u0433\u0434\u0430 \u043f\u0438\u0448\u0443\u0442\u0441\u044f \u044d\u0442\u0438 \u0441\u0442\u0440\u043e\u043a\u0438, \u044f \u043d\u0430\u0441\u0447\u0438\u0442\u0430\u043b 29\u00a0\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0441\u00a0\u0440\u0430\u0437\u043d\u043e\u043e\u0431\u0440\u0430\u0437\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c\u0438 \u043f\u043b\u044e\u0448\u043a\u0430\u043c\u0438 \u0438 \u043a\u0440\u0430\u0441\u0438\u0432\u043e\u0441\u0442\u044f\u043c\u0438, \u043f\u0440\u0438\u0447\u0435\u043c \u043a\u0430\u0436\u0434\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0432 2\u20133\u00a0\u043f\u043e\u0434\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430\u0445, \u043d\u0435\u00a0\u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u043e, \u0447\u0442\u043e\u00a0\u0438\u0445 \u0441\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0431\u0443\u0434\u0435\u0442 \u0435\u0449\u0435 \u0431\u043e\u043b\u044c\u0448\u0435. \u0421\u0430\u043c\u044b\u0439 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442, \u0433\u0434\u0435 \u0432\u044b\u0432\u043e\u0434\u044f\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u0442\u0440\u043e\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0431\u0435\u0437\u00a0\u043a\u0430\u043a\u0438\u0445\u2011\u043b\u0438\u0431\u043e \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0439: <\/p>\n<p><a href=\"https:\/\/www.primefaces.org\/showcase\/ui\/data\/datatable\/basic.xhtml?jfwid=7ffb6\"><u>DataTable\u00a0Basic. DataTable displays data in tabular format<\/u><\/a><\/p>\n<p>\u041c\u044b \u0432\u043e\u0437\u044c\u043c\u0435\u043c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Data Table Filter \u0441\u00a0\u043f\u0440\u043e\u0441\u0442\u044b\u043c \u0434\u0435\u0444\u043e\u043b\u0442\u043d\u044b\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u044f\u043c\u0438 \u0434\u043b\u044f\u00a0\u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438, \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u043c\u0438 \u043d\u0430\u0434 \u043a\u0430\u0436\u0434\u044b\u043c \u043f\u043e\u043b\u0435\u043c\/\u043a\u043e\u043b\u043e\u043d\u043a\u043e\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b:<\/p>\n<p><a href=\"https:\/\/www.primefaces.org\/showcase\/ui\/data\/datatable\/filter.xhtml?jfwid=7ffb6\"><u>DataTable Filter. Filtering updates the data based on the constraints<\/u><\/a><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/525\/526\/63b\/52552663b0da8771eaf9801f89eb1d36.png\" width=\"1872\" height=\"800\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/525\/526\/63b\/52552663b0da8771eaf9801f89eb1d36.png\"\/><figcaption><\/figcaption><\/figure>\n<p>\u041a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e, \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0439 xhtml-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 \u0441 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u043d\u044b\u043c \u043d\u0430 \u043d\u0435\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c \u0438 \u0444\u0430\u0439\u043b\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u043e\u0433\u043e \u0431\u0438\u043d\u0430 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443:<\/p>\n<pre><code>&lt;!DOCTYPE html> &lt;html xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\"       xmlns:h=\"http:\/\/xmlns.jcp.org\/jsf\/html\"       xmlns:f=\"http:\/\/xmlns.jcp.org\/jsf\/core\"       xmlns:p=\"http:\/\/primefaces.org\/ui\">  &lt;f:view contentType=\"text\/html;charset=UTF-8\" encoding=\"UTF-8\"> &lt;h:head>     &lt;h:outputStylesheet library=\"webjars\" name=\"primeflex\/3.2.0\/primeflex.min.css\" \/>     &lt;h:outputStylesheet library=\"css\" name=\"styles.css\"\/>     &lt;meta charset=\"utf-8\" \/>     &lt;meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\" \/>     &lt;title>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b&lt;\/title> &lt;\/h:head>     &lt;h:body>         &lt;div class=\"card\">             &lt;h:form>                 &lt;div class=\"col-12 md:col-2\">                     &lt;p:button href=\"\/employee\/edit\/0\" value=\"\u0421\u043e\u0437\u0434\u0430\u0442\u044c\"\/>                 &lt;\/div>                 &lt;p:dataTable var=\"employee\" value=\"#{employeeFilterView.employees}\" widgetVar=\"employeesTable\"                              emptyMessage=\"No employees found with given criteria\"                              filteredValue=\"#{employeeFilterView.filteredEmployees}\"                              filterBy=\"#{employeeFilterView.filterBy}\"                 >                      &lt;f:facet name=\"header\">                         &lt;span>\u0421\u043f\u0438\u0441\u043e\u043a \u0441\u043e\u0442\u0440\u0443\u0434\u043d\u0438\u043a\u043e\u0432&lt;\/span>                     &lt;\/f:facet>                      &lt;p:column headerText=\"\u0424\u0418\u041e\" sortBy=\"#{employee.name}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.name}\">                         &lt;h:outputText value=\"#{employee.name}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u0421\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f\" sortBy=\"#{employee.specialties}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.specialties}\">                         &lt;h:outputText value=\"#{employee.specialties}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041e\u0442\u0434\u0435\u043b\" sortBy=\"#{employee.employeeDepartment}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.employeeDepartment}\">                         &lt;h:outputText value=\"#{employee.employeeDepartment}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041a\u043e\u043c\u043f\u0435\u0442\u0435\u043d\u0446\u0438\u0438\" sortBy=\"#{employee.skills}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.skills}\">                         &lt;h:outputText value=\"#{employee.skills}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u0423\u0432\u043e\u043b\u0435\u043d\" sortBy=\"#{employee.archived}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.archived}\">                         &lt;h:outputText value=\"#{employee.archived}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041a\u0430\u0440\u0442\u043e\u0447\u043a\u0430 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\">                         &lt;h:outputLink value=\"#{employee.linkToLK}\">                             &lt;h:outputText value=\"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u043a\u0430\u0440\u0442\u043e\u0447\u043a\u0443\" \/>                         &lt;\/h:outputLink>                     &lt;\/p:column>                 &lt;\/p:dataTable>             &lt;\/h:form>         &lt;\/div>     &lt;\/h:body> &lt;\/f:view>  &lt;\/html> <\/code><\/pre>\n<p>\u041a\u0430\u043a\u00a0\u043c\u044b \u0432\u0438\u0434\u0438\u043c, \u044d\u0442\u043e \u043e\u0431\u044b\u0447\u043d\u0430\u044f xhtml\u2011\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0435\u0435 \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u0431\u043b\u043e\u043a\u0430\u043c\u0438. \u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u043e\u0434\u0443\u043c\u0430\u043b\u0438, \u0447\u0442\u043e\u00a0\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0438\u043d\u043a\u043b\u0443\u0434\u0438\u0442\u0441\u044f \u0432\u00a0\u0433\u043b\u0430\u0432\u043d\u0443\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443, \u0438 \u043f\u043e\u0442\u043e\u043c\u0443 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0435 \u0442\u0435\u0433\u0438, \u043c\u043e\u0436\u0435\u0442\u00a0\u0431\u044b\u0442\u044c, \u043d\u0435\u00a0\u043d\u0443\u0436\u043d\u044b, \u0442\u043e \u0432\u044b \u043f\u043e\u0434\u0443\u043c\u0430\u043b\u0438 \u0442\u0430\u043a\u00a0\u0436\u0435 \u0442\u043e\u0447\u043d\u043e, \u043a\u0430\u043a\u00a0\u0438 \u044f \u0432\u043d\u0430\u0447\u0430\u043b\u0435. \u041d\u043e\u00a0\u044d\u0442\u043e \u043e\u0448\u0438\u0431\u043a\u0430, \u0442\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0435\u00a0\u0431\u0443\u0434\u0435\u0442, \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u043b. \u041f\u043e\u0437\u0436\u0435, \u0432\u00a0\u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u044f\u0445 \u0441\u0442\u0430\u0442\u044c\u0438, \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0435\u043c\u0441\u044f \u0441\u00a0\u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043a\u0430\u0436\u0443\u0442 \u043d\u0430\u043c, \u0447\u0442\u043e\u00a0\u0432\u043b\u043e\u0436\u0435\u043d\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0432\u0438\u0434\u0430 \u0432\u00a0PrimeFaces \u0438\u043c\u0435\u0435\u0442 \u0435\u0449\u0435 \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u0430\u043b\u0435\u043a\u043e \u043d\u0435\u00a0\u0432\u0441\u0435 \u0432\u0438\u0434\u044b \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0431\u0443\u0434\u0443\u0442 \u043d\u0430\u00a0\u043d\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e. \u041d\u043e\u00a0\u0432\u00a0\u0442\u0430\u043a\u043e\u043c \u0443\u043f\u0440\u043e\u0449\u0435\u043d\u043d\u043e\u043c \u0432\u0438\u0434\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0441\u00a0\u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0437\u0434\u0435\u0441\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0431\u0443\u0434\u0435\u0442 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e.<\/p>\n<p>\u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e\u00a0\u043d\u0443\u0436\u043d\u043e \u0437\u043d\u0430\u0442\u044c \u043e\u00a0\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 <code>p:dataTable<\/code> \u043d\u0430\u00a0\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<ul>\n<li>\n<p><code>value=\"#{employeeFilterView.employees}\"<\/code>\u00a0\u2014 \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430\u00a0\u043f\u043e\u043b\u0435 \u0431\u0438\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0441\u043f\u0438\u0441\u043e\u043a, \u0438\u0437\u00a0\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b\u0431\u0438\u0440\u0430\u044e\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b;<\/p>\n<\/li>\n<li>\n<p><code>emptyMessage=\"No employees found with given criteria\"<\/code>\u00a0\u2014 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432\u00a0\u0441\u043b\u0443\u0447\u0430\u0435, \u0435\u0441\u043b\u0438 \u0441\u043f\u0438\u0441\u043e\u043a \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u043d\u0435\u00a0\u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d;<\/p>\n<\/li>\n<li>\n<p><code>filteredValue=\"#{employeeFilterView.filteredEmployees}\"<\/code>\u00a0\u2014 \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430\u00a0\u043f\u043e\u043b\u0435 \u0431\u0438\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0443\u0436\u0435 \u043e\u0442\u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0441\u043f\u0438\u0441\u043e\u043a, \u043a\u043e\u0433\u0434\u0430 \u0444\u0438\u043b\u044c\u0442\u0440 \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d.<\/p>\n<\/li>\n<\/ul>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043c\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a \u0441\u043f\u0438\u0441\u043a\u0430\/\u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0438 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u043a\u043e\u043b\u043e\u043d\u043a\u0438\/\u043f\u043e\u043b\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u044b. <code>filterBy<\/code> \u0432\u00a0\u043a\u0430\u0436\u0434\u043e\u043c \u043f\u043e\u043b\u0435 \u0438 \u0432\u044b\u0448\u0435 \u0432\u00a0\u0441\u0430\u043c\u043e\u043c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432\u00a0\u0444\u0438\u043b\u044c\u0442\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0438\u0441\u0430\u0442\u044c \u0432\u00a0\u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u043e\u043b\u044f\u0445 \u0434\u043b\u044f\u00a0\u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438. \u0424\u0438\u043b\u044c\u0442\u0440 \u0443\u043c\u043d\u044b\u0439, \u043f\u043e\u043b\u044f \u0444\u0438\u043b\u044c\u0442\u0440\u0443\u044e\u0442\u0441\u044f \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e, \u0442\u043e \u0435\u0441\u0442\u044c \u043c\u043e\u0436\u043d\u043e \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u00a0\u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c \u043a\u043e\u043b\u043e\u043d\u043a\u0430\u043c \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u0442\u043e\u0439 \u043b\u043e\u0433\u0438\u043a\u0435, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0432\u044b \u043f\u0440\u043e\u043f\u0438\u0448\u0435\u0442\u0435 \u0432\u00a0\u0431\u0438\u043d\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430. \u0412\u043f\u0440\u043e\u0447\u0435\u043c, \u043e\u0431\u00a0\u044d\u0442\u043e\u043c \u044f \u043d\u0430\u043f\u0438\u0448\u0443 \u0447\u0443\u0442\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043d\u0438\u0436\u0435. \u041a\u0440\u043e\u043c\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438, \u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0443 \u043f\u043e\u00a0\u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u043f\u043e\u043b\u044e, \u0434\u043b\u044f\u00a0\u0447\u0435\u0433\u043e \u0441\u043b\u0443\u0436\u0438\u0442 <code>sortBy<\/code>. \u041e\u0447\u0435\u043d\u044c \u0432\u0430\u0436\u043d\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043f\u043e\u043b\u044f <code>filterMatchMode=\"contains\"<\/code>\u00a0\u2014 \u0441\u00a0\u043d\u0435\u0439 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043a\u0430\u043a\u00a0\u043f\u043e\u043b\u043d\u043e\u0442\u0435\u043a\u0441\u0442\u043e\u0432\u0430\u044f, \u0441\u00a0\u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c\/\u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435\u043c \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0438\u043c\u0432\u043e\u043b\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442\u0435 \u0432\u00a0\u043f\u043e\u043b\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438 \u043c\u043e\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044f\u0441\u044c \u043a\u0430\u043a\u00a0\u043f\u043e\u00a0\u0432\u0441\u0435\u043c\u0443 \u0441\u043b\u043e\u0432\u0443, \u0442\u0430\u043a \u0438 \u043f\u043e\u00a0\u0435\u0433\u043e \u0447\u0430\u0441\u0442\u0438 \u0438\u043b\u0438\u00a0\u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c \u0441\u0438\u043c\u0432\u043e\u043b\u0430\u043c. \u042d\u0442\u043e \u041d\u0415\u00a0\u0434\u0435\u0444\u043e\u043b\u0442\u043e\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u0442\u044c \u044f\u0432\u043d\u043e. \u0414\u0440\u0443\u0433\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 \u0438\u043b\u0438\u00a0\u0434\u0440\u0443\u0433\u0438\u0445 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432\u00a0\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438<\/p>\n<p><a href=\"https:\/\/primefaces.github.io\/primefaces\/12_0_0\/#\/components\/datatable\"><u>DataTable. DataTable displays data in tabular format<\/u><\/a><\/p>\n<p>\u0412\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b <code>h:outputText<\/code> \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u044b\u0432\u043e\u0434\u044f\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u0435\u0439 \u0432 \u043a\u0430\u0436\u0434\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b. \u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0432 \u0441\u0441\u044b\u043b\u043a\u0443, \u043e\u0431\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u0435\u0433\u043e \u0435\u0449\u0435 \u0438 \u0432 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 <code>h:outputLink<\/code><\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0439\u0434\u0435\u043c \u043a \u0431\u0438\u043d\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430:<\/p>\n<pre><code class=\"java\"> import jakarta.faces.view.ViewScoped; import jakarta.inject.Inject; import lombok.Getter; import lombok.Setter; import org.primefaces.model.FilterMeta; import org.primefaces.util.LangUtils; import org.satel.ressatel.service.EmployeeService; import org.springframework.stereotype.Component;  import java.io.Serializable; import java.util.ArrayList; import java.util.List; import java.util.Locale;  @Component(\"employeeFilterView\") @ViewScoped @Getter @Setter public class EmployeeFilterView implements Serializable {      private List&lt;Employee> employees;     private List&lt;Employee> filteredEmployees;     private List&lt;FilterMeta> filterBy;      private boolean globalFilterOnly;     private final EmployeeService employeeService;      @Inject     public EmployeeFilterView(EmployeeService employeeService) {         this.employeeService = employeeService;         this.init();     }      public void init() {         employees = employeeService.getShortList();         globalFilterOnly = false;         filterBy = new ArrayList&lt;>();     }      public boolean globalFilterFunction(Object value, Object filter, Locale locale) {         String filterText = (filter == null) ? null : filter.toString().trim().toLowerCase();         if (LangUtils.isBlank(filterText)) {             return true;         }          Employee employee = (Employee) value;         return employee.getName().toLowerCase().contains(filterText)                 || employee.getSpecialties().toLowerCase().contains(filterText)                 || employee.getEmployeeDepartment().toLowerCase().contains(filterText)                 || employee.getSkills().toLowerCase().contains(filterText)                 || employee.getArchived().toLowerCase().contains(filterText);     }      public void toggleGlobalFilter() {         setGlobalFilterOnly(!isGlobalFilterOnly());     }  }  <\/code><\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u044f \u0443\u043f\u043e\u0442\u0440\u0435\u0431\u0438\u043b \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e \u0431\u0438\u043d\u0430 <code>@ViewScoped<\/code> \u0438\u0437 jakarta. Spring \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u043f\u043e\u043d\u044f\u043b \u044d\u0442\u043e\u0442 scope \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u043b \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e \u043a \u0431\u0438\u043d\u0443. \u0422\u0443\u0442 \u043d\u0443\u0436\u043d\u043e \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u043e\u0447\u043d\u043e\u0439 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0438 \u044d\u0442\u043e\u0433\u043e scope \u0432 Spring \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0442\u0430\u043a\u043e\u0433\u043e \u0431\u0438\u043d\u0430 \u0431\u0443\u0434\u0435\u0442 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0434\u043d\u043e\u0439 \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 xhtml \u0441 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c \u043d\u0430 \u043d\u0435\u0439, \u0442\u043e \u0435\u0441\u0442\u044c \u043e\u0434\u043d\u0438\u043c \u0432\u0438\u0434\u043e\u043c JSF + PrimeFaces. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0438\u0448\u0443\u0442 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0435 \u0430\u043d\u0430\u043b\u043e\u0433\u0438 \u0434\u043b\u044f Spring \u0441\u0430\u043c\u0438, \u0435\u0441\u043b\u0438 \u0434\u043b\u044f \u0438\u0445 \u0437\u0430\u0434\u0430\u0447 \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e, \u043a\u0430\u043a \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u043e\u0442 \u0437\u0434\u0435\u0441\u044c:<\/p>\n<p><a href=\"https:\/\/stackoverflow.com\/questions\/13005421\/jsf-view-scope-in-spring\"><u>JSF View scope in Spring<\/u><\/a><\/p>\n<p>\u0415\u0441\u043b\u0438 \u044d\u0442\u043e \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u043e \u0432\u0430\u0448\u0438\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c, \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c scope <a class=\"mention\" href=\"\/users\/Request\">@Request<\/a>, <a class=\"mention\" href=\"\/users\/Session\">@Session<\/a> \u0438\u043b\u0438 <a class=\"mention\" href=\"\/users\/GlobalSession\">@GlobalSession<\/a>, \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0435\u0448\u0430\u0435\u0442 \u0441\u0430\u043c. \u041d\u043e \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0432\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u0438 <code>@ViewScoped<\/code> \u0438\u0437 jakarta \u043d\u0435 \u043f\u0440\u0438\u0432\u0435\u043b\u0430 \u0443 \u043c\u0435\u043d\u044f \u043d\u0438 \u043a \u043a\u0430\u043a\u0438\u043c \u043d\u0435\u043f\u0440\u0438\u044f\u0442\u043d\u044b\u043c \u044d\u0444\u0444\u0435\u043a\u0442\u0430\u043c, \u044f \u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0435\u0435 \u043a\u0430\u043a \u0435\u0441\u0442\u044c.<\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u044f \u043f\u0440\u0438\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0441\u044c \u0438\u043d\u0436\u0435\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0445 \u0431\u0438\u043d\u0430\u0445 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 <a class=\"mention\" href=\"\/users\/Inject\">@Inject<\/a> \u0438\u0437 jakarta, \u0430 \u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430\u0445 \u0441\u0442\u0430\u0432\u043b\u044e scope <code>@ApplicationScoped<\/code> \u0442\u043e\u0436\u0435 \u0438\u0437 jakarta, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e \u0441 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0435\u0439 <code>@Service<\/code> \u0438\u0437 Spring, \u0438 \u0442\u0430\u043a\u0436\u0435 \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u043d\u0435\u0443\u0434\u043e\u0431\u0441\u0442\u0432 \u044d\u0442\u043e \u043f\u043e\u043a\u0430 \u0447\u0442\u043e \u043d\u0435 \u0432\u044b\u0437\u0432\u0430\u043b\u043e.<\/p>\n<p>\u0412 \u0431\u0438\u043d\u0435 \u043c\u044b \u0432\u0438\u0434\u0438\u043c \u043e\u0431\u0435\u0449\u0430\u043d\u043d\u0443\u044e \u043c\u043d\u043e\u0439 \u0432\u044b\u0448\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043b\u043e\u0433\u0438\u043a\u0438 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 <code>globalFilterFunction<\/code>, \u043d\u0435 \u0443\u0434\u0438\u0432\u043b\u044f\u0439\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u044f\u0432\u043d\u043e\u0439 \u0441\u0432\u044f\u0437\u0438 \u043f\u043e\u043b\u044f filterBy \u0441 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439 \u0432\u044b \u043d\u0435 \u0432\u0438\u0434\u0438\u0442\u0435 &#8212; \u0432\u0441\u0435 \u0441\u0432\u044f\u0437\u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0442\u0441\u044f PrimeFaces &#171;\u043f\u043e\u0434 \u043a\u0430\u043f\u043e\u0442\u043e\u043c&#187;. filterBy \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u0438\u0445\u043e\u0434\u0438\u0442 \u0432 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 filter, \u0430 \u0437\u0430\u0442\u0435\u043c \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 filterText \u043f\u0443\u0442\u0435\u043c \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438, \u043f\u0440\u0438\u0445\u043e\u0434\u044f\u0449\u0438\u043c\u0438 \u0438\u0437 \u0411\u0414 \u0434\u043b\u044f \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438. \u0420\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u044c \u043d\u0435 \u0431\u0443\u0434\u0443, \u043e\u043d\u0438 \u0443 \u0432\u0430\u0441 \u0431\u0443\u0434\u0443\u0442 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u0435, \u043f\u043e\u0434 \u0432\u0430\u0448\u0438 \u043d\u0443\u0436\u0434\u044b.<\/p>\n<p>\u0412 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0447\u0430\u0441\u0442\u0438 \u0441\u0442\u0430\u0442\u044c\u0438 \u043c\u044b \u043d\u0430\u0447\u043d\u0435\u043c \u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u044c\u0441\u044f \u0441 \u0444\u043e\u0440\u043c\u0430\u043c\u0438 \u0434\u043b\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0438 \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445, \u0441 \u0442\u0438\u043f\u0430\u043c\u0438 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0434\u043b\u044f \u0438\u043d\u043f\u0443\u0442\u043e\u0432 \u0444\u043e\u0440\u043c \u0438 \u0441 \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u043e\u0439 \u0434\u0430\u043d\u043d\u044b\u0445, \u043f\u0440\u0438\u0445\u043e\u0434\u044f\u0449\u0438\u0445 \u0438\u0437 \u0438\u043d\u043f\u0443\u0442\u043e\u0432.<\/p>\n<p>\u041d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u044e, \u0447\u0442\u043e \u0434\u0430\u043d\u043d\u044b\u0439 \u0446\u0438\u043a\u043b \u0441\u0442\u0430\u0442\u0435\u0439 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043b\u0435\u043d \u0432 \u043f\u0440\u0435\u0434\u0434\u0432\u0435\u0440\u0438\u0438 \u0441\u0442\u0430\u0440\u0442\u0430 \u043a\u0443\u0440\u0441\u0430 &#171;<a href=\"https:\/\/otus.pw\/kdYY\/\">Java Developer. Professional<\/a>&#171;. \u0411\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u044b\u0439 \u0443\u0440\u043e\u043a \u043a\u0443\u0440\u0441\u0430 \u043f\u043e \u0442\u0435\u043c\u0435: &#171;\u0420\u0435\u0430\u043a\u0442\u0438\u0432\u043d\u043e\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a Postgresql \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u0445 \u043d\u0430 Java&#187; \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043f\u043e <a href=\"https:\/\/otus.pw\/kdYY\/\">\u044d\u0442\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0435<\/a>.<\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<p> <!----> <!----><\/div>\n<p> <!----> <!----><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/otus\/blog\/713770\/\"> https:\/\/habr.com\/ru\/company\/otus\/blog\/713770\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u0412\u043e\u00a0\u0432\u0442\u043e\u0440\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u043c\u044b \u043d\u0430\u0443\u0447\u0438\u043b\u0438\u0441\u044c \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u043d\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0432\u00a0\u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c <code>ui:include<\/code> \u043f\u043e\u00a0\u043a\u043b\u0438\u043a\u0443 \u043d\u0430\u00a0\u043f\u0443\u043d\u043a\u0442\u0435 \u043c\u0435\u043d\u044e. \u0422\u0435\u043f\u0435\u0440\u044c \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0437\u0430\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0438\u043d\u043a\u043b\u0443\u0434\u044b \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439. \u0412\u00a0\u043c\u043e\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u043e\u043b\u0435\u0437\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0432\u043a\u043b\u044e\u0447\u0430\u0442\u044c \u0432\u00a0\u0441\u0435\u0431\u044f \u0434\u0430\u043d\u043d\u044b\u0435, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c\u044b\u0435 \u0438\u0437\u00a0\u0441\u043f\u0438\u0441\u043a\u0430, \u043f\u0440\u0438\u0447\u0435\u043c \u043f\u043e\u00a0\u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u0438\u0437\u00a0\u043f\u043e\u043b\u0435\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u043c\u044b \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0435\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044e \u043f\u043e\u00a0\u0442\u0435\u043a\u0441\u0442\u043e\u0432\u043e\u043c\u0443 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u044e \u043f\u043e\u043b\u044f.<\/p>\n<p>\u041f\u043e\u0436\u0430\u043b\u0443\u0439, \u0442\u0440\u0443\u0434\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432\u00a0\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0435 PrimeFaces \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442, \u0443\u00a0\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e\u00a0\u0431\u044b\u043b\u043e\u00a0\u0431\u044b \u0431\u043e\u043b\u044c\u0448\u0435 \u0440\u0430\u0437\u043d\u043e\u043e\u0431\u0440\u0430\u0437\u043d\u044b\u0445 \u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u0447\u0435\u043c \u0443\u00a0\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 Data Table! \u041d\u0430\u00a0\u043c\u043e\u043c\u0435\u043d\u0442, \u043a\u043e\u0433\u0434\u0430 \u043f\u0438\u0448\u0443\u0442\u0441\u044f \u044d\u0442\u0438 \u0441\u0442\u0440\u043e\u043a\u0438, \u044f \u043d\u0430\u0441\u0447\u0438\u0442\u0430\u043b 29\u00a0\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u043e\u0432 \u0441\u00a0\u0440\u0430\u0437\u043d\u043e\u043e\u0431\u0440\u0430\u0437\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u043c\u0438 \u043f\u043b\u044e\u0448\u043a\u0430\u043c\u0438 \u0438 \u043a\u0440\u0430\u0441\u0438\u0432\u043e\u0441\u0442\u044f\u043c\u0438, \u043f\u0440\u0438\u0447\u0435\u043c \u043a\u0430\u0436\u0434\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u0447\u0430\u0441\u0442\u043e \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0432 2\u20133\u00a0\u043f\u043e\u0434\u0432\u0430\u0440\u0438\u0430\u043d\u0442\u0430\u0445, \u043d\u0435\u00a0\u0438\u0441\u043a\u043b\u044e\u0447\u0435\u043d\u043e, \u0447\u0442\u043e\u00a0\u0438\u0445 \u0441\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0431\u0443\u0434\u0435\u0442 \u0435\u0449\u0435 \u0431\u043e\u043b\u044c\u0448\u0435. \u0421\u0430\u043c\u044b\u0439 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442, \u0433\u0434\u0435 \u0432\u044b\u0432\u043e\u0434\u044f\u0442\u0441\u044f \u0442\u043e\u043b\u044c\u043a\u043e \u0441\u0442\u0440\u043e\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0431\u0435\u0437\u00a0\u043a\u0430\u043a\u0438\u0445\u2011\u043b\u0438\u0431\u043e \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0439: <\/p>\n<p><a href=\"https:\/\/www.primefaces.org\/showcase\/ui\/data\/datatable\/basic.xhtml?jfwid=7ffb6\"><u>DataTable\u00a0Basic. DataTable displays data in tabular format<\/u><\/a><\/p>\n<p>\u041c\u044b \u0432\u043e\u0437\u044c\u043c\u0435\u043c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Data Table Filter \u0441\u00a0\u043f\u0440\u043e\u0441\u0442\u044b\u043c \u0434\u0435\u0444\u043e\u043b\u0442\u043d\u044b\u043c \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u043c, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u043f\u043e\u043b\u044f\u043c\u0438 \u0434\u043b\u044f\u00a0\u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438, \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u043c\u0438 \u043d\u0430\u0434 \u043a\u0430\u0436\u0434\u044b\u043c \u043f\u043e\u043b\u0435\u043c\/\u043a\u043e\u043b\u043e\u043d\u043a\u043e\u0439 \u0442\u0430\u0431\u043b\u0438\u0446\u044b:<\/p>\n<p><a href=\"https:\/\/www.primefaces.org\/showcase\/ui\/data\/datatable\/filter.xhtml?jfwid=7ffb6\"><u>DataTable Filter. Filtering updates the data based on the constraints<\/u><\/a><\/p>\n<figure class=\"full-width\"><figcaption><\/figcaption><\/figure>\n<p>\u041a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u043e, \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0430 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e\u0439 xhtml-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 \u0441 \u0440\u0430\u0437\u043c\u0435\u0449\u0435\u043d\u043d\u044b\u043c \u043d\u0430 \u043d\u0435\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c \u0438 \u0444\u0430\u0439\u043b\u043e\u043c \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u043e\u0433\u043e \u0431\u0438\u043d\u0430 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443:<\/p>\n<pre><code>&lt;!DOCTYPE html> &lt;html xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\"       xmlns:h=\"http:\/\/xmlns.jcp.org\/jsf\/html\"       xmlns:f=\"http:\/\/xmlns.jcp.org\/jsf\/core\"       xmlns:p=\"http:\/\/primefaces.org\/ui\">  &lt;f:view contentType=\"text\/html;charset=UTF-8\" encoding=\"UTF-8\"> &lt;h:head>     &lt;h:outputStylesheet library=\"webjars\" name=\"primeflex\/3.2.0\/primeflex.min.css\" \/>     &lt;h:outputStylesheet library=\"css\" name=\"styles.css\"\/>     &lt;meta charset=\"utf-8\" \/>     &lt;meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\" \/>     &lt;title>\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b&lt;\/title> &lt;\/h:head>     &lt;h:body>         &lt;div class=\"card\">             &lt;h:form>                 &lt;div class=\"col-12 md:col-2\">                     &lt;p:button href=\"\/employee\/edit\/0\" value=\"\u0421\u043e\u0437\u0434\u0430\u0442\u044c\"\/>                 &lt;\/div>                 &lt;p:dataTable var=\"employee\" value=\"#{employeeFilterView.employees}\" widgetVar=\"employeesTable\"                              emptyMessage=\"No employees found with given criteria\"                              filteredValue=\"#{employeeFilterView.filteredEmployees}\"                              filterBy=\"#{employeeFilterView.filterBy}\"                 >                      &lt;f:facet name=\"header\">                         &lt;span>\u0421\u043f\u0438\u0441\u043e\u043a \u0441\u043e\u0442\u0440\u0443\u0434\u043d\u0438\u043a\u043e\u0432&lt;\/span>                     &lt;\/f:facet>                      &lt;p:column headerText=\"\u0424\u0418\u041e\" sortBy=\"#{employee.name}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.name}\">                         &lt;h:outputText value=\"#{employee.name}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u0421\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f\" sortBy=\"#{employee.specialties}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.specialties}\">                         &lt;h:outputText value=\"#{employee.specialties}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041e\u0442\u0434\u0435\u043b\" sortBy=\"#{employee.employeeDepartment}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.employeeDepartment}\">                         &lt;h:outputText value=\"#{employee.employeeDepartment}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041a\u043e\u043c\u043f\u0435\u0442\u0435\u043d\u0446\u0438\u0438\" sortBy=\"#{employee.skills}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.skills}\">                         &lt;h:outputText value=\"#{employee.skills}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u0423\u0432\u043e\u043b\u0435\u043d\" sortBy=\"#{employee.archived}\"                               filterMatchMode=\"contains\"                               filterBy=\"#{employee.archived}\">                         &lt;h:outputText value=\"#{employee.archived}\" \/>                     &lt;\/p:column>                      &lt;p:column headerText=\"\u041a\u0430\u0440\u0442\u043e\u0447\u043a\u0430 \u0440\u0435\u0441\u0443\u0440\u0441\u0430\">                         &lt;h:outputLink value=\"#{employee.linkToLK}\">                             &lt;h:outputText value=\"\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u043a\u0430\u0440\u0442\u043e\u0447\u043a\u0443\" \/>                         &lt;\/h:outputLink>                     &lt;\/p:column>                 &lt;\/p:dataTable>             &lt;\/h:form>         &lt;\/div>     &lt;\/h:body> &lt;\/f:view>  &lt;\/html> <\/code><\/pre>\n<p>\u041a\u0430\u043a\u00a0\u043c\u044b \u0432\u0438\u0434\u0438\u043c, \u044d\u0442\u043e \u043e\u0431\u044b\u0447\u043d\u0430\u044f xhtml\u2011\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441\u043e \u0432\u0441\u0435\u043c\u0438 \u0435\u0435 \u043e\u0431\u044b\u0447\u043d\u044b\u043c\u0438 \u0431\u043b\u043e\u043a\u0430\u043c\u0438. \u0415\u0441\u043b\u0438 \u0432\u044b \u043f\u043e\u0434\u0443\u043c\u0430\u043b\u0438, \u0447\u0442\u043e\u00a0\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0438\u043d\u043a\u043b\u0443\u0434\u0438\u0442\u0441\u044f \u0432\u00a0\u0433\u043b\u0430\u0432\u043d\u0443\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443, \u0438 \u043f\u043e\u0442\u043e\u043c\u0443 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u0447\u043d\u044b\u0435 \u0442\u0435\u0433\u0438, \u043c\u043e\u0436\u0435\u0442\u00a0\u0431\u044b\u0442\u044c, \u043d\u0435\u00a0\u043d\u0443\u0436\u043d\u044b, \u0442\u043e \u0432\u044b \u043f\u043e\u0434\u0443\u043c\u0430\u043b\u0438 \u0442\u0430\u043a\u00a0\u0436\u0435 \u0442\u043e\u0447\u043d\u043e, \u043a\u0430\u043a\u00a0\u0438 \u044f \u0432\u043d\u0430\u0447\u0430\u043b\u0435. \u041d\u043e\u00a0\u044d\u0442\u043e \u043e\u0448\u0438\u0431\u043a\u0430, \u0442\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043d\u0435\u00a0\u0431\u0443\u0434\u0435\u0442, \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u043b. \u041f\u043e\u0437\u0436\u0435, \u0432\u00a0\u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0435\u043d\u0438\u044f\u0445 \u0441\u0442\u0430\u0442\u044c\u0438, \u043c\u044b \u0441\u0442\u043e\u043b\u043a\u043d\u0435\u043c\u0441\u044f \u0441\u00a0\u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f\u043c\u0438, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043a\u0430\u0436\u0443\u0442 \u043d\u0430\u043c, \u0447\u0442\u043e\u00a0\u0432\u043b\u043e\u0436\u0435\u043d\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0432\u0438\u0434\u0430 \u0432\u00a0PrimeFaces \u0438\u043c\u0435\u0435\u0442 \u0435\u0449\u0435 \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0434\u0430\u043b\u0435\u043a\u043e \u043d\u0435\u00a0\u0432\u0441\u0435 \u0432\u0438\u0434\u044b \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0431\u0443\u0434\u0443\u0442 \u043d\u0430\u00a0\u043d\u0435\u0439 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e. \u041d\u043e\u00a0\u0432\u00a0\u0442\u0430\u043a\u043e\u043c \u0443\u043f\u0440\u043e\u0449\u0435\u043d\u043d\u043e\u043c \u0432\u0438\u0434\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 \u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0441\u00a0\u0434\u0430\u043d\u043d\u044b\u043c\u0438 \u0437\u0434\u0435\u0441\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0431\u0443\u0434\u0435\u0442 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e.<\/p>\n<p>\u0413\u043b\u0430\u0432\u043d\u043e\u0435, \u0447\u0442\u043e\u00a0\u043d\u0443\u0436\u043d\u043e \u0437\u043d\u0430\u0442\u044c \u043e\u00a0\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430 <code>p:dataTable<\/code> \u043d\u0430\u00a0\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435:<\/p>\n<ul>\n<li>\n<p><code>value=\"#{employeeFilterView.employees}\"<\/code>\u00a0\u2014 \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430\u00a0\u043f\u043e\u043b\u0435 \u0431\u0438\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0441\u043f\u0438\u0441\u043e\u043a, \u0438\u0437\u00a0\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b\u0431\u0438\u0440\u0430\u044e\u0442\u0441\u044f \u0441\u0442\u0440\u043e\u043a\u0438 \u0442\u0430\u0431\u043b\u0438\u0446\u044b;<\/p>\n<\/li>\n<li>\n<p><code>emptyMessage=\"No employees found with given criteria\"<\/code>\u00a0\u2014 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432\u00a0\u0441\u043b\u0443\u0447\u0430\u0435, \u0435\u0441\u043b\u0438 \u0441\u043f\u0438\u0441\u043e\u043a \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u043d\u0435\u00a0\u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d;<\/p>\n<\/li>\n<li>\n<p><code>filteredValue=\"#{employeeFilterView.filteredEmployees}\"<\/code>\u00a0\u2014 \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430\u00a0\u043f\u043e\u043b\u0435 \u0431\u0438\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0443\u0436\u0435 \u043e\u0442\u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0441\u043f\u0438\u0441\u043e\u043a, \u043a\u043e\u0433\u0434\u0430 \u0444\u0438\u043b\u044c\u0442\u0440 \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d.<\/p>\n<\/li>\n<\/ul>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043c\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a \u0441\u043f\u0438\u0441\u043a\u0430\/\u0442\u0430\u0431\u043b\u0438\u0446\u044b \u0438 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u043a\u043e\u043b\u043e\u043d\u043a\u0438\/\u043f\u043e\u043b\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u044b. <code>filterBy<\/code> \u0432\u00a0\u043a\u0430\u0436\u0434\u043e\u043c \u043f\u043e\u043b\u0435 \u0438 \u0432\u044b\u0448\u0435 \u0432\u00a0\u0441\u0430\u043c\u043e\u043c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0435 \u043f\u0435\u0440\u0435\u0434\u0430\u0435\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u0432\u00a0\u0444\u0438\u043b\u044c\u0442\u0440, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043c\u044b \u0431\u0443\u0434\u0435\u043c \u043f\u0438\u0441\u0430\u0442\u044c \u0432\u00a0\u0441\u043f\u0435\u0446\u0438\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u043e\u043b\u044f\u0445 \u0434\u043b\u044f\u00a0\u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438. \u0424\u0438\u043b\u044c\u0442\u0440 \u0443\u043c\u043d\u044b\u0439, \u043f\u043e\u043b\u044f \u0444\u0438\u043b\u044c\u0442\u0440\u0443\u044e\u0442\u0441\u044f \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e, \u0442\u043e \u0435\u0441\u0442\u044c \u043c\u043e\u0436\u043d\u043e \u0444\u0438\u043b\u044c\u0442\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u00a0\u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u043c \u043a\u043e\u043b\u043e\u043d\u043a\u0430\u043c \u043e\u0434\u043d\u043e\u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u0441\u043e\u0433\u043b\u0430\u0441\u043d\u043e \u0442\u043e\u0439 \u043b\u043e\u0433\u0438\u043a\u0435, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0432\u044b \u043f\u0440\u043e\u043f\u0438\u0448\u0435\u0442\u0435 \u0432\u00a0\u0431\u0438\u043d\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430. \u0412\u043f\u0440\u043e\u0447\u0435\u043c, \u043e\u0431\u00a0\u044d\u0442\u043e\u043c \u044f \u043d\u0430\u043f\u0438\u0448\u0443 \u0447\u0443\u0442\u044c \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u043d\u0438\u0436\u0435. \u041a\u0440\u043e\u043c\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438, \u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0443 \u043f\u043e\u00a0\u043a\u0430\u0436\u0434\u043e\u043c\u0443 \u043f\u043e\u043b\u044e, \u0434\u043b\u044f\u00a0\u0447\u0435\u0433\u043e \u0441\u043b\u0443\u0436\u0438\u0442 <code>sortBy<\/code>. \u041e\u0447\u0435\u043d\u044c \u0432\u0430\u0436\u043d\u0430 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043f\u043e\u043b\u044f <code>filterMatchMode=\"contains\"<\/code>\u00a0\u2014 \u0441\u00a0\u043d\u0435\u0439 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442, \u043a\u0430\u043a\u00a0\u043f\u043e\u043b\u043d\u043e\u0442\u0435\u043a\u0441\u0442\u043e\u0432\u0430\u044f, \u0441\u00a0\u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c\/\u0443\u0434\u0430\u043b\u0435\u043d\u0438\u0435\u043c \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u043d\u043e\u0432\u043e\u0433\u043e \u0441\u0438\u043c\u0432\u043e\u043b\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432\u044b \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442\u0435 \u0432\u00a0\u043f\u043e\u043b\u0435 \u0444\u0438\u043b\u044c\u0442\u0440\u0430, \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438 \u043c\u043e\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e \u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044f\u0441\u044c \u043a\u0430\u043a\u00a0\u043f\u043e\u00a0\u0432\u0441\u0435\u043c\u0443 \u0441\u043b\u043e\u0432\u0443, \u0442\u0430\u043a \u0438 \u043f\u043e\u00a0\u0435\u0433\u043e \u0447\u0430\u0441\u0442\u0438 \u0438\u043b\u0438\u00a0\u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c \u0441\u0438\u043c\u0432\u043e\u043b\u0430\u043c. \u042d\u0442\u043e \u041d\u0415\u00a0\u0434\u0435\u0444\u043e\u043b\u0442\u043e\u0432\u043e\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0435\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u0442\u044c \u044f\u0432\u043d\u043e. \u0414\u0440\u0443\u0433\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0430 \u0438\u043b\u0438\u00a0\u0434\u0440\u0443\u0433\u0438\u0445 \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0445 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0439\u0442\u0438 \u0432\u00a0\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438<\/p>\n<p><a href=\"https:\/\/primefaces.github.io\/primefaces\/12_0_0\/#\/components\/datatable\"><u>DataTable. DataTable displays data in tabular format<\/u><\/a><\/p>\n<p>\u0412\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u0432 \u0442\u0430\u0431\u043b\u0438\u0446\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b <code>h:outputText<\/code> \u043f\u0440\u043e\u0441\u0442\u043e \u0432\u044b\u0432\u043e\u0434\u044f\u0442 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043b\u0435\u0439 \u0432 \u043a\u0430\u0436\u0434\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b. \u0415\u0441\u043b\u0438 \u043d\u0443\u0436\u043d\u043e \u043e\u0431\u0435\u0440\u043d\u0443\u0442\u044c \u044d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u0432 \u0441\u0441\u044b\u043b\u043a\u0443, \u043e\u0431\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u0435\u043c \u0435\u0433\u043e \u0435\u0449\u0435 \u0438 \u0432 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 <code>h:outputLink<\/code><\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0439\u0434\u0435\u043c \u043a \u0431\u0438\u043d\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430:<\/p>\n<pre><code class=\"java\"> import jakarta.faces.view.ViewScoped; import jakarta.inject.Inject; import lombok.Getter; import lombok.Setter; import org.primefaces.model.FilterMeta; import org.primefaces.util.LangUtils; import org.satel.ressatel.service.EmployeeService; import org.springframework.stereotype.Component;  import java.io.Serializable; import java.util.ArrayList; import java.util.List; import java.util.Locale;  @Component(\"employeeFilterView\") @ViewScoped @Getter @Setter public class EmployeeFilterView implements Serializable {      private List&lt;Employee> employees;     private List&lt;Employee> filteredEmployees;     private List&lt;FilterMeta> filterBy;      private boolean globalFilterOnly;     private final EmployeeService employeeService;      @Inject     public EmployeeFilterView(EmployeeService employeeService) {         this.employeeService = employeeService;         this.init();     }      public void init() {         employees = employeeService.getShortList();         globalFilterOnly = false;         filterBy = new ArrayList&lt;>();     }      public boolean globalFilterFunction(Object value, Object filter, Locale locale) {         String filterText = (filter == null) ? null : filter.toString().trim().toLowerCase();         if (LangUtils.isBlank(filterText)) {             return true;         }          Employee employee = (Employee) value;         return employee.getName().toLowerCase().contains(filterText)                 || employee.getSpecialties().toLowerCase().contains(filterText)                 || employee.getEmployeeDepartment().toLowerCase().contains(filterText)                 || employee.getSkills().toLowerCase().contains(filterText)                 || employee.getArchived().toLowerCase().contains(filterText);     }      public void toggleGlobalFilter() {         setGlobalFilterOnly(!isGlobalFilterOnly());     }  }  <\/code><\/pre>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u044f \u0443\u043f\u043e\u0442\u0440\u0435\u0431\u0438\u043b \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e \u0431\u0438\u043d\u0430 <code>@ViewScoped<\/code> \u0438\u0437 jakarta. Spring \u043a\u043e\u043d\u0442\u0435\u043a\u0441\u0442 \u043f\u0440\u0435\u043a\u0440\u0430\u0441\u043d\u043e \u043f\u043e\u043d\u044f\u043b \u044d\u0442\u043e\u0442 scope \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u0438\u043b \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u044e \u043a \u0431\u0438\u043d\u0443. \u0422\u0443\u0442 \u043d\u0443\u0436\u043d\u043e \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u043e\u0447\u043d\u043e\u0439 \u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0438 \u044d\u0442\u043e\u0433\u043e scope \u0432 Spring \u043d\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u0435\u0442, \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0442\u0430\u043a\u043e\u0433\u043e \u0431\u0438\u043d\u0430 \u0431\u0443\u0434\u0435\u0442 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0434\u043d\u043e\u0439 \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435\u0439 xhtml \u0441 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u043c \u043d\u0430 \u043d\u0435\u0439, \u0442\u043e \u0435\u0441\u0442\u044c \u043e\u0434\u043d\u0438\u043c \u0432\u0438\u0434\u043e\u043c JSF + PrimeFaces. \u041d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u0438\u0448\u0443\u0442 \u043a\u0430\u0441\u0442\u043e\u043c\u043d\u044b\u0435 \u0430\u043d\u0430\u043b\u043e\u0433\u0438 \u0434\u043b\u044f Spring \u0441\u0430\u043c\u0438, \u0435\u0441\u043b\u0438 \u0434\u043b\u044f \u0438\u0445 \u0437\u0430\u0434\u0430\u0447 \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e, \u043a\u0430\u043a \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u043e\u0442 \u0437\u0434\u0435\u0441\u044c:<\/p>\n<p><a href=\"https:\/\/stackoverflow.com\/questions\/13005421\/jsf-view-scope-in-spring\"><u>JSF View scope in Spring<\/u><\/a><\/p>\n<p>\u0415\u0441\u043b\u0438 \u044d\u0442\u043e \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u043e \u0432\u0430\u0448\u0438\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435\u043c, \u0442\u043e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c scope <a class=\"mention\" href=\"\/users\/Request\">@Request<\/a>, <a class=\"mention\" href=\"\/users\/Session\">@Session<\/a> \u0438\u043b\u0438 <a class=\"mention\" href=\"\/users\/GlobalSession\">@GlobalSession<\/a>, \u043a\u0430\u0436\u0434\u044b\u0439 \u0440\u0435\u0448\u0430\u0435\u0442 \u0441\u0430\u043c. \u041d\u043e \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0432\u0438\u0434\u0438\u043c\u043e\u0441\u0442\u0438 <code>@ViewScoped<\/code> \u0438\u0437 jakarta \u043d\u0435 \u043f\u0440\u0438\u0432\u0435\u043b\u0430 \u0443 \u043c\u0435\u043d\u044f \u043d\u0438 \u043a \u043a\u0430\u043a\u0438\u043c \u043d\u0435\u043f\u0440\u0438\u044f\u0442\u043d\u044b\u043c \u044d\u0444\u0444\u0435\u043a\u0442\u0430\u043c, \u044f \u043e\u0441\u0442\u0430\u0432\u0438\u043b \u0435\u0435 \u043a\u0430\u043a \u0435\u0441\u0442\u044c.<\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u044f \u043f\u0440\u0438\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0441\u044c \u0438\u043d\u0436\u0435\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u0432 \u0443\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u043c\u044b\u0445 \u0431\u0438\u043d\u0430\u0445 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0438 <a class=\"mention\" href=\"\/users\/Inject\">@Inject<\/a> \u0438\u0437 jakarta, \u0430 \u0432 \u0441\u0435\u0440\u0432\u0438\u0441\u0430\u0445 \u0441\u0442\u0430\u0432\u043b\u044e scope <code>@ApplicationScoped<\/code> \u0442\u043e\u0436\u0435 \u0438\u0437 jakarta, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e \u0441 \u0430\u043d\u043d\u043e\u0442\u0430\u0446\u0438\u0435\u0439 <code>@Service<\/code> \u0438\u0437 Spring, \u0438 \u0442\u0430\u043a\u0436\u0435 \u043d\u0438\u043a\u0430\u043a\u0438\u0445 \u043d\u0435\u0443\u0434\u043e\u0431\u0441\u0442\u0432 \u044d\u0442\u043e \u043f\u043e\u043a\u0430 \u0447\u0442\u043e \u043d\u0435 \u0432\u044b\u0437\u0432\u0430\u043b\u043e.<\/p>\n<p>\u0412 \u0431\u0438\u043d\u0435 \u043c\u044b \u0432\u0438\u0434\u0438\u043c \u043e\u0431\u0435\u0449\u0430\u043d\u043d\u0443\u044e \u043c\u043d\u043e\u0439 \u0432\u044b\u0448\u0435 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043b\u043e\u0433\u0438\u043a\u0438 \u0444\u0438\u043b\u044c\u0442\u0440\u0430\u0446\u0438\u0438 \u0432 \u043c\u0435\u0442\u043e\u0434\u0435 <code>globalFilterFunction<\/code>, \u043d\u0435 \u0443\u0434\u0438\u0432\u043b\u044f\u0439\u0442\u0435\u0441\u044c, \u0447\u0442\u043e \u044f\u0432\u043d\u043e\u0439 \u0441\u0432\u044f\u0437\u0438 \u043f\u043e\u043b\u044f filterBy \u0441 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0435\u0439 \u0432\u044b \u043d\u0435 \u0432\u0438\u0434\u0438\u0442\u0435 &#8212; \u0432\u0441\u0435 \u0441\u0432\u044f\u0437\u0438<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-344855","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/344855","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=344855"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/344855\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=344855"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=344855"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=344855"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}