Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
dify
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ai-tech
dify
Commits
d777184f
Commit
d777184f
authored
Mar 13, 2024
by
Joel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: http run
parent
1653e5ee
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
panel.tsx
web/app/components/workflow/nodes/http/panel.tsx
+6
-0
use-config.ts
web/app/components/workflow/nodes/http/use-config.ts
+2
-0
No files found.
web/app/components/workflow/nodes/http/panel.tsx
View file @
d777184f
...
@@ -15,6 +15,7 @@ import OutputVars, { VarItem } from '@/app/components/workflow/nodes/_base/compo
...
@@ -15,6 +15,7 @@ import OutputVars, { VarItem } from '@/app/components/workflow/nodes/_base/compo
import
{
Settings01
}
from
'@/app/components/base/icons/src/vender/line/general'
import
{
Settings01
}
from
'@/app/components/base/icons/src/vender/line/general'
import
type
{
NodePanelProps
}
from
'@/app/components/workflow/types'
import
type
{
NodePanelProps
}
from
'@/app/components/workflow/types'
import
BeforeRunForm
from
'@/app/components/workflow/nodes/_base/components/before-run-form'
import
BeforeRunForm
from
'@/app/components/workflow/nodes/_base/components/before-run-form'
import
ResultPanel
from
'@/app/components/workflow/run/result-panel'
const
i18nPrefix
=
'workflow.nodes.http'
const
i18nPrefix
=
'workflow.nodes.http'
...
@@ -55,8 +56,11 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
...
@@ -55,8 +56,11 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
varInputs
,
varInputs
,
inputVarValues
,
inputVarValues
,
setInputVarValues
,
setInputVarValues
,
runResult
,
}
=
useConfig
(
id
,
data
)
}
=
useConfig
(
id
,
data
)
// console.log(inputs)
return
(
return
(
<
div
className=
'mt-2'
>
<
div
className=
'mt-2'
>
<
div
className=
'px-4 pb-4 space-y-4'
>
<
div
className=
'px-4 pb-4 space-y-4'
>
...
@@ -67,6 +71,7 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
...
@@ -67,6 +71,7 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
}
}
>
>
<
VarList
<
VarList
nodeId=
{
id
}
readonly=
{
readOnly
}
readonly=
{
readOnly
}
list=
{
inputs
.
variables
}
list=
{
inputs
.
variables
}
onChange=
{
handleVarListChange
}
onChange=
{
handleVarListChange
}
...
@@ -173,6 +178,7 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
...
@@ -173,6 +178,7 @@ const Panel: FC<NodePanelProps<HttpNodeType>> = ({
runningStatus=
{
runningStatus
}
runningStatus=
{
runningStatus
}
onRun=
{
handleRun
}
onRun=
{
handleRun
}
onStop=
{
handleStop
}
onStop=
{
handleStop
}
result=
{
<
ResultPanel
{
...
runResult
}
showSteps=
{
false
}
/>
}
/>
/>
)
}
)
}
</
div
>
</
div
>
...
...
web/app/components/workflow/nodes/http/use-config.ts
View file @
d777184f
...
@@ -75,6 +75,7 @@ const useConfig = (id: string, payload: HttpNodeType) => {
...
@@ -75,6 +75,7 @@ const useConfig = (id: string, payload: HttpNodeType) => {
handleStop
,
handleStop
,
runInputData
,
runInputData
,
setRunInputData
,
setRunInputData
,
runResult
,
}
=
useOneStepRun
<
HttpNodeType
>
({
}
=
useOneStepRun
<
HttpNodeType
>
({
id
,
id
,
data
:
inputs
,
data
:
inputs
,
...
@@ -129,6 +130,7 @@ const useConfig = (id: string, payload: HttpNodeType) => {
...
@@ -129,6 +130,7 @@ const useConfig = (id: string, payload: HttpNodeType) => {
varInputs
,
varInputs
,
inputVarValues
,
inputVarValues
,
setInputVarValues
,
setInputVarValues
,
runResult
,
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment