Skip to content

Commit ef50985

Browse files
[fix]imanagerNodeManager例子样式修改 review by songym
1 parent 3e3f281 commit ef50985

File tree

1 file changed

+19
-6
lines changed

1 file changed

+19
-6
lines changed

examples/leaflet/iManagerNodeManager.html

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,18 @@
1212
margin-bottom: 0;
1313
}
1414

15+
#listTable {
16+
margin: 0 auto;
17+
border: 1px solid #cfcfcf;
18+
border-radius: 4px;
19+
border-collapse: collapse;
20+
border-style:hidden;
21+
box-shadow: 0 0 0 1px #cfcfcf;
22+
}
23+
1524
#listTable th, #listTable td {
1625
padding: 5px;
26+
border: 1px solid #cfcfcf;
1727
}
1828
</style>
1929
</head>
@@ -86,13 +96,13 @@ <h4 data-i18n="resources.title_nodeManagementUseExample"></h4>
8696
<table id="listTable">
8797
<thead>
8898
<tr role="row">
89-
<th rowspan="1" colspan="1" style="width: 50px;">
99+
<th rowspan="1" colspan="1" style="width: 80px;">
90100
<div><span>id</span></div>
91101
</th>
92-
<th rowspan="1" colspan="1" style="width: 150px;">
102+
<th rowspan="1" colspan="1" style="width: 200px;">
93103
<div><span data-i18n="resources.text_name"></span></div>
94104
</th>
95-
<th rowspan="1" colspan="1" style="width: 150px;">
105+
<th rowspan="1" colspan="1" style="width: 220px;">
96106
<div><span data-i18n="resources.text_address"></span></div>
97107
</th>
98108
</tr>
@@ -239,15 +249,18 @@ <h4 data-i18n="resources.title_nodeManagementUseExample"></h4>
239249
.then(function (response) {
240250
console.log(JSON.stringify(response));
241251
var result = response;
252+
var html = "";
242253
if (result.list) {
243-
var html = "";
244254
for (var i = 0; i < result.list.length; i++) {
245255
var obj = result.list[i];
246256
var address = obj.productInfos ? obj.productInfos[0].address : "";
247-
html += "<tr role='row'><td>" + obj.id + "</td><td>" + obj.nodeName + "</td><td><a href='" + address + "' target='_blank'>" + address + "</a></td><td></tr>";
257+
html += "<tr role='row'><td>" + obj.id + "</td><td>" + obj.nodeName + "</td><td><a href='" + address + "' target='_blank'>" + address + "</a></td></tr>";
248258
}
249-
$("#nodeList").html(html);
259+
260+
} else {
261+
html += "<tr role='row'><td></td><td></td><td></td></tr>";
250262
}
263+
$("#nodeList").html(html);
251264
});
252265
}
253266

0 commit comments

Comments
 (0)