04c9380367c0e75a706c5869a2fc255b52adbc47.svn-base
7.52 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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
<title>层信息管理</title>
<meta name="decorator" content="default"/>
<script type="text/javascript">
$(document).ready(function() {
});
function page(n,s){
$("#pageNo").val(n);
$("#pageSize").val(s);
$("#searchForm").submit();
return false;
}
function gobackz(){
var url = "${ctx}/reg/base/regBaseZrz/list?repage&XMID=${XMID}&DZ=${DZ}";
window.location = url;
}
function auditC(id, zid){
if(confirm('审核后数据将正式生效,并且不能删除和修改。确认要审核该信息吗?')){
url = "${ctx}/reg/base/regBaseC/audit?id="+id+"&ZID="+zid+"&DZ=${DZ}";
window.location.href=url;
}
}
function unauditC(id, zid){
$.ajax({
type:"POST",
url:"${ctx}/reg/base/regBaseZrz/isnounaudit",
cache: false,
data:"id="+id+"&bj=2&zid="+zid,
async : false,
success:function(modelmap){
if(modelmap.success == 0){
if(confirm('反审核后数据恢复可删除和修改。确认要反审核该信息吗?')){
url = "${ctx}/reg/base/regBaseC/unaudit?id="+id+"&ZID="+zid+"&DZ=${DZ}";
window.location.href=url;
}
}else{
alert(modelmap.msg);
return;
}
}
});
}
function batAuditC(){
if(confirm('批量审核当前幢包含所有层后,数据将正式生效,并且不能删除和修改。确认要审核该信息吗?')){
url = "${ctx}/reg/base/regBaseC/batAudit?ZID=${ZID}&DZ=${DZ}";
window.location.href=url;
}
}
function deleteclink(id, zid){
if(confirm('确认后,将会删除该层以及层下的所有户信息,确定删除吗?')){
//先发送ajax请求看当前项目下有没有已经引用的户信息
$.ajax({
type:"POST",
url:"${ctx}/reg/base/regBaseC/isdelete",
cache: false,
data:"id="+id,
async : false,
success:function(modelmap){
var isdelete = modelmap.data;
var bj = modelmap.bj;
if(isdelete == "1"){ //不可以删除,其中有已被引用的户信息
alert("当前层不可以删除,其下属有已被引用的户信息!");
return;
}else if(bj == "1"){
alert("请从最高层删除 !");
return;
}else{
url = "${ctx}/reg/base/regBaseC/delete?id="+id+"&ZID="+zid+"&DZ=${DZ}";
window.location.href=url;
}
}
});
}
}
function cQuery(){
$(".cerror").remove();
var sjc = $("#sjctext").attr("value");
document.searchForm.action = "${ctx}/reg/base/regBaseC/list?&DZ=${DZ}";
if($("#zddmtext").val() == ""){
$("<span class='cerror'>实际层必须填写为整数!</span>").insertAfter("#sjctext");
return;
}
if(!isInteger(sjc)){
return;
}
document.searchForm.submit();
}
//整数
function isInteger(Code){
var reg = /^-?[0-9]\d*$/;
if(reg.test(Code) === false){
$(".cerror").remove();
$("<span class='cerror'>实际层必须填写为整数!</span>").insertAfter("#sjctext");
return false;
}else{
return true;
}
}
</script>
</head>
<body>
<ul class="nav nav-tabs">
<li class="active"><a href="${ctx}/reg/base/regBaseC/list?ZID=${ZID}&DZ=${DZ}">层信息列表</a></li>
<!--<shiro:hasPermission name="reg:base:regBaseC:edit"><li><a href="${ctx}/reg/base/regBaseC/form?ZID=${ZID}&XMID=${XMID}&DZ=${DZ}">层信息添加</a></li></shiro:hasPermission>-->
</ul>
<form:form id="searchForm" name="searchForm" modelAttribute="regBaseC" action="${ctx}/reg/base/regBaseC/list?&DZ=${DZ}" method="post" class="breadcrumb form-search">
<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
<input id="zid" name="ZID" type="hidden" value="${ZID}" />
<ul class="ul-form">
<li><label>实际层:</label>
<form:input path="sjc" id="sjctext" htmlEscape="false" maxlength="20" class="input-mini"/>
</li>
<li class="btns"><input id="btnSubmit" class="btn btn-primary" type="button" onclick="cQuery()" value="查询"/></li>
<li class="btns"><input id="btnCancel" class="btn" type="button" value="返回幢" onclick="gobackz()"/></li>
<li class="btns"><input id="btnBatAduit" class="btn btn-primary" type="button" value="层批量审核" onclick="batAuditC();"/></li>
<li class="clearfix"></li>
</ul>
</form:form>
<div class="current_fwinfo">当前项目【${XMMC}】,建筑物【${JZWMC}】,一共包含【${cCount}】层</div>
<sys:message content="${message}"/>
<table id="contentTable" class="table table-striped table-bordered table-condensed">
<thead>
<tr>
<th>层号</th>
<th>自然幢号</th>
<th>实际层</th>
<th>层建筑面积</th>
<th>层阳台面积</th>
<%--
<th>层套内建筑面积</th>
<th>层共有建筑面积</th>
<th>层分摊建筑面积</th>
<th>层半墙面积</th>
--%>
<th>层高</th>
<th>水平投影面积</th>
<shiro:hasPermission name="reg:base:regBaseC:edit"><th>操作</th></shiro:hasPermission>
</tr>
</thead>
<tbody>
<c:forEach items="${page.list}" var="regBaseC">
<tr>
<td>
<!--
<c:if test="${regBaseC.isnegativelayer eq '0'}">
<a href="${ctx}/reg/base/regBaseC/form?id=${regBaseC.id}&VIEWS=1">
${regBaseC.ch}
</a>
</c:if>
<c:if test="${regBaseC.isnegativelayer eq '1'}">
<a href="${ctx}/reg/base/regBaseC/form?id=${regBaseC.id}&VIEWS=1">
-${regBaseC.ch}
</a>
</c:if>
-->
<a href="${ctx}/reg/base/regBaseC/form?id=${regBaseC.id}&VIEWS=1&ZID=${ZID}&xg=1&DZ=${DZ}">
${regBaseC.ch}
</a>
</td>
<td>
${regBaseC.zrzh}#
</td>
<td>
${regBaseC.sjc}
</td>
<td>
${regBaseC.cjzmj}
</td>
<td>
${regBaseC.cytmj}
</td>
<%--
<td>
${regBaseC.ctnjzmj}
</td>
<td>
${regBaseC.cgyjzmj}
</td>
<td>
${regBaseC.cftjzmj}
</td>
<td>
${regBaseC.cbqmj}
</td>
--%>
<td>
${regBaseC.cg}
</td>
<td>
${regBaseC.sptymj}
</td>
<shiro:hasPermission name="reg:base:regBaseC:edit">
<td>
<c:if test="${regBaseC.isaudit ne '2'}">
<c:if test="${regBaseC.isaudit eq '0'}">
<!--<a href="#" onclick="auditC('${regBaseC.id}', '${ZID}');">审核</a>
<a href="${ctx}/reg/base/regBaseC/form?id=${regBaseC.id}&ZID=${ZID}&xg=1&DZ=${DZ}">修改</a>
<a href="#" onclick="deleteclink('${regBaseC.id}', '${ZID}')">删除</a>-->
</c:if>
<c:if test="${regBaseC.isaudit eq '1'}">
<a href="${ctx}/reg/base/regBaseH/list?CID=${regBaseC.id}&XMMC=${XMMC}&ZID=${ZID}&XMID=${XMID}&DZ=${DZ}">户信息</a>
<!--<a href="#" onclick="unauditC('${regBaseC.id}', '${ZID}');">反审核</a>-->
</c:if>
<c:if test="${regBaseC.isaudit ne '0' and regBaseC.isaudit ne '1'}">
<!--<a href="#" onclick="auditC('${regBaseC.id}', '${ZID}');">审核</a>
<a href="${ctx}/reg/base/regBaseC/form?id=${regBaseC.id}&ZID=${ZID}&xg=1&DZ=${DZ}">修改</a>
<a href="#" onclick="deleteclink('${regBaseC.id}', '${ZID}')">删除</a>-->
</c:if>
</c:if>
<c:if test="${regBaseC.isaudit eq '2'}">
<a href="${ctx}/reg/base/regBaseH/list?CID=${regBaseC.id}&XMMC=${XMMC}&ZID=${ZID}&XMID=${XMID}&DZ=${DZ}">户信息</a>
<a href="#">已引用</a>
</c:if>
</td>
</shiro:hasPermission>
</tr>
</c:forEach>
</tbody>
</table>
<div class="pagination">${page}</div>
</body>
</html>