mirror of
https://gitee.com/nocobase/nocobase.git
synced 2025-07-02 03:02:19 +08:00
Merge branch 'main' into next
This commit is contained in:
commit
252cb00207
@ -86,7 +86,7 @@ function useVariables(config, options) {
|
|||||||
|
|
||||||
export default class extends Trigger {
|
export default class extends Trigger {
|
||||||
title = `{{t("Post-action event", { ns: "${NAMESPACE}" })}}`;
|
title = `{{t("Post-action event", { ns: "${NAMESPACE}" })}}`;
|
||||||
description = `{{t('Triggered after the completion of a request initiated through an action button or API, such as after adding, updating, or deleting data. Suitable for data processing, sending notifications, etc., after actions are completed.', { ns: "${NAMESPACE}" })}}`;
|
description = `{{t('Triggered after the completion of a request initiated through an action button or API, such as after adding or updating data. Suitable for data processing, sending notifications, etc., after actions are completed.', { ns: "${NAMESPACE}" })}}`;
|
||||||
fieldset = {
|
fieldset = {
|
||||||
collection: {
|
collection: {
|
||||||
type: 'string',
|
type: 'string',
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"Post-action event": "操作后事件",
|
"Post-action event": "操作后事件",
|
||||||
"Triggered after the completion of a request initiated through an action button or API, such as after adding, updating, or deleting data. Suitable for data processing, sending notifications, etc., after actions are completed.":
|
"Triggered after the completion of a request initiated through an action button or API, such as after adding or updating data. Suitable for data processing, sending notifications, etc., after actions are completed.":
|
||||||
"通过操作按钮或 API 发起请求时,在请求执行成功后触发该事件,比如新增、更新、删除操作之后。适用于在操作完成后进行数据处理、发送通知等。",
|
"通过操作按钮或 API 发起请求时,在请求执行成功后触发该事件,比如新增、更新操作之后。适用于在操作完成后进行数据处理、发送通知等。",
|
||||||
"Collection": "数据表",
|
"Collection": "数据表",
|
||||||
"The collection to which the triggered data belongs.": "触发数据所属的数据表。",
|
"The collection to which the triggered data belongs.": "触发数据所属的数据表。",
|
||||||
"Trigger mode": "触发模式",
|
"Trigger mode": "触发模式",
|
||||||
|
@ -8,8 +8,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
import { useFieldSchema } from '@formily/react';
|
||||||
|
import { isValid } from '@formily/shared';
|
||||||
|
|
||||||
import { Plugin } from '@nocobase/client';
|
import { Plugin, WorkflowConfig } from '@nocobase/client';
|
||||||
import { Registry } from '@nocobase/utils/client';
|
import { Registry } from '@nocobase/utils/client';
|
||||||
|
|
||||||
import { ExecutionPage } from './ExecutionPage';
|
import { ExecutionPage } from './ExecutionPage';
|
||||||
@ -91,6 +93,14 @@ export default class PluginWorkflowClient extends Plugin {
|
|||||||
|
|
||||||
this.app.schemaSettingsManager.add(customizeSubmitToWorkflowActionSettings);
|
this.app.schemaSettingsManager.add(customizeSubmitToWorkflowActionSettings);
|
||||||
|
|
||||||
|
this.app.schemaSettingsManager.addItem('actionSettings:delete', 'workflowConfig', {
|
||||||
|
Component: WorkflowConfig,
|
||||||
|
useVisible() {
|
||||||
|
const fieldSchema = useFieldSchema();
|
||||||
|
return isValid(fieldSchema?.['x-action-settings']?.triggerWorkflows);
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
this.registerTrigger('collection', CollectionTrigger);
|
this.registerTrigger('collection', CollectionTrigger);
|
||||||
this.registerTrigger('schedule', ScheduleTrigger);
|
this.registerTrigger('schedule', ScheduleTrigger);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user