blob: 2bed7ffe36746e506f86197d54165db51a6a9718 [file] [log] [blame]
##Licensed to the Apache Software Foundation (ASF) under one or more
##contributor license agreements. See the NOTICE file distributed with
##this work for additional information regarding copyright ownership.
##The ASF licenses this file to You under the Apache License, Version 2.0
##(the "License"); you may not use this file except in compliance with
##the License. You may obtain a copy of the License at
##
##http://www.apache.org/licenses/LICENSE-2.0
##
##Unless required by applicable law or agreed to in writing, software
##distributed under the License is distributed on an "AS IS" BASIS,
##WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
##See the License for the specific language governing permissions and
##limitations under the License.
#set($layout = "/templates/governance/layout/default.vm")
<div class="ico_btn">
#if($currentUser.role != "G")
<a href="routes/add"><img src="$rootContextPath.getURI("images/ico_add.png")" width="12" height="12"/><span
class="ico_font">#springMessageText("add", "add")</span></a>
<span class="ico_line">|</span>
<a href="#" onclick="if(! hasCheckbox('ids')) { showAlert('#springMessageText(
"empty.list","empty.list")'); } else if(! hasChecked('ids')) { showAlert('#springMessageText(
"please.select","please.select")'); } else { showConfirm('#springMessageText(
"confirm.batch.delete","confirm.batch.delete")', 'routes/' + getChecked('ids') + '/delete'); } return false;"><img
src="$rootContextPath.getURI("images/ico_delete.png")" width="12" height="12"/><span
class="ico_font">#springMessageText("batch.delete", "batch.delete")</span></a>
<span class="ico_line">|</span>
<a href="#" onclick="if(! hasCheckbox('ids')) { showAlert('#springMessageText(
"empty.list","empty.list")'); } else if(! hasChecked('ids')) { showAlert('#springMessageText(
"please.select","please.select")'); } else { showConfirm('#springMessageText(
"confirm.batch.enable","confirm.batch.enable")', 'routes/' + getChecked('ids') + '/enable');} return false;"><img
src="$rootContextPath.getURI("images/ico_enable.png")" width="12" height="12"/><span
class="ico_font">#springMessageText("batch.enable", "batch.enable")</span></a>
<span class="ico_line">|</span>
<a href="#" onclick="if(! hasCheckbox('ids')) { showAlert('#springMessageText(
"empty.list","empty.list")'); } else if(! hasChecked('ids')) { showAlert('#springMessageText(
"please.select","please.select")'); } else { showConfirm('#springMessageText(
"confirm.batch.disable","confirm.batch.delete")', 'routes/' + getChecked('ids') + '/disable');} return false;"><img
src="$rootContextPath.getURI("images/ico_disable.png")" width="12" height="12"/><span
class="ico_font">#springMessageText("batch.disable", "batch.disable")</span></a>
#end
</div>
<br/>
<table cellpadding="0" cellspacing="0" class="list list_dubbo" id="table_o">
<tr>
<th width="20"><input type="checkbox" onclick="checkAll('table_o', 'ids', this.checked)"/></th>
<th>#springMessageText("route.name", "route.name"): <input type="text" onkeyup="searchTable('table_o', 1, this.value);"
onclick="searchTable('table_o', 1, this.value);"/>&nbsp;<img
src="$rootContextPath.getURI("images/ico_search.png")" width="12" height="12"/></th>
#if(!$service)
<th>#springMessageText("ServiceName", "ServiceName"): <input type="text" onkeyup="searchTable('table_o', 2, this.value);"
onclick="searchTable('table_o', 2, this.value);"/>&nbsp;<img
src="$rootContextPath.getURI("images/ico_search.png")" width="12" height="12"/></th>
<th width="50">#springMessageText("Priority", "Priority")</th>
<th width="100">#springMessageText("status", "status"): <select onchange="searchTable('table_o', 4, this.value);"
onclick="searchTable('table_o', 4, this.value);">
<option value="">#springMessageText("all", "all")</option>
<option value="#springMessageText("enabled", "enabled")">#springMessageText("enabled", "enabled")</option>
<option value="#springMessageText("disabled", "disabled")">#springMessageText("disabled", "disabled")</option>
</select></th>
#else
<th width="50">#springMessageText("Priority", "Priority")</th>
<th width="100">#springMessageText("status", "status"): <select onchange="searchTable('table_o', 3, this.value);"
onclick="searchTable('table_o', 3, this.value);">
<option value="">#springMessageText("all", "all")</option>
<option value="#springMessageText("enabled", "enabled")">#springMessageText("enabled", "enabled")</option>
<option value="#springMessageText("disabled", "disabled")">#springMessageText("disabled", "disabled")</option>
</select></th>
#end
<th width="340">#springMessageText("operation", "operation")</th>
</tr>
#foreach($route in $routes)
<tr>
<td><input type="checkbox" name="ids" value="$route.id"/></td>
<td><a href="routes/$route.id">$route.name</a></td>
#if(!$service)
<td><a href="services/$route.service/routes">$route.service</a></td>
#end
<td>$route.priority</td>
<td>
#if($route.enabled)
<font color="green">#springMessageText("enabled", "enabled")</font>
#else
<font color="red">#springMessageText("disabled", "disabled")</font>
#end
</td>
<td>
<a href="routes/$route.id/routeselect"><img src="$rootContextPath.getURI("images/ico_show.png")"
width="12" height="12"/><span class="ico_font">#springMessageText(
"proview","proview")</span></a>
#if($currentUser.role != "G")
<span class="ico_line">|</span>
<a href="routes/$route.id/edit"><img src="$rootContextPath.getURI("images/ico_edit.png")" width="12"
height="12"/><span class="ico_font">#springMessageText(
"edit","edit")</span></a>
<span class="ico_line">|</span>
<a href="routes/$route.id/edit?actionflag=copy"><img
src="$rootContextPath.getURI("images/ico_register.png")" width="12" height="12"/><span
class="ico_font">#springMessageText("copy", "copy")</span></a>
<span class="ico_line">|</span>
#if($route.enabled)
<a href="#" onclick="showConfirm('#springMessageText(
"confirm.disable","confirm.disable")', '$route.name', 'routes/$route.id/disable'); return false;">
<img src="$rootContextPath.getURI("images/ico_disable.png")" width="13" height="13"/>
<span class="ico_font">#springMessageText("disable", "disable")</span></a>
#else
<a href="#" onclick="showConfirm('#springMessageText(
"confirm.enable","confirm.enable")', '$route.name', 'routes/$route.id/enable'); return false;">
<img src="$rootContextPath.getURI("images/ico_enable.png")" width="13" height="13"/>
<span class="ico_font">#springMessageText("enable", "enable")</span></a>
#end
<span class="ico_line">|</span>
<a href="#" onclick="showConfirm('#springMessageText(
"confirm.delete","confirm.delete")', '$route.name', 'routes/$route.id/delete'); return false;">
<img src="$rootContextPath.getURI("images/ico_delete.png")" width="12" height="12"/>
<span class="ico_font">#springMessageText("delete", "delete")</span></a>
#end
</td>
</tr>
#end
</table>
<div class="page">#springMessageText("page.total", "page.total")$routes.size()#springMessageText("page.records", "page.records") </div>