UNPKG

@nocobase/plugin-workflow-aggregate

Version:

Used to aggregate data against the database in workflow, such as: statistics, sum, average, etc.

18 lines (17 loc) 607 B
/** * This file is part of the NocoBase (R) project. * Copyright (c) 2020-2024 NocoBase Co., Ltd. * Authors: NocoBase Team. * * This project is dual-licensed under AGPL-3.0 and NocoBase Commercial License. * For more information, please refer to: https://www.nocobase.com/agreement. */ import Joi from 'joi'; import { Processor, Instruction, FlowNodeModel } from '@nocobase/plugin-workflow'; export default class extends Instruction { configSchema: Joi.ObjectSchema<any>; run(node: FlowNodeModel, input: any, processor: Processor): Promise<{ result: any; status: 1; }>; }