mirror of
https://github.com/fofolee/uTools-quickcommand.git
synced 2025-12-19 18:25:44 +08:00
重构Composer组件中的变量管理:改为FlowManager,支持函数名和标识的修改,新增函数时自动弹出管理界面
This commit is contained in:
@@ -92,8 +92,8 @@ export default defineComponent({
|
||||
},
|
||||
},
|
||||
setup() {
|
||||
const getCurrentVariables = inject("getCurrentVariables");
|
||||
return { getCurrentVariables };
|
||||
const getCurrentExistingVar = inject("getCurrentExistingVar");
|
||||
return { getCurrentExistingVar };
|
||||
},
|
||||
emits: ["update:modelValue", "add-command", "action"],
|
||||
data() {
|
||||
@@ -296,7 +296,7 @@ export default defineComponent({
|
||||
if (newCommand.saveOutput && newCommand.outputVariable) {
|
||||
newCommand.outputVariable = processVariable({
|
||||
value: newCommand.outputVariable,
|
||||
existingVars: this.getCurrentVariables().map((v) => v.name),
|
||||
existingVars: this.getCurrentExistingVar().map((v) => v.name),
|
||||
}).processedValue;
|
||||
}
|
||||
return newCommand;
|
||||
|
||||
Reference in New Issue
Block a user