@atlaskit/teams-client 4.22.0 → 4.23.0
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.
- package/CHANGELOG.md +7 -0
- package/dist/cjs/common/utils/permissions/constants.js +5 -2
- package/dist/cjs/common/utils/permissions/types.js +1 -1
- package/dist/cjs/common/utils/ufo/constants.js +1 -1
- package/dist/cjs/common/utils/ufo/index.js +2 -2
- package/dist/cjs/services/legion-client/index.js +220 -196
- package/dist/cjs/services/main.js +566 -540
- package/dist/cjs/services/sentry/utils/get-sentry-config.js +1 -1
- package/dist/es2019/common/utils/permissions/constants.js +5 -2
- package/dist/es2019/common/utils/permissions/types.js +1 -1
- package/dist/es2019/common/utils/ufo/constants.js +1 -1
- package/dist/es2019/common/utils/ufo/index.js +2 -2
- package/dist/es2019/services/legion-client/index.js +8 -2
- package/dist/es2019/services/main.js +7 -0
- package/dist/es2019/services/sentry/utils/get-sentry-config.js +1 -1
- package/dist/esm/common/utils/permissions/constants.js +5 -2
- package/dist/esm/common/utils/permissions/types.js +1 -1
- package/dist/esm/common/utils/ufo/constants.js +1 -1
- package/dist/esm/common/utils/ufo/index.js +2 -2
- package/dist/esm/services/legion-client/index.js +220 -196
- package/dist/esm/services/main.js +566 -540
- package/dist/esm/services/sentry/utils/get-sentry-config.js +1 -1
- package/dist/types/common/utils/permissions/types.d.ts +1 -1
- package/dist/types/common/utils/ufo/constants.d.ts +2 -2
- package/dist/types/services/legion-client/index.d.ts +2 -1
- package/dist/types/services/main.d.ts +4 -0
- package/dist/types-ts4.5/common/utils/permissions/types.d.ts +1 -0
- package/dist/types-ts4.5/common/utils/ufo/constants.d.ts +2 -1
- package/dist/types-ts4.5/services/legion-client/index.d.ts +2 -1
- package/dist/types-ts4.5/services/main.d.ts +4 -0
- package/package.json +1 -1
|
@@ -700,6 +700,27 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
700
700
|
}
|
|
701
701
|
return unArchiveTeam;
|
|
702
702
|
}()
|
|
703
|
+
}, {
|
|
704
|
+
key: "unlinkTeamFromGroup",
|
|
705
|
+
value: function () {
|
|
706
|
+
var _unlinkTeamFromGroup = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee23(teamId, membershipSettings) {
|
|
707
|
+
return _regeneratorRuntime.wrap(function _callee23$(_context23) {
|
|
708
|
+
while (1) switch (_context23.prev = _context23.next) {
|
|
709
|
+
case 0:
|
|
710
|
+
return _context23.abrupt("return", this.patchResource("".concat(v4UrlPath, "/").concat(this.trimTeamARI(teamId)), {
|
|
711
|
+
membershipSettings: membershipSettings
|
|
712
|
+
}));
|
|
713
|
+
case 1:
|
|
714
|
+
case "end":
|
|
715
|
+
return _context23.stop();
|
|
716
|
+
}
|
|
717
|
+
}, _callee23, this);
|
|
718
|
+
}));
|
|
719
|
+
function unlinkTeamFromGroup(_x38, _x39) {
|
|
720
|
+
return _unlinkTeamFromGroup.apply(this, arguments);
|
|
721
|
+
}
|
|
722
|
+
return unlinkTeamFromGroup;
|
|
723
|
+
}()
|
|
703
724
|
/**
|
|
704
725
|
* @private
|
|
705
726
|
* @deprecated should be other means to solve this issue
|
|
@@ -707,23 +728,23 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
707
728
|
}, {
|
|
708
729
|
key: "isSingleFullMemberTeam",
|
|
709
730
|
value: (function () {
|
|
710
|
-
var _isSingleFullMemberTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
731
|
+
var _isSingleFullMemberTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee24(teamId) {
|
|
711
732
|
var members;
|
|
712
|
-
return _regeneratorRuntime.wrap(function
|
|
713
|
-
while (1) switch (
|
|
733
|
+
return _regeneratorRuntime.wrap(function _callee24$(_context24) {
|
|
734
|
+
while (1) switch (_context24.prev = _context24.next) {
|
|
714
735
|
case 0:
|
|
715
|
-
|
|
736
|
+
_context24.next = 2;
|
|
716
737
|
return this.getResource("".concat(v4UrlPath, "/").concat(this.trimTeamARI(teamId), "/members?size=2&membershipState=FULL_MEMBER&siteId=").concat(this.getCloudId()));
|
|
717
738
|
case 2:
|
|
718
|
-
members =
|
|
719
|
-
return
|
|
739
|
+
members = _context24.sent;
|
|
740
|
+
return _context24.abrupt("return", members.entities.length === 1);
|
|
720
741
|
case 4:
|
|
721
742
|
case "end":
|
|
722
|
-
return
|
|
743
|
+
return _context24.stop();
|
|
723
744
|
}
|
|
724
|
-
},
|
|
745
|
+
}, _callee24, this);
|
|
725
746
|
}));
|
|
726
|
-
function isSingleFullMemberTeam(
|
|
747
|
+
function isSingleFullMemberTeam(_x40) {
|
|
727
748
|
return _isSingleFullMemberTeam.apply(this, arguments);
|
|
728
749
|
}
|
|
729
750
|
return isSingleFullMemberTeam;
|
|
@@ -731,46 +752,49 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
731
752
|
}, {
|
|
732
753
|
key: "createTeam",
|
|
733
754
|
value: function () {
|
|
734
|
-
var _createTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
755
|
+
var _createTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee25(displayName, originQuery, members) {
|
|
735
756
|
var membershipSettings,
|
|
757
|
+
typeId,
|
|
736
758
|
organizationId,
|
|
737
759
|
err,
|
|
738
760
|
url,
|
|
739
761
|
legionTeam,
|
|
740
|
-
|
|
741
|
-
return _regeneratorRuntime.wrap(function
|
|
742
|
-
while (1) switch (
|
|
762
|
+
_args25 = arguments;
|
|
763
|
+
return _regeneratorRuntime.wrap(function _callee25$(_context25) {
|
|
764
|
+
while (1) switch (_context25.prev = _context25.next) {
|
|
743
765
|
case 0:
|
|
744
|
-
membershipSettings =
|
|
766
|
+
membershipSettings = _args25.length > 3 && _args25[3] !== undefined ? _args25[3] : 'OPEN';
|
|
767
|
+
typeId = _args25.length > 4 ? _args25[4] : undefined;
|
|
745
768
|
organizationId = this.getContext().orgId;
|
|
746
769
|
if (organizationId) {
|
|
747
|
-
|
|
770
|
+
_context25.next = 7;
|
|
748
771
|
break;
|
|
749
772
|
}
|
|
750
773
|
err = new Error('Organization ID is required');
|
|
751
774
|
this.logException(err, 'createTeam');
|
|
752
775
|
throw err;
|
|
753
|
-
case
|
|
776
|
+
case 7:
|
|
754
777
|
url = "".concat(v4UrlPath, "?").concat(this.constructProductOriginParams(originQuery));
|
|
755
|
-
|
|
778
|
+
_context25.next = 10;
|
|
756
779
|
return this.postResource(url, {
|
|
757
780
|
displayName: displayName,
|
|
758
781
|
description: '',
|
|
759
782
|
membershipSettings: membershipSettings,
|
|
760
783
|
siteId: this.getCloudId(),
|
|
761
784
|
organizationId: organizationId,
|
|
762
|
-
members: _toConsumableArray(new Set(members))
|
|
785
|
+
members: _toConsumableArray(new Set(members)),
|
|
786
|
+
typeId: typeId
|
|
763
787
|
});
|
|
764
|
-
case
|
|
765
|
-
legionTeam =
|
|
766
|
-
return
|
|
767
|
-
case
|
|
788
|
+
case 10:
|
|
789
|
+
legionTeam = _context25.sent;
|
|
790
|
+
return _context25.abrupt("return", this.mapTeamCreateResponseV4ToTeam(legionTeam));
|
|
791
|
+
case 12:
|
|
768
792
|
case "end":
|
|
769
|
-
return
|
|
793
|
+
return _context25.stop();
|
|
770
794
|
}
|
|
771
|
-
},
|
|
795
|
+
}, _callee25, this);
|
|
772
796
|
}));
|
|
773
|
-
function createTeam(
|
|
797
|
+
function createTeam(_x41, _x42, _x43) {
|
|
774
798
|
return _createTeam.apply(this, arguments);
|
|
775
799
|
}
|
|
776
800
|
return createTeam;
|
|
@@ -778,15 +802,15 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
778
802
|
}, {
|
|
779
803
|
key: "createExternalTeam",
|
|
780
804
|
value: function () {
|
|
781
|
-
var _createExternalTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
805
|
+
var _createExternalTeam = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee26(description, externalReference, teamName, siteId) {
|
|
782
806
|
var organizationId, cloudId, err, url, legionExternalTeam;
|
|
783
|
-
return _regeneratorRuntime.wrap(function
|
|
784
|
-
while (1) switch (
|
|
807
|
+
return _regeneratorRuntime.wrap(function _callee26$(_context26) {
|
|
808
|
+
while (1) switch (_context26.prev = _context26.next) {
|
|
785
809
|
case 0:
|
|
786
810
|
organizationId = this.getContext().orgId;
|
|
787
811
|
cloudId = this.getContext().cloudId;
|
|
788
812
|
if (organizationId) {
|
|
789
|
-
|
|
813
|
+
_context26.next = 6;
|
|
790
814
|
break;
|
|
791
815
|
}
|
|
792
816
|
err = new Error('Organization ID is required');
|
|
@@ -794,7 +818,7 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
794
818
|
throw err;
|
|
795
819
|
case 6:
|
|
796
820
|
url = "".concat(v4UrlPath, "/external?origin.cloudId=").concat(encodeURIComponent(this.getCloudId(siteId || cloudId)));
|
|
797
|
-
|
|
821
|
+
_context26.next = 9;
|
|
798
822
|
return this.postResource(url, {
|
|
799
823
|
description: description,
|
|
800
824
|
externalReference: externalReference,
|
|
@@ -803,15 +827,15 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
803
827
|
displayName: teamName
|
|
804
828
|
});
|
|
805
829
|
case 9:
|
|
806
|
-
legionExternalTeam =
|
|
807
|
-
return
|
|
830
|
+
legionExternalTeam = _context26.sent;
|
|
831
|
+
return _context26.abrupt("return", this.mapTeamCreateResponseV4ToTeam(legionExternalTeam));
|
|
808
832
|
case 11:
|
|
809
833
|
case "end":
|
|
810
|
-
return
|
|
834
|
+
return _context26.stop();
|
|
811
835
|
}
|
|
812
|
-
},
|
|
836
|
+
}, _callee26, this);
|
|
813
837
|
}));
|
|
814
|
-
function createExternalTeam(
|
|
838
|
+
function createExternalTeam(_x44, _x45, _x46, _x47) {
|
|
815
839
|
return _createExternalTeam.apply(this, arguments);
|
|
816
840
|
}
|
|
817
841
|
return createExternalTeam;
|
|
@@ -819,23 +843,23 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
819
843
|
}, {
|
|
820
844
|
key: "getTeamAndGroupDiff",
|
|
821
845
|
value: function () {
|
|
822
|
-
var _getTeamAndGroupDiff = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
846
|
+
var _getTeamAndGroupDiff = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee27(teamId, externalReference) {
|
|
823
847
|
var siteId;
|
|
824
|
-
return _regeneratorRuntime.wrap(function
|
|
825
|
-
while (1) switch (
|
|
848
|
+
return _regeneratorRuntime.wrap(function _callee27$(_context27) {
|
|
849
|
+
while (1) switch (_context27.prev = _context27.next) {
|
|
826
850
|
case 0:
|
|
827
851
|
siteId = this.getCloudId();
|
|
828
|
-
return
|
|
852
|
+
return _context27.abrupt("return", this.postResource("".concat(v4UrlPath, "/").concat(this.trimTeamARI(teamId), "/external/diff"), {
|
|
829
853
|
siteId: siteId,
|
|
830
854
|
externalReference: externalReference
|
|
831
855
|
}));
|
|
832
856
|
case 2:
|
|
833
857
|
case "end":
|
|
834
|
-
return
|
|
858
|
+
return _context27.stop();
|
|
835
859
|
}
|
|
836
|
-
},
|
|
860
|
+
}, _callee27, this);
|
|
837
861
|
}));
|
|
838
|
-
function getTeamAndGroupDiff(
|
|
862
|
+
function getTeamAndGroupDiff(_x48, _x49) {
|
|
839
863
|
return _getTeamAndGroupDiff.apply(this, arguments);
|
|
840
864
|
}
|
|
841
865
|
return getTeamAndGroupDiff;
|
|
@@ -843,23 +867,23 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
843
867
|
}, {
|
|
844
868
|
key: "linkExistingTeamToGroup",
|
|
845
869
|
value: function () {
|
|
846
|
-
var _linkExistingTeamToGroup = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
870
|
+
var _linkExistingTeamToGroup = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee28(teamId, externalReference) {
|
|
847
871
|
var siteId;
|
|
848
|
-
return _regeneratorRuntime.wrap(function
|
|
849
|
-
while (1) switch (
|
|
872
|
+
return _regeneratorRuntime.wrap(function _callee28$(_context28) {
|
|
873
|
+
while (1) switch (_context28.prev = _context28.next) {
|
|
850
874
|
case 0:
|
|
851
875
|
siteId = this.getCloudId();
|
|
852
|
-
return
|
|
876
|
+
return _context28.abrupt("return", this.postResource("".concat(v4UrlPath, "/").concat(this.trimTeamARI(teamId), "/external/link"), {
|
|
853
877
|
externalReference: externalReference,
|
|
854
878
|
siteId: siteId
|
|
855
879
|
}));
|
|
856
880
|
case 2:
|
|
857
881
|
case "end":
|
|
858
|
-
return
|
|
882
|
+
return _context28.stop();
|
|
859
883
|
}
|
|
860
|
-
},
|
|
884
|
+
}, _callee28, this);
|
|
861
885
|
}));
|
|
862
|
-
function linkExistingTeamToGroup(
|
|
886
|
+
function linkExistingTeamToGroup(_x50, _x51) {
|
|
863
887
|
return _linkExistingTeamToGroup.apply(this, arguments);
|
|
864
888
|
}
|
|
865
889
|
return linkExistingTeamToGroup;
|
|
@@ -867,11 +891,11 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
867
891
|
}, {
|
|
868
892
|
key: "getWriteMediaToken",
|
|
869
893
|
value: function () {
|
|
870
|
-
var _getWriteMediaToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
871
|
-
return _regeneratorRuntime.wrap(function
|
|
872
|
-
while (1) switch (
|
|
894
|
+
var _getWriteMediaToken = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee29() {
|
|
895
|
+
return _regeneratorRuntime.wrap(function _callee29$(_context29) {
|
|
896
|
+
while (1) switch (_context29.prev = _context29.next) {
|
|
873
897
|
case 0:
|
|
874
|
-
return
|
|
898
|
+
return _context29.abrupt("return", this.getResource('/v4/teams/header-image/media-upload').then(function (response) {
|
|
875
899
|
var _response$baseUrl;
|
|
876
900
|
return _objectSpread(_objectSpread({}, response), {}, {
|
|
877
901
|
baseUrl: (_response$baseUrl = response.baseUrl) !== null && _response$baseUrl !== void 0 && _response$baseUrl.endsWith('/') ? response.baseUrl.slice(0, -1) : response.baseUrl
|
|
@@ -879,9 +903,9 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
879
903
|
}));
|
|
880
904
|
case 1:
|
|
881
905
|
case "end":
|
|
882
|
-
return
|
|
906
|
+
return _context29.stop();
|
|
883
907
|
}
|
|
884
|
-
},
|
|
908
|
+
}, _callee29, this);
|
|
885
909
|
}));
|
|
886
910
|
function getWriteMediaToken() {
|
|
887
911
|
return _getWriteMediaToken.apply(this, arguments);
|
|
@@ -891,25 +915,25 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
891
915
|
}, {
|
|
892
916
|
key: "getSoftDeletedTeamById",
|
|
893
917
|
value: function () {
|
|
894
|
-
var _getSoftDeletedTeamById = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
918
|
+
var _getSoftDeletedTeamById = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee30(teamId) {
|
|
895
919
|
var orgId, siteId;
|
|
896
|
-
return _regeneratorRuntime.wrap(function
|
|
897
|
-
while (1) switch (
|
|
920
|
+
return _regeneratorRuntime.wrap(function _callee30$(_context30) {
|
|
921
|
+
while (1) switch (_context30.prev = _context30.next) {
|
|
898
922
|
case 0:
|
|
899
923
|
orgId = this.getOrgId();
|
|
900
924
|
siteId = this.getCloudId();
|
|
901
|
-
return
|
|
925
|
+
return _context30.abrupt("return", this.getResource("".concat(v4UrlPath, "/org/").concat(orgId, "/soft-deleted/").concat(this.trimTeamARI(teamId), "?siteId=").concat(siteId)).then(function (response) {
|
|
902
926
|
return _objectSpread(_objectSpread({}, response.teamResponse), {}, {
|
|
903
927
|
id: teamId
|
|
904
928
|
});
|
|
905
929
|
}));
|
|
906
930
|
case 3:
|
|
907
931
|
case "end":
|
|
908
|
-
return
|
|
932
|
+
return _context30.stop();
|
|
909
933
|
}
|
|
910
|
-
},
|
|
934
|
+
}, _callee30, this);
|
|
911
935
|
}));
|
|
912
|
-
function getSoftDeletedTeamById(
|
|
936
|
+
function getSoftDeletedTeamById(_x52) {
|
|
913
937
|
return _getSoftDeletedTeamById.apply(this, arguments);
|
|
914
938
|
}
|
|
915
939
|
return getSoftDeletedTeamById;
|
|
@@ -920,13 +944,13 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
920
944
|
}, {
|
|
921
945
|
key: "getUserInSiteUserBase",
|
|
922
946
|
value: (function () {
|
|
923
|
-
var _getUserInSiteUserBase = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
947
|
+
var _getUserInSiteUserBase = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee31(userId) {
|
|
924
948
|
var siteId;
|
|
925
|
-
return _regeneratorRuntime.wrap(function
|
|
926
|
-
while (1) switch (
|
|
949
|
+
return _regeneratorRuntime.wrap(function _callee31$(_context31) {
|
|
950
|
+
while (1) switch (_context31.prev = _context31.next) {
|
|
927
951
|
case 0:
|
|
928
952
|
siteId = this.getCloudId();
|
|
929
|
-
return
|
|
953
|
+
return _context31.abrupt("return", this.getResource("/teams/site/".concat(siteId, "/users/").concat(userId, "/exists"), {
|
|
930
954
|
headers: {
|
|
931
955
|
Accept: 'application/json',
|
|
932
956
|
'X-header-client-id': 'ptc-fe'
|
|
@@ -934,11 +958,11 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
934
958
|
}));
|
|
935
959
|
case 2:
|
|
936
960
|
case "end":
|
|
937
|
-
return
|
|
961
|
+
return _context31.stop();
|
|
938
962
|
}
|
|
939
|
-
},
|
|
963
|
+
}, _callee31, this);
|
|
940
964
|
}));
|
|
941
|
-
function getUserInSiteUserBase(
|
|
965
|
+
function getUserInSiteUserBase(_x53) {
|
|
942
966
|
return _getUserInSiteUserBase.apply(this, arguments);
|
|
943
967
|
}
|
|
944
968
|
return getUserInSiteUserBase;
|
|
@@ -946,22 +970,22 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
946
970
|
}, {
|
|
947
971
|
key: "retrieveBrowseUserPermission",
|
|
948
972
|
value: function () {
|
|
949
|
-
var _retrieveBrowseUserPermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
950
|
-
return _regeneratorRuntime.wrap(function
|
|
951
|
-
while (1) switch (
|
|
973
|
+
var _retrieveBrowseUserPermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee32(product) {
|
|
974
|
+
return _regeneratorRuntime.wrap(function _callee32$(_context32) {
|
|
975
|
+
while (1) switch (_context32.prev = _context32.next) {
|
|
952
976
|
case 0:
|
|
953
|
-
return
|
|
977
|
+
return _context32.abrupt("return", this.getResourceCached("/teams/site/".concat(this.getCloudId(), "/canSearchUsers?product=").concat(product), undefined,
|
|
954
978
|
// 2 minute expiration, resolves duplicate calls in initial load
|
|
955
979
|
{
|
|
956
980
|
expiration: 1000 * 60 * 2
|
|
957
981
|
}));
|
|
958
982
|
case 1:
|
|
959
983
|
case "end":
|
|
960
|
-
return
|
|
984
|
+
return _context32.stop();
|
|
961
985
|
}
|
|
962
|
-
},
|
|
986
|
+
}, _callee32, this);
|
|
963
987
|
}));
|
|
964
|
-
function retrieveBrowseUserPermission(
|
|
988
|
+
function retrieveBrowseUserPermission(_x54) {
|
|
965
989
|
return _retrieveBrowseUserPermission.apply(this, arguments);
|
|
966
990
|
}
|
|
967
991
|
return retrieveBrowseUserPermission;
|
|
@@ -969,27 +993,27 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
969
993
|
}, {
|
|
970
994
|
key: "getPermissions",
|
|
971
995
|
value: function () {
|
|
972
|
-
var _getPermissions = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
996
|
+
var _getPermissions = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee33() {
|
|
973
997
|
var orgId, siteId, err;
|
|
974
|
-
return _regeneratorRuntime.wrap(function
|
|
975
|
-
while (1) switch (
|
|
998
|
+
return _regeneratorRuntime.wrap(function _callee33$(_context33) {
|
|
999
|
+
while (1) switch (_context33.prev = _context33.next) {
|
|
976
1000
|
case 0:
|
|
977
1001
|
orgId = this.getContext().orgId;
|
|
978
1002
|
siteId = this.getCloudId();
|
|
979
1003
|
if (orgId) {
|
|
980
|
-
|
|
1004
|
+
_context33.next = 6;
|
|
981
1005
|
break;
|
|
982
1006
|
}
|
|
983
1007
|
err = new Error('Organization ID is required');
|
|
984
1008
|
this.logException(err, 'getPermissions');
|
|
985
1009
|
throw err;
|
|
986
1010
|
case 6:
|
|
987
|
-
return
|
|
1011
|
+
return _context33.abrupt("return", this.getResourceCached("".concat(v4UrlPath, "/permission/self/organization/").concat(orgId, "?siteId=").concat(siteId)));
|
|
988
1012
|
case 7:
|
|
989
1013
|
case "end":
|
|
990
|
-
return
|
|
1014
|
+
return _context33.stop();
|
|
991
1015
|
}
|
|
992
|
-
},
|
|
1016
|
+
}, _callee33, this);
|
|
993
1017
|
}));
|
|
994
1018
|
function getPermissions() {
|
|
995
1019
|
return _getPermissions.apply(this, arguments);
|
|
@@ -999,36 +1023,36 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
999
1023
|
}, {
|
|
1000
1024
|
key: "getLinkedTeamsBulk",
|
|
1001
1025
|
value: function () {
|
|
1002
|
-
var _getLinkedTeamsBulk = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1026
|
+
var _getLinkedTeamsBulk = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee34(groupIds) {
|
|
1003
1027
|
var organizationId, err, legionExternalTeam;
|
|
1004
|
-
return _regeneratorRuntime.wrap(function
|
|
1005
|
-
while (1) switch (
|
|
1028
|
+
return _regeneratorRuntime.wrap(function _callee34$(_context34) {
|
|
1029
|
+
while (1) switch (_context34.prev = _context34.next) {
|
|
1006
1030
|
case 0:
|
|
1007
1031
|
organizationId = this.getContext().orgId;
|
|
1008
1032
|
if (organizationId) {
|
|
1009
|
-
|
|
1033
|
+
_context34.next = 5;
|
|
1010
1034
|
break;
|
|
1011
1035
|
}
|
|
1012
1036
|
err = new Error('Organization ID is required');
|
|
1013
1037
|
this.logException(err, 'getLinkedTeamsBulk');
|
|
1014
1038
|
throw err;
|
|
1015
1039
|
case 5:
|
|
1016
|
-
|
|
1040
|
+
_context34.next = 7;
|
|
1017
1041
|
return this.postResource("".concat(v4UrlPath, "/external/bulk"), {
|
|
1018
1042
|
organizationId: organizationId,
|
|
1019
1043
|
source: 'ATLASSIAN_GROUP',
|
|
1020
1044
|
externalIds: groupIds
|
|
1021
1045
|
});
|
|
1022
1046
|
case 7:
|
|
1023
|
-
legionExternalTeam =
|
|
1024
|
-
return
|
|
1047
|
+
legionExternalTeam = _context34.sent;
|
|
1048
|
+
return _context34.abrupt("return", legionExternalTeam);
|
|
1025
1049
|
case 9:
|
|
1026
1050
|
case "end":
|
|
1027
|
-
return
|
|
1051
|
+
return _context34.stop();
|
|
1028
1052
|
}
|
|
1029
|
-
},
|
|
1053
|
+
}, _callee34, this);
|
|
1030
1054
|
}));
|
|
1031
|
-
function getLinkedTeamsBulk(
|
|
1055
|
+
function getLinkedTeamsBulk(_x55) {
|
|
1032
1056
|
return _getLinkedTeamsBulk.apply(this, arguments);
|
|
1033
1057
|
}
|
|
1034
1058
|
return getLinkedTeamsBulk;
|
|
@@ -1036,32 +1060,32 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1036
1060
|
}, {
|
|
1037
1061
|
key: "getTeamProfileDetails",
|
|
1038
1062
|
value: function () {
|
|
1039
|
-
var _getTeamProfileDetails = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1063
|
+
var _getTeamProfileDetails = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee35(teamId, siteId) {
|
|
1040
1064
|
var finalSiteId, err, linkedTeamsProfileDetails;
|
|
1041
|
-
return _regeneratorRuntime.wrap(function
|
|
1042
|
-
while (1) switch (
|
|
1065
|
+
return _regeneratorRuntime.wrap(function _callee35$(_context35) {
|
|
1066
|
+
while (1) switch (_context35.prev = _context35.next) {
|
|
1043
1067
|
case 0:
|
|
1044
1068
|
finalSiteId = siteId || this.getCloudId();
|
|
1045
1069
|
if (finalSiteId) {
|
|
1046
|
-
|
|
1070
|
+
_context35.next = 5;
|
|
1047
1071
|
break;
|
|
1048
1072
|
}
|
|
1049
1073
|
err = new Error('Site ID is required');
|
|
1050
1074
|
this.logException(err, 'getTeamProfileDetails');
|
|
1051
1075
|
throw err;
|
|
1052
1076
|
case 5:
|
|
1053
|
-
|
|
1077
|
+
_context35.next = 7;
|
|
1054
1078
|
return this.getResource("".concat(v4UrlPath, "/").concat(teamId, "/profile?siteId=").concat(finalSiteId));
|
|
1055
1079
|
case 7:
|
|
1056
|
-
linkedTeamsProfileDetails =
|
|
1057
|
-
return
|
|
1080
|
+
linkedTeamsProfileDetails = _context35.sent;
|
|
1081
|
+
return _context35.abrupt("return", linkedTeamsProfileDetails);
|
|
1058
1082
|
case 9:
|
|
1059
1083
|
case "end":
|
|
1060
|
-
return
|
|
1084
|
+
return _context35.stop();
|
|
1061
1085
|
}
|
|
1062
|
-
},
|
|
1086
|
+
}, _callee35, this);
|
|
1063
1087
|
}));
|
|
1064
|
-
function getTeamProfileDetails(
|
|
1088
|
+
function getTeamProfileDetails(_x56, _x57) {
|
|
1065
1089
|
return _getTeamProfileDetails.apply(this, arguments);
|
|
1066
1090
|
}
|
|
1067
1091
|
return getTeamProfileDetails;
|
|
@@ -1069,30 +1093,30 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1069
1093
|
}, {
|
|
1070
1094
|
key: "getOrgScope",
|
|
1071
1095
|
value: function () {
|
|
1072
|
-
var _getOrgScope = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1096
|
+
var _getOrgScope = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee36() {
|
|
1073
1097
|
var orgId, err, orgScope;
|
|
1074
|
-
return _regeneratorRuntime.wrap(function
|
|
1075
|
-
while (1) switch (
|
|
1098
|
+
return _regeneratorRuntime.wrap(function _callee36$(_context36) {
|
|
1099
|
+
while (1) switch (_context36.prev = _context36.next) {
|
|
1076
1100
|
case 0:
|
|
1077
1101
|
orgId = this.getContext().orgId;
|
|
1078
1102
|
if (orgId) {
|
|
1079
|
-
|
|
1103
|
+
_context36.next = 5;
|
|
1080
1104
|
break;
|
|
1081
1105
|
}
|
|
1082
1106
|
err = new Error('Organization ID is required');
|
|
1083
1107
|
this.logException(err, 'getOrgScope');
|
|
1084
1108
|
throw err;
|
|
1085
1109
|
case 5:
|
|
1086
|
-
|
|
1110
|
+
_context36.next = 7;
|
|
1087
1111
|
return this.getResourceCached("".concat(v4UrlPath, "/org/").concat(orgId, "/scope"));
|
|
1088
1112
|
case 7:
|
|
1089
|
-
orgScope =
|
|
1090
|
-
return
|
|
1113
|
+
orgScope = _context36.sent;
|
|
1114
|
+
return _context36.abrupt("return", orgScope);
|
|
1091
1115
|
case 9:
|
|
1092
1116
|
case "end":
|
|
1093
|
-
return
|
|
1117
|
+
return _context36.stop();
|
|
1094
1118
|
}
|
|
1095
|
-
},
|
|
1119
|
+
}, _callee36, this);
|
|
1096
1120
|
}));
|
|
1097
1121
|
function getOrgScope() {
|
|
1098
1122
|
return _getOrgScope.apply(this, arguments);
|
|
@@ -1102,26 +1126,26 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1102
1126
|
}, {
|
|
1103
1127
|
key: "restoreTeamToSyncedGroup",
|
|
1104
1128
|
value: function () {
|
|
1105
|
-
var _restoreTeamToSyncedGroup = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1129
|
+
var _restoreTeamToSyncedGroup = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee37(teamId, externalReference) {
|
|
1106
1130
|
var siteId;
|
|
1107
|
-
return _regeneratorRuntime.wrap(function
|
|
1108
|
-
while (1) switch (
|
|
1131
|
+
return _regeneratorRuntime.wrap(function _callee37$(_context37) {
|
|
1132
|
+
while (1) switch (_context37.prev = _context37.next) {
|
|
1109
1133
|
case 0:
|
|
1110
1134
|
siteId = this.getCloudId();
|
|
1111
|
-
|
|
1135
|
+
_context37.next = 3;
|
|
1112
1136
|
return this.postResource("".concat(v4UrlPath, "/").concat(teamId, "/external/restore"), {
|
|
1113
1137
|
externalReference: externalReference,
|
|
1114
1138
|
siteId: siteId
|
|
1115
1139
|
});
|
|
1116
1140
|
case 3:
|
|
1117
|
-
return
|
|
1141
|
+
return _context37.abrupt("return", _context37.sent);
|
|
1118
1142
|
case 4:
|
|
1119
1143
|
case "end":
|
|
1120
|
-
return
|
|
1144
|
+
return _context37.stop();
|
|
1121
1145
|
}
|
|
1122
|
-
},
|
|
1146
|
+
}, _callee37, this);
|
|
1123
1147
|
}));
|
|
1124
|
-
function restoreTeamToSyncedGroup(
|
|
1148
|
+
function restoreTeamToSyncedGroup(_x58, _x59) {
|
|
1125
1149
|
return _restoreTeamToSyncedGroup.apply(this, arguments);
|
|
1126
1150
|
}
|
|
1127
1151
|
return restoreTeamToSyncedGroup;
|
|
@@ -1129,18 +1153,18 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1129
1153
|
}, {
|
|
1130
1154
|
key: "createTeamContainers",
|
|
1131
1155
|
value: function () {
|
|
1132
|
-
var _createTeamContainers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1133
|
-
return _regeneratorRuntime.wrap(function
|
|
1134
|
-
while (1) switch (
|
|
1156
|
+
var _createTeamContainers = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee38(payload) {
|
|
1157
|
+
return _regeneratorRuntime.wrap(function _callee38$(_context38) {
|
|
1158
|
+
while (1) switch (_context38.prev = _context38.next) {
|
|
1135
1159
|
case 0:
|
|
1136
|
-
return
|
|
1160
|
+
return _context38.abrupt("return", this.postResource("".concat(v4UrlPath, "/containers"), _objectSpread({}, payload)));
|
|
1137
1161
|
case 1:
|
|
1138
1162
|
case "end":
|
|
1139
|
-
return
|
|
1163
|
+
return _context38.stop();
|
|
1140
1164
|
}
|
|
1141
|
-
},
|
|
1165
|
+
}, _callee38, this);
|
|
1142
1166
|
}));
|
|
1143
|
-
function createTeamContainers(
|
|
1167
|
+
function createTeamContainers(_x60) {
|
|
1144
1168
|
return _createTeamContainers.apply(this, arguments);
|
|
1145
1169
|
}
|
|
1146
1170
|
return createTeamContainers;
|
|
@@ -1148,23 +1172,23 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1148
1172
|
}, {
|
|
1149
1173
|
key: "getTeamEnabledSites",
|
|
1150
1174
|
value: function () {
|
|
1151
|
-
var _getTeamEnabledSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1175
|
+
var _getTeamEnabledSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee39(teamId) {
|
|
1152
1176
|
var teamEnabledSites;
|
|
1153
|
-
return _regeneratorRuntime.wrap(function
|
|
1154
|
-
while (1) switch (
|
|
1177
|
+
return _regeneratorRuntime.wrap(function _callee39$(_context39) {
|
|
1178
|
+
while (1) switch (_context39.prev = _context39.next) {
|
|
1155
1179
|
case 0:
|
|
1156
|
-
|
|
1180
|
+
_context39.next = 2;
|
|
1157
1181
|
return this.getResourceCached("".concat(v4UrlPath, "/migrations/scope/").concat(teamId));
|
|
1158
1182
|
case 2:
|
|
1159
|
-
teamEnabledSites =
|
|
1160
|
-
return
|
|
1183
|
+
teamEnabledSites = _context39.sent;
|
|
1184
|
+
return _context39.abrupt("return", teamEnabledSites);
|
|
1161
1185
|
case 4:
|
|
1162
1186
|
case "end":
|
|
1163
|
-
return
|
|
1187
|
+
return _context39.stop();
|
|
1164
1188
|
}
|
|
1165
|
-
},
|
|
1189
|
+
}, _callee39, this);
|
|
1166
1190
|
}));
|
|
1167
|
-
function getTeamEnabledSites(
|
|
1191
|
+
function getTeamEnabledSites(_x61) {
|
|
1168
1192
|
return _getTeamEnabledSites.apply(this, arguments);
|
|
1169
1193
|
}
|
|
1170
1194
|
return getTeamEnabledSites;
|
|
@@ -1172,26 +1196,26 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1172
1196
|
}, {
|
|
1173
1197
|
key: "assignTeamsToSites",
|
|
1174
1198
|
value: function () {
|
|
1175
|
-
var _assignTeamsToSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1199
|
+
var _assignTeamsToSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee40(migrations) {
|
|
1176
1200
|
var assignTeamsToSitesResponse;
|
|
1177
|
-
return _regeneratorRuntime.wrap(function
|
|
1178
|
-
while (1) switch (
|
|
1201
|
+
return _regeneratorRuntime.wrap(function _callee40$(_context40) {
|
|
1202
|
+
while (1) switch (_context40.prev = _context40.next) {
|
|
1179
1203
|
case 0:
|
|
1180
|
-
|
|
1204
|
+
_context40.next = 2;
|
|
1181
1205
|
return this.postResource("".concat(v4UrlPath, "/migrations/scope"), {
|
|
1182
1206
|
originOrgId: this.getContext().orgId,
|
|
1183
1207
|
migrations: migrations
|
|
1184
1208
|
});
|
|
1185
1209
|
case 2:
|
|
1186
|
-
assignTeamsToSitesResponse =
|
|
1187
|
-
return
|
|
1210
|
+
assignTeamsToSitesResponse = _context40.sent;
|
|
1211
|
+
return _context40.abrupt("return", assignTeamsToSitesResponse);
|
|
1188
1212
|
case 4:
|
|
1189
1213
|
case "end":
|
|
1190
|
-
return
|
|
1214
|
+
return _context40.stop();
|
|
1191
1215
|
}
|
|
1192
|
-
},
|
|
1216
|
+
}, _callee40, this);
|
|
1193
1217
|
}));
|
|
1194
|
-
function assignTeamsToSites(
|
|
1218
|
+
function assignTeamsToSites(_x62) {
|
|
1195
1219
|
return _assignTeamsToSites.apply(this, arguments);
|
|
1196
1220
|
}
|
|
1197
1221
|
return assignTeamsToSites;
|
|
@@ -1199,21 +1223,21 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1199
1223
|
}, {
|
|
1200
1224
|
key: "getTeamsToBeClonedToJsmSites",
|
|
1201
1225
|
value: function () {
|
|
1202
|
-
var _getTeamsToBeClonedToJsmSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1203
|
-
return _regeneratorRuntime.wrap(function
|
|
1204
|
-
while (1) switch (
|
|
1226
|
+
var _getTeamsToBeClonedToJsmSites = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee41(teamsToSiteScope) {
|
|
1227
|
+
return _regeneratorRuntime.wrap(function _callee41$(_context41) {
|
|
1228
|
+
while (1) switch (_context41.prev = _context41.next) {
|
|
1205
1229
|
case 0:
|
|
1206
|
-
return
|
|
1230
|
+
return _context41.abrupt("return", this.postResource("".concat(v4UrlPath, "/migrations/scope/review"), {
|
|
1207
1231
|
orgId: this.getContext().orgId,
|
|
1208
1232
|
teamsToSiteScope: teamsToSiteScope
|
|
1209
1233
|
}));
|
|
1210
1234
|
case 1:
|
|
1211
1235
|
case "end":
|
|
1212
|
-
return
|
|
1236
|
+
return _context41.stop();
|
|
1213
1237
|
}
|
|
1214
|
-
},
|
|
1238
|
+
}, _callee41, this);
|
|
1215
1239
|
}));
|
|
1216
|
-
function getTeamsToBeClonedToJsmSites(
|
|
1240
|
+
function getTeamsToBeClonedToJsmSites(_x63) {
|
|
1217
1241
|
return _getTeamsToBeClonedToJsmSites.apply(this, arguments);
|
|
1218
1242
|
}
|
|
1219
1243
|
return getTeamsToBeClonedToJsmSites;
|
|
@@ -1221,21 +1245,21 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1221
1245
|
}, {
|
|
1222
1246
|
key: "setTeamSiteAssignmentPermission",
|
|
1223
1247
|
value: function () {
|
|
1224
|
-
var _setTeamSiteAssignmentPermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1225
|
-
return _regeneratorRuntime.wrap(function
|
|
1226
|
-
while (1) switch (
|
|
1248
|
+
var _setTeamSiteAssignmentPermission = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee42(orgId, alignmentPermission) {
|
|
1249
|
+
return _regeneratorRuntime.wrap(function _callee42$(_context42) {
|
|
1250
|
+
while (1) switch (_context42.prev = _context42.next) {
|
|
1227
1251
|
case 0:
|
|
1228
|
-
return
|
|
1252
|
+
return _context42.abrupt("return", this.postResource("".concat(v4UrlPath, "/migrations/scope/permissions"), {
|
|
1229
1253
|
orgId: orgId,
|
|
1230
1254
|
alignmentPermission: alignmentPermission
|
|
1231
1255
|
}));
|
|
1232
1256
|
case 1:
|
|
1233
1257
|
case "end":
|
|
1234
|
-
return
|
|
1258
|
+
return _context42.stop();
|
|
1235
1259
|
}
|
|
1236
|
-
},
|
|
1260
|
+
}, _callee42, this);
|
|
1237
1261
|
}));
|
|
1238
|
-
function setTeamSiteAssignmentPermission(
|
|
1262
|
+
function setTeamSiteAssignmentPermission(_x64, _x65) {
|
|
1239
1263
|
return _setTeamSiteAssignmentPermission.apply(this, arguments);
|
|
1240
1264
|
}
|
|
1241
1265
|
return setTeamSiteAssignmentPermission;
|
|
@@ -1243,12 +1267,12 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1243
1267
|
}, {
|
|
1244
1268
|
key: "getAssignedTeams",
|
|
1245
1269
|
value: function () {
|
|
1246
|
-
var _getAssignedTeams = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1270
|
+
var _getAssignedTeams = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee43(orgId, count, cursor, displayNameContains) {
|
|
1247
1271
|
var assignedTeamsResponse;
|
|
1248
|
-
return _regeneratorRuntime.wrap(function
|
|
1249
|
-
while (1) switch (
|
|
1272
|
+
return _regeneratorRuntime.wrap(function _callee43$(_context43) {
|
|
1273
|
+
while (1) switch (_context43.prev = _context43.next) {
|
|
1250
1274
|
case 0:
|
|
1251
|
-
|
|
1275
|
+
_context43.next = 2;
|
|
1252
1276
|
return this.postResource("".concat(v4UrlPath, "/migrations/scope/aligned/search"), {
|
|
1253
1277
|
orgId: orgId,
|
|
1254
1278
|
count: count,
|
|
@@ -1256,15 +1280,15 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1256
1280
|
displayNameContains: displayNameContains
|
|
1257
1281
|
});
|
|
1258
1282
|
case 2:
|
|
1259
|
-
assignedTeamsResponse =
|
|
1260
|
-
return
|
|
1283
|
+
assignedTeamsResponse = _context43.sent;
|
|
1284
|
+
return _context43.abrupt("return", assignedTeamsResponse);
|
|
1261
1285
|
case 4:
|
|
1262
1286
|
case "end":
|
|
1263
|
-
return
|
|
1287
|
+
return _context43.stop();
|
|
1264
1288
|
}
|
|
1265
|
-
},
|
|
1289
|
+
}, _callee43, this);
|
|
1266
1290
|
}));
|
|
1267
|
-
function getAssignedTeams(
|
|
1291
|
+
function getAssignedTeams(_x66, _x67, _x68, _x69) {
|
|
1268
1292
|
return _getAssignedTeams.apply(this, arguments);
|
|
1269
1293
|
}
|
|
1270
1294
|
return getAssignedTeams;
|
|
@@ -1272,12 +1296,12 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1272
1296
|
}, {
|
|
1273
1297
|
key: "getUnassignedTeams",
|
|
1274
1298
|
value: function () {
|
|
1275
|
-
var _getUnassignedTeams = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1299
|
+
var _getUnassignedTeams = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee44(orgId, count, cursor, query) {
|
|
1276
1300
|
var unassignedTeamsResponse;
|
|
1277
|
-
return _regeneratorRuntime.wrap(function
|
|
1278
|
-
while (1) switch (
|
|
1301
|
+
return _regeneratorRuntime.wrap(function _callee44$(_context44) {
|
|
1302
|
+
while (1) switch (_context44.prev = _context44.next) {
|
|
1279
1303
|
case 0:
|
|
1280
|
-
|
|
1304
|
+
_context44.next = 2;
|
|
1281
1305
|
return this.postResource("".concat(v4UrlPath, "/migrations/scope/unaligned/search"), {
|
|
1282
1306
|
orgId: orgId,
|
|
1283
1307
|
count: count,
|
|
@@ -1285,15 +1309,15 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1285
1309
|
query: query
|
|
1286
1310
|
});
|
|
1287
1311
|
case 2:
|
|
1288
|
-
unassignedTeamsResponse =
|
|
1289
|
-
return
|
|
1312
|
+
unassignedTeamsResponse = _context44.sent;
|
|
1313
|
+
return _context44.abrupt("return", unassignedTeamsResponse);
|
|
1290
1314
|
case 4:
|
|
1291
1315
|
case "end":
|
|
1292
|
-
return
|
|
1316
|
+
return _context44.stop();
|
|
1293
1317
|
}
|
|
1294
|
-
},
|
|
1318
|
+
}, _callee44, this);
|
|
1295
1319
|
}));
|
|
1296
|
-
function getUnassignedTeams(
|
|
1320
|
+
function getUnassignedTeams(_x70, _x71, _x72, _x73) {
|
|
1297
1321
|
return _getUnassignedTeams.apply(this, arguments);
|
|
1298
1322
|
}
|
|
1299
1323
|
return getUnassignedTeams;
|
|
@@ -1301,26 +1325,26 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1301
1325
|
}, {
|
|
1302
1326
|
key: "getTeamSiteAssignmentOrgDetails",
|
|
1303
1327
|
value: function () {
|
|
1304
|
-
var _getTeamSiteAssignmentOrgDetails = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1328
|
+
var _getTeamSiteAssignmentOrgDetails = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee45() {
|
|
1305
1329
|
var orgId, err;
|
|
1306
|
-
return _regeneratorRuntime.wrap(function
|
|
1307
|
-
while (1) switch (
|
|
1330
|
+
return _regeneratorRuntime.wrap(function _callee45$(_context45) {
|
|
1331
|
+
while (1) switch (_context45.prev = _context45.next) {
|
|
1308
1332
|
case 0:
|
|
1309
1333
|
orgId = this.getContext().orgId;
|
|
1310
1334
|
if (orgId) {
|
|
1311
|
-
|
|
1335
|
+
_context45.next = 5;
|
|
1312
1336
|
break;
|
|
1313
1337
|
}
|
|
1314
1338
|
err = new Error('Organization ID is required');
|
|
1315
1339
|
this.logException(err, 'getTeamSiteAssignmentOrgDetails');
|
|
1316
1340
|
throw err;
|
|
1317
1341
|
case 5:
|
|
1318
|
-
return
|
|
1342
|
+
return _context45.abrupt("return", this.getResource("".concat(v4UrlPath, "/migrations/scope/details/").concat(orgId)));
|
|
1319
1343
|
case 6:
|
|
1320
1344
|
case "end":
|
|
1321
|
-
return
|
|
1345
|
+
return _context45.stop();
|
|
1322
1346
|
}
|
|
1323
|
-
},
|
|
1347
|
+
}, _callee45, this);
|
|
1324
1348
|
}));
|
|
1325
1349
|
function getTeamSiteAssignmentOrgDetails() {
|
|
1326
1350
|
return _getTeamSiteAssignmentOrgDetails.apply(this, arguments);
|
|
@@ -1474,27 +1498,27 @@ export var LegionClient = /*#__PURE__*/function (_RestClient) {
|
|
|
1474
1498
|
}, {
|
|
1475
1499
|
key: "getTeamStatesInBulk",
|
|
1476
1500
|
value: function () {
|
|
1477
|
-
var _getTeamStatesInBulk = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function
|
|
1478
|
-
return _regeneratorRuntime.wrap(function
|
|
1479
|
-
while (1) switch (
|
|
1501
|
+
var _getTeamStatesInBulk = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee46(orgId, teamIds) {
|
|
1502
|
+
return _regeneratorRuntime.wrap(function _callee46$(_context46) {
|
|
1503
|
+
while (1) switch (_context46.prev = _context46.next) {
|
|
1480
1504
|
case 0:
|
|
1481
|
-
|
|
1482
|
-
return
|
|
1505
|
+
_context46.prev = 0;
|
|
1506
|
+
return _context46.abrupt("return", this.postResource("".concat(v4UrlPath, "/adminhub/states/bulk"), {
|
|
1483
1507
|
orgId: orgId,
|
|
1484
1508
|
teamIds: teamIds
|
|
1485
1509
|
}));
|
|
1486
1510
|
case 4:
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
this.logException(
|
|
1490
|
-
throw
|
|
1511
|
+
_context46.prev = 4;
|
|
1512
|
+
_context46.t0 = _context46["catch"](0);
|
|
1513
|
+
this.logException(_context46.t0, 'getTeamStatesInBulk');
|
|
1514
|
+
throw _context46.t0;
|
|
1491
1515
|
case 8:
|
|
1492
1516
|
case "end":
|
|
1493
|
-
return
|
|
1517
|
+
return _context46.stop();
|
|
1494
1518
|
}
|
|
1495
|
-
},
|
|
1519
|
+
}, _callee46, this, [[0, 4]]);
|
|
1496
1520
|
}));
|
|
1497
|
-
function getTeamStatesInBulk(
|
|
1521
|
+
function getTeamStatesInBulk(_x74, _x75) {
|
|
1498
1522
|
return _getTeamStatesInBulk.apply(this, arguments);
|
|
1499
1523
|
}
|
|
1500
1524
|
return getTeamStatesInBulk;
|