delete reps on dash

This commit is contained in:
2024-05-30 17:55:43 +01:00
parent 86ead475c0
commit 7bba9ea362
5 changed files with 132 additions and 11 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
import { hashAPIPath } from "../../../actions";
import { deleteBlobCase } from "../../../actions/azurestorage";
import { deleteBlobCase, deleteBlobRep } from "../../../actions/azurestorage";
import nextConnect from "next-connect";
import middleware from "../middleware/middleware";
@@ -28,7 +28,7 @@ ApiProxy.get(async (req, res) => {
// console.log(hashAPIPath(checkquerypath) == "&hash=" + checkHash);
//if (hashAPIPath(checkquerypath) == "&hash=" + checkHash) {
await deleteBlobCase(containerName, casefolderID).then((data) => {
await deleteBlobRep(containerName, casefolderID).then((data) => {
return res.status(200).json({ data: data });
});
// } else {
+10 -2
View File
@@ -62,10 +62,18 @@ ApiProxy.get(async (req, res) => {
"\n////////////////////////////\n getRepsBlobs:",
data
);
let result = await downloadAllRepsFiles(containerName, data);
return res.status(200).json(result);
return data;
})
.then(async (data) => {
console.log("\n////////////////////////////\n now here:", data);
let result = await downloadAllRepsFiles(containerName, data);
return res
.setHeader("Cache-Control", "no-store")
.status(200)
.json(result);
})
.catch((error) => {
console.log(
"///////////////////////\ngetRepsFromBlob api in api route response: " +