mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-05 15:36:49 +08:00
添加工作流备注功能
This commit is contained in:
@@ -344,6 +344,10 @@ export const actionStepOptions = [
|
|||||||
title: i18n.global.t('actionStep.invokePlugin'),
|
title: i18n.global.t('actionStep.invokePlugin'),
|
||||||
value: '调用插件',
|
value: '调用插件',
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
title: i18n.global.t('actionStep.note'),
|
||||||
|
value: '备注',
|
||||||
|
},
|
||||||
]
|
]
|
||||||
|
|
||||||
// 操作步骤字典
|
// 操作步骤字典
|
||||||
|
|||||||
@@ -152,7 +152,7 @@ async function doDelete() {
|
|||||||
<VCardText>
|
<VCardText>
|
||||||
<VCol>
|
<VCol>
|
||||||
<div class="d-flex justify-space-between flex-wrap flex-md-nowrap flex-column flex-md-row">
|
<div class="d-flex justify-space-between flex-wrap flex-md-nowrap flex-column flex-md-row">
|
||||||
<div class="ma-auto">
|
<div class="ma-auto mt-5">
|
||||||
<div class="workflow-preview">
|
<div class="workflow-preview">
|
||||||
<VueFlow
|
<VueFlow
|
||||||
:nodes="nodes"
|
:nodes="nodes"
|
||||||
@@ -257,7 +257,7 @@ async function doDelete() {
|
|||||||
border: 1px solid rgba(var(--v-border-color), var(--v-border-opacity));
|
border: 1px solid rgba(var(--v-border-color), var(--v-border-opacity));
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
background-color: rgba(var(--v-theme-surface), 0.8);
|
background-color: rgba(var(--v-theme-surface), 0.8);
|
||||||
block-size: 320px;
|
block-size: 280px;
|
||||||
inline-size: 240px;
|
inline-size: 240px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,58 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import { useI18n } from 'vue-i18n'
|
||||||
|
|
||||||
|
const { t } = useI18n()
|
||||||
|
|
||||||
|
defineProps({
|
||||||
|
id: {
|
||||||
|
type: String,
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
data: {
|
||||||
|
type: Object,
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<VCard max-width="20rem" class="note-card">
|
||||||
|
<VCardItem class="py-2">
|
||||||
|
<template v-slot:prepend>
|
||||||
|
<VAvatar color="warning">
|
||||||
|
<VIcon icon="mdi-note-text" size="x-large"></VIcon>
|
||||||
|
</VAvatar>
|
||||||
|
</template>
|
||||||
|
<VCardTitle>{{ t('workflow.note.title') }}</VCardTitle>
|
||||||
|
</VCardItem>
|
||||||
|
<VDivider />
|
||||||
|
<VCardText>
|
||||||
|
<VRow>
|
||||||
|
<VCol cols="12">
|
||||||
|
<VTextarea
|
||||||
|
v-model="data.content"
|
||||||
|
:label="t('workflow.note.content')"
|
||||||
|
:placeholder="t('workflow.note.placeholder')"
|
||||||
|
outlined
|
||||||
|
dense
|
||||||
|
auto-grow
|
||||||
|
rows="3"
|
||||||
|
max-rows="6"
|
||||||
|
clearable
|
||||||
|
/>
|
||||||
|
</VCol>
|
||||||
|
</VRow>
|
||||||
|
</VCardText>
|
||||||
|
</VCard>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.note-card {
|
||||||
|
background: linear-gradient(135deg, rgba(var(--v-theme-warning), 0.1) 0%, rgba(var(--v-theme-warning), 0.05) 100%);
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
border-color: rgba(var(--v-theme-warning), 0.4);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -74,6 +74,7 @@ function getActionIcon(type: string): string {
|
|||||||
'SendMessageAction': 'mdi-message-arrow-right',
|
'SendMessageAction': 'mdi-message-arrow-right',
|
||||||
'TransferFileAction': 'mdi-file-move',
|
'TransferFileAction': 'mdi-file-move',
|
||||||
'InvokePluginAction': 'mdi-run',
|
'InvokePluginAction': 'mdi-run',
|
||||||
|
'NoteAction': 'mdi-note-text',
|
||||||
}
|
}
|
||||||
|
|
||||||
return iconMap[type] || 'mdi-puzzle-outline'
|
return iconMap[type] || 'mdi-puzzle-outline'
|
||||||
|
|||||||
@@ -93,6 +93,7 @@ export default {
|
|||||||
sendMessage: 'Send Message',
|
sendMessage: 'Send Message',
|
||||||
transferFile: 'Transfer File',
|
transferFile: 'Transfer File',
|
||||||
invokePlugin: 'Invoke Plugin',
|
invokePlugin: 'Invoke Plugin',
|
||||||
|
note: 'Note',
|
||||||
},
|
},
|
||||||
qualityOptions: {
|
qualityOptions: {
|
||||||
all: 'All',
|
all: 'All',
|
||||||
@@ -660,6 +661,12 @@ export default {
|
|||||||
actionParams: 'Action Parameters',
|
actionParams: 'Action Parameters',
|
||||||
loadPluginSettingFailed: 'Failed to load plugin settings',
|
loadPluginSettingFailed: 'Failed to load plugin settings',
|
||||||
},
|
},
|
||||||
|
note: {
|
||||||
|
title: 'Note',
|
||||||
|
subtitle: 'Add workflow description notes',
|
||||||
|
content: 'Note Content',
|
||||||
|
placeholder: 'Please enter note content...',
|
||||||
|
},
|
||||||
title: 'Workflow',
|
title: 'Workflow',
|
||||||
share: 'Workflow Share',
|
share: 'Workflow Share',
|
||||||
searchShares: 'Search Workflow Shares',
|
searchShares: 'Search Workflow Shares',
|
||||||
|
|||||||
@@ -93,6 +93,7 @@ export default {
|
|||||||
sendMessage: '发送消息',
|
sendMessage: '发送消息',
|
||||||
transferFile: '整理文件',
|
transferFile: '整理文件',
|
||||||
invokePlugin: '调用插件',
|
invokePlugin: '调用插件',
|
||||||
|
note: '备注',
|
||||||
},
|
},
|
||||||
qualityOptions: {
|
qualityOptions: {
|
||||||
all: '全部',
|
all: '全部',
|
||||||
@@ -657,6 +658,12 @@ export default {
|
|||||||
actionParams: '动作参数',
|
actionParams: '动作参数',
|
||||||
loadPluginSettingFailed: '加载插件设置失败',
|
loadPluginSettingFailed: '加载插件设置失败',
|
||||||
},
|
},
|
||||||
|
note: {
|
||||||
|
title: '备注',
|
||||||
|
subtitle: '添加流程说明注释',
|
||||||
|
content: '备注内容',
|
||||||
|
placeholder: '请输入备注内容...',
|
||||||
|
},
|
||||||
title: '工作流',
|
title: '工作流',
|
||||||
share: '工作流分享',
|
share: '工作流分享',
|
||||||
searchShares: '搜索工作流分享',
|
searchShares: '搜索工作流分享',
|
||||||
|
|||||||
@@ -93,6 +93,7 @@ export default {
|
|||||||
sendMessage: '發送消息',
|
sendMessage: '發送消息',
|
||||||
transferFile: '整理文件',
|
transferFile: '整理文件',
|
||||||
invokePlugin: '調用插件',
|
invokePlugin: '調用插件',
|
||||||
|
note: '備註',
|
||||||
},
|
},
|
||||||
qualityOptions: {
|
qualityOptions: {
|
||||||
all: '全部',
|
all: '全部',
|
||||||
@@ -655,6 +656,12 @@ export default {
|
|||||||
actionParams: '動作參數',
|
actionParams: '動作參數',
|
||||||
loadPluginSettingFailed: '加載插件設置失敗',
|
loadPluginSettingFailed: '加載插件設置失敗',
|
||||||
},
|
},
|
||||||
|
note: {
|
||||||
|
title: '備註',
|
||||||
|
subtitle: '添加流程說明註釋',
|
||||||
|
content: '備註內容',
|
||||||
|
placeholder: '請輸入備註內容...',
|
||||||
|
},
|
||||||
title: '工作流',
|
title: '工作流',
|
||||||
share: '工作流分享',
|
share: '工作流分享',
|
||||||
searchShares: '搜索工作流分享',
|
searchShares: '搜索工作流分享',
|
||||||
|
|||||||
Reference in New Issue
Block a user