permissions

This commit is contained in:
2023-10-17 22:57:25 +03:00
parent 4b9e9cb4f6
commit 632684f514
29 changed files with 370 additions and 223 deletions
+12 -9
View File
@@ -15,6 +15,7 @@
export let filter;
export let inModal;
export let modalUrl;
export let isWritable;
export let records;
export let systemFields = [];
// export let visibleFields = [];
@@ -83,7 +84,7 @@
<div class="d-flex align-items-center ">
{#if schema.type === "collection"}
{#if !inModal}
{#if !inModal && isWritable}
<a
href="{channel.lucentUrl}/records/new?schema={schema.name}"
class="btn btn-sm btn-primary"
@@ -109,14 +110,16 @@
<ul class="dropdown-menu">
{#if filter["status_in"] === "trashed"}
<li>
<a
class="dropdown-item"
href="{channel.lucentUrl}/content/{schema.name}/emptyTrash"
>
Empty trash
</a>
</li>
{#if isWritable}
<li>
<a
class="dropdown-item"
href="{channel.lucentUrl}/content/{schema.name}/emptyTrash"
>
Empty trash
</a>
</li>
{/if}
{:else}
<li>