From 4f6657a3b9e3f22d051337e86c979710eee711bd Mon Sep 17 00:00:00 2001 From: bill bittner Date: Thu, 11 Jan 2018 15:37:32 -0800 Subject: [PATCH] added display of publishing status --- public/assets/js/publishFileFunctions.js | 8 ---- react/actions/index.js | 3 +- react/components/PublishStatus.jsx | 55 ++++++++++++++++++------ react/containers/PublishForm.jsx | 22 ++++++---- react/containers/PublishTool.jsx | 29 +++++++------ react/reducers/index.js | 20 ++++++--- 6 files changed, 89 insertions(+), 48 deletions(-) diff --git a/public/assets/js/publishFileFunctions.js b/public/assets/js/publishFileFunctions.js index 425d3094..38dac496 100644 --- a/public/assets/js/publishFileFunctions.js +++ b/public/assets/js/publishFileFunctions.js @@ -1,14 +1,6 @@ var stagedFiles = null; const publishFileFunctions = { - returnNullOrChannel: function () { - const channelRadio = document.getElementById('channel-radio'); - if (channelRadio.checked) { - const channelInput = document.getElementById('channel-name-select'); - return channelInput.value.trim(); - } - return null; - }, // Validate the publish submission and then trigger upload showUploadStartedMessage: function (){ console.log('starting upload'); diff --git a/react/actions/index.js b/react/actions/index.js index 45926bd1..3c730282 100644 --- a/react/actions/index.js +++ b/react/actions/index.js @@ -52,9 +52,10 @@ export function setPublishInChannel (channel) { }; }; -export function updatePublishStatus (status) { +export function updatePublishStatus (status, message) { return { type: PUBLISH_STATUS_UPDATE, status, + message, }; }; diff --git a/react/components/PublishStatus.jsx b/react/components/PublishStatus.jsx index 4f27e519..87ca9921 100644 --- a/react/components/PublishStatus.jsx +++ b/react/components/PublishStatus.jsx @@ -1,18 +1,49 @@ import React from 'react'; -class PublishStatus extends React.Component { - render () { - return ( -