{% include "partials/header.html.j2" %}
<section class="bg-center bg-no-repeat text-gray-800 dark:text-gray-200 bg-gray-300 dark:bg-gray-700 bg-blend-multiply">
    <div class="flex justify-between items-center px-4 mx-auto py-4 lg:py-5">
        {%if user and user.name != "" %}
        <h1 class="mt-2 mx-5 mb-4 text-3xl font-extrabold tracking-tight leading-none tex-gray-700 dark:text-gray-300  md:text-4xl lg:text-5xl">
            <div class="flex">Logs : 
                <button 
                    type="button" 
                    class="ml-4 flex space-x-2 px-2 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-500" 
                    data-popover-target="popover-{{user.name}}-profile" data-popover-placement="bottom" 
                    onclick="edit_usr('{{user.id}}')"
                >
                    <span class="ml-4 text-indigo-500 text-4xl">{{user.name}} <span class="ml-5 text-3xl text-gray-500">id: {{user.id}}</span></span>
                </button>
            </div> 
        </h1>
        <div data-popover id="popover-{{user.name}}-profile" role="tooltip" class="absolute z-10 invisible inline-block w-64 text-sm text-gray-500 transition-opacity duration-300 bg-white border border-gray-200 rounded-lg shadow-sm opacity-0 dark:text-gray-400 dark:bg-gray-800 dark:border-gray-600">
            <div class="p-3 flex flex-col items-center space-y-3">
                <p class="text-base font-semibold leading-none text-gray-900 dark:text-white">
                    {{user.fullname}}
                </p>
                <p class="text-base font-semibold leading-none text-gray-900 dark:text-white">
                    {{user.email}}
                </p>
                <p class="mb-3 text-sm font-normal">
                    {{user.description}}
                </p>
                <div id="toast-{{user.name}}" class="flex items-center w-full max-w-xs p-4 space-x-4 text-gray-500 bg-white divide-x divide-gray-200 rounded-lg shadow dark:text-gray-400 dark:divide-gray-700 space-x dark:bg-gray-800" role="alert">
                    <svg aria-hidden="true" class="w-5 h-5 text-blue-600 dark:text-blue-500" focusable="false"><use href="#symbl-edit" /></svg>
                    <div class="pl-4 text-sm font-normal">Click to Edit</div>
                </div>
            </div>
            <div data-popper-arrow></div>
        </div>
        {% else %}
        <h1 class="mt-2 mx-5 mb-4 text-3xl font-extrabold tracking-tight leading-none tex-gray-700 dark:text-gray-300  md:text-4xl lg:text-5xl">
            <div>Logs </div> 
        </h1>
        {% endif %}
        <div class="mx-8"><span id="count-select" class="p-2 text-gray-700 dark:text-gray-300"></span>{{total_logs | default(value="") }} items</div>
