Get user re-querying working when they disconnect and improve the user status
This commit is contained in:
parent
1bf6cbbd45
commit
bb095a9b4e
5 changed files with 148 additions and 36 deletions
|
|
@ -1,30 +1,47 @@
|
|||
<ul class="user-list">
|
||||
{{#each users as | user |}}
|
||||
<li style="--spinner-inner-colour: var(--user-color-{{user.id}})">
|
||||
<div class="grow">
|
||||
{{ user.name }}
|
||||
<li
|
||||
style="--spinner-inner-colour: var(--user-color-{{user.id}})"
|
||||
data-user-id="{{ user.id }}"
|
||||
>
|
||||
<div class="user-summary">
|
||||
<div class="grow">
|
||||
{{ user.name }}
|
||||
</div>
|
||||
{{#if (eq user.status "cancelled")}}
|
||||
<span>Cancelled by User</span>
|
||||
{{else if (eq user.status "waiting")}}
|
||||
<span class="loader"></span>
|
||||
{{else if (eq user.status "disconnected")}}
|
||||
<taf-icon
|
||||
data-tooltip="taf.Apps.QueryStatus.user-disconnected-tooltip"
|
||||
name="icons/disconnected"
|
||||
var:size="40px"
|
||||
var:stroke="currentColor"
|
||||
var:fill="currentColor"
|
||||
></taf-icon>
|
||||
{{else if (eq user.status "unprompted")}}
|
||||
<button
|
||||
type="button"
|
||||
data-action="promptUser"
|
||||
>
|
||||
Send Request
|
||||
</button>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{#if user.answers}}
|
||||
{{#if (eq user.status "finished")}}
|
||||
<div class="chip-list">
|
||||
{{#each user.answers as | answer |}}
|
||||
<span class="chip">
|
||||
{{ @key }}
|
||||
<span class="key">
|
||||
{{ @key }}
|
||||
</span>
|
||||
<span class="value">
|
||||
{{ answer }}
|
||||
</span>
|
||||
</span>
|
||||
{{/each}}
|
||||
</div>
|
||||
{{else if user.active}}
|
||||
<span class="loader"></span>
|
||||
{{else}}
|
||||
<taf-icon
|
||||
data-tooltip="taf.Apps.QueryStatus.user-disconnected-tooltip"
|
||||
name="icons/disconnected"
|
||||
var:size="40px"
|
||||
var:stroke="currentColor"
|
||||
var:fill="currentColor"
|
||||
></taf-icon>
|
||||
{{/if}}
|
||||
</li>
|
||||
{{/each}}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue