dagster-dingtalk 0.1.20__py3-none-any.whl → 0.1.22__py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
dagster_dingtalk/app_client.py
CHANGED
@@ -99,6 +99,30 @@ class 智能人事_花名册_API:
|
|
99
99
|
)
|
100
100
|
return response.json()
|
101
101
|
|
102
|
+
def 获取花名册字段组详情(self) -> dict:
|
103
|
+
response = self.__client.oapi.post(
|
104
|
+
url="/topapi/smartwork/hrm/employee/field/grouplist",
|
105
|
+
json={"agentid": self.__client.agent_id},
|
106
|
+
)
|
107
|
+
return response.json()
|
108
|
+
|
109
|
+
def 更新员工花名册信息(self, user_id: str, groups: List[dict]) -> dict:
|
110
|
+
"""
|
111
|
+
花名册分组数据结构查看 https://open.dingtalk.com/document/orgapp/intelligent-personnel-update-employee-file-information
|
112
|
+
:param user_id: 被更新字段信息的员工userid
|
113
|
+
:param groups: 花名册分组
|
114
|
+
:return:
|
115
|
+
"""
|
116
|
+
response = self.__client.oapi.post(
|
117
|
+
url="/topapi/smartwork/hrm/employee/v2/update",
|
118
|
+
json={
|
119
|
+
"agentid": self.__client.agent_id,
|
120
|
+
"param": {"groups": groups},
|
121
|
+
"user_id": user_id
|
122
|
+
},
|
123
|
+
)
|
124
|
+
return response.json()
|
125
|
+
|
102
126
|
def 获取员工花名册字段信息(self, user_id_list:List[str], field_filter_list:List[str]|None = None, text_to_select_convert:bool|None = None) -> dict:
|
103
127
|
body_dict = {"userIdList": user_id_list, "appAgentId": self.__client.agent_id}
|
104
128
|
if field_filter_list is not None:
|
@@ -106,7 +130,7 @@ class 智能人事_花名册_API:
|
|
106
130
|
if text_to_select_convert is not None:
|
107
131
|
body_dict["text2SelectConvert"] = text_to_select_convert
|
108
132
|
|
109
|
-
response = self.__client.api.post(url="/
|
133
|
+
response = self.__client.api.post(url="/v1.0/hrm/rosters/lists/query", json=body_dict, )
|
110
134
|
return response.json()
|
111
135
|
|
112
136
|
# noinspection NonAsciiCharacters
|
@@ -175,6 +199,15 @@ class 通讯录管理_用户管理_API:
|
|
175
199
|
response = self.__client.api.get(url="/v1.0/contact/empLeaveRecords", params=params)
|
176
200
|
return response.json()
|
177
201
|
|
202
|
+
def 获取部门用户userid列表(self, dept_id: int):
|
203
|
+
response = self.__client.oapi.post(url="/topapi/user/listid", json={"dept_id": dept_id})
|
204
|
+
return response.json()
|
205
|
+
|
206
|
+
def 根据unionid获取用户userid(self, unionid: str):
|
207
|
+
response = self.__client.oapi.post(url="/topapi/user/getbyunionid", json={"unionid": unionid})
|
208
|
+
return response.json()
|
209
|
+
|
210
|
+
|
178
211
|
# noinspection NonAsciiCharacters
|
179
212
|
class 通讯录管理_部门管理_API:
|
180
213
|
def __init__(self, _client:DingTalkClient):
|
@@ -1,8 +1,8 @@
|
|
1
1
|
dagster_dingtalk/__init__.py,sha256=jAyn67nRx5wU0YYWDMRINn7Tt3joP5IXsztTtyMbxsE,424
|
2
|
-
dagster_dingtalk/app_client.py,sha256=
|
2
|
+
dagster_dingtalk/app_client.py,sha256=9HnIe0Tr6y06SzVAOvVeZ2dJ30zl0syqfPK_IzRfkUo,27831
|
3
3
|
dagster_dingtalk/operations.py,sha256=C1wwXCW7mpKhLC1-Y7TCP_72L9e93a9ceVHRWhNda-Q,3891
|
4
4
|
dagster_dingtalk/resources.py,sha256=1u8-oXRa7H_e0CAYkTJDxbjEmt3ZcD_ntBNvrS_rwr8,17430
|
5
5
|
dagster_dingtalk/version.py,sha256=ncWWGHPke5qy2-s8w3nAgDE4R__CZi-Q7CLWtmtkbvA,25
|
6
|
-
dagster_dingtalk-0.1.
|
7
|
-
dagster_dingtalk-0.1.
|
8
|
-
dagster_dingtalk-0.1.
|
6
|
+
dagster_dingtalk-0.1.22.dist-info/METADATA,sha256=KkxV5-h7oj7oj0IQ_nRzxSG8yJLLbHavauo0kRzxGKk,7996
|
7
|
+
dagster_dingtalk-0.1.22.dist-info/WHEEL,sha256=Nq82e9rUAnEjt98J6MlVmMCZb-t9cYE2Ir1kpBmnWfs,88
|
8
|
+
dagster_dingtalk-0.1.22.dist-info/RECORD,,
|
File without changes
|