@titaui/pc 1.12.9-beta.8 → 1.12.9-beta.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -145,9 +145,13 @@ var getSubordinateData = function getSubordinateData(_ref3) {
145
145
  if (authType == "okr") authTypeId = "62";
146
146
  if (authType == "performance") authTypeId = "31";
147
147
  if (authType == "total") authTypeId = "0";
148
- return _axios["default"].get("".concat(requestDomain(), "/api/v1/").concat(tenantId, "/").concat(userId, "/org/GetDepartmentSubordinates?objtype=").concat(authTypeId)).then(function (res) {
149
- var _res$data$Data$users = res.data.Data.users,
150
- users = _res$data$Data$users === void 0 ? [] : _res$data$Data$users;
148
+ return _axios["default"].get("".concat(requestDomain(), "/api/v2/").concat(tenantId, "/").concat(userId, "/org/subordinate?to_userId=").concat(userId)).then(function (res) {
149
+ // const { users = [] } = res.data.Data;
150
+ var data = res.data.Data;
151
+ var users = [];
152
+ data.forEach(function (ele) {
153
+ users.push(ele.user);
154
+ });
151
155
  var transUsers = (0, _utils.translateUsersToTreeNode)(users || []); // resolve && resolve([...transUsers]);
152
156
 
153
157
  return _toConsumableArray(transUsers);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@titaui/pc",
3
- "version": "1.12.9-beta.8",
3
+ "version": "1.12.9-beta.9",
4
4
  "nameCN": "",
5
5
  "description": "",
6
6
  "main": "lib/index.js",