Skip to main content

listDerogations

@svenvw/fdm-source


@svenvw/fdm-source / fdm-core/src / listDerogations

Function: listDerogations()

listDerogations(fdm, principal_id, b_id_farm): Promise<any[]>

Defined in: fdm-core/src/derogation.ts:162

Lists all derogations for a given farm.

This function checks if the principal has 'read' permission on the farm before returning the list.

Parameters

fdm

any

The FDM instance providing the connection to the database.

principal_id

any

The identifier of the principal requesting the list.

b_id_farm

any

The identifier of the farm.

Returns

Promise<any[]>

A Promise that resolves with a list of derogations for the specified farm.

Throws

If the principal does not have permission to read the farm's derogations.