</section>
<section class="bg-white dark:bg-gray-900 pt-0 px-2 lg:px-5">
    <div class="relative min-h-200 overflow-x-auto overflow-y-hidden shadow-md sm:rounded-lg">
        <div class="flex flex-col md:flex-row items-center justify-center space-y-3  md:justify-between py-4 bg-white dark:bg-gray-800">
            <div>
                <button id="dropdown-action-button" data-dropdown-toggle="dropdown-action" class="ml-2 inline-flex items-center text-gray-500 bg-white border border-gray-300 focus:outline-none hover:bg-gray-100 focus:ring-4 focus:ring-gray-200 font-medium rounded-lg text-sm px-3 py-1.5 dark:bg-gray-800 dark:text-gray-400 dark:border-gray-600 dark:hover:bg-gray-700 dark:hover:border-gray-600 dark:focus:ring-gray-700" type="button">
                    <span class="sr-only">Action button</span>
                    Action
                    <svg class="w-3 h-3 ml-2" aria-hidden="true" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>
                </button>
                <!-- Dropdown menu -->
                <div id="dropdown-action" class="z-10 hidden bg-white divide-y divide-gray-100 rounded-lg shadow w-44 dark:bg-gray-700 dark:divide-gray-600">
                    <ul class="py-1 text-sm text-gray-700 dark:text-gray-200" aria-labelledby="dropdown-action-button">
                        <li>
                            <button  class="block px-4 py-2 hover:bg-gray-100 dark:hover:bg-gray-600 dark:hover:text-white" onclick="on_log_delete('{{user.id}}')">Delete</button>
                        </li>
                    </ul>
                    <div class="py-1 hidden">
                        <button class="block px-4 py-2 hover:bg-gray-400 dark:hover:bg-gray-500 dark:text-gray-700 dark:hover:text-gray-100" onclick="clean_log('{{user.id}}')">Delete content</button>
                    </div>
                </div>
            </div>
            <button class="max-w-38 relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden text-sm font-medium text-gray-900 rounded-lg group bg-gradient-to-br from-pink-500 to-orange-400 group-hover:from-pink-500 group-hover:to-orange-400 hover:text-white dark:text-white focus:ring-4 focus:outline-none focus:ring-pink-200 dark:focus:ring-pink-800"
                type="button" onclick="clean_log('{{user.id}}')"
            >
               <span class="flex items-center space-x-2 px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0">
                    <svg class="w-6 h-6"><use href="#symbl-trash" /></svg>
                    <span class="text-sm"> Clean all</span>
               </span>
            </button>
            {% if user and user.name != '' %}
            <a href="/logs" class=" relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden text-sm font-medium text-gray-900 rounded-lg group bg-gradient-to-br from-purple-600 to-blue-500 group-hover:from-purple-600 group-hover:to-blue-500 hover:text-white dark:text-white focus:ring-4 focus:outline-none focus:ring-blue-300 dark:focus:ring-blue-800">
                <span class="relative px-2 py-1 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0">
                   <img src="/assets/images/log.svg" width="40em"> 
                </span>
            </a>
            {% endif %}
            <a href="/signup" class="max-w-32 relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden text-sm font-medium text-gray-900 rounded-lg group bg-gradient-to-br from-purple-600 to-blue-500 group-hover:from-purple-600 group-hover:to-blue-500 hover:text-white dark:text-white focus:ring-4 focus:outline-none focus:ring-blue-300 dark:focus:ring-blue-800">
                <span class="relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0">
                   New Signup 
                </span>
            </a>
            {% if signup_mode != "open" %} 
            <a href="/invite" class="max-w-38 relative inline-flex items-center justify-center p-0.5 mb-2 mr-2 overflow-hidden text-sm font-medium text-gray-900 rounded-lg group bg-gradient-to-br from-pink-500 to-orange-400 group-hover:from-pink-500 group-hover:to-orange-400 hover:text-white dark:text-white focus:ring-4 focus:outline-none focus:ring-pink-200 dark:focus:ring-pink-800">
                <span class="relative px-5 py-2.5 transition-all ease-in duration-75 bg-white dark:bg-gray-900 rounded-md group-hover:bg-opacity-0">
                    Invite new User
                </span>
            </a>
            {% endif %}
            <label for="table-search" class="sr-only">Search</label>
            <div class="relative">
                <div class="absolute inset-y-0 left-0 flex items-center pl-3 pointer-events-none">
                    <svg class="w-5 h-5 text-gray-500 dark:text-gray-400" aria-hidden="true" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M8 4a4 4 0 100 8 4 4 0 000-8zM2 8a6 6 0 1110.89 3.476l4.817 4.817a1 1 0 01-1.414 1.414l-4.816-4.816A6 6 0 012 8z" clip-rule="evenodd"></path></svg>
                </div>
                <input type="text" id="table-search-usrs" class="block p-2 pl-10 w-60 text-sm text-gray-900 border border-gray-300 rounded-lg w-80 bg-gray-50 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500" placeholder="Search for logs"
                  onchange="on_search(this,event)"
                  onkeydown="on_search_keydown(this,event)"
                >
                <button type="button" class="absolute inset-y-0 right-2 text-gray-400 bg-transparent hover:bg-gray-200 hover:text-gray-900 rounded-lg text-sm inline-flex items-center dark:hover:bg-gray-600 dark:hover:text-white"
                    onclick="clean_search()"
                >
                    <svg aria-hidden="true" class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"></path></svg>  
                </button>
            </div>
        </div>
        <div id="alert-danger" class="hidden flex items-center w-full max-w-xs mt-2 p-4 mb-4 text-gray-500 bg-white rounded-lg shadow dark:text-gray-400 dark:bg-gray-800" role="alert">
            <div class="inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-red-500 bg-red-100 rounded-lg dark:bg-red-800 dark:text-red-200">
                <svg aria-hidden="true" class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"></path></svg>
                <span class="sr-only">Error icon</span>
            </div>
            <div id="danger-message" class="ml-3 text-sm font-normal"></div>
            <button type="button" class="ml-auto -mx-0 -my-1.5 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex h-8 w-8 dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-700" 
                aria-label="Close"
                onclick="alert_danger('close','')"
            >
                <span class="sr-only">Close</span>
                <svg aria-hidden="true" class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"></path></svg>
            </button>
        </div>
        <div id="alert-info" class="hidden flex items-center w-full max-w-xs mt-2 py-4 mb-4 text-gray-500 bg-white rounded-lg shadow dark:text-gray-400 dark:bg-gray-800" role="alert">
            <div class="inline-flex items-center justify-center flex-shrink-0 w-8 h-8 text-green-500 bg-green-100 rounded-lg dark:bg-green-800 dark:text-green-200">
                <svg aria-hidden="true" class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z" clip-rule="evenodd"></path></svg>
                <span class="sr-only">Info icon</span>
            </div>
            <div id="info-message" class="ml-3 text-sm font-normal"></div>
            <button type="button" class="ml-auto -mx-0 -my-1.5 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex h-8 w-8 dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-700" 
                aria-label="Close"
                onclick="alert_info('close','')"
            >
                <span class="sr-only">Close</span>
                <svg aria-hidden="true" class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path fill-rule="evenodd" d="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z" clip-rule="evenodd"></path></svg>
            </button>
        </div>
        <table id="table-log" class="w-full text-sm text-left text-gray-500 dark:text-gray-400">
            <thead class="text-xs text-gray-700 uppercase bg-gray-50 dark:bg-gray-700 dark:text-gray-400">
                <tr>
                    <th data-th="check" scope="col" class="py-4 pl-2">
                        <div class="flex items-center">
                            <input id="checkbox-all" type="checkbox" class="w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 dark:focus:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600"
                                onchange="on_check_all(this,event)"
                            >
                            <label for="checkbox-all-search" class="sr-only">checkbox</label>
                        </div>
                    </th>
                    <th data-th="when" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                            When / Who
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                            <svg id="when-arrow-down" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-up" /></svg> 
                            <svg id="when-arrow-up" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-down" /></svg> 
                        </div>
                    </th>
                    <th data-th="origin" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                            Origin 
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                            <svg id="origin-arrow-down" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-up" /></svg> 
                            <svg id="origin-arrow-up" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-down" /></svg> 
                        </div>
                    </th>
                    <th data-th="context" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                           Context
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                            <svg id="context-arrow-down" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-up" /></svg> 
                            <svg id="context-arrow-up" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-down" /></svg> 
                        </div>
                    </th>
                    <th data-th="request" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                           Request info
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                            <svg id="request-arrow-down" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-up" /></svg> 
                            <svg id="request-arrow-up" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-down" /></svg> 
                        </div>
                    </th>        
                    <th data-th="roles" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                            Roles
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                        </div>
                    </th>
                    <th data-th="agent" scope="col" class="px-6 py-3">
                        <div class="flex items-center">
                           Request agent 
                            <svg class="hidden pl-2 w-4 h-4"><use href="#symbl-table-col-sort" /></svg>
                            <svg id="agent-arrow-down" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-up" /></svg> 
                            <svg id="agent-arrow-up" class="hidden pl-2 w-6 h-6"><use href="#symbl-arrow-down" /></svg> 
                        </div>
                    </th>        
                </tr>
            </thead>
            <tbody>
                {% for it in logs %}
                    {% if loop.index % 2 == 0%}
                    {% set tr_css="bg-gray-100 dark:bg-gray-800" %}
                    {% else %}
                    {% set tr_css="bg-white dark:bg-gray-900" %}
                    {% endif %}
                    {% if user.isadmin == true %}
                       {% set text_isadmin = '1' %}
                    {% else %}
                       {% set text_isadmin = '0' %}
                    {% endif %}
                {% set ip = it.content.req.ip | default(value="") %}
                {% set agent = it.content.req.agent | default(value="") %}
                {% set line_data = it.line_id~':'~it.content.origin~':'~it.content.context~':'~ip~':'~it.content.role~':'~agent %} 
                <tr data-row="{{line_data}}" class="{{tr_css}} hover:bg-gray-300 dark:hover:bg-gray-700">
                    <td class="w-4 p-2">
                        <div class="flex items-center">
                            <input data-col="{{loop.index0}}" data-lineid="{{it.line_id}}" id="checkbox-table-search-3" type="checkbox" class="col-check w-4 h-4 text-blue-600 bg-gray-100 border-gray-300 rounded focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 dark:focus:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600">
                            <label for="checkbox-table-search-3" class="sr-only">checkbox</label>
                        </div>
                       
                    </td>
                    <th scope="row" class="flex items-center px-6 py-4 font-medium text-gray-900 whitespace-nowrap dark:text-white">
                        {% if user and user.name != '' %}
                        <div class="border-0.5 p-0.5 border-gray-500 rounded-lg">
                            <div 
                                class="flex flex-col space-y-2 px-2 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-500" 
                            >
                               <div class="text-gray-800 dark:text-gray-300">{{it.content.when}}</div> 
                               <div class="text-xs"><span class="text-gray-500 text-xs"> line:</span> {{it.line_id}}</div>
                               {% if it.content.sid != '' %}<div class="text-xs"><span class="text-gray-500 text-xs"> SID:</span> {{it.content.sid}}</div> {% endif %}
                               <div>
                                {% if it.content.id != '' %}<span class="text-xs"><span class="text-gray-500 text-xs"> ID:</span> {{it.content.id}}</span> {% endif %}
                                {% if user and user.name != '' %} <span class="pl-2 text-gray-800 dark:text-gray-300 text-xs font-semibold">{{user.name}}</span>{% endif %}
                               </div>
                            </div>
                        </div>
                        {% else %}
                        <div 
                           class="flex flex-col px-2 space-y-2 px-2 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-500" 
                        >
                        <div class="text-gray-800 dark:text-gray-300">{{it.content.when}}</div> 
                        <div class="text-xs"><span class="text-gray-500 text-xs"> line:</span> {{it.line_id}}</div>
                        {% if it.content.sid != '' %}<div class="text-xs"><span class="text-gray-500 text-xs"> SID:</span> {{it.content.sid}}</div> {% endif %}
                        {% if it.content.id != '' %}<span class="text-xs"><span class="text-gray-500 text-xs"> ID:</span> {{it.content.id}}</span> {% endif %}
                        {% endif %}
                        </div>
                    </th>
                    <td class="px-6">
                        <div class="flex flex-col space-y-2">
                            <span class="text-xs">{{it.content.origin}}</span>
                            <span class="text-xs">{{it.content.trigger}}</span>
                        </div>
                    </td>
                    <td class="px-6">
                        <div class="flex flex-col items-start space-y-2">
                            {% set arr_info = it.content.info | split(pat=",") %}
                            {% if arr_info | length > 1 %}
                            <button id="{{loop.index0}}-info"
                                class="flex flex-col items-start space-y-2 px-2 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-500" 
                                type="button"
                                onclick="on_log_info(this)"
                            >
                            {% for info in arr_info %}
                               <span class="{% if loop.index0 > 0 %}hidden{% endif %} flex items-start text-xs">{{info | replace(from="'", to="")}}</span>
                            {% endfor %}    
                            </button>
                            {% else %}
                               <div class="flex items-start text-xs">{{it.content.info}}</div>
                            {% endif %}
                            <div class="text-xs">{{it.content.context}}</div>
                        </div>
                    </td>
                    <td class="px-6">
                        <div class="flex flex-col my-2">
                            {% if ip != "" %}
                            <span><span class="text-gray-500 text-xs">IP:</span> {{ip | replace(from=":", to=" -> ")}}</span>
                            {% endif %}
                            {% if it.content.req.ref and it.content.req.ref != "" %}
                            <span class="mt-2 text-xs"><span class="text-gray-500 text-xs">Ref:</span> {{it.content.req.ref}}</span>
                            {% endif %}
                            {% if it.content.req.auth and it.content.req.auth != "" %}
                            <span class="mt-2 text-xs"><span class="text-gray-500 text-xs">Auth:</span> {{it.content.req.auth}}</span>
                            {% endif %}
                            {% if it.content.req.int and it.content.req.int != "" %}
                            <span class="mt-2 text-xs"><span class="text-gray-500 text-xs">Int:</span> {{it.content.req.int}}</span>
                            {% endif %}
                        </div>
                    </td>
                    <td class="px-6">
                        {% set roles = it.content.role | split(pat=",") %}
                        {% for rol in roles %}
                            {% if rol != "" %}
                                <span class="inline-flex items-center px-2 py-1 mr-2 mb-2 text-sm font-medium text-blue-800 bg-blue-100 rounded dark:bg-blue-900 dark:text-blue-300">
                                {{rol}}
                                </span>
                            {% endif %}
                        {% endfor %}
                    </td>
                    <td class="px-6">
                        {% if agent != "" %}
                            <div class="flex flex-col space-y-2">
                            {% set arr_agent = agent | split(pat=")") %}
                            {% for agnt in arr_agent %}
                            <span class="text-xs">{{agnt}})</span>
                            {% endfor %}
                            </div>
                        {% endif %}
                    </td>
                </tr>
                {% endfor %}
            </tbody>
        </table>
        <!-- Edit user modal -->
        {% include "partials/modal_edit_user.html.j2" %}
    </div>
</section>
<script id="js-data">
   let logs_list = JSON.stringify({{logs | map(attribute="line_id") | json_encode() | safe }});
</script>
<script>
    const GETUSER_URL = "{{main_url}}/userget";
    const SAVEUSER_URL = "{{main_url}}/usersave";
    const DELETELOG_URL = "{{main_url}}/logdelete";
</script>
<script src="{{assets_url | default(value='')}}/js/logs.js"></script> 
{% include "partials/symbols.html.j2" %} 
{% include "partials/footer.html.j2" %}
