Continue AI features and improve protocol support
This commit is contained in:
@@ -13,22 +13,24 @@
|
||||
<th>uuid</th>
|
||||
<th>account</th>
|
||||
<th>name</th>
|
||||
<th>person</th>
|
||||
<th>actions</th>
|
||||
</thead>
|
||||
{% for item in object_list %}
|
||||
<tr>
|
||||
<td>{{ item.source_number }}</td>
|
||||
<td>{{ item.chat.source_number }}</td>
|
||||
<td>
|
||||
<a
|
||||
class="has-text-grey button nowrap-child"
|
||||
onclick="window.prompt('Copy to clipboard: Ctrl+C, Enter', '{{ item.source_uuid }}');">
|
||||
onclick="window.prompt('Copy to clipboard: Ctrl+C, Enter', '{{ item.chat.source_uuid }}');">
|
||||
<span class="icon" data-tooltip="Copy to clipboard">
|
||||
<i class="fa-solid fa-copy" aria-hidden="true"></i>
|
||||
</span>
|
||||
</a>
|
||||
</td>
|
||||
<td>{{ item.account }}</td>
|
||||
<td>{{ item.source_name }}</td>
|
||||
<td>{{ item.chat.account }}</td>
|
||||
<td>{{ item.chat.source_name }}</td>
|
||||
<td>{{ item.person_name|default:"-" }}</td>
|
||||
<td>
|
||||
<div class="buttons">
|
||||
<button
|
||||
@@ -37,7 +39,7 @@
|
||||
hx-trigger="click"
|
||||
hx-target="#modals-here"
|
||||
hx-swap="innerHTML"
|
||||
hx-confirm="Are you sure you wish to unlink {{ item }}?"
|
||||
hx-confirm="Are you sure you wish to unlink {{ item.chat }}?"
|
||||
class="button">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
@@ -46,51 +48,67 @@
|
||||
</span>
|
||||
</button>
|
||||
{% if type == 'page' %}
|
||||
<a href="{# url 'signal_contacts' type=type pk=item #}"><button
|
||||
class="button">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="fa-solid fa-eye"></i>
|
||||
{% if item.can_compose %}
|
||||
<a href="{{ item.compose_page_url }}"><button
|
||||
class="button"
|
||||
title="Manual text mode">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="{{ item.manual_icon_class }}"></i>
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</a>
|
||||
<a href="{# url 'signal_chats' type=type pk=item #}"><button
|
||||
class="button">
|
||||
</button>
|
||||
</a>
|
||||
{% else %}
|
||||
<button class="button" disabled title="No identifier available for manual send">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="{{ item.manual_icon_class }}"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
{% endif %}
|
||||
<a href="{{ item.ai_url }}"><button
|
||||
class="button"
|
||||
title="Open AI workspace">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="fa-solid fa-envelope"></i>
|
||||
<i class="fa-solid fa-brain-circuit"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</a>
|
||||
{% else %}
|
||||
<button
|
||||
hx-headers='{"X-CSRFToken": "{{ csrf_token }}"}'
|
||||
hx-get="{# url 'signal_contacts' type=type pk=item #}"
|
||||
hx-trigger="click"
|
||||
hx-target="#{{ type }}s-here"
|
||||
hx-swap="innerHTML"
|
||||
class="button">
|
||||
{% if item.can_compose %}
|
||||
<button
|
||||
hx-headers='{"X-CSRFToken": "{{ csrf_token }}"}'
|
||||
hx-get="{{ item.compose_widget_url }}"
|
||||
hx-trigger="click"
|
||||
hx-target="#widgets-here"
|
||||
hx-swap="afterend"
|
||||
class="button">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="{{ item.manual_icon_class }}"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
{% else %}
|
||||
<button class="button" disabled title="No identifier available for manual send">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="{{ item.manual_icon_class }}"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
{% endif %}
|
||||
<a href="{{ item.ai_url }}"><button class="button">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="fa-solid fa-eye"></i>
|
||||
<i class="fa-solid fa-brain-circuit"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
<button
|
||||
hx-headers='{"X-CSRFToken": "{{ csrf_token }}"}'
|
||||
hx-get="{# url 'signal_chats' type=type pk=item #}"
|
||||
hx-trigger="click"
|
||||
hx-target="#{{ type }}s-here"
|
||||
hx-swap="innerHTML"
|
||||
class="button">
|
||||
<span class="icon-text">
|
||||
<span class="icon">
|
||||
<i class="fa-solid fa-envelope"></i>
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</button></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
@@ -98,4 +116,4 @@
|
||||
{% endfor %}
|
||||
|
||||
</table>
|
||||
{% endcache %}
|
||||
{% endcache %}
|
||||
|
||||
Reference in New Issue
Block a user