From c35138e7e3b68df5712ffa844936fb3d603ef555 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Losada=20Hern=C3=A1ndez?= Date: Sun, 11 May 2025 23:59:25 +0200 Subject: [PATCH] client side --- .../editor/metadataEditor/metadataEditor.jsx | 49 ++++++++++++++++--- .../editor/metadataEditor/metadataEditor.less | 23 +++++++-- 2 files changed, 61 insertions(+), 11 deletions(-) diff --git a/client/homebrew/editor/metadataEditor/metadataEditor.jsx b/client/homebrew/editor/metadataEditor/metadataEditor.jsx index 8f256922f..5fd6d6f1a 100644 --- a/client/homebrew/editor/metadataEditor/metadataEditor.jsx +++ b/client/homebrew/editor/metadataEditor/metadataEditor.jsx @@ -156,6 +156,19 @@ const MetadataEditor = createClass({ }); }, + handleDeleteAuthor : function(author){ + if(!confirm('Are you sure you want to delete this author? They will lose all edit access to this brew.')) return; + request.put(`/api/${this.props.metadata.editId}/${author}`) + .send() + .end((err, res)=>{ + if(err) { + this.props.reportError(err); + } else { + window.location.reload(); + } + }); + }, + renderSystems : function(){ return _.map(SYSTEMS, (val)=>{ return