Compare commits
No commits in common. "96c55db63dbfed92b78ff0e7bdab7a8cce4d76e9" and "f3cc07c009ed0a34e61f1aad47a1a31778145439" have entirely different histories.
96c55db63d
...
f3cc07c009
@ -4,7 +4,7 @@
|
||||
import Toastify from "toastify-js";
|
||||
import { tick, createEventDispatcher } from "svelte";
|
||||
export let copy_modal_open;
|
||||
export let new_client;
|
||||
export let new_station;
|
||||
const dispatch = createEventDispatcher();
|
||||
let valueCopy = null;
|
||||
let areaDom;
|
||||
@ -13,7 +13,7 @@
|
||||
copy_modal_open = false;
|
||||
}
|
||||
async function copy() {
|
||||
valueCopy = new_client.key;
|
||||
valueCopy = new_station.key;
|
||||
await tick();
|
||||
areaDom.focus();
|
||||
areaDom.select();
|
||||
@ -80,7 +80,7 @@
|
||||
</h3>
|
||||
<div class="mt-2 mb-6">
|
||||
<p class="text-sm text-gray-500">
|
||||
{$_('the-statsclient-api-token-will-only-get-displayed-once-you-wont-be-able-to-change-or-view-it-again')}
|
||||
{$_('the-scanstations-api-token-will-only-get-displayed-once-you-wont-be-able-to-change-or-view-it-again')}
|
||||
<br />
|
||||
{$_('please-copy-the-token-and-store-it-somewhere-save')}
|
||||
</p>
|
||||
@ -94,7 +94,7 @@
|
||||
name="token"
|
||||
class:bg-green-200={copied}
|
||||
class="mt-1 focus:ring-indigo-500 focus:border-indigo-500 block w-full shadow-sm rounded-l-md sm:text-sm border-gray-300 border bg-gray-50 text-gray-500 p-2">
|
||||
{new_client.key}
|
||||
{new_station.key}
|
||||
</p>
|
||||
<div
|
||||
class="bg-gray-200 border-gray-300 border-t border-b border-r text-black rounded-r-md sm:text-sm p-2 mt-1 cursor-pointer">
|
@ -80,7 +80,7 @@
|
||||
</div>
|
||||
<div class="mb-8 text-3xl font-extrabold leading-tight">
|
||||
#{original_data.id}
|
||||
<span data-id="stations_actions_${original_data.id}">
|
||||
<span data-id="stations_actions_${editable.id}">
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('STATSCLIENT:DELETE')}
|
||||
{#if delete_triggered}
|
||||
<button
|
||||
@ -98,7 +98,7 @@
|
||||
delete_triggered = true;
|
||||
}}
|
||||
type="button"
|
||||
class="w-full justify-center rounded-md border border-transparent shadow-sm px-4 py-2 bg-red-600 text-base font-medium text-white hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm">{$_('delete-statsclient')}</button>
|
||||
class="w-full justify-center rounded-md border border-transparent shadow-sm px-4 py-2 bg-red-600 text-base font-medium text-white hover:bg-red-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500 sm:ml-3 sm:w-auto sm:text-sm">{$_('delete-station')}</button>
|
||||
{/if}
|
||||
{/if}
|
||||
</span>
|
||||
|
@ -2,8 +2,8 @@
|
||||
import { _ } from "svelte-i18n";
|
||||
import store from "../../store";
|
||||
import AddStatsClientModal from "./AddStatsClientModal.svelte";
|
||||
import CopyStatsClientTokenModal from "./CopyStatsClientTokenModal.svelte";
|
||||
import StatsClientsOverview from "./StatsClientsOverview.svelte";
|
||||
// import CopyStatsClientsTokenModal from "./CopyStatsClientsTokenModal.svelte";
|
||||
import StatsClientssOverview from "./StatsClientsOverview.svelte";
|
||||
export let modal_open = false;
|
||||
export let copy_modal_open = false;
|
||||
export let new_client = {};
|
||||
@ -24,10 +24,10 @@
|
||||
</button>
|
||||
{/if}
|
||||
</span>
|
||||
<StatsClientsOverview bind:current_clients bind:modal_open bind:new_client bind:copy_modal_open />
|
||||
<StatsClientssOverview bind:current_clients bind:modal_open bind:new_client bind:copy_modal_open />
|
||||
</section>
|
||||
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('STATSCLIENT:CREATE')}
|
||||
<AddStatsClientModal bind:modal_open bind:current_clients bind:new_client bind:copy_modal_open/>
|
||||
<CopyStatsClientTokenModal bind:copy_modal_open bind:new_client />
|
||||
<!-- <CopyStatsClientsTokenModal bind:copy_modal_open bind:new_client /> -->
|
||||
{/if}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<script>
|
||||
import { _ } from "svelte-i18n";
|
||||
import AddStatsClientModal from "./AddStatsClientModal.svelte";
|
||||
import CopyScanStationTokenModal from "./CopyStatsClientTokenModal.svelte";
|
||||
import CopyScanStationTokenModal from "./CopyScanStationTokenModal.svelte";
|
||||
import scanstations_empty from "./statsclients_empty.svg";
|
||||
let modal_open = false;
|
||||
let copy_modal_open = false;
|
||||
|
@ -56,6 +56,11 @@
|
||||
scope="col"
|
||||
class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
|
||||
{$_('prefix')}
|
||||
</th>
|
||||
<th
|
||||
scope="col"
|
||||
class="px-6 py-3 text-left text-xs font-medium text-gray-500 uppercase tracking-wider">
|
||||
{$_('key')}
|
||||
</th>
|
||||
<th scope="col" class="relative px-6 py-3">
|
||||
<span class="sr-only">{$_('action')}</span>
|
||||
@ -87,6 +92,14 @@
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap">
|
||||
<div class="flex items-center">
|
||||
<div class="ml-4">
|
||||
<div class="text-sm font-medium text-gray-900">
|
||||
{c.key}
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
{#if active_deletes[c.id] === true}
|
||||
<td
|
||||
class="px-6 py-4 whitespace-nowrap text-right text-sm font-medium">
|
||||
|
@ -469,7 +469,5 @@
|
||||
"statsclient-is-being-added": "Statsclient wird angelegt...",
|
||||
"please-provide-the-required-information-to-create-a-new-statsclient": "Bitte gebe alle für einen Statsclient notwendigen Informationen an",
|
||||
"you-dont-have-any-scanclients-yet": "Es gibt noch keine Statsclients",
|
||||
"add-the-first-statsclient": "Erstelle deinen ersten Statsclient.",
|
||||
"the-statsclient-api-token-will-only-get-displayed-once-you-wont-be-able-to-change-or-view-it-again": "Der Statsclient Token wird nur einmal angezeigt - du kannst ihn nicht ändern oder ihn dir nochmal anzeigen lassen!",
|
||||
"delete-statsclient": "Statsclient löschen"
|
||||
"add-the-first-statsclient": "Erstelle deinen ersten Statsclient."
|
||||
}
|
||||
|
@ -470,7 +470,5 @@
|
||||
"statsclient-is-being-added": "Statsclient is being added...",
|
||||
"please-provide-the-required-information-to-create-a-new-statsclient": "Please provide the required information to create a new statsclient",
|
||||
"you-dont-have-any-scanclients-yet": "You don't have any statsclients yet",
|
||||
"add-the-first-statsclient": "Add your first statsclient.",
|
||||
"the-statsclient-api-token-will-only-get-displayed-once-you-wont-be-able-to-change-or-view-it-again": "The statsclient api token will only get displayed once - you won't be able to change or view it again!",
|
||||
"delete-statsclient": "Delete statsclient"
|
||||
"add-the-first-statsclient": "Add your first statsclient."
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user