feat(oa): 添加部门ID字段和按编号查询金蝶同步信息功能
- 在部门结构体中添加DepartmentId字段用于存储部门ID - 新增Ik3cloudInfoByNumber方法支持通过部门编号查询金蝶同步信息 - 实现基于部门编号的金蝶信息获取接口 - 保持原有金蝶同步功能的完整性
This commit is contained in:
@@ -121,6 +121,7 @@ type ReplyDepartmentIk3cloudInfo struct {
|
|||||||
Number string `json:"number"` // 金蝶员工编码
|
Number string `json:"number"` // 金蝶员工编码
|
||||||
PositionId int64 `json:"positionId"` // 金蝶部门职位id
|
PositionId int64 `json:"positionId"` // 金蝶部门职位id
|
||||||
PositionNumber string `json:"positionNumber"` // 金蝶部门职位编码
|
PositionNumber string `json:"positionNumber"` // 金蝶部门职位编码
|
||||||
|
DepartmentId int64 `json:"departmentId"` // 部门id
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ik3cloudInfo @TITLE 金蝶同步信息
|
// Ik3cloudInfo @TITLE 金蝶同步信息
|
||||||
@@ -133,6 +134,16 @@ func (d *department) Ik3cloudInfo(ctx context.Context, departmentId int64) (repl
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Ik3cloudInfoByNumber @TITLE 金蝶同步信息
|
||||||
|
func (d *department) Ik3cloudInfoByNumber(ctx context.Context, departmentNumber string) (reply ReplyDepartmentIk3cloudInfo, err error) {
|
||||||
|
xClient, err := client.GetClient(d)
|
||||||
|
if err != nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
err = xClient.Call(ctx, "Ik3cloudInfoByNumber", departmentNumber, &reply)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
// Ik3cloud @TITLE 金蝶集成
|
// Ik3cloud @TITLE 金蝶集成
|
||||||
func (d *department) Ik3cloud(ctx context.Context, departmentId int64) (err error) {
|
func (d *department) Ik3cloud(ctx context.Context, departmentId int64) (err error) {
|
||||||
xClient, err := client.GetClient(d)
|
xClient, err := client.GetClient(d)
|
||||||
|
|||||||
Reference in New Issue
Block a user