macros_list to macros
This commit is contained in:
@@ -49,7 +49,11 @@ module.exports = {
|
|||||||
methods: {
|
methods: {
|
||||||
backup: function () {
|
backup: function () {
|
||||||
document.getElementById("download-target").src =
|
document.getElementById("download-target").src =
|
||||||
"/api/config/download/" + this.state.macros_list.map(item => item.file_name).join(",");
|
"/api/config/download/" +
|
||||||
|
this.state.macros
|
||||||
|
.filter(item => item.file_name != "default")
|
||||||
|
.map(item => item.file_name)
|
||||||
|
.join(",");
|
||||||
},
|
},
|
||||||
|
|
||||||
restore_config: function () {
|
restore_config: function () {
|
||||||
@@ -69,11 +73,11 @@ module.exports = {
|
|||||||
await fetch("/api/config/restore", {
|
await fetch("/api/config/restore", {
|
||||||
method: "PUT",
|
method: "PUT",
|
||||||
body: formData,
|
body: formData,
|
||||||
headers:{
|
headers: {
|
||||||
'Type':'zip'
|
Type: "zip",
|
||||||
}
|
},
|
||||||
});
|
});
|
||||||
console.log('done');
|
console.log("done");
|
||||||
// SvelteComponents.showDialog("Message", {
|
// SvelteComponents.showDialog("Message", {
|
||||||
// title: "Success",
|
// title: "Success",
|
||||||
// message: "Configuration restored",
|
// message: "Configuration restored",
|
||||||
|
|||||||
Reference in New Issue
Block a user