@pnp/cli-microsoft365 11.0.0-beta.3655c37 → 11.0.0-beta.4abfd23
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/allCommands.json +1 -1
- package/allCommandsFull.json +1 -1
- package/dist/m365/entra/commands/group/group-member-add.js +6 -27
- package/dist/m365/entra/commands/group/group-member-set.js +5 -26
- package/dist/m365/entra/commands/m365group/m365group-get.js +1 -7
- package/dist/m365/entra/commands/m365group/m365group-list.js +1 -7
- package/dist/m365/entra/commands/pim/pim-role-assignment-eligibility-list.js +1 -7
- package/dist/m365/entra/commands/pim/pim-role-assignment-list.js +1 -7
- package/dist/m365/entra/commands/pim/pim-role-request-list.js +1 -7
- package/dist/m365/flow/commands/flow-list.js +7 -14
- package/dist/m365/flow/commands/run/run-get.js +1 -7
- package/dist/m365/graph/commands/subscription/subscription-add.js +3 -10
- package/dist/m365/pp/commands/solution/solution-publisher-list.js +1 -8
- package/dist/m365/purview/commands/threatassessment/threatassessment-get.js +1 -7
- package/dist/m365/spo/commands/file/file-move.js +2 -8
- package/dist/m365/spo/commands/hubsite/hubsite-get.js +4 -13
- package/dist/m365/spo/commands/hubsite/hubsite-list.js +1 -8
- package/dist/m365/spo/commands/{tenant/tenant-site-archive.js → site/site-archive.js} +14 -14
- package/dist/m365/spo/commands/{tenant/tenant-site-list.js → site/site-list.js} +16 -27
- package/dist/m365/spo/commands/{tenant/tenant-site-membership-list.js → site/site-membership-list.js} +15 -15
- package/dist/m365/spo/commands/{tenant/tenant-site-rename.js → site/site-rename.js} +14 -14
- package/dist/m365/spo/commands/{tenant/tenant-site-unarchive.js → site/site-unarchive.js} +14 -14
- package/dist/m365/spo/commands/term/term-list.js +1 -7
- package/dist/m365/spo/commands.js +4 -5
- package/dist/m365/teams/commands/chat/chat-member-add.js +3 -9
- package/dist/m365/viva/commands/engage/engage-network-list.js +1 -7
- package/docs/docs/cmd/entra/group/group-member-add.mdx +7 -26
- package/docs/docs/cmd/entra/group/group-member-set.mdx +5 -23
- package/docs/docs/cmd/entra/m365group/m365group-get.mdx +0 -3
- package/docs/docs/cmd/entra/m365group/m365group-list.mdx +0 -3
- package/docs/docs/cmd/entra/pim/pim-role-assignment-eligibility-list.mdx +0 -3
- package/docs/docs/cmd/entra/pim/pim-role-assignment-list.mdx +0 -3
- package/docs/docs/cmd/entra/pim/pim-role-request-list.mdx +0 -3
- package/docs/docs/cmd/flow/flow-list.mdx +0 -3
- package/docs/docs/cmd/flow/run/run-get.mdx +0 -3
- package/docs/docs/cmd/graph/subscription/subscription-add.mdx +0 -3
- package/docs/docs/cmd/pp/solution/solution-publisher-list.mdx +0 -3
- package/docs/docs/cmd/purview/threatassessment/threatassessment-get.mdx +0 -3
- package/docs/docs/cmd/spo/file/file-move.mdx +0 -3
- package/docs/docs/cmd/spo/homesite/homesite-set.mdx +1 -1
- package/docs/docs/cmd/spo/hubsite/hubsite-get.mdx +0 -3
- package/docs/docs/cmd/spo/hubsite/hubsite-list.mdx +0 -3
- package/docs/docs/cmd/spo/{tenant/tenant-site-archive.mdx → site/site-archive.mdx} +4 -4
- package/docs/docs/cmd/spo/{tenant/tenant-site-list.mdx → site/site-list.mdx} +7 -16
- package/docs/docs/cmd/spo/{tenant/tenant-site-membership-list.mdx → site/site-membership-list.mdx} +5 -5
- package/docs/docs/cmd/spo/{tenant/tenant-site-rename.mdx → site/site-rename.mdx} +7 -7
- package/docs/docs/cmd/spo/{tenant/tenant-site-unarchive.mdx → site/site-unarchive.mdx} +4 -4
- package/docs/docs/cmd/spo/term/term-list.mdx +0 -3
- package/docs/docs/cmd/teams/chat/chat-member-add.mdx +2 -5
- package/docs/docs/cmd/viva/engage/engage-network-list.mdx +0 -3
- package/package.json +1 -1
- package/dist/m365/spo/commands/tenant/SPOTenantSitePropertiesEnumerable.js +0 -2
- package/dist/m365/spo/commands/tenant/TenantSiteProperties.js +0 -2
|
@@ -29,20 +29,12 @@ class SpoHubSiteGetCommand extends SpoCommand {
|
|
|
29
29
|
}
|
|
30
30
|
async commandAction(logger, args) {
|
|
31
31
|
try {
|
|
32
|
-
if (args.options.includeAssociatedSites) {
|
|
33
|
-
await this.warn(logger, `Parameter 'includeAssociatedSites' is deprecated. Please use 'withAssociatedSites' instead`);
|
|
34
|
-
}
|
|
35
32
|
const spoUrl = await spo.getSpoUrl(logger, this.debug);
|
|
36
33
|
const hubSite = args.options.id ? await this.getHubSiteById(spoUrl, args.options) : await this.getHubSite(spoUrl, args.options);
|
|
37
|
-
if (
|
|
38
|
-
|
|
39
|
-
throw 'includeAssociatedSites option is only allowed with json output mode';
|
|
40
|
-
}
|
|
41
|
-
else {
|
|
42
|
-
throw 'withAssociatedSites option is only allowed with json output mode';
|
|
43
|
-
}
|
|
34
|
+
if (args.options.withAssociatedSites && (args.options.output && args.options.output !== 'json')) {
|
|
35
|
+
throw 'withAssociatedSites option is only allowed with json output mode';
|
|
44
36
|
}
|
|
45
|
-
if (
|
|
37
|
+
if (args.options.withAssociatedSites === true && args.options.output && !cli.shouldTrimOutput(args.options.output)) {
|
|
46
38
|
const spoAdminUrl = await spo.getSpoAdminUrl(logger, this.debug);
|
|
47
39
|
const associatedSitesCommandOutput = await this.getAssociatedSites(spoAdminUrl, hubSite.SiteId, logger, args);
|
|
48
40
|
const associatedSites = JSON.parse(associatedSitesCommandOutput.stdout);
|
|
@@ -108,12 +100,11 @@ _SpoHubSiteGetCommand_instances = new WeakSet(), _SpoHubSiteGetCommand_initTelem
|
|
|
108
100
|
id: typeof args.options.id !== 'undefined',
|
|
109
101
|
title: typeof args.options.title !== 'undefined',
|
|
110
102
|
url: typeof args.options.url !== 'undefined',
|
|
111
|
-
includeAssociatedSites: args.options.includeAssociatedSites === true,
|
|
112
103
|
withAssociatedSites: args.options.withAssociatedSites === true
|
|
113
104
|
});
|
|
114
105
|
});
|
|
115
106
|
}, _SpoHubSiteGetCommand_initOptions = function _SpoHubSiteGetCommand_initOptions() {
|
|
116
|
-
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '-u, --url [url]' }, { option: '--
|
|
107
|
+
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '-u, --url [url]' }, { option: '--withAssociatedSites' });
|
|
117
108
|
}, _SpoHubSiteGetCommand_initValidators = function _SpoHubSiteGetCommand_initValidators() {
|
|
118
109
|
this.validators.push(async (args) => {
|
|
119
110
|
if (args.options.id && !validation.isValidGuid(args.options.id)) {
|
|
@@ -29,14 +29,10 @@ class SpoHubSiteListCommand extends SpoCommand {
|
|
|
29
29
|
}
|
|
30
30
|
async commandAction(logger, args) {
|
|
31
31
|
try {
|
|
32
|
-
if (args.options.includeAssociatedSites) {
|
|
33
|
-
await this.warn(logger, `Parameter 'includeAssociatedSites' is deprecated. Please use 'withAssociatedSites' instead`);
|
|
34
|
-
}
|
|
35
32
|
const spoAdminUrl = await spo.getSpoAdminUrl(logger, this.debug);
|
|
36
33
|
const hubSitesResult = await odata.getAllItems(`${spoAdminUrl}/_api/hubsites`);
|
|
37
34
|
const hubSites = hubSitesResult;
|
|
38
|
-
|
|
39
|
-
if (!(shouldIncludeAssociatedSites !== true || args.options.output && args.options.output !== 'json')) {
|
|
35
|
+
if (!(args.options.withAssociatedSites !== true || args.options.output && args.options.output !== 'json')) {
|
|
40
36
|
if (this.debug) {
|
|
41
37
|
await logger.logToStderr('Retrieving associated sites...');
|
|
42
38
|
await logger.logToStderr('');
|
|
@@ -108,14 +104,11 @@ class SpoHubSiteListCommand extends SpoCommand {
|
|
|
108
104
|
_SpoHubSiteListCommand_instances = new WeakSet(), _SpoHubSiteListCommand_initTelemetry = function _SpoHubSiteListCommand_initTelemetry() {
|
|
109
105
|
this.telemetry.push((args) => {
|
|
110
106
|
Object.assign(this.telemetryProperties, {
|
|
111
|
-
includeAssociatedSites: args.options.includeAssociatedSites === true,
|
|
112
107
|
withAssociatedSites: args.options.withAssociatedSites === true
|
|
113
108
|
});
|
|
114
109
|
});
|
|
115
110
|
}, _SpoHubSiteListCommand_initOptions = function _SpoHubSiteListCommand_initOptions() {
|
|
116
111
|
this.options.unshift({
|
|
117
|
-
option: '-i, --includeAssociatedSites'
|
|
118
|
-
}, {
|
|
119
112
|
option: '--withAssociatedSites'
|
|
120
113
|
});
|
|
121
114
|
};
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var _SpoSiteArchiveCommand_instances, _SpoSiteArchiveCommand_initTelemetry, _SpoSiteArchiveCommand_initOptions, _SpoSiteArchiveCommand_initValidators, _SpoSiteArchiveCommand_initTypes;
|
|
7
7
|
import { cli } from '../../../../cli/cli.js';
|
|
8
8
|
import config from '../../../../config.js';
|
|
9
9
|
import request from '../../../../request.js';
|
|
@@ -11,20 +11,20 @@ import { validation } from '../../../../utils/validation.js';
|
|
|
11
11
|
import { spo } from '../../../../utils/spo.js';
|
|
12
12
|
import SpoCommand from '../../../base/SpoCommand.js';
|
|
13
13
|
import commands from '../../commands.js';
|
|
14
|
-
class
|
|
14
|
+
class SpoSiteArchiveCommand extends SpoCommand {
|
|
15
15
|
get name() {
|
|
16
|
-
return commands.
|
|
16
|
+
return commands.SITE_ARCHIVE;
|
|
17
17
|
}
|
|
18
18
|
get description() {
|
|
19
19
|
return 'Archives a site collection';
|
|
20
20
|
}
|
|
21
21
|
constructor() {
|
|
22
22
|
super();
|
|
23
|
-
|
|
24
|
-
__classPrivateFieldGet(this,
|
|
25
|
-
__classPrivateFieldGet(this,
|
|
26
|
-
__classPrivateFieldGet(this,
|
|
27
|
-
__classPrivateFieldGet(this,
|
|
23
|
+
_SpoSiteArchiveCommand_instances.add(this);
|
|
24
|
+
__classPrivateFieldGet(this, _SpoSiteArchiveCommand_instances, "m", _SpoSiteArchiveCommand_initTelemetry).call(this);
|
|
25
|
+
__classPrivateFieldGet(this, _SpoSiteArchiveCommand_instances, "m", _SpoSiteArchiveCommand_initOptions).call(this);
|
|
26
|
+
__classPrivateFieldGet(this, _SpoSiteArchiveCommand_instances, "m", _SpoSiteArchiveCommand_initValidators).call(this);
|
|
27
|
+
__classPrivateFieldGet(this, _SpoSiteArchiveCommand_instances, "m", _SpoSiteArchiveCommand_initTypes).call(this);
|
|
28
28
|
}
|
|
29
29
|
async commandAction(logger, args) {
|
|
30
30
|
const archiveSite = async () => {
|
|
@@ -81,19 +81,19 @@ class SpoTenantSiteArchiveCommand extends SpoCommand {
|
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
|
-
|
|
84
|
+
_SpoSiteArchiveCommand_instances = new WeakSet(), _SpoSiteArchiveCommand_initTelemetry = function _SpoSiteArchiveCommand_initTelemetry() {
|
|
85
85
|
this.telemetry.push((args) => {
|
|
86
86
|
Object.assign(this.telemetryProperties, {
|
|
87
87
|
force: !!args.options.force
|
|
88
88
|
});
|
|
89
89
|
});
|
|
90
|
-
},
|
|
90
|
+
}, _SpoSiteArchiveCommand_initOptions = function _SpoSiteArchiveCommand_initOptions() {
|
|
91
91
|
this.options.unshift({ option: '-u, --url <url>' }, { option: '-f, --force' });
|
|
92
|
-
},
|
|
92
|
+
}, _SpoSiteArchiveCommand_initValidators = function _SpoSiteArchiveCommand_initValidators() {
|
|
93
93
|
this.validators.push(async (args) => validation.isValidSharePointUrl(args.options.url));
|
|
94
|
-
},
|
|
94
|
+
}, _SpoSiteArchiveCommand_initTypes = function _SpoSiteArchiveCommand_initTypes() {
|
|
95
95
|
this.types.string.push('url');
|
|
96
96
|
this.types.boolean.push('force');
|
|
97
97
|
};
|
|
98
|
-
export default new
|
|
99
|
-
//# sourceMappingURL=
|
|
98
|
+
export default new SpoSiteArchiveCommand();
|
|
99
|
+
//# sourceMappingURL=site-archive.js.map
|
|
@@ -3,16 +3,16 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var _SpoSiteListCommand_instances, _SpoSiteListCommand_initTelemetry, _SpoSiteListCommand_initOptions, _SpoSiteListCommand_initValidators;
|
|
7
7
|
import config from '../../../../config.js';
|
|
8
8
|
import request from '../../../../request.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
10
10
|
import { spo } from '../../../../utils/spo.js';
|
|
11
11
|
import SpoCommand from '../../../base/SpoCommand.js';
|
|
12
12
|
import commands from '../../commands.js';
|
|
13
|
-
class
|
|
13
|
+
class SpoSiteListCommand extends SpoCommand {
|
|
14
14
|
get name() {
|
|
15
|
-
return commands.
|
|
15
|
+
return commands.SITE_LIST;
|
|
16
16
|
}
|
|
17
17
|
get description() {
|
|
18
18
|
return 'Lists sites of the given type';
|
|
@@ -22,20 +22,17 @@ class SpoTenantSiteListCommand extends SpoCommand {
|
|
|
22
22
|
}
|
|
23
23
|
constructor() {
|
|
24
24
|
super();
|
|
25
|
-
|
|
26
|
-
__classPrivateFieldGet(this,
|
|
27
|
-
__classPrivateFieldGet(this,
|
|
28
|
-
__classPrivateFieldGet(this,
|
|
25
|
+
_SpoSiteListCommand_instances.add(this);
|
|
26
|
+
__classPrivateFieldGet(this, _SpoSiteListCommand_instances, "m", _SpoSiteListCommand_initTelemetry).call(this);
|
|
27
|
+
__classPrivateFieldGet(this, _SpoSiteListCommand_instances, "m", _SpoSiteListCommand_initOptions).call(this);
|
|
28
|
+
__classPrivateFieldGet(this, _SpoSiteListCommand_instances, "m", _SpoSiteListCommand_initValidators).call(this);
|
|
29
29
|
}
|
|
30
30
|
alias() {
|
|
31
31
|
return [commands.SITE_LIST];
|
|
32
32
|
}
|
|
33
33
|
async commandAction(logger, args) {
|
|
34
|
-
if (args.options.includeOneDriveSites) {
|
|
35
|
-
await this.warn(logger, `Parameter 'includeOneDriveSites' is deprecated. Please use 'withOneDriveSites' instead`);
|
|
36
|
-
}
|
|
37
34
|
const webTemplate = this.getWebTemplateId(args.options);
|
|
38
|
-
const includeOneDriveSites =
|
|
35
|
+
const includeOneDriveSites = args.options.withOneDriveSites || false;
|
|
39
36
|
const personalSite = includeOneDriveSites === false ? '0' : '1';
|
|
40
37
|
try {
|
|
41
38
|
const spoAdminUrl = await spo.getSpoAdminUrl(logger, this.debug);
|
|
@@ -79,7 +76,7 @@ class SpoTenantSiteListCommand extends SpoCommand {
|
|
|
79
76
|
if (options.webTemplate) {
|
|
80
77
|
return options.webTemplate;
|
|
81
78
|
}
|
|
82
|
-
if (options.
|
|
79
|
+
if (options.withOneDriveSites) {
|
|
83
80
|
return '';
|
|
84
81
|
}
|
|
85
82
|
switch (options.type) {
|
|
@@ -92,17 +89,16 @@ class SpoTenantSiteListCommand extends SpoCommand {
|
|
|
92
89
|
}
|
|
93
90
|
}
|
|
94
91
|
}
|
|
95
|
-
|
|
92
|
+
_SpoSiteListCommand_instances = new WeakSet(), _SpoSiteListCommand_initTelemetry = function _SpoSiteListCommand_initTelemetry() {
|
|
96
93
|
this.telemetry.push((args) => {
|
|
97
94
|
Object.assign(this.telemetryProperties, {
|
|
98
95
|
webTemplate: args.options.webTemplate,
|
|
99
96
|
type: args.options.type,
|
|
100
97
|
filter: (!(!args.options.filter)).toString(),
|
|
101
|
-
includeOneDriveSites: typeof args.options.includeOneDriveSites !== 'undefined',
|
|
102
98
|
withOneDriveSites: typeof args.options.withOneDriveSites !== 'undefined'
|
|
103
99
|
});
|
|
104
100
|
});
|
|
105
|
-
},
|
|
101
|
+
}, _SpoSiteListCommand_initOptions = function _SpoSiteListCommand_initOptions() {
|
|
106
102
|
this.options.unshift({
|
|
107
103
|
option: '-t, --type [type]',
|
|
108
104
|
autocomplete: ['TeamSite', 'CommunicationSite']
|
|
@@ -110,12 +106,10 @@ _SpoTenantSiteListCommand_instances = new WeakSet(), _SpoTenantSiteListCommand_i
|
|
|
110
106
|
option: '--webTemplate [webTemplate]'
|
|
111
107
|
}, {
|
|
112
108
|
option: '--filter [filter]'
|
|
113
|
-
}, {
|
|
114
|
-
option: '--includeOneDriveSites'
|
|
115
109
|
}, {
|
|
116
110
|
option: '--withOneDriveSites'
|
|
117
111
|
});
|
|
118
|
-
},
|
|
112
|
+
}, _SpoSiteListCommand_initValidators = function _SpoSiteListCommand_initValidators() {
|
|
119
113
|
this.validators.push(async (args) => {
|
|
120
114
|
if (args.options.type && args.options.webTemplate) {
|
|
121
115
|
return 'Specify either type or webTemplate, but not both';
|
|
@@ -125,17 +119,12 @@ _SpoTenantSiteListCommand_instances = new WeakSet(), _SpoTenantSiteListCommand_i
|
|
|
125
119
|
typeValues.indexOf(args.options.type) < 0) {
|
|
126
120
|
return `${args.options.type} is not a valid value for the type option. Allowed values are ${typeValues.join('|')}`;
|
|
127
121
|
}
|
|
128
|
-
if (args.options.
|
|
122
|
+
if (args.options.withOneDriveSites
|
|
129
123
|
&& (args.options.type || args.options.webTemplate)) {
|
|
130
|
-
|
|
131
|
-
return 'When using includeOneDriveSites, don\'t specify the type or webTemplate options';
|
|
132
|
-
}
|
|
133
|
-
else {
|
|
134
|
-
return 'When using withOneDriveSites, don\'t specify the type or webTemplate options';
|
|
135
|
-
}
|
|
124
|
+
return 'When using withOneDriveSites, don\'t specify the type or webTemplate options';
|
|
136
125
|
}
|
|
137
126
|
return true;
|
|
138
127
|
});
|
|
139
128
|
};
|
|
140
|
-
export default new
|
|
141
|
-
//# sourceMappingURL=
|
|
129
|
+
export default new SpoSiteListCommand();
|
|
130
|
+
//# sourceMappingURL=site-list.js.map
|
|
@@ -3,15 +3,15 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var _SpoSiteMembershipListCommand_instances, _a, _SpoSiteMembershipListCommand_initTelemetry, _SpoSiteMembershipListCommand_initOptions, _SpoSiteMembershipListCommand_initValidators, _SpoSiteMembershipListCommand_initTypes;
|
|
7
7
|
import { odata } from '../../../../utils/odata.js';
|
|
8
8
|
import { spo } from '../../../../utils/spo.js';
|
|
9
9
|
import { validation } from '../../../../utils/validation.js';
|
|
10
10
|
import SpoCommand from '../../../base/SpoCommand.js';
|
|
11
11
|
import commands from '../../commands.js';
|
|
12
|
-
class
|
|
12
|
+
class SpoSiteMembershipListCommand extends SpoCommand {
|
|
13
13
|
get name() {
|
|
14
|
-
return commands.
|
|
14
|
+
return commands.SITE_MEMBERSHIP_LIST;
|
|
15
15
|
}
|
|
16
16
|
get description() {
|
|
17
17
|
return `Retrieves information about default site groups' membership`;
|
|
@@ -21,11 +21,11 @@ class SpoTenantSiteMembershipListCommand extends SpoCommand {
|
|
|
21
21
|
}
|
|
22
22
|
constructor() {
|
|
23
23
|
super();
|
|
24
|
-
|
|
25
|
-
__classPrivateFieldGet(this,
|
|
26
|
-
__classPrivateFieldGet(this,
|
|
27
|
-
__classPrivateFieldGet(this,
|
|
28
|
-
__classPrivateFieldGet(this,
|
|
24
|
+
_SpoSiteMembershipListCommand_instances.add(this);
|
|
25
|
+
__classPrivateFieldGet(this, _SpoSiteMembershipListCommand_instances, "m", _SpoSiteMembershipListCommand_initTelemetry).call(this);
|
|
26
|
+
__classPrivateFieldGet(this, _SpoSiteMembershipListCommand_instances, "m", _SpoSiteMembershipListCommand_initOptions).call(this);
|
|
27
|
+
__classPrivateFieldGet(this, _SpoSiteMembershipListCommand_instances, "m", _SpoSiteMembershipListCommand_initValidators).call(this);
|
|
28
|
+
__classPrivateFieldGet(this, _SpoSiteMembershipListCommand_instances, "m", _SpoSiteMembershipListCommand_initTypes).call(this);
|
|
29
29
|
}
|
|
30
30
|
;
|
|
31
31
|
async commandAction(logger, args) {
|
|
@@ -90,29 +90,29 @@ class SpoTenantSiteMembershipListCommand extends SpoCommand {
|
|
|
90
90
|
}
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
|
-
_a =
|
|
93
|
+
_a = SpoSiteMembershipListCommand, _SpoSiteMembershipListCommand_instances = new WeakSet(), _SpoSiteMembershipListCommand_initTelemetry = function _SpoSiteMembershipListCommand_initTelemetry() {
|
|
94
94
|
this.telemetry.push((args) => {
|
|
95
95
|
Object.assign(this.telemetryProperties, {
|
|
96
96
|
role: typeof args.options.role !== 'undefined'
|
|
97
97
|
});
|
|
98
98
|
});
|
|
99
|
-
},
|
|
99
|
+
}, _SpoSiteMembershipListCommand_initOptions = function _SpoSiteMembershipListCommand_initOptions() {
|
|
100
100
|
this.options.unshift({
|
|
101
101
|
option: '-u, --siteUrl <siteUrl>'
|
|
102
102
|
}, {
|
|
103
103
|
option: '-r, --role [role]',
|
|
104
104
|
autocomplete: _a.RoleNames
|
|
105
105
|
});
|
|
106
|
-
},
|
|
106
|
+
}, _SpoSiteMembershipListCommand_initValidators = function _SpoSiteMembershipListCommand_initValidators() {
|
|
107
107
|
this.validators.push(async (args) => {
|
|
108
108
|
if (args.options.role && !_a.RoleNames.some(roleName => roleName.toLocaleLowerCase() === args.options.role.toLocaleLowerCase())) {
|
|
109
109
|
return `'${args.options.role}' is not a valid value for option 'role'. Valid values are: ${_a.RoleNames.join(', ')}`;
|
|
110
110
|
}
|
|
111
111
|
return validation.isValidSharePointUrl(args.options.siteUrl);
|
|
112
112
|
});
|
|
113
|
-
},
|
|
113
|
+
}, _SpoSiteMembershipListCommand_initTypes = function _SpoSiteMembershipListCommand_initTypes() {
|
|
114
114
|
this.types.string.push('role', 'siteUrl');
|
|
115
115
|
};
|
|
116
|
-
|
|
117
|
-
export default new
|
|
118
|
-
//# sourceMappingURL=
|
|
116
|
+
SpoSiteMembershipListCommand.RoleNames = ['Owner', 'Member', 'Visitor'];
|
|
117
|
+
export default new SpoSiteMembershipListCommand();
|
|
118
|
+
//# sourceMappingURL=site-membership-list.js.map
|
|
@@ -3,26 +3,26 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var _SpoSiteRenameCommand_instances, _SpoSiteRenameCommand_initTelemetry, _SpoSiteRenameCommand_initOptions, _SpoSiteRenameCommand_initValidators;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { formatting } from '../../../../utils/formatting.js';
|
|
9
9
|
import { spo } from '../../../../utils/spo.js';
|
|
10
10
|
import { timersUtil } from '../../../../utils/timersUtil.js';
|
|
11
11
|
import SpoCommand from '../../../base/SpoCommand.js';
|
|
12
12
|
import commands from '../../commands.js';
|
|
13
|
-
class
|
|
13
|
+
class SpoSiteRenameCommand extends SpoCommand {
|
|
14
14
|
get name() {
|
|
15
|
-
return commands.
|
|
15
|
+
return commands.SITE_RENAME;
|
|
16
16
|
}
|
|
17
17
|
get description() {
|
|
18
18
|
return 'Renames the URL and title of a site collection';
|
|
19
19
|
}
|
|
20
20
|
constructor() {
|
|
21
21
|
super();
|
|
22
|
-
|
|
23
|
-
__classPrivateFieldGet(this,
|
|
24
|
-
__classPrivateFieldGet(this,
|
|
25
|
-
__classPrivateFieldGet(this,
|
|
22
|
+
_SpoSiteRenameCommand_instances.add(this);
|
|
23
|
+
__classPrivateFieldGet(this, _SpoSiteRenameCommand_instances, "m", _SpoSiteRenameCommand_initTelemetry).call(this);
|
|
24
|
+
__classPrivateFieldGet(this, _SpoSiteRenameCommand_instances, "m", _SpoSiteRenameCommand_initOptions).call(this);
|
|
25
|
+
__classPrivateFieldGet(this, _SpoSiteRenameCommand_instances, "m", _SpoSiteRenameCommand_initValidators).call(this);
|
|
26
26
|
}
|
|
27
27
|
async commandAction(logger, args) {
|
|
28
28
|
try {
|
|
@@ -92,11 +92,11 @@ class SpoTenantSiteRenameCommand extends SpoCommand {
|
|
|
92
92
|
if (this.operationData.JobState === "Success") {
|
|
93
93
|
return;
|
|
94
94
|
}
|
|
95
|
-
await timersUtil.setTimeout(
|
|
95
|
+
await timersUtil.setTimeout(SpoSiteRenameCommand.checkIntervalInMs);
|
|
96
96
|
await command.waitForRenameCompletion(command, isVerbose, spoAdminUrl, siteUrl, iteration);
|
|
97
97
|
}
|
|
98
98
|
}
|
|
99
|
-
|
|
99
|
+
_SpoSiteRenameCommand_instances = new WeakSet(), _SpoSiteRenameCommand_initTelemetry = function _SpoSiteRenameCommand_initTelemetry() {
|
|
100
100
|
this.telemetry.push((args) => {
|
|
101
101
|
Object.assign(this.telemetryProperties, {
|
|
102
102
|
newTitle: typeof args.options.newTitle !== 'undefined',
|
|
@@ -105,7 +105,7 @@ _SpoTenantSiteRenameCommand_instances = new WeakSet(), _SpoTenantSiteRenameComma
|
|
|
105
105
|
wait: !!args.options.wait
|
|
106
106
|
});
|
|
107
107
|
});
|
|
108
|
-
},
|
|
108
|
+
}, _SpoSiteRenameCommand_initOptions = function _SpoSiteRenameCommand_initOptions() {
|
|
109
109
|
this.options.unshift({
|
|
110
110
|
option: '-u, --url <url>'
|
|
111
111
|
}, {
|
|
@@ -119,7 +119,7 @@ _SpoTenantSiteRenameCommand_instances = new WeakSet(), _SpoTenantSiteRenameComma
|
|
|
119
119
|
}, {
|
|
120
120
|
option: '--wait'
|
|
121
121
|
});
|
|
122
|
-
},
|
|
122
|
+
}, _SpoSiteRenameCommand_initValidators = function _SpoSiteRenameCommand_initValidators() {
|
|
123
123
|
this.validators.push(async (args) => {
|
|
124
124
|
if (args.options.url.toLowerCase() === args.options.newUrl.toLowerCase()) {
|
|
125
125
|
return 'The new URL cannot be the same as the target URL.';
|
|
@@ -127,6 +127,6 @@ _SpoTenantSiteRenameCommand_instances = new WeakSet(), _SpoTenantSiteRenameComma
|
|
|
127
127
|
return true;
|
|
128
128
|
});
|
|
129
129
|
};
|
|
130
|
-
|
|
131
|
-
export default new
|
|
132
|
-
//# sourceMappingURL=
|
|
130
|
+
SpoSiteRenameCommand.checkIntervalInMs = 5000;
|
|
131
|
+
export default new SpoSiteRenameCommand();
|
|
132
|
+
//# sourceMappingURL=site-rename.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var
|
|
6
|
+
var _SpoSiteUnarchiveCommand_instances, _SpoSiteUnarchiveCommand_initTelemetry, _SpoSiteUnarchiveCommand_initOptions, _SpoSiteUnarchiveCommand_initValidators, _SpoSiteUnarchiveCommand_initTypes;
|
|
7
7
|
import { cli } from '../../../../cli/cli.js';
|
|
8
8
|
import config from '../../../../config.js';
|
|
9
9
|
import request from '../../../../request.js';
|
|
@@ -11,20 +11,20 @@ import { spo } from '../../../../utils/spo.js';
|
|
|
11
11
|
import { validation } from '../../../../utils/validation.js';
|
|
12
12
|
import SpoCommand from '../../../base/SpoCommand.js';
|
|
13
13
|
import commands from '../../commands.js';
|
|
14
|
-
class
|
|
14
|
+
class SpoSiteUnarchiveCommand extends SpoCommand {
|
|
15
15
|
get name() {
|
|
16
|
-
return commands.
|
|
16
|
+
return commands.SITE_UNARCHIVE;
|
|
17
17
|
}
|
|
18
18
|
get description() {
|
|
19
19
|
return 'Unarchives a site collection';
|
|
20
20
|
}
|
|
21
21
|
constructor() {
|
|
22
22
|
super();
|
|
23
|
-
|
|
24
|
-
__classPrivateFieldGet(this,
|
|
25
|
-
__classPrivateFieldGet(this,
|
|
26
|
-
__classPrivateFieldGet(this,
|
|
27
|
-
__classPrivateFieldGet(this,
|
|
23
|
+
_SpoSiteUnarchiveCommand_instances.add(this);
|
|
24
|
+
__classPrivateFieldGet(this, _SpoSiteUnarchiveCommand_instances, "m", _SpoSiteUnarchiveCommand_initTelemetry).call(this);
|
|
25
|
+
__classPrivateFieldGet(this, _SpoSiteUnarchiveCommand_instances, "m", _SpoSiteUnarchiveCommand_initOptions).call(this);
|
|
26
|
+
__classPrivateFieldGet(this, _SpoSiteUnarchiveCommand_instances, "m", _SpoSiteUnarchiveCommand_initValidators).call(this);
|
|
27
|
+
__classPrivateFieldGet(this, _SpoSiteUnarchiveCommand_instances, "m", _SpoSiteUnarchiveCommand_initTypes).call(this);
|
|
28
28
|
}
|
|
29
29
|
async commandAction(logger, args) {
|
|
30
30
|
if (args.options.force) {
|
|
@@ -76,23 +76,23 @@ class SpoTenantSiteUnarchiveCommand extends SpoCommand {
|
|
|
76
76
|
}
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
|
-
|
|
79
|
+
_SpoSiteUnarchiveCommand_instances = new WeakSet(), _SpoSiteUnarchiveCommand_initTelemetry = function _SpoSiteUnarchiveCommand_initTelemetry() {
|
|
80
80
|
this.telemetry.push((args) => {
|
|
81
81
|
Object.assign(this.telemetryProperties, {
|
|
82
82
|
force: !!args.options.force
|
|
83
83
|
});
|
|
84
84
|
});
|
|
85
|
-
},
|
|
85
|
+
}, _SpoSiteUnarchiveCommand_initOptions = function _SpoSiteUnarchiveCommand_initOptions() {
|
|
86
86
|
this.options.unshift({
|
|
87
87
|
option: '-u, --url <url>'
|
|
88
88
|
}, {
|
|
89
89
|
option: '-f, --force'
|
|
90
90
|
});
|
|
91
|
-
},
|
|
91
|
+
}, _SpoSiteUnarchiveCommand_initValidators = function _SpoSiteUnarchiveCommand_initValidators() {
|
|
92
92
|
this.validators.push(async (args) => validation.isValidSharePointUrl(args.options.url));
|
|
93
|
-
},
|
|
93
|
+
}, _SpoSiteUnarchiveCommand_initTypes = function _SpoSiteUnarchiveCommand_initTypes() {
|
|
94
94
|
this.types.string.push('url');
|
|
95
95
|
this.types.boolean.push('force');
|
|
96
96
|
};
|
|
97
|
-
export default new
|
|
98
|
-
//# sourceMappingURL=
|
|
97
|
+
export default new SpoSiteUnarchiveCommand();
|
|
98
|
+
//# sourceMappingURL=site-unarchive.js.map
|
|
@@ -31,9 +31,6 @@ class SpoTermListCommand extends SpoCommand {
|
|
|
31
31
|
__classPrivateFieldGet(this, _SpoTermListCommand_instances, "m", _SpoTermListCommand_initOptionSets).call(this);
|
|
32
32
|
}
|
|
33
33
|
async commandAction(logger, args) {
|
|
34
|
-
if (args.options.includeChildTerms) {
|
|
35
|
-
await this.warn(logger, `Parameter 'includeChildTerms' is deprecated. Please use 'withChildTerms' instead`);
|
|
36
|
-
}
|
|
37
34
|
try {
|
|
38
35
|
const spoWebUrl = args.options.webUrl ? args.options.webUrl : await spo.getSpoAdminUrl(logger, this.debug);
|
|
39
36
|
const res = await spo.getRequestDigest(spoWebUrl);
|
|
@@ -43,7 +40,7 @@ class SpoTermListCommand extends SpoCommand {
|
|
|
43
40
|
const termGroupQuery = args.options.termGroupId ? `<Method Id="77" ParentId="75" Name="GetById"><Parameters><Parameter Type="Guid">{${args.options.termGroupId}}</Parameter></Parameters></Method>` : `<Method Id="77" ParentId="75" Name="GetByName"><Parameters><Parameter Type="String">${formatting.escapeXml(args.options.termGroupName)}</Parameter></Parameters></Method>`;
|
|
44
41
|
const termSetQuery = args.options.termSetId ? `<Method Id="82" ParentId="80" Name="GetById"><Parameters><Parameter Type="Guid">{${args.options.termSetId}}</Parameter></Parameters></Method>` : `<Method Id="82" ParentId="80" Name="GetByName"><Parameters><Parameter Type="String">${formatting.escapeXml(args.options.termSetName)}</Parameter></Parameters></Method>`;
|
|
45
42
|
const data = `<Request AddExpandoFieldTypeSuffix="true" SchemaVersion="15.0.0.0" LibraryVersion="16.0.0.0" ApplicationName="${config.applicationName}" xmlns="http://schemas.microsoft.com/sharepoint/clientquery/2009"><Actions><ObjectPath Id="70" ObjectPathId="69" /><ObjectIdentityQuery Id="71" ObjectPathId="69" /><ObjectPath Id="73" ObjectPathId="72" /><ObjectIdentityQuery Id="74" ObjectPathId="72" /><ObjectPath Id="76" ObjectPathId="75" /><ObjectPath Id="78" ObjectPathId="77" /><ObjectIdentityQuery Id="79" ObjectPathId="77" /><ObjectPath Id="81" ObjectPathId="80" /><ObjectPath Id="83" ObjectPathId="82" /><ObjectIdentityQuery Id="84" ObjectPathId="82" /><ObjectPath Id="86" ObjectPathId="85" /><Query Id="87" ObjectPathId="85"><Query SelectAllProperties="false"><Properties /></Query><ChildItemQuery SelectAllProperties="true"><Properties><Property Name="Name" ScalarProperty="true" /><Property Name="Id" ScalarProperty="true" /></Properties></ChildItemQuery></Query></Actions><ObjectPaths><StaticMethod Id="69" Name="GetTaxonomySession" TypeId="{981cbc68-9edc-4f8d-872f-71146fcbb84f}" /><Method Id="72" ParentId="69" Name="GetDefaultSiteCollectionTermStore" /><Property Id="75" ParentId="72" Name="Groups" />${termGroupQuery}<Property Id="80" ParentId="77" Name="TermSets" />${termSetQuery}<Property Id="85" ParentId="82" Name="Terms" /></ObjectPaths></Request>`;
|
|
46
|
-
const shouldIncludeChildTerms = args.options.
|
|
43
|
+
const shouldIncludeChildTerms = args.options.withChildTerms;
|
|
47
44
|
const result = await this.executeCsomCall(data, spoWebUrl, res);
|
|
48
45
|
const terms = [];
|
|
49
46
|
if (result._Child_Items_ && result._Child_Items_.length > 0) {
|
|
@@ -146,7 +143,6 @@ _SpoTermListCommand_instances = new WeakSet(), _SpoTermListCommand_initTelemetry
|
|
|
146
143
|
termGroupName: typeof args.options.termGroupName !== 'undefined',
|
|
147
144
|
termSetId: typeof args.options.termSetId !== 'undefined',
|
|
148
145
|
termSetName: typeof args.options.termSetName !== 'undefined',
|
|
149
|
-
includeChildTerms: !!args.options.includeChildTerms,
|
|
150
146
|
withChildTerms: !!args.options.withChildTerms
|
|
151
147
|
});
|
|
152
148
|
});
|
|
@@ -161,8 +157,6 @@ _SpoTermListCommand_instances = new WeakSet(), _SpoTermListCommand_initTelemetry
|
|
|
161
157
|
option: '--termSetId [termSetId]'
|
|
162
158
|
}, {
|
|
163
159
|
option: '--termSetName [termSetName]'
|
|
164
|
-
}, {
|
|
165
|
-
option: '--includeChildTerms'
|
|
166
160
|
}, {
|
|
167
161
|
option: '--withChildTerms'
|
|
168
162
|
});
|
|
@@ -265,6 +265,7 @@ export default {
|
|
|
265
265
|
SITE_APPPERMISSION_LIST: `${prefix} site apppermission list`,
|
|
266
266
|
SITE_APPPERMISSION_REMOVE: `${prefix} site apppermission remove`,
|
|
267
267
|
SITE_APPPERMISSION_SET: `${prefix} site apppermission set`,
|
|
268
|
+
SITE_ARCHIVE: `${prefix} site archive`,
|
|
268
269
|
SITE_COMMSITE_ENABLE: `${prefix} site commsite enable`,
|
|
269
270
|
SITE_ENSURE: `${prefix} site ensure`,
|
|
270
271
|
SITE_GET: `${prefix} site get`,
|
|
@@ -273,6 +274,7 @@ export default {
|
|
|
273
274
|
SITE_HUBSITE_DISCONNECT: `${prefix} site hubsite disconnect`,
|
|
274
275
|
SITE_HUBSITE_THEME_SYNC: `${prefix} site hubsite theme sync`,
|
|
275
276
|
SITE_LIST: `${prefix} site list`,
|
|
277
|
+
SITE_MEMBERSHIP_LIST: `${prefix} site membership list`,
|
|
276
278
|
SITE_INPLACERECORDSMANAGEMENT_SET: `${prefix} site inplacerecordsmanagement set`,
|
|
277
279
|
SITE_RECYCLEBINITEM_CLEAR: `${prefix} site recyclebinitem clear`,
|
|
278
280
|
SITE_RECYCLEBINITEM_LIST: `${prefix} site recyclebinitem list`,
|
|
@@ -280,9 +282,11 @@ export default {
|
|
|
280
282
|
SITE_RECYCLEBINITEM_REMOVE: `${prefix} site recyclebinitem remove`,
|
|
281
283
|
SITE_RECYCLEBINITEM_RESTORE: `${prefix} site recyclebinitem restore`,
|
|
282
284
|
SITE_REMOVE: `${prefix} site remove`,
|
|
285
|
+
SITE_RENAME: `${prefix} site rename`,
|
|
283
286
|
SITE_SET: `${prefix} site set`,
|
|
284
287
|
SITE_SHARINGPERMISSION_SET: `${prefix} site sharingpermission set`,
|
|
285
288
|
SITE_CHROME_SET: `${prefix} site chrome set`,
|
|
289
|
+
SITE_UNARCHIVE: `${prefix} site unarchive`,
|
|
286
290
|
SITEDESIGN_ADD: `${prefix} sitedesign add`,
|
|
287
291
|
SITEDESIGN_APPLY: `${prefix} sitedesign apply`,
|
|
288
292
|
SITEDESIGN_GET: `${prefix} sitedesign get`,
|
|
@@ -330,11 +334,6 @@ export default {
|
|
|
330
334
|
TENANT_RECYCLEBINITEM_RESTORE: `${prefix} tenant recyclebinitem restore`,
|
|
331
335
|
TENANT_SETTINGS_LIST: `${prefix} tenant settings list`,
|
|
332
336
|
TENANT_SETTINGS_SET: `${prefix} tenant settings set`,
|
|
333
|
-
TENANT_SITE_ARCHIVE: `${prefix} tenant site archive`,
|
|
334
|
-
TENANT_SITE_LIST: `${prefix} tenant site list`,
|
|
335
|
-
TENANT_SITE_RENAME: `${prefix} tenant site rename`,
|
|
336
|
-
TENANT_SITE_MEMBERSHIP_LIST: `${prefix} tenant site membership list`,
|
|
337
|
-
TENANT_SITE_UNARCHIVE: `${prefix} tenant site unarchive`,
|
|
338
337
|
TERM_ADD: `${prefix} term add`,
|
|
339
338
|
TERM_GET: `${prefix} term get`,
|
|
340
339
|
TERM_LIST: `${prefix} term list`,
|
|
@@ -29,9 +29,6 @@ class TeamsChatMemberAddCommand extends GraphCommand {
|
|
|
29
29
|
if (this.verbose) {
|
|
30
30
|
await logger.logToStderr(`Adding member ${args.options.userId || args.options.userName} to chat with id ${args.options.chatId}...`);
|
|
31
31
|
}
|
|
32
|
-
if (args.options.includeAllHistory) {
|
|
33
|
-
await this.warn(logger, `Parameter 'includeAllHistory' is deprecated. Please use 'withAllHistory' instead`);
|
|
34
|
-
}
|
|
35
32
|
const chatMemberAddOptions = {
|
|
36
33
|
url: `${this.resource}/v1.0/chats/${args.options.chatId}/members`,
|
|
37
34
|
headers: {
|
|
@@ -41,7 +38,7 @@ class TeamsChatMemberAddCommand extends GraphCommand {
|
|
|
41
38
|
data: {
|
|
42
39
|
'@odata.type': '#microsoft.graph.aadUserConversationMember',
|
|
43
40
|
'user@odata.bind': `https://graph.microsoft.com/v1.0/users/${args.options.userId || formatting.encodeQueryParameter(args.options.userName)}`,
|
|
44
|
-
visibleHistoryStartDateTime:
|
|
41
|
+
visibleHistoryStartDateTime: args.options.withAllHistory ? '0001-01-01T00:00:00Z' : args.options.visibleHistoryStartDateTime,
|
|
45
42
|
roles: [args.options.role || 'owner']
|
|
46
43
|
}
|
|
47
44
|
};
|
|
@@ -59,7 +56,6 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
|
|
|
59
56
|
userName: typeof args.options.userName !== 'undefined',
|
|
60
57
|
role: typeof args.options.role !== 'undefined',
|
|
61
58
|
visibleHistoryStartDateTime: typeof args.options.visibleHistoryStartDateTime !== 'undefined',
|
|
62
|
-
includeAllHistory: !!args.options.includeAllHistory,
|
|
63
59
|
withAllHistory: !!args.options.withAllHistory
|
|
64
60
|
});
|
|
65
61
|
});
|
|
@@ -75,8 +71,6 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
|
|
|
75
71
|
autocomplete: _a.roles
|
|
76
72
|
}, {
|
|
77
73
|
option: '--visibleHistoryStartDateTime [visibleHistoryStartDateTime]'
|
|
78
|
-
}, {
|
|
79
|
-
option: '--includeAllHistory'
|
|
80
74
|
}, {
|
|
81
75
|
option: '--withAllHistory'
|
|
82
76
|
});
|
|
@@ -101,8 +95,8 @@ _a = TeamsChatMemberAddCommand, _TeamsChatMemberAddCommand_instances = new WeakS
|
|
|
101
95
|
});
|
|
102
96
|
}, _TeamsChatMemberAddCommand_initOptionSets = function _TeamsChatMemberAddCommand_initOptionSets() {
|
|
103
97
|
this.optionSets.push({ options: ['userId', 'userName'] }, {
|
|
104
|
-
options: ['visibleHistoryStartDateTime', '
|
|
105
|
-
runsWhen: (args) => args.options.visibleHistoryStartDateTime || args.options.
|
|
98
|
+
options: ['visibleHistoryStartDateTime', 'withAllHistory'],
|
|
99
|
+
runsWhen: (args) => args.options.visibleHistoryStartDateTime || args.options.withAllHistory
|
|
106
100
|
});
|
|
107
101
|
};
|
|
108
102
|
TeamsChatMemberAddCommand.roles = ['owner', 'guest'];
|
|
@@ -24,9 +24,6 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
|
|
|
24
24
|
__classPrivateFieldGet(this, _VivaEngageNetworkListCommand_instances, "m", _VivaEngageNetworkListCommand_initOptions).call(this);
|
|
25
25
|
}
|
|
26
26
|
async commandAction(logger, args) {
|
|
27
|
-
if (args.options.includeSuspended) {
|
|
28
|
-
await this.warn(logger, `Parameter 'includeSuspended' is deprecated. Please use 'withSuspended' instead`);
|
|
29
|
-
}
|
|
30
27
|
const requestOptions = {
|
|
31
28
|
url: `${this.resource}/v1/networks/current.json`,
|
|
32
29
|
headers: {
|
|
@@ -35,7 +32,7 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
|
|
|
35
32
|
},
|
|
36
33
|
responseType: 'json',
|
|
37
34
|
data: {
|
|
38
|
-
includeSuspended: (args.options.
|
|
35
|
+
includeSuspended: (args.options.withSuspended !== undefined && args.options.withSuspended !== false)
|
|
39
36
|
}
|
|
40
37
|
};
|
|
41
38
|
try {
|
|
@@ -50,14 +47,11 @@ class VivaEngageNetworkListCommand extends VivaEngageCommand {
|
|
|
50
47
|
_VivaEngageNetworkListCommand_instances = new WeakSet(), _VivaEngageNetworkListCommand_initTelemetry = function _VivaEngageNetworkListCommand_initTelemetry() {
|
|
51
48
|
this.telemetry.push((args) => {
|
|
52
49
|
Object.assign(this.telemetryProperties, {
|
|
53
|
-
includeSuspended: args.options.includeSuspended,
|
|
54
50
|
withSuspended: args.options.withSuspended
|
|
55
51
|
});
|
|
56
52
|
});
|
|
57
53
|
}, _VivaEngageNetworkListCommand_initOptions = function _VivaEngageNetworkListCommand_initOptions() {
|
|
58
54
|
this.options.unshift({
|
|
59
|
-
option: '--includeSuspended'
|
|
60
|
-
}, {
|
|
61
55
|
option: '--withSuspended'
|
|
62
56
|
});
|
|
63
57
|
};
|