source: ether_megapoli/trunk/web/data/access/capt.jsp @ 161

Last change on this file since 161 was 161, checked in by vmipsl, 13 years ago

Import medias files and cleanup

File size: 4.3 KB
Line 
1<%@ page import="com.medias.Context" contentType="text/html; charset=UTF-8"%>
2<%@ page import="com.medias.Calcul"%>
3<%@ page import="java.util.ArrayList"%>
4<%@ page language="java" contentType="text/html; charset=UTF-8"%>
5<%@ taglib uri="/WEB-INF/tlds/struts-tiles.tld" prefix="tiles"%>
6<%@ taglib uri="/WEB-INF/tlds/struts-html.tld" prefix="html"%>
7<%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean"%>
8<%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic"%>
9<%@ taglib uri="/WEB-INF/tlds/struts-nested.tld" prefix="nested"%>
10
11<tiles:insert page="/resources/templates/template.jsp" flush="true">
12
13        <bean:define type="java.lang.String" id="relativePath" value="<%=Context.getRelativePath(request)%>"/>
14
15        <tiles:put name="nav" value='<%=relativePath+"/navCapts.jsp"%>'/>
16
17        <tiles:put name="title" type="string">
18                <bean:message key="app.title"/> - <bean:message key="data.access.capt"/>
19        </tiles:put>
20
21        <tiles:put name="bodytitle" type="string">
22                <bean:message key="data.access.capt"/>
23        </tiles:put>
24
25        <tiles:put name="body" type="string">
26               
27                <div id="errors"><html:errors/></div>
28                <div id="messages">
29                        <html:messages id="mess" property="<%= org.apache.struts.action.ActionMessages.GLOBAL_MESSAGE %>" message="true">
30                                <bean:write name="mess"/>
31                        </html:messages>
32                </div>
33               
34                <%--div class="submit">
35                        <html:link page="/data/access/access.jsp"><bean:message key="data.access"/></html:link>
36                </div--%>
37               
38                <nested:root name="capteursForm">
39                <table>
40                        <tr><th/>
41                                <%--nested:define id="b_capteurs" property="capteurs"/>
42                                <bean:define type="java.lang.String" id="nbCapteurs" value="<%=(new Integer(((ArrayList)b_capteurs).size())).toString()%>"/--%>
43                                <nested:size id="nbCapteurs" property="capteurs"/>
44                                <bean:write name="nbCapteurs"/>
45                                <logic:equal name="nbCapteurs" value="1">
46                                        <bean:message key="data.access.capt2" arg0=""/>
47                                </logic:equal>
48                                <logic:notEqual name="nbCapteurs" value="1">
49                                        <bean:message key="data.access.capt2" arg0="s"/>
50                                </logic:notEqual>
51                        </th></tr>
52                        <bean:define id="nomTypePrec" value=""/>
53                        <nested:iterate property="capteurs" indexId="captId">
54                                <nested:nest property="typeCapteur">
55                                        <nested:define id="nomType" property="typeCapteurNom"/>
56                                </nested:nest>
57                                <tr><td>
58                                        <nested:notEqual name="nomType" value="${nomTypePrec}">
59                                                <div id="messages"><bean:write name="nomType"/>&nbsp;:</div>
60                                        </nested:notEqual>
61                                        <bean:define type="java.lang.String" id="parite" value="<%=Calcul.getParite(captId.intValue())%>"/>
62                                        <logic:equal name="parite" value="pair"><bean:define id="idP" value="pair"/></logic:equal>
63                                        <logic:equal name="parite" value="impair"><bean:define id="idP" value="impair"/></logic:equal>
64                                        <table class="${idP}" style="margin-left: 20px">
65                                                <tr>
66                                                        <td nowrap>
67                                                                <nested:define id="id" property="capteurId"/>
68                                                                <html:link page="/DescCapteur.do" titleKey="data.access.capt4" paramName="id" paramId="idCapt">
69                                                                        <nested:notEqual property="capteurModele" value="UNKNOWN">
70                                                                                <nested:write property="capteurModele"/>
71                                                                                <nested:notEqual property="fabriquant.fabriquantNom" value="UNKNOWN">
72                                                                                        - <nested:write property="fabriquant.fabriquantNom"/>
73                                                                                </nested:notEqual>
74                                                                        </nested:notEqual>
75                                                                        <nested:equal property="capteurModele" value="UNKNOWN">
76                                                                                <nested:notEqual property="fabriquant.fabriquantNom" value="UNKNOWN">
77                                                                                        <nested:write property="fabriquant.fabriquantNom"/>
78                                                                                </nested:notEqual>
79                                                                                <nested:equal property="fabriquant.fabriquantNom" value="UNKNOWN">
80                                                                                        Unknown
81                                                                                </nested:equal>
82                                                                        </nested:equal>
83                                                                        <nested:notEqual property="capteurNumserie" value="UNKNOWN">
84                                                                                (<bean:message key="data.access.capt.nums"/>&nbsp;:&nbsp;<nested:write property="capteurNumserie"/>)
85                                                                        </nested:notEqual>
86                                                                </html:link>
87                                                        </td>
88                                                </tr>
89                                        </table>
90                                        <bean:define id="nomTypePrec" value="${nomType}"/>
91                                </td></tr>
92                        </nested:iterate>
93                </table>
94                </nested:root>
95       
96                <div class="hdp" align="right">
97                        <html:link page="/data/access/capt.jsp" anchor="top" titleKey="app.hdp">
98                                <html:img page="/images/utils/hdp1.png"/>
99                        </html:link>
100                </div>
101                       
102                <%--div class="submit">
103                        <html:link page="/data/access/access.jsp"><bean:message key="data.access"/></html:link>
104                </div--%>
105        </tiles:put>
106</tiles:insert>
Note: See TracBrowser for help on using the repository browser.