Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0" encoding="UTF-8"?>
- <!DOCTYPE html>
- <html xmlns="http://www.w3.org/1999/xhtml"
- xmlns:ui="http://java.sun.com/jsf/facelets"
- xmlns:f="http://java.sun.com/jsf/core"
- xmlns:h="http://java.sun.com/jsf/html"
- xmlns:p="http://primefaces.org/ui">
- <ui:composition template="../../partials/main.xhtml">
- <ui:define name="banner"></ui:define>
- <ui:define name="content">
- <div id="main">
- <section>
- <div class="inner">
- <h3>Lista Albumów</h3>
- <div class="inner">
- <hr />
- <h:form id="form">
- <p:growl id="msgs" showDetail="false" closeable="true"
- life="2000" />
- <div class="table-wrapper">
- <p:dataTable id="plyta" var="p" rows="5"
- value="#{plytaListBB.list}" editable="true"
- paginator="true"
- paginatorTemplate="{CurrentPageReport} {PageLinks}"
- rowsPerPageTemplate="5,10,15">
- <p:column headerText="Tytuł" >
- <h:outputText value="#{p.tytul}" />
- </p:column>
- <p:column headerText="Gatunek" >
- <h:outputText value="#{p.gatunek.nazwaGatunku}" />
- </p:column>
- <p:column headerText="Autor" >
- <h:outputText value="#{p.autor.nazwaAutora}" />
- </p:column>
- <p:column>
- <f:facet name="header">
- <h:outputText value="Edytuj" />
- </f:facet>
- <p:commandButton value = "Edytuj" class = "button fit small"
- action="#{plytaListBB.edit(p)}"
- />
- </p:column>
- <p:column>
- <f:facet name="header">
- <h:outputText value="Usuń" />
- </f:facet>
- <p:commandButton value="Usuń" class="button fit small"
- action="#{plytaListBB.deletePlyta(p)}"
- update=":form:msgs plyta" />
- </p:column>
- <p:column>
- <f:facet name="header">
- <h:outputText value="Dodaj do listy" />
- </f:facet>
- <p:commandButton value = "Dodaj do mojej listy" class = "button fit small"
- action="#{plytaListBB.addToUser(p)}"
- />
- </p:column>
- </p:dataTable>
- </div>
- <hr />
- </h:form>
- </div>
- </div>
- </section>
- </div>
- </ui:define>
- </ui:composition>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement