Appearance
获取员工详情 API
| Path | Method | Created At |
|---|---|---|
| /api/accounts/employees/{id}/detail | GET | 2025-11-29 00:39:11 |
Request
| Key | Rule | Description |
|---|---|---|
| id | integer,min:0 | trans:validate.EMPLOYEE_NOT_FOUND |
Response
| Key | Type | Example | Comment |
|---|---|---|---|
| id | int | 1 | 员工编号 |
| name | string | 张三 | 姓名 |
| avatar | string | https://xxx.com/avatar.jpg | 头像 |
| username | string | ZhangSan | 登录用户名 |
| phone | string | 13912345678 | 手机号 |
| string | username@domain.com | 邮箱 | |
| departments | array | [{"id": 1, "name": "商务部门"}, {"id": 2, "name": "技术部门"}] | 所在部门列表 |
| positionName | string | 商务主管 | 岗位名称 |
| createdAt | string | 2024-01-02 03:04:05 | 加入时间 |
| isEmployee | bool | true | 是否为员工 |
TypeScript Result Example:
TypeScript
interface Result {
/** 员工编号 */
id: number;
/** 姓名 */
name: string;
/** 头像 */
avatar: string;
/** 登录用户名 */
username: string;
/** 手机号 */
phone: string;
/** 邮箱 */
email: string;
/** 所在部门列表 */
departments: any;
/** 岗位名称 */
positionName: string;
/** 加入时间 */
createdAt: string;
/** 是否为员工 */
isEmployee: any;
}