0
Dynamics enums in Approval Step Approval
One script reply has been approved by the moderators Verified

As one of the return key of this step, return an object enums that contains the default arguments of the form arguments.

Created by henri186 251 days ago Viewed 7635 times
1
Submitted by henri186 Deno
Verified 251 days ago
1
//this assumes the Form tab has a string field named "foo"
2

3
import * as wmill from "npm:windmill-client@^1.158.2"
4

5
export async function main() {
6
    // if no argument is passed, if user is logged in, it will use the user's username
7
    const resumeUrls = await wmill.getResumeUrls("approver1") 
8

9
    // send the resumeUrls to the recipient or see Prompt section above
10

11
    return {
12
        enums: {
13
            foo: ["choice1", "choice2"]
14
        },
15
    }
16
}