-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtabView.xhtml
More file actions
41 lines (35 loc) · 1.58 KB
/
tabView.xhtml
File metadata and controls
41 lines (35 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:p="http://primefaces.org/ui">
<h:head>
<title>Zadanie programistyczne Dawid Krężel</title>
<link href="./css/styles.css" rel="stylesheet" type="text/css" />
</h:head>
<h:body>
<h:form id="form">
<p:outputLabel for="ileZakladek" value="Podaj ile zakładek otworzyć? " style="font-weight:bold" />
<p:inputText id="ileZakladek" value="#{mojBean.ile}" />
<p:commandButton id="start" value="Generuj zakładki" update="tabView" />
<p:growl id="wiadomosc" showDetail="true" />
<p:panel id="tabView" header="Panel zakładek" >
<p:tabView value="#{mojBean.list}" var="listItem" widgetVar="zakladki" >
<p:ajax event="tabChange" listener="#{zakladka.onChange}" />
<p:tab title="#{listItem.id}" >
<h:outputText value="Jestem #{listItem.id} zakładką w kolejności. " />
<p:commandButton value="Zamknij zakładke"
onclick="confirmation.show()" />
</p:tab>
</p:tabView>
</p:panel>
<p:confirmDialog id="wyborButton" message="#{zakladka.aktualneId} ?"
header="Twój wybór" severit="alert" widgetVar="confirmation">
<p:commandButton value="Tak" oncomplete="confirmation.hide()"
onclick="zakladki.remove(zakladki.getActiveIndex())" />
<p:commandButton value="Nie" onclick="confirmation.hide()" />
</p:confirmDialog>
</h:form>
</h:body>
</html>