1
0
Fork 0
mirror of synced 2024-09-21 20:01:32 +12:00
budibase/packages/builder/src/components/start/ExportAppModal.svelte

17 lines
507 B
Svelte
Raw Normal View History

2022-05-25 20:26:10 +12:00
<script>
import { ModalContent, Toggle } from "@budibase/bbui"
export let app
let includeRows = true
const exportApp = () => {
const id = app.deployed ? app.prodId : app.devId
const appName = encodeURIComponent(app.name)
window.location = `/api/backups/export?appId=${id}&appname=${appName}&includeRows=${includeRows}`
}
</script>
<ModalContent title={"Export"} confirmText={"Export"} onConfirm={exportApp}>
<Toggle text="Include Data" bind:value={includeRows} />
</ModalContent>