Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Our largest app is reaching a boiling point with bookmarks. Enough people have made bookmarks with layouts that it is taking forever (7mins+) for the bookmark list to load in our app and the sheets won't load anything until it loads. We have realized this is due to a percentage of bookmarks having layouts saved. We are working with Qlik RND on solving the overall problem but for now I need to remove the layouts of any bookmarks that have them. I have already tried setting the "isExtended" property to false on all of them but that does not work. It looks like I need to set the qPatches in the layout either to an empty array or remove it all together. I think I need to do this through the ApplyPatches method but am having problems with it. Below is my current code which is returning an invalid parameters response.
const app = await qlik.openApp("dd33cb85-f9ee-4774-b145-415eea6a24e2", config)
const applayout = await app.getAppLayout()
const doc = applayout.engineApp
const bm = await doc.getBookmark({
"qId": "9ccc7b68-024c-4c70-b886-be2e648ccaed"
});
let patches = await bm.applyPatches({
"qPatches": [
{
"qOp": "remove",
"qPath": "/qBookmarkDef/qPatches",
"qValue": "[]"
}
]
})
This is the documentation I am referencing https://qlik.dev/apis/json-rpc/qix/genericbookmark#%23%2Fentries%2FGenericBookmark%2Fentries%2FApply.... @ErikWetterberg I tried following one of your blog posts but couldn't get it to work.
Did you find any solution for this? I'm having the exact same problem and need to clear all the patches for the existing bookmarks.
@_jespers_ I don't think we ever did but there was a bug in Qlik's code for the layouts where it was fetching the layout for each bookmark when you grabbed the bookmark list. They worked with us and fixed it in a release but I am not sure which one.