diff --git a/lib/www/client/source/src/views/ProjectSettings.vue b/lib/www/client/source/src/views/ProjectSettings.vue
index ff43dc6..a161447 100644
--- a/lib/www/client/source/src/views/ProjectSettings.vue
+++ b/lib/www/client/source/src/views/ProjectSettings.vue
@@ -139,6 +139,19 @@
+
+
+
+
+ mdi-cloud-upload
+ Upload
+
@@ -577,8 +590,23 @@ export default {
}
},
- upload () {
- console.log("UPLOAD");
+ async upload () {
+ const url = `/project/${this.$route.params.project}/configuration`;
+ const init = {
+ method: "PUT",
+ headers: {
+ //"If-Match": "" // Ensure we're not overwriting someone else's changes
+ "Content-Type": "application/json"
+ },
+ body: {...this.configuration, archived: true}
+ };
+ const res = await this.api([url, init]);
+ if (res && res.id == this.configuration.id) {
+ // In case the server decided to apply any changes
+ this.showSnack(["Configuration uploaded to server", "success"]);
+ this.$nextTick( () => this.configuration = res );
+ }
+ },
async loadFromFile () {
if (!this.fileInputErrors.length) {