mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-16 20:07:49 +01:00
feat: single model export
This commit is contained in:
@@ -126,6 +126,13 @@
|
||||
saveAs(blob, `models-export-${Date.now()}.json`);
|
||||
};
|
||||
|
||||
const exportModelHandler = async (model) => {
|
||||
let blob = new Blob([JSON.stringify([model])], {
|
||||
type: 'application/json'
|
||||
});
|
||||
saveAs(blob, `${model.id}-${Date.now()}.json`);
|
||||
};
|
||||
|
||||
const positionChangeHanlder = async () => {
|
||||
// Get the new order of the models
|
||||
const modelIds = Array.from(document.getElementById('model-list').children).map((child) =>
|
||||
@@ -322,6 +329,9 @@
|
||||
cloneHandler={() => {
|
||||
cloneModelHandler(model);
|
||||
}}
|
||||
exportHandler={() => {
|
||||
exportModelHandler(model);
|
||||
}}
|
||||
hideHandler={() => {
|
||||
hideModelHandler(model);
|
||||
}}
|
||||
|
||||
Reference in New Issue
Block a user