dept
Overview¶
This is an object for reading "Depts" information in "Server Script". It is retrieved using the Get method of the "depts object".
Properties¶
| No | Property name | get | set | type | Description |
|---|---|---|---|---|---|
| 1 | DeptId | Yes | No | int | Department ID |
| 2 | DeptCode | Yes | No | string | Department code |
| 3 | DeptName | Yes | No | string | Department name |
Methods¶
| No | Name | Description |
|---|---|---|
| 1 | GetMembers | Get the "user object" of the users who belong to the group. |
Usage Examples¶
In the example below, the "dept object" of the department to which the logged-in user belongs is retrieved, and the department code and department name are output to the log.
let myDept = depts.Get(context.DeptId);
if (myDept) {
context.Log(`${myDept.DeptCode},${myDept.DeptName}`);
}