diff --git a/frontend/src/components/Billing.jsx b/frontend/src/components/Billing.jsx index c3687489..d3a65927 100644 --- a/frontend/src/components/Billing.jsx +++ b/frontend/src/components/Billing.jsx @@ -970,7 +970,7 @@ const Billing = (props) => { const isChildOrg = userdata.active_org.creator_org !== "" && userdata.active_org.creator_org !== undefined && userdata.active_org.creator_org !== null return ( -
+
{addDealModal} Billing & Licensing diff --git a/frontend/src/components/Branding.jsx b/frontend/src/components/Branding.jsx index 9dd40791..c3c32058 100644 --- a/frontend/src/components/Branding.jsx +++ b/frontend/src/components/Branding.jsx @@ -15,7 +15,7 @@ import { //import { useAlert const Branding = (props) => { - const { globalUrl, userdata, serverside, billingInfo, stripeKey, selectedOrganization, handleGetOrg, } = props; + const { globalUrl, userdata, serverside, billingInfo,clickedFromOrgTab, stripeKey, selectedOrganization, handleGetOrg, } = props; //const alert = useAlert(); const [publishingInfo, setPublishingInfo] = useState(""); const [publishRequirements, setPublishRequirements] = useState([]) @@ -103,7 +103,7 @@ const Branding = (props) => { } return ( -
+

Branding

diff --git a/frontend/src/components/CacheView.jsx b/frontend/src/components/CacheView.jsx index 4d4d02fe..4e4f2fdd 100644 --- a/frontend/src/components/CacheView.jsx +++ b/frontend/src/components/CacheView.jsx @@ -1,10 +1,10 @@ import React, { useState, useEffect } from "react"; import theme from "../theme.jsx"; -import { toast } from 'react-toastify'; -import ReactJson from "react-json-view"; - +import { toast } from 'react-toastify'; +import ReactJson from "react-json-view"; + import { - Typography, + Typography, Tooltip, Divider, TextField, @@ -22,8 +22,8 @@ import { } from "@mui/material"; import { - Link as LinkIcon, - AutoFixHigh as AutoFixHighIcon, + Link as LinkIcon, + AutoFixHigh as AutoFixHighIcon, Edit as EditIcon, FileCopy as FileCopyIcon, SelectAll as SelectAllIcon, @@ -46,7 +46,7 @@ import { Visibility as VisibilityIcon, VisibilityOff as VisibilityOffIcon, } from "@mui/icons-material"; -import { validateJson, } from "../views/Workflows.jsx"; +import { validateJson, } from "../views/Workflows.jsx"; const scrollStyle1 = { height: 100, @@ -64,9 +64,9 @@ const scrollStyle2 = { overflow: "scroll", } - + const CacheView = (props) => { - const { globalUrl, userdata, serverside, orgId } = props; + const { globalUrl, userdata, serverside, orgId, isSelectedDataStore } = props; const [orgCache, setOrgCache] = React.useState(""); const [listCache, setListCache] = React.useState([]); const [addCache, setAddCache] = React.useState(""); @@ -79,7 +79,7 @@ const CacheView = (props) => { const [dataValue, setDataValue] = React.useState({}); const [editCache, setEditCache] = React.useState(false); const [show, setShow] = useState({}); - + useEffect(() => { listOrgCache(orgId); }, []); @@ -155,22 +155,22 @@ const CacheView = (props) => { const deleteCache = (orgId, key) => { toast("Attempting to delete Cache"); - + // method: "DELETE", - const method = "POST" - //const url = `${globalUrl}/api/v1/orgs/${orgId}/cache/${key}` - const url = `${globalUrl}/api/v1/orgs/${orgId}/delete_cache` - const parsed = { - "org_id": orgId, - "key": key, - } - + const method = "POST" + //const url = `${globalUrl}/api/v1/orgs/${orgId}/cache/${key}` + const url = `${globalUrl}/api/v1/orgs/${orgId}/delete_cache` + const parsed = { + "org_id": orgId, + "key": key, + } + fetch(url, { - method: method, + method: method, headers: { Accept: "application/json", }, - body: JSON.stringify(parsed), + body: JSON.stringify(parsed), credentials: "include", }) .then((response) => { @@ -255,20 +255,20 @@ const CacheView = (props) => { }); }; - const isValidJson = validateJson(value) - const autoFixJson = (inputvalue) => { - console.log("inputvalue: ", inputvalue) - try { - var parsedjson = JSON.parse(inputvalue) - - // setValue() with the parsed json as string - setValue(JSON.stringify(parsedjson, null, 2)) - } catch (e) { - console.log("Error parsing JSON: ", e) - //return JSON.stringify(inputvalue); - } - } - + const isValidJson = validateJson(value) + const autoFixJson = (inputvalue) => { + console.log("inputvalue: ", inputvalue) + try { + var parsedjson = JSON.parse(inputvalue) + + // setValue() with the parsed json as string + setValue(JSON.stringify(parsedjson, null, 2)) + } catch (e) { + console.log("Error parsing JSON: ", e) + //return JSON.stringify(inputvalue); + } + } + const modalView = ( // console.log("key:", dataValue.key), //console.log("value:",dataValue.value), @@ -316,21 +316,21 @@ const CacheView = (props) => { />
-
- - Value - ({isValidJson.valid === true ? "Valid" : "Invalid"} JSON) - - - { - autoFixJson(value) - }} - > - - - -
+
+ + Value - ({isValidJson.valid === true ? "Valid" : "Invalid"} JSON) + + + { + autoFixJson(value) + }} + > + + + +
{ id="Valuefield" margin="normal" variant="outlined" - multiline - minRows={4} - maxRows={12} + multiline + minRows={4} + maxRows={12} //defaultValue={editCache ? dataValue.value : ""} - value={value} + value={value} onChange={(e) => setValue(e.target.value)} />
- - - + />} + + { if (index % 2 === 0) { bgColor = "#1f2023"; } - - const validate = validateJson(data.value); + + const validate = validateJson(data.value); return ( { primary={data.key} /> { - //handleReactJsonClipboard(copy); - }} - displayDataTypes={false} - onSelect={(select) => { - //HandleJsonCopy(showResult, select, data.action.label); - //console.log("SELECTED!: ", select); - }} - name={"value"} - /> - : - data.value + primary={validate.valid ? + { + //handleReactJsonClipboard(copy); + }} + displayDataTypes={false} + onSelect={(select) => { + //HandleJsonCopy(showResult, select, data.action.label); + //console.log("SELECTED!: ", select); + }} + name={"value"} + /> + : + data.value } /> { style={{ padding: "6px" }} onClick={() => { setEditCache(true) - setDataValue({ - "key": data.key, - "value":data.value - }) - setValue(data.value) + setDataValue({ + "key": data.key, + "value":data.value + }) + setValue(data.value) setModalOpen(true) }} > @@ -525,18 +525,18 @@ const CacheView = (props) => { { - window.open(`${globalUrl}/api/v1/orgs/${orgId}/cache/${data.key}?type=text&authorization=${data.public_authorization}`, "_blank"); - }} + window.open(`${globalUrl}/api/v1/orgs/${orgId}/cache/${data.key}?type=text&authorization=${data.public_authorization}`, "_blank"); + }} > - + diff --git a/frontend/src/components/Files.jsx b/frontend/src/components/Files.jsx index 106cd18d..c13bf067 100644 --- a/frontend/src/components/Files.jsx +++ b/frontend/src/components/Files.jsx @@ -41,7 +41,7 @@ import ShuffleCodeEditor from "../components/ShuffleCodeEditor1.jsx"; import theme from "../theme.jsx"; const Files = (props) => { - const { globalUrl, userdata, serverside, selectedOrganization, isCloud, } = props; + const { globalUrl, userdata, serverside, selectedOrganization, isCloud,isSelectedFiles } = props; const [files, setFiles] = React.useState([]); const [selectedNamespace, setSelectedNamespace] = React.useState("default"); @@ -617,16 +617,16 @@ const Files = (props) => { style={{ maxWidth: window.innerWidth > 1366 ? 1366 : 1200, margin: "auto", - padding: 20, + padding: isSelectedFiles ? null : 20, }} onDrop={uploadFile} > -
+
setLoadFileModalOpen(true)} > @@ -636,15 +636,15 @@ const Files = (props) => { {fileDownloadModal} -
-

Files

- +
+

Files

+ Files from Workflows are a way to store as well as edit files.{" "} Learn more @@ -659,6 +659,7 @@ const Files = (props) => { onClick={() => { upload.click(); }} + style={{backgroundColor: isSelectedFiles?'rgba(255, 132, 68, 0.2)':null, color:isSelectedFiles?"#FF8444":null, borderRadius:isSelectedFiles?200:null, width:isSelectedFiles?162:null, height:isSelectedFiles?40:null}} > Upload files @@ -678,7 +679,7 @@ const Files = (props) => { }} />