@pnp/cli-microsoft365 7.2.0-beta.194fd07 → 7.2.0-beta.2970c86
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/.eslintrc.cjs +2 -0
- package/dist/m365/aad/commands/administrativeunit/administrativeunit-add.js +3 -3
- package/dist/m365/spfx/commands/project/project-doctor/doctor-1.18.1-rc.0.js +21 -0
- package/dist/m365/spfx/commands/project/project-doctor.js +2 -1
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN014010_CODE_settings_filesexclude_jest.js +44 -0
- package/dist/m365/spfx/commands/project/project-upgrade/upgrade-1.18.1-rc.0.js +57 -0
- package/dist/m365/spfx/commands/project/project-upgrade.js +16 -13
- package/dist/m365/spfx/commands/spfx-doctor.js +15 -0
- package/dist/m365/tenant/commands/people/people-profilecardproperty-add.js +128 -0
- package/dist/m365/tenant/commands/people/people-profilecardproperty-get.js +73 -0
- package/dist/m365/tenant/commands/people/people-profilecardproperty-list.js +63 -0
- package/dist/m365/tenant/commands/people/people-profilecardproperty-remove.js +84 -0
- package/dist/m365/tenant/commands/people/profileCardProperties.js +24 -0
- package/dist/m365/tenant/commands.js +4 -0
- package/docs/docs/cmd/aad/administrativeunit/administrativeunit-add.mdx +6 -2
- package/docs/docs/cmd/aad/administrativeunit/administrativeunit-get.mdx +5 -1
- package/docs/docs/cmd/aad/administrativeunit/administrativeunit-list.mdx +5 -1
- package/docs/docs/cmd/aad/administrativeunit/administrativeunit-remove.mdx +6 -2
- package/docs/docs/cmd/spfx/project/project-upgrade.mdx +1 -1
- package/docs/docs/cmd/tenant/people/people-profilecardproperty-add.mdx +174 -0
- package/docs/docs/cmd/tenant/people/people-profilecardproperty-get.mdx +97 -0
- package/docs/docs/cmd/tenant/people/people-profilecardproperty-list.mdx +106 -0
- package/docs/docs/cmd/tenant/people/people-profilecardproperty-remove.mdx +61 -0
- package/package.json +2 -1
package/.eslintrc.cjs
CHANGED
|
@@ -16,6 +16,7 @@ const dictionary = [
|
|
|
16
16
|
'audit',
|
|
17
17
|
'bin',
|
|
18
18
|
'builder',
|
|
19
|
+
'card',
|
|
19
20
|
'catalog',
|
|
20
21
|
'checklist',
|
|
21
22
|
'client',
|
|
@@ -68,6 +69,7 @@ const dictionary = [
|
|
|
68
69
|
'permission',
|
|
69
70
|
'place',
|
|
70
71
|
'policy',
|
|
72
|
+
'profile',
|
|
71
73
|
'property',
|
|
72
74
|
'records',
|
|
73
75
|
'recycle',
|
|
@@ -24,7 +24,7 @@ class AadAdministrativeUnitAddCommand extends GraphCommand {
|
|
|
24
24
|
const requestOptions = {
|
|
25
25
|
url: `${this.resource}/v1.0/directory/administrativeUnits`,
|
|
26
26
|
headers: {
|
|
27
|
-
|
|
27
|
+
accept: 'application/json;odata.metadata=none'
|
|
28
28
|
},
|
|
29
29
|
responseType: 'json',
|
|
30
30
|
data: {
|
|
@@ -45,7 +45,7 @@ class AadAdministrativeUnitAddCommand extends GraphCommand {
|
|
|
45
45
|
_AadAdministrativeUnitAddCommand_instances = new WeakSet(), _AadAdministrativeUnitAddCommand_initTelemetry = function _AadAdministrativeUnitAddCommand_initTelemetry() {
|
|
46
46
|
this.telemetry.push((args) => {
|
|
47
47
|
Object.assign(this.telemetryProperties, {
|
|
48
|
-
hiddenMembership: args.options.hiddenMembership
|
|
48
|
+
hiddenMembership: !!args.options.hiddenMembership
|
|
49
49
|
});
|
|
50
50
|
});
|
|
51
51
|
}, _AadAdministrativeUnitAddCommand_initOptions = function _AadAdministrativeUnitAddCommand_initOptions() {
|
|
@@ -54,7 +54,7 @@ _AadAdministrativeUnitAddCommand_instances = new WeakSet(), _AadAdministrativeUn
|
|
|
54
54
|
}, {
|
|
55
55
|
option: '-d, --description [description]'
|
|
56
56
|
}, {
|
|
57
|
-
option: '--hiddenMembership
|
|
57
|
+
option: '--hiddenMembership'
|
|
58
58
|
});
|
|
59
59
|
};
|
|
60
60
|
export default new AadAdministrativeUnitAddCommand();
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { FN001008_DEP_react } from './rules/FN001008_DEP_react.js';
|
|
2
|
+
import { FN001009_DEP_react_dom } from './rules/FN001009_DEP_react_dom.js';
|
|
3
|
+
import { FN001035_DEP_fluentui_react } from './rules/FN001035_DEP_fluentui_react.js';
|
|
4
|
+
import { FN002004_DEVDEP_gulp } from './rules/FN002004_DEVDEP_gulp.js';
|
|
5
|
+
import { FN002007_DEVDEP_ajv } from './rules/FN002007_DEVDEP_ajv.js';
|
|
6
|
+
import { FN002013_DEVDEP_types_webpack_env } from './rules/FN002013_DEVDEP_types_webpack_env.js';
|
|
7
|
+
import { FN002015_DEVDEP_types_react } from './rules/FN002015_DEVDEP_types_react.js';
|
|
8
|
+
import { FN002016_DEVDEP_types_react_dom } from './rules/FN002016_DEVDEP_types_react_dom.js';
|
|
9
|
+
import { FN002019_DEVDEP_microsoft_rush_stack_compiler } from './rules/FN002019_DEVDEP_microsoft_rush_stack_compiler.js';
|
|
10
|
+
export default [
|
|
11
|
+
new FN001008_DEP_react('17'),
|
|
12
|
+
new FN001009_DEP_react_dom('17'),
|
|
13
|
+
new FN001035_DEP_fluentui_react('^8.106.4'),
|
|
14
|
+
new FN002004_DEVDEP_gulp('4.0.2'),
|
|
15
|
+
new FN002007_DEVDEP_ajv('^6.12.5'),
|
|
16
|
+
new FN002013_DEVDEP_types_webpack_env('~1.15.2'),
|
|
17
|
+
new FN002015_DEVDEP_types_react('17'),
|
|
18
|
+
new FN002016_DEVDEP_types_react_dom('17'),
|
|
19
|
+
new FN002019_DEVDEP_microsoft_rush_stack_compiler(['4.7'])
|
|
20
|
+
];
|
|
21
|
+
//# sourceMappingURL=doctor-1.18.1-rc.0.js.map
|
|
@@ -67,7 +67,8 @@ class SpfxProjectDoctorCommand extends BaseProjectCommand {
|
|
|
67
67
|
'1.17.2',
|
|
68
68
|
'1.17.3',
|
|
69
69
|
'1.17.4',
|
|
70
|
-
'1.18.0'
|
|
70
|
+
'1.18.0',
|
|
71
|
+
'1.18.1-rc.0'
|
|
71
72
|
];
|
|
72
73
|
__classPrivateFieldGet(this, _SpfxProjectDoctorCommand_instances, "m", _SpfxProjectDoctorCommand_initTelemetry).call(this);
|
|
73
74
|
__classPrivateFieldGet(this, _SpfxProjectDoctorCommand_instances, "m", _SpfxProjectDoctorCommand_initOptions).call(this);
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { JsonRule } from '../../JsonRule.js';
|
|
2
|
+
export class FN014010_CODE_settings_filesexclude_jest extends JsonRule {
|
|
3
|
+
constructor() {
|
|
4
|
+
super();
|
|
5
|
+
}
|
|
6
|
+
get id() {
|
|
7
|
+
return 'FN014010';
|
|
8
|
+
}
|
|
9
|
+
get title() {
|
|
10
|
+
return 'Exclude Jest output files in .vscode/settings.json';
|
|
11
|
+
}
|
|
12
|
+
get description() {
|
|
13
|
+
return `Add excluding Jest output files in .vscode/settings.json`;
|
|
14
|
+
}
|
|
15
|
+
get resolution() {
|
|
16
|
+
return `{
|
|
17
|
+
"files.exclude": {
|
|
18
|
+
"**/jest-output": true
|
|
19
|
+
}
|
|
20
|
+
}`;
|
|
21
|
+
}
|
|
22
|
+
get resolutionType() {
|
|
23
|
+
return 'json';
|
|
24
|
+
}
|
|
25
|
+
get severity() {
|
|
26
|
+
return 'Required';
|
|
27
|
+
}
|
|
28
|
+
get file() {
|
|
29
|
+
return '.vscode/settings.json';
|
|
30
|
+
}
|
|
31
|
+
visit(project, findings) {
|
|
32
|
+
if (!project.vsCode ||
|
|
33
|
+
!project.vsCode.settingsJson ||
|
|
34
|
+
!project.vsCode.settingsJson["files.exclude"]) {
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
if (project.vsCode.settingsJson["files.exclude"]["**/jest-output"] === true) {
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
const node = this.getAstNodeFromFile(project.vsCode.settingsJson, `files;#exclude`);
|
|
41
|
+
this.addFindingWithPosition(findings, node);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
//# sourceMappingURL=FN014010_CODE_settings_filesexclude_jest.js.map
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { FN001001_DEP_microsoft_sp_core_library } from './rules/FN001001_DEP_microsoft_sp_core_library.js';
|
|
2
|
+
import { FN001002_DEP_microsoft_sp_lodash_subset } from './rules/FN001002_DEP_microsoft_sp_lodash_subset.js';
|
|
3
|
+
import { FN001003_DEP_microsoft_sp_office_ui_fabric_core } from './rules/FN001003_DEP_microsoft_sp_office_ui_fabric_core.js';
|
|
4
|
+
import { FN001004_DEP_microsoft_sp_webpart_base } from './rules/FN001004_DEP_microsoft_sp_webpart_base.js';
|
|
5
|
+
import { FN001011_DEP_microsoft_sp_dialog } from './rules/FN001011_DEP_microsoft_sp_dialog.js';
|
|
6
|
+
import { FN001012_DEP_microsoft_sp_application_base } from './rules/FN001012_DEP_microsoft_sp_application_base.js';
|
|
7
|
+
import { FN001013_DEP_microsoft_decorators } from './rules/FN001013_DEP_microsoft_decorators.js';
|
|
8
|
+
import { FN001014_DEP_microsoft_sp_listview_extensibility } from './rules/FN001014_DEP_microsoft_sp_listview_extensibility.js';
|
|
9
|
+
import { FN001021_DEP_microsoft_sp_property_pane } from './rules/FN001021_DEP_microsoft_sp_property_pane.js';
|
|
10
|
+
import { FN001022_DEP_office_ui_fabric_react } from './rules/FN001022_DEP_office_ui_fabric_react.js';
|
|
11
|
+
import { FN001023_DEP_microsoft_sp_component_base } from './rules/FN001023_DEP_microsoft_sp_component_base.js';
|
|
12
|
+
import { FN001024_DEP_microsoft_sp_diagnostics } from './rules/FN001024_DEP_microsoft_sp_diagnostics.js';
|
|
13
|
+
import { FN001025_DEP_microsoft_sp_dynamic_data } from './rules/FN001025_DEP_microsoft_sp_dynamic_data.js';
|
|
14
|
+
import { FN001026_DEP_microsoft_sp_extension_base } from './rules/FN001026_DEP_microsoft_sp_extension_base.js';
|
|
15
|
+
import { FN001027_DEP_microsoft_sp_http } from './rules/FN001027_DEP_microsoft_sp_http.js';
|
|
16
|
+
import { FN001028_DEP_microsoft_sp_list_subscription } from './rules/FN001028_DEP_microsoft_sp_list_subscription.js';
|
|
17
|
+
import { FN001029_DEP_microsoft_sp_loader } from './rules/FN001029_DEP_microsoft_sp_loader.js';
|
|
18
|
+
import { FN001030_DEP_microsoft_sp_module_interfaces } from './rules/FN001030_DEP_microsoft_sp_module_interfaces.js';
|
|
19
|
+
import { FN001031_DEP_microsoft_sp_odata_types } from './rules/FN001031_DEP_microsoft_sp_odata_types.js';
|
|
20
|
+
import { FN001032_DEP_microsoft_sp_page_context } from './rules/FN001032_DEP_microsoft_sp_page_context.js';
|
|
21
|
+
import { FN001034_DEP_microsoft_sp_adaptive_card_extension_base } from './rules/FN001034_DEP_microsoft_sp_adaptive_card_extension_base.js';
|
|
22
|
+
import { FN002001_DEVDEP_microsoft_sp_build_web } from './rules/FN002001_DEVDEP_microsoft_sp_build_web.js';
|
|
23
|
+
import { FN002002_DEVDEP_microsoft_sp_module_interfaces } from './rules/FN002002_DEVDEP_microsoft_sp_module_interfaces.js';
|
|
24
|
+
import { FN002022_DEVDEP_microsoft_eslint_plugin_spfx } from './rules/FN002022_DEVDEP_microsoft_eslint_plugin_spfx.js';
|
|
25
|
+
import { FN002023_DEVDEP_microsoft_eslint_config_spfx } from './rules/FN002023_DEVDEP_microsoft_eslint_config_spfx.js';
|
|
26
|
+
import { FN010001_YORC_version } from './rules/FN010001_YORC_version.js';
|
|
27
|
+
import { FN014010_CODE_settings_filesexclude_jest } from './rules/FN014010_CODE_settings_filesexclude_jest.js';
|
|
28
|
+
export default [
|
|
29
|
+
new FN001001_DEP_microsoft_sp_core_library('1.18.1-rc.0'),
|
|
30
|
+
new FN001002_DEP_microsoft_sp_lodash_subset('1.18.1-rc.0'),
|
|
31
|
+
new FN001003_DEP_microsoft_sp_office_ui_fabric_core('1.18.1-rc.0'),
|
|
32
|
+
new FN001004_DEP_microsoft_sp_webpart_base('1.18.1-rc.0'),
|
|
33
|
+
new FN001011_DEP_microsoft_sp_dialog('1.18.1-rc.0'),
|
|
34
|
+
new FN001012_DEP_microsoft_sp_application_base('1.18.1-rc.0'),
|
|
35
|
+
new FN001014_DEP_microsoft_sp_listview_extensibility('1.18.1-rc.0'),
|
|
36
|
+
new FN001021_DEP_microsoft_sp_property_pane('1.18.1-rc.0'),
|
|
37
|
+
new FN001022_DEP_office_ui_fabric_react('', false),
|
|
38
|
+
new FN001023_DEP_microsoft_sp_component_base('1.18.1-rc.0'),
|
|
39
|
+
new FN001024_DEP_microsoft_sp_diagnostics('1.18.1-rc.0'),
|
|
40
|
+
new FN001025_DEP_microsoft_sp_dynamic_data('1.18.1-rc.0'),
|
|
41
|
+
new FN001026_DEP_microsoft_sp_extension_base('1.18.1-rc.0'),
|
|
42
|
+
new FN001027_DEP_microsoft_sp_http('1.18.1-rc.0'),
|
|
43
|
+
new FN001028_DEP_microsoft_sp_list_subscription('1.18.1-rc.0'),
|
|
44
|
+
new FN001029_DEP_microsoft_sp_loader('1.18.1-rc.0'),
|
|
45
|
+
new FN001030_DEP_microsoft_sp_module_interfaces('1.18.1-rc.0'),
|
|
46
|
+
new FN001031_DEP_microsoft_sp_odata_types('1.18.1-rc.0'),
|
|
47
|
+
new FN001032_DEP_microsoft_sp_page_context('1.18.1-rc.0'),
|
|
48
|
+
new FN001013_DEP_microsoft_decorators('1.18.1-rc.0'),
|
|
49
|
+
new FN001034_DEP_microsoft_sp_adaptive_card_extension_base('1.18.1-rc.0'),
|
|
50
|
+
new FN002001_DEVDEP_microsoft_sp_build_web('1.18.1-rc.0'),
|
|
51
|
+
new FN002002_DEVDEP_microsoft_sp_module_interfaces('1.18.1-rc.0'),
|
|
52
|
+
new FN002022_DEVDEP_microsoft_eslint_plugin_spfx('1.18.1-rc.0'),
|
|
53
|
+
new FN002023_DEVDEP_microsoft_eslint_config_spfx('1.18.1-rc.0'),
|
|
54
|
+
new FN010001_YORC_version('1.18.1-rc.0'),
|
|
55
|
+
new FN014010_CODE_settings_filesexclude_jest()
|
|
56
|
+
];
|
|
57
|
+
//# sourceMappingURL=upgrade-1.18.1-rc.0.js.map
|
|
@@ -7,6 +7,8 @@ var _SpfxProjectUpgradeCommand_instances, _a, _SpfxProjectUpgradeCommand_initTel
|
|
|
7
7
|
import fs from 'fs';
|
|
8
8
|
import os from 'os';
|
|
9
9
|
import path from 'path';
|
|
10
|
+
// uncomment to support upgrading to preview releases
|
|
11
|
+
import { prerelease } from 'semver';
|
|
10
12
|
import { CommandError } from '../../../../Command.js';
|
|
11
13
|
import { fsUtil } from '../../../../utils/fsUtil.js';
|
|
12
14
|
import { packageManager } from '../../../../utils/packageManager.js';
|
|
@@ -69,7 +71,8 @@ class SpfxProjectUpgradeCommand extends BaseProjectCommand {
|
|
|
69
71
|
'1.17.2',
|
|
70
72
|
'1.17.3',
|
|
71
73
|
'1.17.4',
|
|
72
|
-
'1.18.0'
|
|
74
|
+
'1.18.0',
|
|
75
|
+
'1.18.1-rc.0'
|
|
73
76
|
];
|
|
74
77
|
__classPrivateFieldGet(this, _SpfxProjectUpgradeCommand_instances, "m", _SpfxProjectUpgradeCommand_initTelemetry).call(this);
|
|
75
78
|
__classPrivateFieldGet(this, _SpfxProjectUpgradeCommand_instances, "m", _SpfxProjectUpgradeCommand_initOptions).call(this);
|
|
@@ -82,15 +85,15 @@ class SpfxProjectUpgradeCommand extends BaseProjectCommand {
|
|
|
82
85
|
}
|
|
83
86
|
this.toVersion = args.options.toVersion ? args.options.toVersion : this.supportedVersions[this.supportedVersions.length - 1];
|
|
84
87
|
// uncomment to support upgrading to preview releases
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
88
|
+
if (!args.options.toVersion &&
|
|
89
|
+
!args.options.preview &&
|
|
90
|
+
prerelease(this.toVersion)) {
|
|
91
|
+
// no version and no preview specified while the current version to
|
|
92
|
+
// upgrade to is a prerelease so let's grab the first non-preview version
|
|
93
|
+
// since we're supporting only one preview version, it's sufficient for
|
|
94
|
+
// us to take second to last version
|
|
95
|
+
this.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
|
|
96
|
+
}
|
|
94
97
|
this.packageManager = args.options.packageManager || 'npm';
|
|
95
98
|
this.shell = args.options.shell || 'bash';
|
|
96
99
|
if (this.supportedVersions.indexOf(this.toVersion) < 0) {
|
|
@@ -477,9 +480,9 @@ _a = SpfxProjectUpgradeCommand, _SpfxProjectUpgradeCommand_instances = new WeakS
|
|
|
477
480
|
preview: args.options.preview
|
|
478
481
|
});
|
|
479
482
|
// uncomment to support upgrading to preview releases
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
+
if (prerelease(this.telemetryProperties.toVersion) && !args.options.preview) {
|
|
484
|
+
this.telemetryProperties.toVersion = this.supportedVersions[this.supportedVersions.length - 2];
|
|
485
|
+
}
|
|
483
486
|
});
|
|
484
487
|
}, _SpfxProjectUpgradeCommand_initOptions = function _SpfxProjectUpgradeCommand_initOptions() {
|
|
485
488
|
this.options.unshift({
|
|
@@ -538,6 +538,21 @@ class SpfxDoctorCommand extends BaseProjectCommand {
|
|
|
538
538
|
range: '^4',
|
|
539
539
|
fix: 'npm i -g yo@4'
|
|
540
540
|
}
|
|
541
|
+
},
|
|
542
|
+
'1.18.1-rc.0': {
|
|
543
|
+
gulpCli: {
|
|
544
|
+
range: '^1 || ^2',
|
|
545
|
+
fix: 'npm i -g gulp-cli@2'
|
|
546
|
+
},
|
|
547
|
+
node: {
|
|
548
|
+
range: '>=16.13.0 <17.0.0 || >=18.17.1 <19.0.0',
|
|
549
|
+
fix: 'Install Node.js >=16.13.0 <17.0.0 || >=18.17.1 <19.0.0'
|
|
550
|
+
},
|
|
551
|
+
sp: SharePointVersion.SPO,
|
|
552
|
+
yo: {
|
|
553
|
+
range: '^4',
|
|
554
|
+
fix: 'npm i -g yo@4'
|
|
555
|
+
}
|
|
541
556
|
}
|
|
542
557
|
};
|
|
543
558
|
__classPrivateFieldGet(this, _SpfxDoctorCommand_instances, "m", _SpfxDoctorCommand_initTelemetry).call(this);
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
2
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
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
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
|
+
};
|
|
6
|
+
var _TenantPeopleProfileCardPropertyAddCommand_instances, _TenantPeopleProfileCardPropertyAddCommand_initTelemetry, _TenantPeopleProfileCardPropertyAddCommand_initOptions, _TenantPeopleProfileCardPropertyAddCommand_initValidators;
|
|
7
|
+
import request from '../../../../request.js';
|
|
8
|
+
import GraphCommand from '../../../base/GraphCommand.js';
|
|
9
|
+
import commands from '../../commands.js';
|
|
10
|
+
import { profileCardPropertyNames } from './profileCardProperties.js';
|
|
11
|
+
class TenantPeopleProfileCardPropertyAddCommand extends GraphCommand {
|
|
12
|
+
get name() {
|
|
13
|
+
return commands.PEOPLE_PROFILECARDPROPERTY_ADD;
|
|
14
|
+
}
|
|
15
|
+
get description() {
|
|
16
|
+
return 'Adds an additional attribute to the profile card properties';
|
|
17
|
+
}
|
|
18
|
+
constructor() {
|
|
19
|
+
super();
|
|
20
|
+
_TenantPeopleProfileCardPropertyAddCommand_instances.add(this);
|
|
21
|
+
this.excludeOptions = ['name', 'displayName', 'debug', 'verbose', 'output'];
|
|
22
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyAddCommand_instances, "m", _TenantPeopleProfileCardPropertyAddCommand_initTelemetry).call(this);
|
|
23
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyAddCommand_instances, "m", _TenantPeopleProfileCardPropertyAddCommand_initOptions).call(this);
|
|
24
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyAddCommand_instances, "m", _TenantPeopleProfileCardPropertyAddCommand_initValidators).call(this);
|
|
25
|
+
}
|
|
26
|
+
allowUnknownOptions() {
|
|
27
|
+
return true;
|
|
28
|
+
}
|
|
29
|
+
async commandAction(logger, args) {
|
|
30
|
+
const directoryPropertyName = profileCardPropertyNames.find(n => n.toLowerCase() === args.options.name.toLowerCase());
|
|
31
|
+
if (this.verbose) {
|
|
32
|
+
await logger.logToStderr(`Adding '${directoryPropertyName}' as a profile card property...`);
|
|
33
|
+
}
|
|
34
|
+
const requestOptions = {
|
|
35
|
+
url: `${this.resource}/v1.0/admin/people/profileCardProperties`,
|
|
36
|
+
headers: {
|
|
37
|
+
'content-type': 'application/json',
|
|
38
|
+
accept: 'application/json;odata.metadata=none'
|
|
39
|
+
},
|
|
40
|
+
responseType: 'json',
|
|
41
|
+
data: {
|
|
42
|
+
directoryPropertyName,
|
|
43
|
+
annotations: this.getAnnotations(args.options)
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
try {
|
|
47
|
+
const response = await request.post(requestOptions);
|
|
48
|
+
// Transform the output to make it more readable
|
|
49
|
+
if (args.options.output && args.options.output !== 'json' && response.annotations.length > 0) {
|
|
50
|
+
const annotation = response.annotations[0];
|
|
51
|
+
response.displayName = annotation.displayName;
|
|
52
|
+
annotation.localizations.forEach((l) => {
|
|
53
|
+
response[`displayName ${l.languageTag}`] = l.displayName;
|
|
54
|
+
});
|
|
55
|
+
delete response.annotations;
|
|
56
|
+
}
|
|
57
|
+
await logger.log(response);
|
|
58
|
+
}
|
|
59
|
+
catch (err) {
|
|
60
|
+
this.handleRejectedODataJsonPromise(err);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
getAnnotations(options) {
|
|
64
|
+
if (!options.displayName) {
|
|
65
|
+
return [];
|
|
66
|
+
}
|
|
67
|
+
return [
|
|
68
|
+
{
|
|
69
|
+
displayName: options.displayName,
|
|
70
|
+
localizations: this.getLocalizations(options)
|
|
71
|
+
}
|
|
72
|
+
];
|
|
73
|
+
}
|
|
74
|
+
getLocalizations(options) {
|
|
75
|
+
const unknownOptions = Object.keys(options).filter(key => !this.excludeOptions.includes(key));
|
|
76
|
+
if (unknownOptions.length === 0) {
|
|
77
|
+
return [];
|
|
78
|
+
}
|
|
79
|
+
const localizations = [];
|
|
80
|
+
unknownOptions.forEach(key => {
|
|
81
|
+
localizations.push({
|
|
82
|
+
languageTag: key.replace('displayName-', ''),
|
|
83
|
+
displayName: options[key]
|
|
84
|
+
});
|
|
85
|
+
});
|
|
86
|
+
return localizations;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
_TenantPeopleProfileCardPropertyAddCommand_instances = new WeakSet(), _TenantPeopleProfileCardPropertyAddCommand_initTelemetry = function _TenantPeopleProfileCardPropertyAddCommand_initTelemetry() {
|
|
90
|
+
this.telemetry.push((args) => {
|
|
91
|
+
Object.assign(this.telemetryProperties, {
|
|
92
|
+
displayName: typeof args.options.displayName !== 'undefined'
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
}, _TenantPeopleProfileCardPropertyAddCommand_initOptions = function _TenantPeopleProfileCardPropertyAddCommand_initOptions() {
|
|
96
|
+
this.options.unshift({
|
|
97
|
+
option: '-n, --name <name>',
|
|
98
|
+
autocomplete: profileCardPropertyNames
|
|
99
|
+
}, {
|
|
100
|
+
option: '-d, --displayName [displayName]'
|
|
101
|
+
});
|
|
102
|
+
}, _TenantPeopleProfileCardPropertyAddCommand_initValidators = function _TenantPeopleProfileCardPropertyAddCommand_initValidators() {
|
|
103
|
+
this.validators.push(async (args) => {
|
|
104
|
+
const propertyName = args.options.name.toLowerCase();
|
|
105
|
+
if (profileCardPropertyNames.every(n => n.toLowerCase() !== propertyName)) {
|
|
106
|
+
return `${args.options.name} is not a valid value for name. Allowed values are ${profileCardPropertyNames.join(', ')}`;
|
|
107
|
+
}
|
|
108
|
+
if (propertyName.startsWith("customattribute") && args.options.displayName === undefined) {
|
|
109
|
+
return `The option 'displayName' is required when adding customAttributes as profile card properties`;
|
|
110
|
+
}
|
|
111
|
+
if (!propertyName.startsWith("customattribute") && args.options.displayName !== undefined) {
|
|
112
|
+
return `The option 'displayName' can only be used when adding customAttributes as profile card properties`;
|
|
113
|
+
}
|
|
114
|
+
const unknownOptions = Object.keys(args.options).filter(key => !this.excludeOptions.includes(key));
|
|
115
|
+
if (!propertyName.startsWith('customattribute') && unknownOptions.length > 0) {
|
|
116
|
+
return `Unknown options like ${unknownOptions.join(', ')} are only supported with customAttributes`;
|
|
117
|
+
}
|
|
118
|
+
if (propertyName.startsWith('customattribute')) {
|
|
119
|
+
const wronglyFormattedOptions = unknownOptions.filter(key => !key.toLowerCase().startsWith('displayname-'));
|
|
120
|
+
if (wronglyFormattedOptions.length > 0) {
|
|
121
|
+
return `Wrong option format detected for the following option(s): ${wronglyFormattedOptions.join(', ')}'. When adding localizations for customAttributes, use the format displayName-<languageTag>.`;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
return true;
|
|
125
|
+
});
|
|
126
|
+
};
|
|
127
|
+
export default new TenantPeopleProfileCardPropertyAddCommand();
|
|
128
|
+
//# sourceMappingURL=people-profilecardproperty-add.js.map
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
2
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
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
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
|
+
};
|
|
6
|
+
var _TenantPeopleProfileCardPropertyGetCommand_instances, _TenantPeopleProfileCardPropertyGetCommand_initOptions, _TenantPeopleProfileCardPropertyGetCommand_initValidators;
|
|
7
|
+
import GraphCommand from '../../../base/GraphCommand.js';
|
|
8
|
+
import request from '../../../../request.js';
|
|
9
|
+
import { profileCardPropertyNames } from './profileCardProperties.js';
|
|
10
|
+
import commands from '../../commands.js';
|
|
11
|
+
class TenantPeopleProfileCardPropertyGetCommand extends GraphCommand {
|
|
12
|
+
get name() {
|
|
13
|
+
return commands.PEOPLE_PROFILECARDPROPERTY_GET;
|
|
14
|
+
}
|
|
15
|
+
get description() {
|
|
16
|
+
return 'Retrieves information about a specific profile card property';
|
|
17
|
+
}
|
|
18
|
+
constructor() {
|
|
19
|
+
super();
|
|
20
|
+
_TenantPeopleProfileCardPropertyGetCommand_instances.add(this);
|
|
21
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyGetCommand_instances, "m", _TenantPeopleProfileCardPropertyGetCommand_initOptions).call(this);
|
|
22
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyGetCommand_instances, "m", _TenantPeopleProfileCardPropertyGetCommand_initValidators).call(this);
|
|
23
|
+
}
|
|
24
|
+
async commandAction(logger, args) {
|
|
25
|
+
try {
|
|
26
|
+
if (this.verbose) {
|
|
27
|
+
await logger.logToStderr(`Retrieving information about profile card property '${args.options.name}'...`);
|
|
28
|
+
}
|
|
29
|
+
const requestOptions = {
|
|
30
|
+
url: `${this.resource}/v1.0/admin/people/profileCardProperties/${args.options.name}`,
|
|
31
|
+
headers: {
|
|
32
|
+
accept: 'application/json;odata.metadata=none'
|
|
33
|
+
},
|
|
34
|
+
responseType: 'json'
|
|
35
|
+
};
|
|
36
|
+
const result = await request.get(requestOptions);
|
|
37
|
+
let output = result;
|
|
38
|
+
// Transform the output to make it more readable
|
|
39
|
+
if (args.options.output && args.options.output !== 'json' && result.annotations.length > 0) {
|
|
40
|
+
output = result.annotations[0].localizations.reduce((acc, curr) => ({
|
|
41
|
+
...acc,
|
|
42
|
+
['displayName ' + curr.languageTag]: curr.displayName
|
|
43
|
+
}), {
|
|
44
|
+
...result,
|
|
45
|
+
displayName: result.annotations[0].displayName
|
|
46
|
+
});
|
|
47
|
+
delete output.annotations;
|
|
48
|
+
}
|
|
49
|
+
await logger.log(output);
|
|
50
|
+
}
|
|
51
|
+
catch (err) {
|
|
52
|
+
if (err.response?.status === 404) {
|
|
53
|
+
this.handleError(`Profile card property '${args.options.name}' does not exist.`);
|
|
54
|
+
}
|
|
55
|
+
this.handleRejectedODataJsonPromise(err);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
_TenantPeopleProfileCardPropertyGetCommand_instances = new WeakSet(), _TenantPeopleProfileCardPropertyGetCommand_initOptions = function _TenantPeopleProfileCardPropertyGetCommand_initOptions() {
|
|
60
|
+
this.options.unshift({
|
|
61
|
+
option: '-n, --name <name>',
|
|
62
|
+
autocomplete: profileCardPropertyNames
|
|
63
|
+
});
|
|
64
|
+
}, _TenantPeopleProfileCardPropertyGetCommand_initValidators = function _TenantPeopleProfileCardPropertyGetCommand_initValidators() {
|
|
65
|
+
this.validators.push(async (args) => {
|
|
66
|
+
if (!profileCardPropertyNames.some(p => p.toLowerCase() === args.options.name.toLowerCase())) {
|
|
67
|
+
return `'${args.options.name}' is not a valid value for option name. Allowed values are: ${profileCardPropertyNames.join(', ')}.`;
|
|
68
|
+
}
|
|
69
|
+
return true;
|
|
70
|
+
});
|
|
71
|
+
};
|
|
72
|
+
export default new TenantPeopleProfileCardPropertyGetCommand();
|
|
73
|
+
//# sourceMappingURL=people-profilecardproperty-get.js.map
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import GraphCommand from '../../../base/GraphCommand.js';
|
|
2
|
+
import request from '../../../../request.js';
|
|
3
|
+
import commands from '../../commands.js';
|
|
4
|
+
class TenantPeopleProfileCardPropertyListCommand extends GraphCommand {
|
|
5
|
+
get name() {
|
|
6
|
+
return commands.PEOPLE_PROFILECARDPROPERTY_LIST;
|
|
7
|
+
}
|
|
8
|
+
get description() {
|
|
9
|
+
return 'Lists all profile card properties';
|
|
10
|
+
}
|
|
11
|
+
constructor() {
|
|
12
|
+
super();
|
|
13
|
+
}
|
|
14
|
+
async commandAction(logger, args) {
|
|
15
|
+
try {
|
|
16
|
+
if (this.verbose) {
|
|
17
|
+
await logger.logToStderr(`Lists all profile card properties...`);
|
|
18
|
+
}
|
|
19
|
+
const requestOptions = {
|
|
20
|
+
url: `${this.resource}/v1.0/admin/people/profileCardProperties`,
|
|
21
|
+
headers: {
|
|
22
|
+
accept: 'application/json;odata.metadata=none'
|
|
23
|
+
},
|
|
24
|
+
responseType: 'json'
|
|
25
|
+
};
|
|
26
|
+
const result = await request.get(requestOptions);
|
|
27
|
+
let output = result;
|
|
28
|
+
if (args.options.output && args.options.output !== 'json') {
|
|
29
|
+
output = output.value.sort((n1, n2) => {
|
|
30
|
+
const localizations1 = n1.annotations[0]?.localizations?.length ?? 0;
|
|
31
|
+
const localizations2 = n2.annotations[0]?.localizations?.length ?? 0;
|
|
32
|
+
if (localizations1 > localizations2) {
|
|
33
|
+
return -1;
|
|
34
|
+
}
|
|
35
|
+
if (localizations1 < localizations2) {
|
|
36
|
+
return 1;
|
|
37
|
+
}
|
|
38
|
+
return 0;
|
|
39
|
+
});
|
|
40
|
+
output = output.map((p) => {
|
|
41
|
+
const propertyAnnotations = p.annotations[0]?.localizations?.map((l) => {
|
|
42
|
+
return { ['displayName ' + l.languageTag]: l.displayName };
|
|
43
|
+
}) ?? [];
|
|
44
|
+
const propertyAnnotationsObject = Object.assign({}, ...propertyAnnotations);
|
|
45
|
+
const result = { directoryPropertyName: p.directoryPropertyName };
|
|
46
|
+
if (p.annotations[0]?.displayName) {
|
|
47
|
+
result.displayName = p.annotations[0]?.displayName;
|
|
48
|
+
}
|
|
49
|
+
return {
|
|
50
|
+
...result,
|
|
51
|
+
...propertyAnnotationsObject
|
|
52
|
+
};
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
await logger.log(output);
|
|
56
|
+
}
|
|
57
|
+
catch (err) {
|
|
58
|
+
this.handleRejectedODataJsonPromise(err);
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
export default new TenantPeopleProfileCardPropertyListCommand();
|
|
63
|
+
//# sourceMappingURL=people-profilecardproperty-list.js.map
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
2
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
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
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
|
+
};
|
|
6
|
+
var _TenantPeopleProfileCardPropertyRemoveCommand_instances, _TenantPeopleProfileCardPropertyRemoveCommand_initTelemetry, _TenantPeopleProfileCardPropertyRemoveCommand_initOptions, _TenantPeopleProfileCardPropertyRemoveCommand_initValidators;
|
|
7
|
+
import { Cli } from '../../../../cli/Cli.js';
|
|
8
|
+
import request from '../../../../request.js';
|
|
9
|
+
import GraphCommand from '../../../base/GraphCommand.js';
|
|
10
|
+
import commands from '../../commands.js';
|
|
11
|
+
import { profileCardPropertyNames } from './profileCardProperties.js';
|
|
12
|
+
class TenantPeopleProfileCardPropertyRemoveCommand extends GraphCommand {
|
|
13
|
+
get name() {
|
|
14
|
+
return commands.PEOPLE_PROFILECARDPROPERTY_REMOVE;
|
|
15
|
+
}
|
|
16
|
+
get description() {
|
|
17
|
+
return 'Removes an additional attribute from the profile card properties';
|
|
18
|
+
}
|
|
19
|
+
constructor() {
|
|
20
|
+
super();
|
|
21
|
+
_TenantPeopleProfileCardPropertyRemoveCommand_instances.add(this);
|
|
22
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyRemoveCommand_instances, "m", _TenantPeopleProfileCardPropertyRemoveCommand_initTelemetry).call(this);
|
|
23
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyRemoveCommand_instances, "m", _TenantPeopleProfileCardPropertyRemoveCommand_initOptions).call(this);
|
|
24
|
+
__classPrivateFieldGet(this, _TenantPeopleProfileCardPropertyRemoveCommand_instances, "m", _TenantPeopleProfileCardPropertyRemoveCommand_initValidators).call(this);
|
|
25
|
+
}
|
|
26
|
+
async commandAction(logger, args) {
|
|
27
|
+
const directoryPropertyName = profileCardPropertyNames.find(n => n.toLowerCase() === args.options.name.toLowerCase());
|
|
28
|
+
const removeProfileCardProperty = async () => {
|
|
29
|
+
if (this.verbose) {
|
|
30
|
+
await logger.logToStderr(`Removing '${directoryPropertyName}' as a profile card property...`);
|
|
31
|
+
}
|
|
32
|
+
const requestOptions = {
|
|
33
|
+
url: `${this.resource}/v1.0/admin/people/profileCardProperties/${directoryPropertyName}`,
|
|
34
|
+
headers: {
|
|
35
|
+
'content-type': 'application/json'
|
|
36
|
+
},
|
|
37
|
+
responseType: 'json'
|
|
38
|
+
};
|
|
39
|
+
try {
|
|
40
|
+
await request.delete(requestOptions);
|
|
41
|
+
}
|
|
42
|
+
catch (err) {
|
|
43
|
+
this.handleRejectedODataJsonPromise(err);
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
if (args.options.force) {
|
|
47
|
+
await removeProfileCardProperty();
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
const result = await Cli.prompt({
|
|
51
|
+
type: 'confirm',
|
|
52
|
+
name: 'continue',
|
|
53
|
+
default: false,
|
|
54
|
+
message: `Are you sure you want to remove the profile card property '${directoryPropertyName}'?`
|
|
55
|
+
});
|
|
56
|
+
if (result.continue) {
|
|
57
|
+
await removeProfileCardProperty();
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
_TenantPeopleProfileCardPropertyRemoveCommand_instances = new WeakSet(), _TenantPeopleProfileCardPropertyRemoveCommand_initTelemetry = function _TenantPeopleProfileCardPropertyRemoveCommand_initTelemetry() {
|
|
63
|
+
this.telemetry.push((args) => {
|
|
64
|
+
Object.assign(this.telemetryProperties, {
|
|
65
|
+
force: !!args.options.force
|
|
66
|
+
});
|
|
67
|
+
});
|
|
68
|
+
}, _TenantPeopleProfileCardPropertyRemoveCommand_initOptions = function _TenantPeopleProfileCardPropertyRemoveCommand_initOptions() {
|
|
69
|
+
this.options.unshift({
|
|
70
|
+
option: '-n, --name <name>',
|
|
71
|
+
autocomplete: profileCardPropertyNames
|
|
72
|
+
}, {
|
|
73
|
+
option: '-f, --force'
|
|
74
|
+
});
|
|
75
|
+
}, _TenantPeopleProfileCardPropertyRemoveCommand_initValidators = function _TenantPeopleProfileCardPropertyRemoveCommand_initValidators() {
|
|
76
|
+
this.validators.push(async (args) => {
|
|
77
|
+
if (profileCardPropertyNames.every(n => n.toLowerCase() !== args.options.name.toLowerCase())) {
|
|
78
|
+
return `${args.options.name} is not a valid value for name. Allowed values are ${profileCardPropertyNames.join(', ')}`;
|
|
79
|
+
}
|
|
80
|
+
return true;
|
|
81
|
+
});
|
|
82
|
+
};
|
|
83
|
+
export default new TenantPeopleProfileCardPropertyRemoveCommand();
|
|
84
|
+
//# sourceMappingURL=people-profilecardproperty-remove.js.map
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export const profileCardPropertyNames = [
|
|
2
|
+
'UserPrincipalName',
|
|
3
|
+
'Fax',
|
|
4
|
+
'StreetAddress',
|
|
5
|
+
'PostalCode',
|
|
6
|
+
'StateOrProvince',
|
|
7
|
+
'Alias',
|
|
8
|
+
'customAttribute1',
|
|
9
|
+
'customAttribute2',
|
|
10
|
+
'customAttribute3',
|
|
11
|
+
'customAttribute4',
|
|
12
|
+
'customAttribute5',
|
|
13
|
+
'customAttribute6',
|
|
14
|
+
'customAttribute7',
|
|
15
|
+
'customAttribute8',
|
|
16
|
+
'customAttribute9',
|
|
17
|
+
'customAttribute10',
|
|
18
|
+
'customAttribute11',
|
|
19
|
+
'customAttribute12',
|
|
20
|
+
'customAttribute13',
|
|
21
|
+
'customAttribute14',
|
|
22
|
+
'customAttribute15'
|
|
23
|
+
];
|
|
24
|
+
//# sourceMappingURL=profileCardProperties.js.map
|
|
@@ -2,6 +2,10 @@ const prefix = 'tenant';
|
|
|
2
2
|
export default {
|
|
3
3
|
ID_GET: `${prefix} id get`,
|
|
4
4
|
INFO_GET: `${prefix} info get`,
|
|
5
|
+
PEOPLE_PROFILECARDPROPERTY_ADD: `${prefix} people profilecardproperty add`,
|
|
6
|
+
PEOPLE_PROFILECARDPROPERTY_GET: `${prefix} people profilecardproperty get`,
|
|
7
|
+
PEOPLE_PROFILECARDPROPERTY_LIST: `${prefix} people profilecardproperty list`,
|
|
8
|
+
PEOPLE_PROFILECARDPROPERTY_REMOVE: `${prefix} people profilecardproperty remove`,
|
|
5
9
|
REPORT_ACTIVEUSERCOUNTS: `${prefix} report activeusercounts`,
|
|
6
10
|
REPORT_ACTIVEUSERDETAIL: `${prefix} report activeuserdetail`,
|
|
7
11
|
REPORT_OFFICE365ACTIVATIONCOUNTS: `${prefix} report office365activationcounts`,
|
|
@@ -21,7 +21,7 @@ m365 aad administrativeunit add [options]
|
|
|
21
21
|
`-d, --description [description]`
|
|
22
22
|
: Description for the administrative unit.
|
|
23
23
|
|
|
24
|
-
`--hiddenMembership
|
|
24
|
+
`--hiddenMembership`
|
|
25
25
|
: Indicates whether the administrative unit and its members are hidden.
|
|
26
26
|
```
|
|
27
27
|
|
|
@@ -112,4 +112,8 @@ m365 aad administrativeunit add --displayName 'Marketing Division' --hiddenMembe
|
|
|
112
112
|
```
|
|
113
113
|
|
|
114
114
|
</TabItem>
|
|
115
|
-
</Tabs>
|
|
115
|
+
</Tabs>
|
|
116
|
+
|
|
117
|
+
## More information
|
|
118
|
+
|
|
119
|
+
- Administrative units: https://learn.microsoft.com/entra/identity/role-based-access-control/administrative-units
|
|
@@ -95,4 +95,8 @@ m365 aad administrativeunit get --displayName 'Marketing Division'
|
|
|
95
95
|
```
|
|
96
96
|
|
|
97
97
|
</TabItem>
|
|
98
|
-
</Tabs>
|
|
98
|
+
</Tabs>
|
|
99
|
+
|
|
100
|
+
## More information
|
|
101
|
+
|
|
102
|
+
- Administrative units: https://learn.microsoft.com/entra/identity/role-based-access-control/administrative-units
|
|
@@ -19,7 +19,7 @@ m365 aad administrativeunit remove [options]
|
|
|
19
19
|
`-n, --displayName [displayName]`
|
|
20
20
|
: The display name of the administrative unit. Specify either `id` or `displayName` but not both.
|
|
21
21
|
|
|
22
|
-
`-f, --force
|
|
22
|
+
`-f, --force`
|
|
23
23
|
: Don't prompt for confirmation.
|
|
24
24
|
```
|
|
25
25
|
|
|
@@ -49,4 +49,8 @@ m365 aad administrativeunit remove --displayName 'Marketing Division'
|
|
|
49
49
|
|
|
50
50
|
## Response
|
|
51
51
|
|
|
52
|
-
The command won't return a response on success
|
|
52
|
+
The command won't return a response on success
|
|
53
|
+
|
|
54
|
+
## More information
|
|
55
|
+
|
|
56
|
+
- Administrative units: https://learn.microsoft.com/entra/identity/role-based-access-control/administrative-units
|
|
@@ -35,7 +35,7 @@ m365 spfx project upgrade [options]
|
|
|
35
35
|
|
|
36
36
|
## Remarks
|
|
37
37
|
|
|
38
|
-
The `spfx project upgrade` command helps you upgrade your SharePoint Framework project to the specified version. If no version is specified, the command will upgrade to the latest version of the SharePoint Framework it supports (v1.18.0).
|
|
38
|
+
The `spfx project upgrade` command helps you upgrade your SharePoint Framework project to the specified version. If no version is specified, the command will upgrade to the latest version of the SharePoint Framework it supports (v1.18.1-rc.0).
|
|
39
39
|
|
|
40
40
|
This command doesn't change your project files. Instead, it gives you a report with all steps necessary to upgrade your project to the specified version of the SharePoint Framework. Changing project files is error-prone, especially when it comes to updating your solution's code. This is why at this moment, this command produces a report that you can use yourself to perform the necessary updates and verify that everything is working as expected.
|
|
41
41
|
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# tenant people profilecardproperty add
|
|
6
|
+
|
|
7
|
+
Adds an additional attribute to the profile card properties
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 tenant people profilecardproperty add [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
```md definition-list
|
|
18
|
+
`-n, --name <name>`
|
|
19
|
+
: The name of the property to add. Allowed values: `UserPrincipalName`, `Fax`, `StreetAddress`, `PostalCode`, `StateOrProvince`, `Alias`, `customAttribute1`, `customAttribute2`, `customAttribute3`, `customAttribute4`, `customAttribute5`, `customAttribute6`, `customAttribute7`, `customAttribute8`, `customAttribute9`, `customAttribute10`, `customAttribute11`, `customAttribute12`, `customAttribute13`, `customAttribute14`, `customAttribute15`.
|
|
20
|
+
|
|
21
|
+
`-d, --displayName [displayName]`
|
|
22
|
+
: The display name of a property, only use this together with a custom extension attribute.
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
<Global />
|
|
26
|
+
|
|
27
|
+
## Remarks
|
|
28
|
+
|
|
29
|
+
:::info
|
|
30
|
+
|
|
31
|
+
To use this command you must be either **Tenant Administrator** or **Global Administrator**.
|
|
32
|
+
|
|
33
|
+
:::
|
|
34
|
+
|
|
35
|
+
:::info
|
|
36
|
+
|
|
37
|
+
You can specify localized values for the `displayName` as well. These can be entered by suffixing the displayName option with a language code: `--displayName-nl-NL "Kostencentrum"`, `--displayName-de "Kostenstelle"`.
|
|
38
|
+
|
|
39
|
+
:::
|
|
40
|
+
|
|
41
|
+
:::caution
|
|
42
|
+
|
|
43
|
+
When adding an attribute to a profile card, it takes up to 24 hours for the addition to be displayed.
|
|
44
|
+
|
|
45
|
+
:::
|
|
46
|
+
|
|
47
|
+
## Examples
|
|
48
|
+
|
|
49
|
+
Add the UPN as a profile property to the profile cards properties
|
|
50
|
+
|
|
51
|
+
```sh
|
|
52
|
+
m365 tenant people profilecardproperty add --name UserPrincipalName
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Add a custom extension attribute _Cost Center_ as a profile property to the profile cards properties
|
|
56
|
+
|
|
57
|
+
```sh
|
|
58
|
+
m365 tenant people profilecardproperty add --name customAttribute1 --displayName 'Cost Center'
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Add a custom extension attribute _Cost Center_ as a profile property to the profile cards properties with a Dutch localization
|
|
62
|
+
|
|
63
|
+
```sh
|
|
64
|
+
m365 tenant people profilecardproperty add --name customAttribute1 --displayName 'Cost Center' --displayName-nl-NL 'Kostencentrum'
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## Response
|
|
68
|
+
|
|
69
|
+
### Standard response
|
|
70
|
+
|
|
71
|
+
<Tabs>
|
|
72
|
+
<TabItem value="JSON">
|
|
73
|
+
|
|
74
|
+
```json
|
|
75
|
+
{
|
|
76
|
+
"directoryPropertyName": "UserPrincipalName",
|
|
77
|
+
"annotations": []
|
|
78
|
+
}
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
</TabItem>
|
|
82
|
+
<TabItem value="Text">
|
|
83
|
+
|
|
84
|
+
```text
|
|
85
|
+
annotations : []
|
|
86
|
+
directoryPropertyName: UserPrincipalName
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
</TabItem>
|
|
90
|
+
<TabItem value="CSV">
|
|
91
|
+
|
|
92
|
+
```csv
|
|
93
|
+
directoryPropertyName
|
|
94
|
+
UserPrincipalName
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
</TabItem>
|
|
98
|
+
<TabItem value="Markdown">
|
|
99
|
+
|
|
100
|
+
```md
|
|
101
|
+
# tenant people profilecardproperty add --name 'UserPrincipalName'
|
|
102
|
+
|
|
103
|
+
Date: 11/2/2023
|
|
104
|
+
|
|
105
|
+
Property | Value
|
|
106
|
+
---------|-------
|
|
107
|
+
directoryPropertyName | UserPrincipalName
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
</TabItem>
|
|
111
|
+
</Tabs>
|
|
112
|
+
|
|
113
|
+
### Response with a customAttribute
|
|
114
|
+
|
|
115
|
+
When we make use of one of the customAttributes, the response will differ.
|
|
116
|
+
|
|
117
|
+
<Tabs>
|
|
118
|
+
<TabItem value="JSON">
|
|
119
|
+
|
|
120
|
+
```json
|
|
121
|
+
{
|
|
122
|
+
"directoryPropertyName": "customAttribute1",
|
|
123
|
+
"annotations": [
|
|
124
|
+
{
|
|
125
|
+
"displayName": "Cost center",
|
|
126
|
+
"localizations": [
|
|
127
|
+
{
|
|
128
|
+
"languageTag": "nl-NL",
|
|
129
|
+
"displayName": "Kostenplaats"
|
|
130
|
+
}
|
|
131
|
+
]
|
|
132
|
+
}
|
|
133
|
+
]
|
|
134
|
+
}
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
</TabItem>
|
|
138
|
+
<TabItem value="Text">
|
|
139
|
+
|
|
140
|
+
```text
|
|
141
|
+
directoryPropertyName: customAttribute1
|
|
142
|
+
displayName : Cost center
|
|
143
|
+
displayName nl-NL : Kostenplaats
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
</TabItem>
|
|
147
|
+
<TabItem value="CSV">
|
|
148
|
+
|
|
149
|
+
```csv
|
|
150
|
+
directoryPropertyName,displayName,displayName nl-NL
|
|
151
|
+
customAttribute1,Cost center,Kostenplaats
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
</TabItem>
|
|
155
|
+
<TabItem value="Markdown">
|
|
156
|
+
|
|
157
|
+
```md
|
|
158
|
+
# tenant people profilecardproperty add --name 'customAttribute1' --displayName 'Cost center' --displayName-nl-NL 'Kostenplaats'
|
|
159
|
+
|
|
160
|
+
Date: 11/2/2023
|
|
161
|
+
|
|
162
|
+
Property | Value
|
|
163
|
+
---------|-------
|
|
164
|
+
directoryPropertyName | customAttribute1
|
|
165
|
+
displayName | Cost center
|
|
166
|
+
displayName nl-NL | Kostenplaats
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
</TabItem>
|
|
170
|
+
</Tabs>
|
|
171
|
+
|
|
172
|
+
## More information
|
|
173
|
+
|
|
174
|
+
- https://learn.microsoft.com/graph/add-properties-profilecard
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# tenant people profilecardproperty get
|
|
6
|
+
|
|
7
|
+
Retrieves information about a specific profile card property
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 tenant people profilecardproperty get [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
```md definition-list
|
|
18
|
+
`-n, --name <name>`
|
|
19
|
+
: The name of the property to retrieve. Allowed values: `UserPrincipalName`, `Fax`, `StreetAddress`, `PostalCode`, `StateOrProvince`, `Alias`, `customAttribute1`, `customAttribute2`, `customAttribute3`, `customAttribute4`, `customAttribute5`, `customAttribute6`, `customAttribute7`, `customAttribute8`, `customAttribute9`, `customAttribute10`, `customAttribute11`, `customAttribute12`, `customAttribute13`, `customAttribute14`, `customAttribute15`.
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
<Global />
|
|
23
|
+
|
|
24
|
+
## Remarks
|
|
25
|
+
|
|
26
|
+
:::info
|
|
27
|
+
|
|
28
|
+
To use this command you must be either **Tenant Administrator** or **Global Administrator**.
|
|
29
|
+
|
|
30
|
+
:::
|
|
31
|
+
|
|
32
|
+
## Examples
|
|
33
|
+
|
|
34
|
+
Retrieve information about a specific profile card property
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
m365 tenant people profilecardproperty get --name customAttribute1
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Response
|
|
41
|
+
|
|
42
|
+
<Tabs>
|
|
43
|
+
<TabItem value="JSON">
|
|
44
|
+
|
|
45
|
+
```json
|
|
46
|
+
{
|
|
47
|
+
"directoryPropertyName": "customAttribute1",
|
|
48
|
+
"annotations": [
|
|
49
|
+
{
|
|
50
|
+
"displayName": "Cost center",
|
|
51
|
+
"localizations": [
|
|
52
|
+
{
|
|
53
|
+
"languageTag": "nl-NL",
|
|
54
|
+
"displayName": "Kostencentrum"
|
|
55
|
+
}
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
]
|
|
59
|
+
}
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
</TabItem>
|
|
63
|
+
<TabItem value="Text">
|
|
64
|
+
|
|
65
|
+
```text
|
|
66
|
+
directoryPropertyName: customAttribute1
|
|
67
|
+
displayName : Cost center
|
|
68
|
+
displayName nl-NL : Kostencentrum
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
</TabItem>
|
|
72
|
+
<TabItem value="CSV">
|
|
73
|
+
|
|
74
|
+
```csv
|
|
75
|
+
directoryPropertyName,displayName,displayName nl-NL
|
|
76
|
+
customAttribute1,Cost center,Kostencentrum
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
</TabItem>
|
|
80
|
+
<TabItem value="Markdown">
|
|
81
|
+
|
|
82
|
+
```md
|
|
83
|
+
# tenant people profilecardproperty get --name "customAttribute1"
|
|
84
|
+
|
|
85
|
+
Date: 3/11/2023
|
|
86
|
+
|
|
87
|
+
## Cost center
|
|
88
|
+
|
|
89
|
+
Property | Value
|
|
90
|
+
---------|-------
|
|
91
|
+
directoryPropertyName | customAttribute1
|
|
92
|
+
displayName | Cost center
|
|
93
|
+
displayName nl-NL | Kostencentrum
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
</TabItem>
|
|
97
|
+
</Tabs>
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# tenant people profilecardproperty list
|
|
6
|
+
|
|
7
|
+
Lists all profile card properties
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 tenant people profilecardproperty list [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
<Global />
|
|
18
|
+
|
|
19
|
+
## Remarks
|
|
20
|
+
|
|
21
|
+
:::info
|
|
22
|
+
|
|
23
|
+
To use this command you must be either **Tenant Administrator** or **Global Administrator**.
|
|
24
|
+
|
|
25
|
+
:::
|
|
26
|
+
|
|
27
|
+
## Examples
|
|
28
|
+
|
|
29
|
+
Lists all profile card properties
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
m365 tenant people profilecardproperty list
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## Response
|
|
36
|
+
|
|
37
|
+
<Tabs>
|
|
38
|
+
<TabItem value="JSON">
|
|
39
|
+
|
|
40
|
+
```json
|
|
41
|
+
{
|
|
42
|
+
"value": [
|
|
43
|
+
{
|
|
44
|
+
"directoryPropertyName": "customAttribute1",
|
|
45
|
+
"annotations": [
|
|
46
|
+
{
|
|
47
|
+
"displayName": "Cost center",
|
|
48
|
+
"localizations": [
|
|
49
|
+
{
|
|
50
|
+
"languageTag": "de",
|
|
51
|
+
"displayName": "Kostenstelle"
|
|
52
|
+
}
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
]
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"directoryPropertyName": "Alias",
|
|
59
|
+
"annotations": []
|
|
60
|
+
}
|
|
61
|
+
]
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
</TabItem>
|
|
66
|
+
<TabItem value="Text">
|
|
67
|
+
|
|
68
|
+
```text
|
|
69
|
+
directoryPropertyName displayName displayName de
|
|
70
|
+
--------------------- -------------- --------------
|
|
71
|
+
customAttribute1 Cost center Kostenstelle
|
|
72
|
+
Alias
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
</TabItem>
|
|
76
|
+
<TabItem value="CSV">
|
|
77
|
+
|
|
78
|
+
```csv
|
|
79
|
+
directoryPropertyName,displayName,displayName de
|
|
80
|
+
customAttribute1,Cost center,Kostenstelle
|
|
81
|
+
Alias,,
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
</TabItem>
|
|
85
|
+
<TabItem value="Markdown">
|
|
86
|
+
|
|
87
|
+
```md
|
|
88
|
+
# tenant people profilecardproperty list
|
|
89
|
+
|
|
90
|
+
Date: 11/4/2023
|
|
91
|
+
|
|
92
|
+
## Cost center
|
|
93
|
+
|
|
94
|
+
Property | Value
|
|
95
|
+
---------|-------
|
|
96
|
+
directoryPropertyName | customAttribute1
|
|
97
|
+
displayName | Cost center
|
|
98
|
+
displayName de | Kostenstelle
|
|
99
|
+
|
|
100
|
+
Property | Value
|
|
101
|
+
---------|-------
|
|
102
|
+
directoryPropertyName | Alias
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
</TabItem>
|
|
106
|
+
</Tabs>
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import Global from '/docs/cmd/_global.mdx';
|
|
2
|
+
import Tabs from '@theme/Tabs';
|
|
3
|
+
import TabItem from '@theme/TabItem';
|
|
4
|
+
|
|
5
|
+
# tenant people profilecardproperty remove
|
|
6
|
+
|
|
7
|
+
Removes an additional attribute from the profile card properties
|
|
8
|
+
|
|
9
|
+
## Usage
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
m365 tenant people profilecardproperty remove [options]
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Options
|
|
16
|
+
|
|
17
|
+
```md definition-list
|
|
18
|
+
`-n, --name <name>`
|
|
19
|
+
: The name of the property to remove. Allowed values: `UserPrincipalName`, `Fax`, `StreetAddress`, `PostalCode`, `StateOrProvince`, `Alias`, `customAttribute1`, `customAttribute2`, `customAttribute3`, `customAttribute4`, `customAttribute5`, `customAttribute6`, `customAttribute7`, `customAttribute8`, `customAttribute9`, `customAttribute10`, `customAttribute11`, `customAttribute12`, `customAttribute13`, `customAttribute14`, `customAttribute15`.
|
|
20
|
+
|
|
21
|
+
`-f, --force`
|
|
22
|
+
: Don't prompt for confirmation.
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
<Global />
|
|
26
|
+
|
|
27
|
+
## Remarks
|
|
28
|
+
|
|
29
|
+
:::info
|
|
30
|
+
|
|
31
|
+
To use this command you must be either **Tenant Administrator** or **Global Administrator**.
|
|
32
|
+
|
|
33
|
+
:::
|
|
34
|
+
|
|
35
|
+
:::caution
|
|
36
|
+
|
|
37
|
+
When removing an attribute from a profile card, it takes up to 24 hours for the change to be displayed.
|
|
38
|
+
|
|
39
|
+
:::
|
|
40
|
+
|
|
41
|
+
## Examples
|
|
42
|
+
|
|
43
|
+
Removes the UPN as a profile property from the profile cards
|
|
44
|
+
|
|
45
|
+
```sh
|
|
46
|
+
m365 tenant people profilecardproperty remove --name UserPrincipalName
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Removes the UPN as a profile property from the profile cards, without showing a confirmation prompt
|
|
50
|
+
|
|
51
|
+
```sh
|
|
52
|
+
m365 tenant people profilecardproperty remove --name UserPrincipalName --force
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## Response
|
|
56
|
+
|
|
57
|
+
The command won't return a response on success.
|
|
58
|
+
|
|
59
|
+
## More information
|
|
60
|
+
|
|
61
|
+
- https://learn.microsoft.com/graph/add-properties-profilecard
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pnp/cli-microsoft365",
|
|
3
|
-
"version": "7.2.0-beta.
|
|
3
|
+
"version": "7.2.0-beta.2970c86",
|
|
4
4
|
"description": "Manage Microsoft 365 and SharePoint Framework projects on any platform",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"main": "./dist/api.js",
|
|
@@ -173,6 +173,7 @@
|
|
|
173
173
|
"Lengelle, Veronique <25181757+veronicageek@users.noreply.github.com>",
|
|
174
174
|
"Levert, Sebastien <slevert@outlook.com>",
|
|
175
175
|
"Lingstuyl, Martin <mlingstuyl@live.com>",
|
|
176
|
+
"Macháček, Martin <machacek@edhouse.cz>",
|
|
176
177
|
"Maillot, Michaël <battosaimykle@gmail.com>",
|
|
177
178
|
"Mastykarz, Waldek <waldek@mastykarz.nl>",
|
|
178
179
|
"McDonnell, Kevin <kevin@mcd79.com>",
|