[IN_DEPARTMENT] - In Department

22-Aug-2022 · Felix Fung

What is this?

A Yes/No question variable.

Check whether the Placement is assigned to a certain Department. Department Code would be used in the formula.

What will the Value be Returned?

Y - if the Placement is under the specified Department by the end of the Pay Period.

N - if the Placement is not under the specified Department by the end of the Pay Period

Usage

Hightlight part content can be changed

1. Basic Form

Check single Department.

If the condition is correct, return the 1st value. Otherwise, returns the 2nd value.

Payroll Variable Description Usage
[IN_DEPARTMENT(Department Code)] Check whether the Placement is assigned to a certain Department Only staff under HR&Admin Department would have HKD 1,000 allowance
IIF ('[IN_DEPARTMENT(HR&ADMIN)]'='Y', 1000,0)

Staff not under Sales Department use 1,000 as pay rate. Only Sales Dapartment staff use Avervage Daily Wages as pay rate
IIF ('[IN_DEPARTMENT(SALES)]'='N',1000,[ADW])

2. Parameters/Variations

Parameters/Variations Description Usage
| Check Multiple Departments [IN_DEPARTMENT(SALES|IT|HR&ADMIN)]

                                                                                                               

{"status":"error","code":2,"details":null,"message":"An unexpected error occurred! Enable debug mode for more info: https:\/\/getkirby.com\/docs\/reference\/system\/options\/debug"}{"status":"error","code":32,"details":null,"message":"An unexpected error occurred! Enable debug mode for more info: https:\/\/getkirby.com\/docs\/reference\/system\/options\/debug"}