Fixed docker compose with :z instead
This commit is contained in:
@@ -2687,9 +2687,9 @@ const ParsedAction = (props) => {
|
||||
disableScrollLock: true,
|
||||
}}
|
||||
value={
|
||||
selectedActionEnvironment === undefined ||
|
||||
selectedActionEnvironment.Name === undefined
|
||||
? ""
|
||||
selectedActionEnvironment === undefined || selectedActionEnvironment === null ||
|
||||
selectedActionEnvironment.Name === undefined || selectedActionEnvironment.Name === null
|
||||
? isCloud ? "Cloud" : "Shuffle"
|
||||
: selectedActionEnvironment.Name
|
||||
}
|
||||
SelectDisplayProps={{
|
||||
@@ -2738,13 +2738,17 @@ const ParsedAction = (props) => {
|
||||
workflow.execution_variables !== null &&
|
||||
workflow.execution_variables.length > 0 ? (
|
||||
<div style={{ marginTop: "20px" }}>
|
||||
<Typography>Set execution variable (optional)</Typography>
|
||||
<Typography>Execution variable (optional)</Typography>
|
||||
<Select
|
||||
MenuProps={{
|
||||
disableScrollLock: true,
|
||||
}}
|
||||
value={
|
||||
selectedAction.execution_variable !== undefined
|
||||
&& selectedAction.execution_variable !== null
|
||||
&& selectedAction.execution_variable.name !== undefined
|
||||
&& selectedAction.execution_variable.name !== null
|
||||
&& selectedAction.execution_variable.name.length > 0
|
||||
? selectedAction.execution_variable.name
|
||||
: "No selection"
|
||||
}
|
||||
|
||||
@@ -1079,6 +1079,10 @@ const AngularWorkflow = (defaultprops) => {
|
||||
curworkflowAction.parameters = newparams;
|
||||
newActions.push(curworkflowAction);
|
||||
} else if (type === "TRIGGER") {
|
||||
if (useworkflow.triggers === undefined || useworkflow.triggers === null) {
|
||||
useworkflow.triggers = [];
|
||||
}
|
||||
|
||||
var curworkflowTrigger = useworkflow.triggers.find(
|
||||
(a) => a.id === cyelements[key].data()["id"]
|
||||
);
|
||||
@@ -1090,7 +1094,7 @@ const AngularWorkflow = (defaultprops) => {
|
||||
|
||||
newTriggers.push(curworkflowTrigger);
|
||||
} else if (type === "COMMENT") {
|
||||
if (useworkflow.comments === undefined) {
|
||||
if (useworkflow.comments === undefined || useworkflow.comments === null) {
|
||||
useworkflow.comments = [];
|
||||
}
|
||||
|
||||
@@ -2567,6 +2571,7 @@ const AngularWorkflow = (defaultprops) => {
|
||||
}
|
||||
}
|
||||
|
||||
console.log("ACTION: ", curaction)
|
||||
setSelectedApp(curapp);
|
||||
setSelectedAction(curaction);
|
||||
|
||||
@@ -8544,22 +8549,34 @@ const AngularWorkflow = (defaultprops) => {
|
||||
onChange={(event, newValue) => {
|
||||
handleWorkflowSelectionUpdate({ target: { value: newValue} })
|
||||
}}
|
||||
renderOption={(data) => {
|
||||
renderOption={(data, index) => {
|
||||
if (data.id === workflow.id) {
|
||||
data = workflow;
|
||||
}
|
||||
|
||||
//key={index}
|
||||
return (
|
||||
<MenuItem
|
||||
style={{
|
||||
backgroundColor: theme.palette.inputColor,
|
||||
color: data.id === workflow.id ? "red" : "white",
|
||||
}}
|
||||
value={data}
|
||||
>
|
||||
{data.name}
|
||||
</MenuItem>
|
||||
<Tooltip arrow placement="left" title={
|
||||
<span style={{}}>
|
||||
{data.image !== undefined && data.image !== null && data.image.length > 0 ?
|
||||
<img src={data.image} alt={data.name} style={{backgroundColor: theme.palette.surfaceColor, maxHeight: 200, minHeigth: 200, borderRadius: theme.palette.borderRadius, }} />
|
||||
: null}
|
||||
<Typography>
|
||||
Choose {data.name}
|
||||
</Typography>
|
||||
</span>
|
||||
} placement="bottom">
|
||||
<MenuItem
|
||||
style={{
|
||||
backgroundColor: theme.palette.inputColor,
|
||||
color: data.id === workflow.id ? "red" : "white",
|
||||
}}
|
||||
key={index}
|
||||
value={data}
|
||||
>
|
||||
{data.name}
|
||||
</MenuItem>
|
||||
</Tooltip>
|
||||
)
|
||||
}}
|
||||
renderInput={(params) => {
|
||||
|
||||
+14
-14
@@ -544,7 +544,6 @@ const Apps = (props) => {
|
||||
data.name = newAppname;
|
||||
setSelectedApp(data);
|
||||
|
||||
console.log(data);
|
||||
if (
|
||||
data.actions !== undefined &&
|
||||
data.actions !== null &&
|
||||
@@ -747,20 +746,21 @@ const Apps = (props) => {
|
||||
) : null;
|
||||
|
||||
//var editNewButton = editButton === null ?
|
||||
console.log("User, & genrrated, activate: ", props.userdata, selectedApp.generated, selectedApp.activated)
|
||||
var editNewButton = selectedApp.generated && selectedApp.activated && props.userdata.id !== selectedApp.owner ?
|
||||
<Link to={activateUrl} style={{ textDecoration: "none" }}>
|
||||
<Tooltip title={"Edit this public app to your liking"}>
|
||||
<Button
|
||||
variant="contained"
|
||||
component="label"
|
||||
color="primary"
|
||||
style={{ marginTop: 10, marginRight: 10 }}
|
||||
>
|
||||
<EditIcon />
|
||||
</Button>
|
||||
</Tooltip>
|
||||
</Link>
|
||||
isCloud ?
|
||||
<Link to={activateUrl} style={{ textDecoration: "none" }}>
|
||||
<Tooltip title={"Edit this public app to your liking"}>
|
||||
<Button
|
||||
variant="contained"
|
||||
component="label"
|
||||
color="primary"
|
||||
style={{ marginTop: 10, marginRight: 10 }}
|
||||
>
|
||||
<EditIcon />
|
||||
</Button>
|
||||
</Tooltip>
|
||||
</Link>
|
||||
: null
|
||||
: null
|
||||
|
||||
const activateButton =
|
||||
|
||||
@@ -460,9 +460,7 @@ export const validateJson = (showResult) => {
|
||||
try {
|
||||
for (const [key, value] of Object.entries(result)) {
|
||||
if (typeof value === "string" && (value.startsWith("{") || value.startsWith("["))) {
|
||||
console.log("INSIDE: ", key, value);
|
||||
const inside_result = validateJson(value)
|
||||
console.log("Inside: ", inside_result)
|
||||
if (inside_result.valid) {
|
||||
console.log("Replacing value since it's valid JSON!")
|
||||
if (typeof inside_result.result === "string") {
|
||||
@@ -970,7 +968,6 @@ const Workflows = (props) => {
|
||||
};
|
||||
|
||||
const handleKeysetting = (categorydata, workflows) => {
|
||||
console.log("Workflows: ", workflows)
|
||||
//workflows[0].category = ["detect"]
|
||||
//workflows[0].usecase_ids = ["Correlate tickets"]
|
||||
|
||||
@@ -1011,7 +1008,6 @@ const Workflows = (props) => {
|
||||
newcategories.push(category)
|
||||
}
|
||||
|
||||
console.log("Categories: ", newcategories)
|
||||
setUsecases(newcategories)
|
||||
} else {
|
||||
setUsecases(categorydata)
|
||||
@@ -1036,7 +1032,6 @@ const Workflows = (props) => {
|
||||
})
|
||||
.then((responseJson) => {
|
||||
if (responseJson.success !== false) {
|
||||
console.log("Usecases: ", responseJson)
|
||||
handleKeysetting(responseJson, workflows)
|
||||
}
|
||||
})
|
||||
@@ -1976,7 +1971,6 @@ const Workflows = (props) => {
|
||||
}
|
||||
|
||||
const new_url = `${globalUrl}/api/v1/workflows${extraData}`
|
||||
console.log("Got new url: ", new_url)
|
||||
return fetch(new_url, {
|
||||
method: method,
|
||||
headers: {
|
||||
|
||||
Reference in New Issue
Block a user