Skip to content
detail.html 3.56 KiB
Newer Older
Lucie LONG's avatar
Lucie LONG committed
<!--
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
    Copyright 2022-2023 ETSI TeraFlowSDN - TFS OSG (https://tfs.etsi.org/)
Lucie LONG's avatar
Lucie LONG committed
   
    Licensed 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.
   -->
   {% extends 'base.html' %}
   
   {% block content %}
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
    <h1>Link {{ link.name }} ({{ link.link_id.link_uuid.uuid }})</h1>
Lucie LONG's avatar
Lucie LONG committed
    <div class="row mb-3">
          <div class="col-sm-3">
               <button type="button" class="btn btn-success" onclick="window.location.href='{{ url_for('link.home') }}'">
                    <i class="bi bi-box-arrow-in-left"></i>
                    Back to link list
               </button>
          </div>
     </div>

     <br>
       <div class="row mb-3">
            <div class="col-sm-4">
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
               <b>UUID: </b>{{ link.link_id.link_uuid.uuid }}<br>
               <b>Name: </b>{{ link.name }}<br>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
           </div>
Lucie LONG's avatar
Lucie LONG committed
            <div class="col-sm-8">
                    <table class="table table-striped table-hover">
                        <thead>
                            <tr>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                                <th scope="col">Endpoint UUID</th>
Lucie LONG's avatar
Lucie LONG committed
                                <th scope="col">Device</th>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                                <th scope="col">Endpoint Type</th>
Lucie LONG's avatar
Lucie LONG committed
                            </tr>
                        </thead>
                        <tbody>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                              {% for endpoint in link.link_endpoint_ids %}
Lucie LONG's avatar
Lucie LONG committed
                              <tr>
                                   <td>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                                        {{ endpoints_data.get(endpoint.endpoint_uuid.uuid, (endpoint.endpoint_uuid.uuid, ''))[0] }}
Lucie LONG's avatar
Lucie LONG committed
                                   </td>
                                   <td>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                                        <a href="{{ url_for('device.detail', device_uuid=endpoint.device_id.device_uuid.uuid) }}">
                                             {{ device_names.get(endpoint.device_id.device_uuid.uuid, endpoint.device_id.device_uuid.uuid) }}
Lucie LONG's avatar
Lucie LONG committed
                                             <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="currentColor" class="bi bi-eye" viewBox="0 0 16 16">
                                                 <path d="M16 8s-3-5.5-8-5.5S0 8 0 8s3 5.5 8 5.5S16 8 16 8zM1.173 8a13.133 13.133 0 0 1 1.66-2.043C4.12 4.668 5.88 3.5 8 3.5c2.12 0 3.879 1.168 5.168 2.457A13.133 13.133 0 0 1 14.828 8c-.058.087-.122.183-.195.288-.335.48-.83 1.12-1.465 1.755C11.879 11.332 10.119 12.5 8 12.5c-2.12 0-3.879-1.168-5.168-2.457A13.134 13.134 0 0 1 1.172 8z"/>
                                                 <path d="M8 5.5a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5zM4.5 8a3.5 3.5 0 1 1 7 0 3.5 3.5 0 0 1-7 0z"/>
                                             </svg>
                                        </a>
Lucie LONG's avatar
Lucie LONG committed
                                   </td>
Lluis Gifre Renom's avatar
Lluis Gifre Renom committed
                                   <td>
                                        {{ endpoints_data.get(endpoint.endpoint_uuid.uuid, ('', '-'))[1] }}
                                   </td>
Lucie LONG's avatar
Lucie LONG committed
                              </tr>
                              {% endfor %}
                        </tbody>
                    </table>
            </div>
        </div>

   {% endblock %}