parent
a7098df9cf
commit
45e7f6a0d1
@ -84,13 +84,12 @@
|
||||
text: "Contact is being added...",
|
||||
duration: -1,
|
||||
}).showToast();
|
||||
const group=teams.concat(orgs).find(g=>g.id===selected_team)
|
||||
console.log(group);
|
||||
const groups=teams.concat(orgs).map(g=>g.id)
|
||||
let postdata = {
|
||||
group: group,
|
||||
groups: groups,
|
||||
firstname: firstname_input_value,
|
||||
lastname: lastname_input_value,
|
||||
adress: {
|
||||
address: {
|
||||
address1:address_input1_value,
|
||||
address2:address_input2_value||"",
|
||||
postalcode:address_zipcode_value,
|
||||
|
@ -4,14 +4,13 @@
|
||||
import AddContactModal from "./AddContactModal.svelte";
|
||||
import ContactsOverview from "./ContactsOverview.svelte";
|
||||
export let modal_open = false;
|
||||
console.log(store.state.jwtinfo.userdetails.permissions);
|
||||
let current_contacts=[];
|
||||
</script>
|
||||
|
||||
<section class="container p-5">
|
||||
<span class="mb-1 text-3xl font-extrabold leading-tight">
|
||||
{$_('contacts')}
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('USER:CREATE')}
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('CONTACT:CREATE')}
|
||||
<button
|
||||
on:click={() => {
|
||||
modal_open = true;
|
||||
@ -25,6 +24,6 @@
|
||||
<ContactsOverview bind:current_contacts />
|
||||
</section>
|
||||
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('USER:CREATE')}
|
||||
{#if store.state.jwtinfo.userdetails.permissions.includes('CONTACT:CREATE')}
|
||||
<AddContactModal bind:current_contacts bind:modal_open />
|
||||
{/if}
|
||||
|
@ -24,7 +24,6 @@
|
||||
{#if current_contacts.length === 0}
|
||||
<ContactsEmptyState />
|
||||
{:else}
|
||||
{JSON.stringify(current_contacts)}
|
||||
<input
|
||||
type="search"
|
||||
bind:value={searchvalue}
|
||||
@ -99,7 +98,6 @@
|
||||
<div class="flex items-center">
|
||||
<div class="ml-4">
|
||||
<div class="text-sm font-medium text-gray-900">
|
||||
<!-- {JSON.stringify(t.address)} -->
|
||||
{t.address.address1}<br>
|
||||
{t.address.address2 || ''}<br>
|
||||
{t.address.postalcode}
|
||||
|
Loading…
x
Reference in New Issue
Block a user