From 86758585d81e466bd4830299a0f9d1400612e404 Mon Sep 17 00:00:00 2001 From: Maho Sasaki Date: Fri, 26 Feb 2021 23:50:43 -0600 Subject: [PATCH 1/2] also show 409 message for delete with items with dependency - still needs to be styled --- .../MainTableView/DeleteTuple/DeleteTuple.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/Components/MainTableView/DeleteTuple/DeleteTuple.tsx b/src/Components/MainTableView/DeleteTuple/DeleteTuple.tsx index 8c93462..2df1871 100644 --- a/src/Components/MainTableView/DeleteTuple/DeleteTuple.tsx +++ b/src/Components/MainTableView/DeleteTuple/DeleteTuple.tsx @@ -102,8 +102,14 @@ class DeleteTuple extends React.Component<{ this.setState({isDeletingEntry: false, dependencies: []}) // Check for error mesage 500, if so throw error - shouldn't happen as often once real dependency check is in place - if (result.status === 500) { - throw Error(`${result.status} - ${result.statusText}`) + if (result.status === 500 || result.status === 409) { + result.text() + .then(errorMessage => { + throw Error(`${result.status} - ${result.statusText}: (${errorMessage})`) + }) + .catch(error => { + this.setState({deleteStatusMessage: error.message}) + }) } // return result - expecting a Delete Succesful string From 3001f8770a083ee5e60e28b9186ff57c5f59e34f Mon Sep 17 00:00:00 2001 From: Maho Sasaki Date: Fri, 26 Feb 2021 23:56:41 -0600 Subject: [PATCH 2/2] update version --- CHANGELOG.md | 4 ++-- docker-compose-deploy.yaml | 4 ++-- package-lock.json | 2 +- package.json | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d80810e..bcca0fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ Observes [Semantic Versioning](https://semver.org/spec/v2.0.0.html) standard and [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) convention. -## [0.1.0-beta.0] - 2021-02-26 +## [0.1.0-beta.1] - 2021-02-26 ### Added - Support for double data type (#72) PR #86 - Added search functionailty for table list similar to schema. (#73) PR #88 @@ -47,5 +47,5 @@ Observes [Semantic Versioning](https://semver.org/spec/v2.0.0.html) standard and - Multi database server connections supported by opening new tabs. - Support of DJ NEURO - [Managed Database Hosting](https://djneuro.io/services/) users. -[0.1.0-beta.0]: https://github.com/datajoint/datajoint-labbook/compare/0.1.0-alpha.2...0.1.0-beta.0 +[0.1.0-beta.1]: https://github.com/datajoint/datajoint-labbook/compare/0.1.0-alpha.2...0.1.0-beta.1 [0.1.0-alpha.2]: https://github.com/datajoint/datajoint-labbook/releases/tag/0.1.0-alpha.2 \ No newline at end of file diff --git a/docker-compose-deploy.yaml b/docker-compose-deploy.yaml index 73c9d88..ba13691 100644 --- a/docker-compose-deploy.yaml +++ b/docker-compose-deploy.yaml @@ -1,5 +1,5 @@ -# PHARUS_VERSION=0.1.0b0 DJLABBOOK_VERSION=0.1.0-beta.0 docker-compose -f docker-compose-deploy.yaml pull -# PHARUS_VERSION=0.1.0b0 DJLABBOOK_VERSION=0.1.0-beta.0 docker-compose -f docker-compose-deploy.yaml up -d +# PHARUS_VERSION=0.1.0b0 DJLABBOOK_VERSION=0.1.0-beta.1 docker-compose -f docker-compose-deploy.yaml pull +# PHARUS_VERSION=0.1.0b0 DJLABBOOK_VERSION=0.1.0-beta.1 docker-compose -f docker-compose-deploy.yaml up -d # # Intended for production deployment. # Note: You must run both commands above for minimal outage. diff --git a/package-lock.json b/package-lock.json index f91a5b7..1fadab8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "datajoint-labbook", - "version": "0.1.0-beta.0", + "version": "0.1.0-beta.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 68ddf08..7b47235 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "datajoint-labbook", - "version": "0.1.0-beta.0", + "version": "0.1.0-beta.1", "description": "A frontend with graphical user interface for DataJoint pipelines built using React.", "private": false, "repository": {