| ##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") |
| #if(! $addresses || $addresses.size() == 0) |
| <font color="red">#springMessageText("not.found", "not.found")</font> (<a href="addresses?keyword=*">#springMessageText("show.all", "show.all") </a>) |
| #elseif($keyword && $addresses.size() == 1) |
| <script type="text/javascript"> |
| #if($providerAddresses.contains($addresses.iterator().next())) |
| window.location.href = "addresses/$addresses.iterator().next()/providers"; |
| #else |
| window.location.href = "addresses/$addresses.iterator().next()/consumers"; |
| #end |
| </script> |
| #else |
| <table cellpadding="0" cellspacing="0" class="list list_dubbo" id="table_o"> |
| <tr> |
| <th>#springMessageText("address", "address"): |
| <input type="text" onkeyup="searchTable('table_o', 0, this.value);" |
| onclick="searchTable('table_o', 0, this.value);"/> <img |
| src="$rootContextPath.getURI("images/ico_search.png")" width="12" height="12"/> |
| </th> |
| <th width="100">#springMessageText("role", "role"): <select onchange="searchTable('table_o', 1, this.value);" |
| onclick="searchTable('table_o', 1, this.value);"> |
| <option value="">#springMessageText("all", "all")</option> |
| <option value="#springMessageText("provider", "provider")">#springMessageText("provider", "provider")</option> |
| <option value="#springMessageText("consumer", "consumer")">#springMessageText("consumer", "consumer")</option> |
| </select></th> |
| </tr> |
| #foreach($address in $addresses) |
| <tr> |
| <td> |
| #if($providerAddresses.contains($address)) |
| <a href="addresses/$address/providers">$address</a> |
| #else |
| <a href="addresses/$address/consumers">$address</a> |
| #end |
| </td> |
| <td> |
| #if($providerAddresses.contains($address)) |
| <font color="green">#springMessageText("provider", "provider")</font> |
| #end |
| #if($consumerAddresses.contains($address)) |
| <font color="blue">#springMessageText("consumer", "consumer")</font> |
| #end |
| </td> |
| </tr> |
| #end |
| </table> |
| <div class="page">#springMessageText("page.total", "page.total")$addresses.size()#springMessageText("page.records", "page.records") </div> |
| #end |