MCPcopy Create free account
hub / github.com/FlowiseAI/Flowise / runAgain

Function runAgain

packages/ui/src/views/evaluations/EvaluationResult.jsx:183–208  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

181 }
182
183 const runAgain = async () => {
184 const confirmPayload = {
185 title: `Run Again`,
186 description: `Initiate Rerun for Evaluation ${evaluation.name}?`,
187 confirmButtonName: 'Yes',
188 cancelButtonName: 'No'
189 }
190 const isConfirmed = await confirm(confirmPayload)
191
192 if (isConfirmed) {
193 runAgainApi.request(evaluation?.id)
194 enqueueSnackbar({
195 message: "Evaluation '" + evaluation.name + "' is running. Redirecting to evaluations page.",
196 options: {
197 key: new Date().getTime() + Math.random(),
198 variant: 'success',
199 action: (key) => (
200 <Button style={{ color: 'white' }} onClick={() => closeSnackbar(key)}>
201 <IconX />
202 </Button>
203 )
204 }
205 })
206 navigate(`/evaluations`)
207 }
208 }
209
210 const URLpath = document.location.pathname.toString().split('/')
211 const evalId = URLpath[URLpath.length - 1] === 'evaluation_rows' ? '' : URLpath[URLpath.length - 1]

Callers

nothing calls this directly

Calls 4

enqueueSnackbarFunction · 0.90
closeSnackbarFunction · 0.90
confirmFunction · 0.85
getTimeMethod · 0.45

Tested by

no test coverage detected