tidy up
This commit is contained in:
parent
b8c18d3d91
commit
495a255987
|
@ -1,12 +1,9 @@
|
||||||
<script>
|
<script>
|
||||||
import Tooltip from "../Tooltip/Tooltip.svelte"
|
import Tooltip from "../Tooltip/Tooltip.svelte"
|
||||||
import Link from "../Link/Link.svelte"
|
import Link from "../Link/Link.svelte"
|
||||||
import { createEventDispatcher } from "svelte"
|
|
||||||
|
|
||||||
export let value
|
export let value
|
||||||
|
|
||||||
const dispatch = createEventDispatcher()
|
|
||||||
|
|
||||||
const displayLimit = 5
|
const displayLimit = 5
|
||||||
$: attachments = value?.slice(0, displayLimit) ?? []
|
$: attachments = value?.slice(0, displayLimit) ?? []
|
||||||
$: leftover = (value?.length ?? 0) - attachments.length
|
$: leftover = (value?.length ?? 0) - attachments.length
|
||||||
|
|
|
@ -65,12 +65,6 @@
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
const selectAttachment = ({ url }) => {
|
|
||||||
$goto(
|
|
||||||
`/builder/app/${$params.application}/data/table/${tableId}/relationship/${rowId}/${fieldName}`
|
|
||||||
)
|
|
||||||
}
|
|
||||||
|
|
||||||
const deleteRows = async () => {
|
const deleteRows = async () => {
|
||||||
await api.post(`/api/${tableId}/rows`, {
|
await api.post(`/api/${tableId}/rows`, {
|
||||||
rows: selectedRows,
|
rows: selectedRows,
|
||||||
|
|
Loading…
Reference in New Issue