# Variable webMobileCommons

webMobileCommons: {
get_extra_menu: (
role: number,
__: (str: string) => string,
user?: User,
locale?: string,
req?: Req,
) => any;
getWorkflowStepUserForm: (
run: WorkflowRun,
trigger: Trigger,
step: WorkflowStep,
req: any,
res: any,
) => Promise<Form>;
prepare_insert_row: (row: any, fields: Field[]) => Promise<any>;
prepare_update_row: (
table: Table,
row: any,
id: number,
) => Promise<string[]>;
show_calculated_fieldview: (
req: any,
res: any,
param2: { fieldName: string; fieldview: string; tableName: string },
) => Promise<any>;
}

#### Type Declaration

- ##### get_extra_menu: (
  role: number,
  __: (str: string) => string,
  user?: User,
  locale?: string,
  req?: Req,
  ) => any

  Get extra menu

- ##### getWorkflowStepUserForm: (
  run: WorkflowRun,
  trigger: Trigger,
  step: WorkflowStep,
  req: any,
  res: any,
  ) => Promise<Form>

  prepare a form for a workflow step

- ##### prepare_insert_row: (row: any, fields: Field[]) => Promise<any>

  take a row from a form, and prepare it for a db insert needed for tabulator

- ##### prepare_update_row: (table: Table, row: any, id: number) => Promise<string[]>

  take a row from a form, and prepare it for a db update needed for tabulator

- ##### show_calculated_fieldview: (
  req: any,
  res: any,
  param2: { fieldName: string; fieldview: string; tableName: string },
  ) => Promise<any>

- Defined in packages/saltcorn-data/web-mobile-commons.ts:589