Skip to content
Snippets Groups Projects

Add direct S3 interaction

Merged Daniel Göbel requested to merge feature/s3-interaction into development
1 file
+ 4
11
Compare changes
  • Side-by-side
  • Inline
@@ -4,8 +4,7 @@ import { CopyObjectCommand } from "@aws-sdk/client-s3";
import BootstrapModal from "@/components/Modals/BootstrapModal.vue";
import type { BucketOut } from "@/client";
import { Modal, Toast } from "bootstrap";
import { onMounted, reactive, watch, computed } from "vue";
import type { ComputedRef } from "vue";
import { onMounted, reactive, watch } from "vue";
const props = defineProps<{
modalID: string;
@@ -31,15 +30,9 @@ let copyModal: Modal | null = null;
let successToast: Toast | null = null;
let errorToast: Toast | null = null;
const sourceFilteredBuckets: ComputedRef<BucketOut[]> = computed(() => {
return props.availableBuckets.filter(
(bucket) => bucket.name !== props.sourceBucketName
);
});
function getFileName(key: string): string {
const spliitedKey = key.split("/");
return spliitedKey[spliitedKey.length - 1];
const splittedKey = key.split("/");
return splittedKey[splittedKey.length - 1];
}
function copyObject() {
@@ -159,7 +152,7 @@ onMounted(() => {
>
<option disabled selected>Select one...</option>
<option
v-for="bucket in sourceFilteredBuckets"
v-for="bucket in props.availableBuckets"
:key="bucket.name"
:value="bucket.name"
>
Loading