Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/candidate-9.2.x' into candidate-…
Browse files Browse the repository at this point in the history
…9.4.x

Signed-off-by: Gordon Smith <[email protected]>

# Conflicts:
#	helm/hpcc/Chart.yaml
#	helm/hpcc/templates/_helpers.tpl
#	helm/hpcc/templates/dafilesrv.yaml
#	helm/hpcc/templates/dali.yaml
#	helm/hpcc/templates/dfuserver.yaml
#	helm/hpcc/templates/eclagent.yaml
#	helm/hpcc/templates/eclccserver.yaml
#	helm/hpcc/templates/eclscheduler.yaml
#	helm/hpcc/templates/esp.yaml
#	helm/hpcc/templates/localroxie.yaml
#	helm/hpcc/templates/roxie.yaml
#	helm/hpcc/templates/sasha.yaml
#	helm/hpcc/templates/thor.yaml
#	version.cmake
  • Loading branch information
GordonSmith committed May 9, 2024
2 parents a006f6c + f28e5b6 commit 729fa4f
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 5 deletions.
11 changes: 8 additions & 3 deletions esp/src/src-react/components/ECLPlayground.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const logger = scopedLogger("../components/ECLPlayground.tsx");

interface ECLPlaygroundProps {
wuid?: string;
ecl?: string;
}

const enum OutputMode {
Expand Down Expand Up @@ -339,7 +340,7 @@ const ECLEditorToolbar: React.FunctionComponent<ECLEditorToolbarProps> = ({

export const ECLPlayground: React.FunctionComponent<ECLPlaygroundProps> = (props) => {

const { wuid } = props;
const { wuid, ecl } = props;
const theme = useTheme();

const [outputMode, setOutputMode] = React.useState<OutputMode>(OutputMode.ERRORS);
Expand All @@ -363,13 +364,17 @@ export const ECLPlayground: React.FunctionComponent<ECLPlaygroundProps> = (props
setOutputMode(OutputMode.RESULTS);
}
});
} else if (ecl) {
setEclContent(ecl);
}

fetch("/esp/files/eclwatch/ecl/ECLPlaygroundSamples.json")
.then(response => response.json())
.then(json => setEclSamples(
json.items.map(item => {
if (item.selected && !wuid) setSelectedEclSample(item.filename);
if (item.selected && !wuid && !ecl) {
setSelectedEclSample(item.filename);
}
return { key: item.filename, text: item.name };
})
));
Expand All @@ -381,7 +386,7 @@ export const ECLPlayground: React.FunctionComponent<ECLPlaygroundProps> = (props
editor.option("theme", "default");
}
}
}, [wuid, editor, theme]);
}, [wuid, editor, theme, ecl]);

React.useEffect(() => {
fetch(`/esp/files/eclwatch/ecl/${selectedEclSample}`)
Expand Down
6 changes: 6 additions & 0 deletions esp/src/src-react/components/Files.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,12 @@ export const Files: React.FunctionComponent<FilesProps> = ({
return Utility.convertedSize(row.IntSize);
},
},
CompressedFileSizeString: {
label: nlsHPCC.CompressedSize,
formatter: (value, row) => {
return Utility.convertedSize(row.CompressedFileSize);
}
},
Parts: {
label: nlsHPCC.Parts, width: 40,
},
Expand Down
4 changes: 2 additions & 2 deletions esp/src/src-react/routes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ export const routes: RoutesEx = [
path: ["/play", "/playground"],
children: [
{
path: "", action: () => import("./components/ECLPlayground").then(_ => {
return <_.ECLPlayground />;
path: "", action: (ctx, params) => import("./components/ECLPlayground").then(_ => {
return <_.ECLPlayground ecl={parseSearch(ctx.search)?.ecl as string} />;
})
},
{
Expand Down

0 comments on commit 729fa4f

Please sign in to comment.