@pnp/cli-microsoft365 5.0.0 → 5.1.0-beta.04832fc
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/dist/cli/Cli.js +21 -6
- package/dist/cli/index.js +5 -1
- package/dist/m365/aad/commands/app/app-add.js +11 -11
- package/dist/m365/aad/commands/app/app-delete.js +3 -3
- package/dist/m365/aad/commands/app/app-get.js +3 -3
- package/dist/m365/aad/commands/app/app-role-delete.js +2 -2
- package/dist/m365/aad/commands/app/app-role-list.js +6 -5
- package/dist/m365/aad/commands/approleassignment/approleassignment-add.js +4 -4
- package/dist/m365/aad/commands/approleassignment/approleassignment-list.js +3 -3
- package/dist/m365/aad/commands/approleassignment/approleassignment-remove.js +4 -4
- package/dist/m365/aad/commands/group/group-list.js +8 -7
- package/dist/m365/aad/commands/groupsetting/groupsetting-add.js +2 -2
- package/dist/m365/aad/commands/groupsetting/groupsetting-get.js +2 -2
- package/dist/m365/aad/commands/groupsetting/groupsetting-list.js +7 -6
- package/dist/m365/aad/commands/groupsetting/groupsetting-remove.js +2 -2
- package/dist/m365/aad/commands/groupsetting/groupsetting-set.js +2 -2
- package/dist/m365/aad/commands/groupsettingtemplate/groupsettingtemplate-get.js +8 -8
- package/dist/m365/aad/commands/groupsettingtemplate/groupsettingtemplate-list.js +7 -6
- package/dist/m365/aad/commands/o365group/o365group-add.js +41 -3
- package/dist/m365/aad/commands/o365group/o365group-conversation-list.js +8 -8
- package/dist/m365/aad/commands/o365group/o365group-conversation-post-list.js +87 -0
- package/dist/m365/aad/commands/o365group/o365group-get.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-list.js +15 -12
- package/dist/m365/aad/commands/o365group/o365group-recyclebinitem-clear.js +8 -7
- package/dist/m365/aad/commands/o365group/o365group-recyclebinitem-list.js +7 -6
- package/dist/m365/aad/commands/o365group/o365group-recyclebinitem-restore.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-remove.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-renew.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-set.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-teamify.js +2 -2
- package/dist/m365/aad/commands/o365group/o365group-user-add.js +3 -3
- package/dist/m365/aad/commands/o365group/o365group-user-list.js +21 -15
- package/dist/m365/aad/commands/o365group/o365group-user-remove.js +3 -3
- package/dist/m365/aad/commands/o365group/o365group-user-set.js +23 -17
- package/dist/m365/aad/commands/oauth2grant/oauth2grant-add.js +3 -3
- package/dist/m365/aad/commands/oauth2grant/oauth2grant-list.js +2 -2
- package/dist/m365/aad/commands/sp/sp-add.js +3 -3
- package/dist/m365/aad/commands/sp/sp-get.js +3 -3
- package/dist/m365/aad/commands/user/user-get.js +2 -2
- package/dist/m365/aad/commands/user/user-hibp.js +2 -2
- package/dist/m365/aad/commands/user/user-list.js +7 -6
- package/dist/m365/aad/commands/user/user-set.js +2 -2
- package/dist/m365/aad/commands.js +1 -0
- package/dist/m365/base/AppCommand.js +2 -2
- package/dist/m365/base/SpoCommand.js +0 -260
- package/dist/m365/cli/commands/cli-doctor.js +2 -2
- package/dist/m365/commands/status.js +3 -3
- package/dist/m365/file/commands/file-add.js +3 -3
- package/dist/m365/file/commands/file-list.js +14 -12
- package/dist/m365/flow/commands/flow-export.js +2 -2
- package/dist/m365/flow/commands/flow-remove.js +2 -2
- package/dist/m365/flow/commands/run/run-cancel.js +2 -2
- package/dist/m365/flow/commands/run/run-resubmit.js +2 -2
- package/dist/m365/graph/commands/schemaextension/schemaextension-add.js +2 -2
- package/dist/m365/graph/commands/schemaextension/schemaextension-list.js +2 -2
- package/dist/m365/graph/commands/schemaextension/schemaextension-set.js +2 -2
- package/dist/m365/graph/commands/subscription/subscription-add.js +2 -2
- package/dist/m365/onedrive/commands/onedrive-list.js +3 -2
- package/dist/m365/outlook/commands/message/message-list.js +6 -5
- package/dist/m365/outlook/commands/room/room-list.js +7 -6
- package/dist/m365/outlook/commands/roomlist/roomlist-list.js +7 -6
- package/dist/m365/pa/commands/app/app-get.js +2 -2
- package/dist/m365/pa/commands/app/app-remove.js +2 -2
- package/dist/m365/pa/commands/pcf/pcf-init.js +4 -4
- package/dist/m365/pa/commands/solution/solution-init.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-add.js +2 -2
- package/dist/m365/planner/commands/bucket/bucket-list.js +7 -7
- package/dist/m365/planner/commands/plan/plan-add.js +2 -2
- package/dist/m365/planner/commands/plan/plan-details-get.js +134 -0
- package/dist/m365/planner/commands/plan/plan-get.js +7 -7
- package/dist/m365/planner/commands/plan/plan-list.js +2 -2
- package/dist/m365/planner/commands/task/task-add.js +6 -6
- package/dist/m365/planner/commands/task/task-details-get.js +2 -2
- package/dist/m365/planner/commands/task/task-list.js +23 -23
- package/dist/m365/planner/commands/task/task-set.js +6 -6
- package/dist/m365/planner/commands.js +1 -0
- package/dist/m365/spfx/commands/package/package-generate.js +4 -4
- package/dist/m365/spfx/commands/project/base-project-command.js +18 -19
- package/dist/m365/spfx/commands/project/model/index.js +5 -1
- package/dist/m365/spfx/commands/project/project-externalize/index.js +5 -1
- package/dist/m365/spfx/commands/project/project-externalize/rules/index.js +5 -1
- package/dist/m365/spfx/commands/project/project-upgrade/index.js +5 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001005_DEP_types_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001006_DEP_types_react_dom.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001008_DEP_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001009_DEP_react_dom.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001015_DEP_types_react_addons_shallow_compare.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001016_DEP_types_react_addons_update.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001017_DEP_types_react_addons_update.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001019_DEP_knockout.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001020_DEP_types_knockout.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001022_DEP_office_ui_fabric_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001033_DEP_tslib.js +14 -0
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN002015_DEVDEP_types_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN002016_DEVDEP_types_react_dom.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN020001_RES_types_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN022001_SCSS_remove_fabric_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN022002_SCSS_add_fabric_react.js +2 -2
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN023002_GITIGNORE_heft.js +40 -0
- package/dist/m365/spfx/commands/project/project-upgrade/upgrade-1.15.0-beta.1.js +63 -0
- package/dist/m365/spfx/commands/project/project-upgrade.js +24 -19
- package/dist/m365/spo/commands/app/app-add.js +3 -2
- package/dist/m365/spo/commands/app/app-deploy.js +4 -4
- package/dist/m365/spo/commands/app/app-get.js +4 -4
- package/dist/m365/spo/commands/app/app-install.js +3 -3
- package/dist/m365/spo/commands/app/app-instance-list.js +2 -1
- package/dist/m365/spo/commands/app/app-list.js +3 -2
- package/dist/m365/spo/commands/app/app-remove.js +4 -5
- package/dist/m365/spo/commands/app/app-retract.js +4 -5
- package/dist/m365/spo/commands/app/app-uninstall.js +3 -3
- package/dist/m365/spo/commands/app/app-upgrade.js +3 -3
- package/dist/m365/spo/commands/apppage/apppage-add.js +2 -2
- package/dist/m365/spo/commands/apppage/apppage-set.js +2 -2
- package/dist/m365/spo/commands/cdn/cdn-get.js +4 -3
- package/dist/m365/spo/commands/cdn/cdn-origin-add.js +5 -5
- package/dist/m365/spo/commands/cdn/cdn-origin-list.js +4 -3
- package/dist/m365/spo/commands/cdn/cdn-origin-remove.js +5 -5
- package/dist/m365/spo/commands/cdn/cdn-policy-list.js +4 -3
- package/dist/m365/spo/commands/cdn/cdn-policy-set.js +5 -5
- package/dist/m365/spo/commands/cdn/cdn-set.js +3 -2
- package/dist/m365/spo/commands/contenttype/contenttype-add.js +6 -6
- package/dist/m365/spo/commands/contenttype/contenttype-field-remove.js +6 -6
- package/dist/m365/spo/commands/contenttype/contenttype-field-set.js +6 -6
- package/dist/m365/spo/commands/contenttype/contenttype-get.js +2 -1
- package/dist/m365/spo/commands/contenttype/contenttype-list.js +2 -1
- package/dist/m365/spo/commands/contenttype/contenttype-remove.js +2 -1
- package/dist/m365/spo/commands/contenttypehub/contenttypehub-get.js +3 -2
- package/dist/m365/spo/commands/customaction/customaction-add.js +3 -3
- package/dist/m365/spo/commands/customaction/customaction-clear.js +2 -1
- package/dist/m365/spo/commands/customaction/customaction-get.js +3 -3
- package/dist/m365/spo/commands/customaction/customaction-list.js +2 -1
- package/dist/m365/spo/commands/customaction/customaction-remove.js +3 -3
- package/dist/m365/spo/commands/customaction/customaction-set.js +4 -4
- package/dist/m365/spo/commands/externaluser/externaluser-list.js +6 -6
- package/dist/m365/spo/commands/feature/feature-enable.js +2 -1
- package/dist/m365/spo/commands/feature/feature-list.js +2 -1
- package/dist/m365/spo/commands/field/field-add.js +3 -2
- package/dist/m365/spo/commands/field/field-get.js +5 -5
- package/dist/m365/spo/commands/field/field-remove.js +5 -5
- package/dist/m365/spo/commands/field/field-set.js +10 -10
- package/dist/m365/spo/commands/file/file-add.js +5 -7
- package/dist/m365/spo/commands/file/file-checkin.js +3 -3
- package/dist/m365/spo/commands/file/file-checkout.js +3 -3
- package/dist/m365/spo/commands/file/file-copy.js +18 -7
- package/dist/m365/spo/commands/file/file-get.js +3 -3
- package/dist/m365/spo/commands/file/file-list.js +3 -3
- package/dist/m365/spo/commands/file/file-move.js +18 -7
- package/dist/m365/spo/commands/file/file-remove.js +3 -3
- package/dist/m365/spo/commands/file/file-sharinginfo-get.js +3 -3
- package/dist/m365/spo/commands/folder/folder-add.js +3 -3
- package/dist/m365/spo/commands/folder/folder-copy.js +16 -5
- package/dist/m365/spo/commands/folder/folder-get.js +3 -3
- package/dist/m365/spo/commands/folder/folder-list.js +3 -3
- package/dist/m365/spo/commands/folder/folder-move.js +16 -5
- package/dist/m365/spo/commands/folder/folder-remove.js +3 -3
- package/dist/m365/spo/commands/folder/folder-rename.js +6 -8
- package/dist/m365/spo/commands/group/group-get.js +2 -1
- package/dist/m365/spo/commands/group/group-list.js +2 -1
- package/dist/m365/spo/commands/group/group-remove.js +2 -1
- package/dist/m365/spo/commands/group/group-user-add.js +2 -1
- package/dist/m365/spo/commands/group/group-user-list.js +2 -1
- package/dist/m365/spo/commands/group/group-user-remove.js +2 -1
- package/dist/m365/spo/commands/hidedefaultthemes/hidedefaultthemes-get.js +2 -1
- package/dist/m365/spo/commands/hidedefaultthemes/hidedefaultthemes-set.js +2 -1
- package/dist/m365/spo/commands/homesite/homesite-get.js +2 -1
- package/dist/m365/spo/commands/homesite/homesite-remove.js +3 -2
- package/dist/m365/spo/commands/homesite/homesite-set.js +5 -5
- package/dist/m365/spo/commands/hubsite/hubsite-connect.js +4 -4
- package/dist/m365/spo/commands/hubsite/hubsite-data-get.js +2 -1
- package/dist/m365/spo/commands/hubsite/hubsite-disconnect.js +3 -2
- package/dist/m365/spo/commands/hubsite/hubsite-get.js +3 -3
- package/dist/m365/spo/commands/hubsite/hubsite-list.js +2 -1
- package/dist/m365/spo/commands/hubsite/hubsite-register.js +3 -2
- package/dist/m365/spo/commands/hubsite/hubsite-rights-grant.js +6 -6
- package/dist/m365/spo/commands/hubsite/hubsite-rights-revoke.js +6 -6
- package/dist/m365/spo/commands/hubsite/hubsite-set.js +8 -8
- package/dist/m365/spo/commands/hubsite/hubsite-theme-sync.js +2 -1
- package/dist/m365/spo/commands/hubsite/hubsite-unregister.js +3 -2
- package/dist/m365/spo/commands/knowledgehub/knowledgehub-get.js +3 -2
- package/dist/m365/spo/commands/knowledgehub/knowledgehub-remove.js +3 -2
- package/dist/m365/spo/commands/knowledgehub/knowledgehub-set.js +5 -5
- package/dist/m365/spo/commands/list/list-add.js +5 -5
- package/dist/m365/spo/commands/list/list-contenttype-add.js +3 -3
- package/dist/m365/spo/commands/list/list-contenttype-default-set.js +3 -3
- package/dist/m365/spo/commands/list/list-contenttype-list.js +3 -3
- package/dist/m365/spo/commands/list/list-contenttype-remove.js +3 -3
- package/dist/m365/spo/commands/list/list-get.js +3 -3
- package/dist/m365/spo/commands/list/list-label-get.js +4 -4
- package/dist/m365/spo/commands/list/list-label-set.js +5 -5
- package/dist/m365/spo/commands/list/list-list.js +2 -1
- package/dist/m365/spo/commands/list/list-remove.js +3 -3
- package/dist/m365/spo/commands/list/list-set.js +6 -6
- package/dist/m365/spo/commands/list/list-sitescript-get.js +4 -4
- package/dist/m365/spo/commands/list/list-view-field-add.js +5 -5
- package/dist/m365/spo/commands/list/list-view-field-remove.js +5 -5
- package/dist/m365/spo/commands/list/list-view-field-set.js +5 -5
- package/dist/m365/spo/commands/list/list-view-get.js +5 -5
- package/dist/m365/spo/commands/list/list-view-list.js +3 -3
- package/dist/m365/spo/commands/list/list-view-remove.js +4 -4
- package/dist/m365/spo/commands/list/list-view-set.js +5 -5
- package/dist/m365/spo/commands/list/list-webhook-add.js +3 -3
- package/dist/m365/spo/commands/list/list-webhook-get.js +4 -4
- package/dist/m365/spo/commands/list/list-webhook-list.js +4 -4
- package/dist/m365/spo/commands/list/list-webhook-remove.js +4 -4
- package/dist/m365/spo/commands/list/list-webhook-set.js +4 -4
- package/dist/m365/spo/commands/listitem/listitem-add.js +5 -7
- package/dist/m365/spo/commands/listitem/listitem-attachment-list.js +3 -3
- package/dist/m365/spo/commands/listitem/listitem-get.js +3 -3
- package/dist/m365/spo/commands/listitem/listitem-isrecord.js +5 -7
- package/dist/m365/spo/commands/listitem/listitem-list.js +4 -4
- package/dist/m365/spo/commands/listitem/listitem-record-declare.js +6 -8
- package/dist/m365/spo/commands/listitem/listitem-record-undeclare.js +5 -7
- package/dist/m365/spo/commands/listitem/listitem-remove.js +3 -3
- package/dist/m365/spo/commands/listitem/listitem-set.js +4 -4
- package/dist/m365/spo/commands/mail/mail-send.js +2 -1
- package/dist/m365/spo/commands/navigation/navigation-node-add.js +2 -1
- package/dist/m365/spo/commands/navigation/navigation-node-list.js +2 -1
- package/dist/m365/spo/commands/navigation/navigation-node-remove.js +3 -2
- package/dist/m365/spo/commands/orgassetslibrary/orgassetslibrary-add.js +5 -4
- package/dist/m365/spo/commands/orgassetslibrary/orgassetslibrary-list.js +3 -2
- package/dist/m365/spo/commands/orgassetslibrary/orgassetslibrary-remove.js +3 -2
- package/dist/m365/spo/commands/orgnewssite/orgnewssite-list.js +3 -2
- package/dist/m365/spo/commands/orgnewssite/orgnewssite-remove.js +5 -5
- package/dist/m365/spo/commands/orgnewssite/orgnewssite-set.js +5 -5
- package/dist/m365/spo/commands/page/Page.js +2 -2
- package/dist/m365/spo/commands/page/page-add.js +4 -4
- package/dist/m365/spo/commands/page/page-clientsidewebpart-add.js +3 -3
- package/dist/m365/spo/commands/page/page-column-get.js +2 -1
- package/dist/m365/spo/commands/page/page-column-list.js +2 -1
- package/dist/m365/spo/commands/page/page-control-get.js +3 -3
- package/dist/m365/spo/commands/page/page-control-list.js +2 -1
- package/dist/m365/spo/commands/page/page-control-set.js +3 -3
- package/dist/m365/spo/commands/page/page-copy.js +2 -1
- package/dist/m365/spo/commands/page/page-get.js +3 -3
- package/dist/m365/spo/commands/page/page-header-set.js +2 -1
- package/dist/m365/spo/commands/page/page-list.js +2 -1
- package/dist/m365/spo/commands/page/page-remove.js +4 -4
- package/dist/m365/spo/commands/page/page-section-add.js +2 -1
- package/dist/m365/spo/commands/page/page-section-get.js +2 -1
- package/dist/m365/spo/commands/page/page-section-list.js +2 -1
- package/dist/m365/spo/commands/page/page-set.js +4 -4
- package/dist/m365/spo/commands/page/page-template-list.js +2 -1
- package/dist/m365/spo/commands/page/page-text-add.js +4 -4
- package/dist/m365/spo/commands/propertybag/propertybag-base.js +4 -4
- package/dist/m365/spo/commands/propertybag/propertybag-get.js +4 -6
- package/dist/m365/spo/commands/propertybag/propertybag-list.js +4 -6
- package/dist/m365/spo/commands/propertybag/propertybag-remove.js +6 -9
- package/dist/m365/spo/commands/propertybag/propertybag-set.js +8 -10
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-grant-add.js +4 -4
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-grant-list.js +3 -2
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-grant-revoke.js +4 -4
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-permissionrequest-approve.js +5 -5
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-permissionrequest-deny.js +5 -5
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-permissionrequest-list.js +3 -2
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-set.js +3 -2
- package/dist/m365/spo/commands/site/site-add.js +36 -16
- package/dist/m365/spo/commands/site/site-appcatalog-add.js +5 -5
- package/dist/m365/spo/commands/site/site-appcatalog-remove.js +5 -5
- package/dist/m365/spo/commands/site/site-apppermission-add.js +3 -4
- package/dist/m365/spo/commands/site/site-apppermission-get.js +2 -2
- package/dist/m365/spo/commands/site/site-apppermission-list.js +2 -2
- package/dist/m365/spo/commands/site/site-apppermission-remove.js +3 -4
- package/dist/m365/spo/commands/site/site-apppermission-set.js +3 -4
- package/dist/m365/spo/commands/site/site-chrome-set.js +2 -1
- package/dist/m365/spo/commands/site/site-classic-add.js +33 -13
- package/dist/m365/spo/commands/site/site-classic-list.js +4 -4
- package/dist/m365/spo/commands/site/site-classic-set.js +33 -13
- package/dist/m365/spo/commands/site/site-commsite-enable.js +6 -6
- package/dist/m365/spo/commands/site/site-ensure.js +2 -1
- package/dist/m365/spo/commands/site/site-get.js +2 -1
- package/dist/m365/spo/commands/site/site-groupify.js +2 -1
- package/dist/m365/spo/commands/site/site-inplacerecordsmanagement-set.js +3 -3
- package/dist/m365/spo/commands/site/site-list.js +4 -4
- package/dist/m365/spo/commands/site/site-recyclebinitem-list.js +2 -1
- package/dist/m365/spo/commands/site/site-recyclebinitem-restore.js +66 -0
- package/dist/m365/spo/commands/site/site-remove.js +34 -14
- package/dist/m365/spo/commands/site/site-rename.js +3 -2
- package/dist/m365/spo/commands/site/site-set.js +12 -12
- package/dist/m365/spo/commands/sitedesign/sitedesign-add.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-apply.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-get.js +3 -3
- package/dist/m365/spo/commands/sitedesign/sitedesign-list.js +2 -1
- package/dist/m365/spo/commands/sitedesign/sitedesign-remove.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-rights-grant.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-rights-list.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-rights-revoke.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-run-list.js +3 -3
- package/dist/m365/spo/commands/sitedesign/sitedesign-run-status-get.js +3 -3
- package/dist/m365/spo/commands/sitedesign/sitedesign-set.js +4 -4
- package/dist/m365/spo/commands/sitedesign/sitedesign-task-get.js +3 -3
- package/dist/m365/spo/commands/sitedesign/sitedesign-task-list.js +2 -1
- package/dist/m365/spo/commands/sitedesign/sitedesign-task-remove.js +3 -3
- package/dist/m365/spo/commands/sitescript/sitescript-add.js +3 -2
- package/dist/m365/spo/commands/sitescript/sitescript-get.js +4 -4
- package/dist/m365/spo/commands/sitescript/sitescript-list.js +3 -2
- package/dist/m365/spo/commands/sitescript/sitescript-remove.js +4 -4
- package/dist/m365/spo/commands/sitescript/sitescript-set.js +4 -4
- package/dist/m365/spo/commands/spo-search.js +4 -4
- package/dist/m365/spo/commands/spo-set.js +2 -1
- package/dist/m365/spo/commands/storageentity/storageentity-get.js +2 -1
- package/dist/m365/spo/commands/storageentity/storageentity-list.js +2 -1
- package/dist/m365/spo/commands/storageentity/storageentity-remove.js +5 -5
- package/dist/m365/spo/commands/storageentity/storageentity-set.js +5 -5
- package/dist/m365/spo/commands/tenant/tenant-appcatalog-add.js +2 -1
- package/dist/m365/spo/commands/tenant/tenant-appcatalogurl-get.js +2 -1
- package/dist/m365/spo/commands/tenant/tenant-recyclebinitem-list.js +3 -2
- package/dist/m365/spo/commands/tenant/tenant-recyclebinitem-remove.js +16 -6
- package/dist/m365/spo/commands/tenant/tenant-recyclebinitem-restore.js +16 -6
- package/dist/m365/spo/commands/tenant/tenant-settings-list.js +3 -2
- package/dist/m365/spo/commands/tenant/tenant-settings-set.js +5 -5
- package/dist/m365/spo/commands/term/term-add.js +13 -13
- package/dist/m365/spo/commands/term/term-get.js +9 -9
- package/dist/m365/spo/commands/term/term-group-add.js +6 -6
- package/dist/m365/spo/commands/term/term-group-get.js +5 -5
- package/dist/m365/spo/commands/term/term-group-list.js +3 -2
- package/dist/m365/spo/commands/term/term-list.js +7 -7
- package/dist/m365/spo/commands/term/term-set-add.js +9 -9
- package/dist/m365/spo/commands/term/term-set-get.js +7 -7
- package/dist/m365/spo/commands/term/term-set-list.js +5 -5
- package/dist/m365/spo/commands/theme/theme-apply.js +5 -5
- package/dist/m365/spo/commands/theme/theme-get.js +4 -4
- package/dist/m365/spo/commands/theme/theme-list.js +2 -1
- package/dist/m365/spo/commands/theme/theme-remove.js +2 -1
- package/dist/m365/spo/commands/theme/theme-set.js +5 -5
- package/dist/m365/spo/commands/user/user-get.js +2 -1
- package/dist/m365/spo/commands/user/user-list.js +2 -1
- package/dist/m365/spo/commands/user/user-remove.js +2 -1
- package/dist/m365/spo/commands/userprofile/userprofile-get.js +3 -3
- package/dist/m365/spo/commands/userprofile/userprofile-set.js +3 -2
- package/dist/m365/spo/commands/web/web-add.js +4 -3
- package/dist/m365/spo/commands/web/web-clientsidewebpart-list.js +2 -1
- package/dist/m365/spo/commands/web/web-get.js +2 -1
- package/dist/m365/spo/commands/web/web-installedlanguage-list.js +2 -1
- package/dist/m365/spo/commands/web/web-list.js +2 -1
- package/dist/m365/spo/commands/web/web-reindex.js +10 -11
- package/dist/m365/spo/commands/web/web-remove.js +2 -1
- package/dist/m365/spo/commands/web/web-set.js +2 -1
- package/dist/m365/spo/commands.js +1 -0
- package/dist/m365/teams/commands/app/app-install.js +4 -4
- package/dist/m365/teams/commands/app/app-list.js +8 -8
- package/dist/m365/teams/commands/app/app-remove.js +2 -2
- package/dist/m365/teams/commands/app/app-uninstall.js +2 -2
- package/dist/m365/teams/commands/app/app-update.js +2 -2
- package/dist/m365/teams/commands/channel/channel-add.js +2 -2
- package/dist/m365/teams/commands/channel/channel-get.js +3 -3
- package/dist/m365/teams/commands/channel/channel-list.js +7 -8
- package/dist/m365/teams/commands/channel/channel-remove.js +3 -3
- package/dist/m365/teams/commands/channel/channel-set.js +2 -2
- package/dist/m365/teams/commands/chat/chat-list.js +7 -6
- package/dist/m365/teams/commands/chat/chat-member-list.js +8 -8
- package/dist/m365/teams/commands/chat/chat-message-list.js +9 -9
- package/dist/m365/teams/commands/chat/chat-message-send.js +54 -62
- package/dist/m365/teams/commands/conversationmember/conversationmember-add.js +3 -3
- package/dist/m365/teams/commands/conversationmember/conversationmember-list.js +9 -9
- package/dist/m365/teams/commands/funsettings/funsettings-list.js +2 -2
- package/dist/m365/teams/commands/funsettings/funsettings-set.js +2 -2
- package/dist/m365/teams/commands/guestsettings/guestsettings-list.js +2 -2
- package/dist/m365/teams/commands/guestsettings/guestsettings-set.js +2 -2
- package/dist/m365/teams/commands/membersettings/membersettings-list.js +2 -2
- package/dist/m365/teams/commands/membersettings/membersettings-set.js +2 -2
- package/dist/m365/teams/commands/message/message-get.js +3 -3
- package/dist/m365/teams/commands/message/message-list.js +12 -12
- package/dist/m365/teams/commands/message/message-reply-list.js +10 -10
- package/dist/m365/teams/commands/messagingsettings/messagingsettings-list.js +2 -2
- package/dist/m365/teams/commands/messagingsettings/messagingsettings-set.js +3 -3
- package/dist/m365/teams/commands/report/report-directroutingcalls.js +3 -3
- package/dist/m365/teams/commands/report/report-pstncalls.js +3 -3
- package/dist/m365/teams/commands/tab/tab-add.js +5 -5
- package/dist/m365/teams/commands/tab/tab-get.js +4 -4
- package/dist/m365/teams/commands/tab/tab-list.js +10 -10
- package/dist/m365/teams/commands/tab/tab-remove.js +4 -4
- package/dist/m365/teams/commands/team/team-archive.js +2 -2
- package/dist/m365/teams/commands/team/team-clone.js +2 -2
- package/dist/m365/teams/commands/team/team-get.js +2 -2
- package/dist/m365/teams/commands/team/team-list.js +10 -12
- package/dist/m365/teams/commands/team/team-remove.js +2 -2
- package/dist/m365/teams/commands/team/team-set.js +2 -2
- package/dist/m365/teams/commands/team/team-unarchive.js +2 -2
- package/dist/m365/teams/commands/user/user-app-add.js +3 -3
- package/dist/m365/teams/commands/user/user-app-list.js +10 -10
- package/dist/m365/teams/commands/user/user-app-remove.js +2 -2
- package/dist/m365/teams/commands/user/user-list.js +14 -8
- package/dist/m365/tenant/commands/auditlog/auditlog-report.js +2 -2
- package/dist/m365/tenant/commands/id/id-get.js +2 -2
- package/dist/m365/tenant/commands/report/report-office365activationcounts.js +2 -2
- package/dist/m365/tenant/commands/report/report-office365activationsusercounts.js +2 -2
- package/dist/m365/tenant/commands/report/report-office365activationsuserdetail.js +2 -2
- package/dist/m365/tenant/commands/service/service-list.js +2 -2
- package/dist/m365/tenant/commands/service/service-message-list.js +2 -2
- package/dist/m365/tenant/commands/service/service-report-historicalservicestatus.js +2 -2
- package/dist/m365/tenant/commands/serviceannouncement/serviceannouncement-healthissue-list.js +7 -6
- package/dist/m365/tenant/commands/serviceannouncement/serviceannouncement-message-list.js +7 -6
- package/dist/m365/tenant/commands/status/status-list.js +2 -2
- package/dist/m365/todo/commands/list/list-list.js +7 -6
- package/dist/m365/todo/commands/task/task-list.js +7 -6
- package/dist/request.js +4 -4
- package/dist/settingsNames.js +1 -0
- package/dist/utils/accessToken.js +44 -0
- package/dist/utils/formatting.js +69 -0
- package/dist/utils/fsUtil.js +36 -0
- package/dist/utils/index.js +26 -0
- package/dist/utils/odata.js +37 -0
- package/dist/utils/sinonUtil.js +19 -0
- package/dist/{m365/spfx/commands/project/project-upgrade/Utils.js → utils/spfx.js} +7 -19
- package/dist/utils/spo.js +432 -0
- package/dist/utils/urlUtil.js +174 -0
- package/dist/utils/validation.js +310 -0
- package/docs/docs/cmd/aad/o365group/o365group-add.md +42 -6
- package/docs/docs/cmd/aad/o365group/o365group-conversation-post-list.md +36 -0
- package/docs/docs/cmd/planner/plan/plan-details-get.md +45 -0
- package/docs/docs/cmd/spfx/project/project-upgrade.md +1 -1
- package/docs/docs/cmd/spo/site/site-recyclebinitem-restore.md +27 -0
- package/docs/docs/cmd/teams/chat/chat-message-send.md +4 -4
- package/npm-shrinkwrap.json +175 -190
- package/package.json +11 -11
- package/dist/Utils.js +0 -575
- package/dist/m365/base/AzmgmtResponse.js +0 -3
- package/dist/m365/base/GraphItemsListCommand.js +0 -46
- package/dist/m365/base/GraphResponse.js +0 -3
- package/dist/m365/base/GraphResponseError.js +0 -3
- package/dist/m365/spo/ClientSvc.js +0 -128
- package/dist/m365/spo/FolderExtensions.js +0 -101
- package/dist/m365/spo/commands/site/SpoOperation.js +0 -3
- package/dist/m365/spo/spo.js +0 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class GraphSchemaExtensionAddCommand extends GraphCommand_1.default {
|
|
@@ -61,7 +61,7 @@ class GraphSchemaExtensionAddCommand extends GraphCommand_1.default {
|
|
|
61
61
|
return options.concat(parentOptions);
|
|
62
62
|
}
|
|
63
63
|
validate(args) {
|
|
64
|
-
if (args.options.owner && !
|
|
64
|
+
if (args.options.owner && !utils_1.validation.isValidGuid(args.options.owner)) {
|
|
65
65
|
return `The specified owner '${args.options.owner}' is not a valid App Id`;
|
|
66
66
|
}
|
|
67
67
|
return this.validateProperties(args.options.properties);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class GraphSchemaExtensionListCommand extends GraphCommand_1.default {
|
|
@@ -93,7 +93,7 @@ class GraphSchemaExtensionListCommand extends GraphCommand_1.default {
|
|
|
93
93
|
return options.concat(parentOptions);
|
|
94
94
|
}
|
|
95
95
|
validate(args) {
|
|
96
|
-
if (args.options.owner && !
|
|
96
|
+
if (args.options.owner && !utils_1.validation.isValidGuid(args.options.owner)) {
|
|
97
97
|
return `${args.options.owner} is not a valid GUID`;
|
|
98
98
|
}
|
|
99
99
|
if (args.options.pageNumber && parseInt(args.options.pageNumber) < 1) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class GraphSchemaExtensionSetCommand extends GraphCommand_1.default {
|
|
@@ -104,7 +104,7 @@ class GraphSchemaExtensionSetCommand extends GraphCommand_1.default {
|
|
|
104
104
|
return options.concat(parentOptions);
|
|
105
105
|
}
|
|
106
106
|
validate(args) {
|
|
107
|
-
if (!
|
|
107
|
+
if (!utils_1.validation.isValidGuid(args.options.owner)) {
|
|
108
108
|
return `The specified owner '${args.options.owner}' is not a valid App Id`;
|
|
109
109
|
}
|
|
110
110
|
if (!args.options.status && !args.options.properties && !args.options.targetTypes && !args.options.description) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
const DEFAULT_EXPIRATION_DELAY_IN_MINUTES_PER_RESOURCE_TYPE = {
|
|
@@ -136,7 +136,7 @@ class GraphSubscriptionAddCommand extends GraphCommand_1.default {
|
|
|
136
136
|
if (!this.isValidChangeTypes(args.options.changeType)) {
|
|
137
137
|
return `The specified changeType is invalid. Valid options are 'created', 'updated' and 'deleted'`;
|
|
138
138
|
}
|
|
139
|
-
if (args.options.expirationDateTime && !
|
|
139
|
+
if (args.options.expirationDateTime && !utils_1.validation.isValidISODateTime(args.options.expirationDateTime)) {
|
|
140
140
|
return 'The expirationDateTime is not a valid ISO date string';
|
|
141
141
|
}
|
|
142
142
|
if (args.options.clientState && args.options.clientState.length > 128) {
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const config_1 = require("../../../config");
|
|
4
4
|
const request_1 = require("../../../request");
|
|
5
|
+
const utils_1 = require("../../../utils");
|
|
5
6
|
const SpoCommand_1 = require("../../base/SpoCommand");
|
|
6
7
|
const commands_1 = require("../commands");
|
|
7
8
|
class OneDriveListCommand extends SpoCommand_1.default {
|
|
@@ -15,7 +16,7 @@ class OneDriveListCommand extends SpoCommand_1.default {
|
|
|
15
16
|
return ['Title', 'Url'];
|
|
16
17
|
}
|
|
17
18
|
commandAction(logger, args, cb) {
|
|
18
|
-
|
|
19
|
+
utils_1.spo
|
|
19
20
|
.getSpoAdminUrl(logger, this.debug)
|
|
20
21
|
.then((spoAdminUrl) => {
|
|
21
22
|
if (this.verbose) {
|
|
@@ -31,7 +32,7 @@ class OneDriveListCommand extends SpoCommand_1.default {
|
|
|
31
32
|
}
|
|
32
33
|
getAllSites(spoAdminUrl, startIndex, formDigest, logger) {
|
|
33
34
|
return new Promise((resolve, reject) => {
|
|
34
|
-
|
|
35
|
+
utils_1.spo
|
|
35
36
|
.ensureFormDigest(spoAdminUrl, logger, formDigest, this.debug)
|
|
36
37
|
.then((res) => {
|
|
37
38
|
const requestOptions = {
|
|
@@ -2,10 +2,11 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const os = require("os");
|
|
4
4
|
const request_1 = require("../../../../request");
|
|
5
|
-
const
|
|
5
|
+
const utils_1 = require("../../../../utils");
|
|
6
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
7
|
const commands_1 = require("../../commands");
|
|
7
8
|
const Outlook_1 = require("../../Outlook");
|
|
8
|
-
class OutlookMessageListCommand extends
|
|
9
|
+
class OutlookMessageListCommand extends GraphCommand_1.default {
|
|
9
10
|
get name() {
|
|
10
11
|
return commands_1.default.MESSAGE_LIST;
|
|
11
12
|
}
|
|
@@ -26,10 +27,10 @@ class OutlookMessageListCommand extends GraphItemsListCommand_1.GraphItemsListCo
|
|
|
26
27
|
.getFolderId(args)
|
|
27
28
|
.then((folderId) => {
|
|
28
29
|
const url = folderId ? `me/mailFolders/${folderId}/messages` : 'me/messages';
|
|
29
|
-
return
|
|
30
|
+
return utils_1.odata.getAllItems(`${this.resource}/v1.0/${url}?$top=50`, logger);
|
|
30
31
|
})
|
|
31
|
-
.then(() => {
|
|
32
|
-
logger.log(
|
|
32
|
+
.then((messages) => {
|
|
33
|
+
logger.log(messages);
|
|
33
34
|
cb();
|
|
34
35
|
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
35
36
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const utils_1 = require("../../../../utils");
|
|
4
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
4
5
|
const commands_1 = require("../../commands");
|
|
5
|
-
class OutlookRoomListCommand extends
|
|
6
|
+
class OutlookRoomListCommand extends GraphCommand_1.default {
|
|
6
7
|
get name() {
|
|
7
8
|
return commands_1.default.ROOM_LIST;
|
|
8
9
|
}
|
|
@@ -22,10 +23,10 @@ class OutlookRoomListCommand extends GraphItemsListCommand_1.GraphItemsListComma
|
|
|
22
23
|
if (args.options.roomlistEmail) {
|
|
23
24
|
endpoint = `${this.resource}/v1.0/places/${args.options.roomlistEmail}/microsoft.graph.roomlist/rooms`;
|
|
24
25
|
}
|
|
25
|
-
|
|
26
|
-
.getAllItems(endpoint, logger
|
|
27
|
-
.then(() => {
|
|
28
|
-
logger.log(
|
|
26
|
+
utils_1.odata
|
|
27
|
+
.getAllItems(endpoint, logger)
|
|
28
|
+
.then((rooms) => {
|
|
29
|
+
logger.log(rooms);
|
|
29
30
|
cb();
|
|
30
31
|
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
31
32
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
const
|
|
3
|
+
const utils_1 = require("../../../../utils");
|
|
4
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
4
5
|
const commands_1 = require("../../commands");
|
|
5
|
-
class OutlookRoomListListCommand extends
|
|
6
|
+
class OutlookRoomListListCommand extends GraphCommand_1.default {
|
|
6
7
|
get name() {
|
|
7
8
|
return commands_1.default.ROOMLIST_LIST;
|
|
8
9
|
}
|
|
@@ -13,10 +14,10 @@ class OutlookRoomListListCommand extends GraphItemsListCommand_1.GraphItemsListC
|
|
|
13
14
|
return ['id', 'displayName', 'phone', 'emailAddress'];
|
|
14
15
|
}
|
|
15
16
|
commandAction(logger, args, cb) {
|
|
16
|
-
|
|
17
|
-
.getAllItems(`${this.resource}/v1.0/places/microsoft.graph.roomlist`, logger
|
|
18
|
-
.then(() => {
|
|
19
|
-
logger.log(
|
|
17
|
+
utils_1.odata
|
|
18
|
+
.getAllItems(`${this.resource}/v1.0/places/microsoft.graph.roomlist`, logger)
|
|
19
|
+
.then((roomLists) => {
|
|
20
|
+
logger.log(roomLists);
|
|
20
21
|
cb();
|
|
21
22
|
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
22
23
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const cli_1 = require("../../../../cli");
|
|
4
4
|
const request_1 = require("../../../../request");
|
|
5
|
-
const
|
|
5
|
+
const utils_1 = require("../../../../utils");
|
|
6
6
|
const AzmgmtCommand_1 = require("../../../base/AzmgmtCommand");
|
|
7
7
|
const commands_1 = require("../../commands");
|
|
8
8
|
const paAppListCommand = require("../app/app-list");
|
|
@@ -110,7 +110,7 @@ class PaAppGetCommand extends AzmgmtCommand_1.default {
|
|
|
110
110
|
if (args.options.name && args.options.displayName) {
|
|
111
111
|
return 'Specify either name or displayName but not both';
|
|
112
112
|
}
|
|
113
|
-
if (args.options.name && !
|
|
113
|
+
if (args.options.name && !utils_1.validation.isValidGuid(args.options.name)) {
|
|
114
114
|
return `${args.options.name} is not a valid GUID`;
|
|
115
115
|
}
|
|
116
116
|
return true;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const cli_1 = require("../../../../cli");
|
|
4
4
|
const request_1 = require("../../../../request");
|
|
5
|
-
const
|
|
5
|
+
const utils_1 = require("../../../../utils");
|
|
6
6
|
const AzmgmtCommand_1 = require("../../../base/AzmgmtCommand");
|
|
7
7
|
const commands_1 = require("../../commands");
|
|
8
8
|
class PaAppRemoveCommand extends AzmgmtCommand_1.default {
|
|
@@ -73,7 +73,7 @@ class PaAppRemoveCommand extends AzmgmtCommand_1.default {
|
|
|
73
73
|
return options.concat(parentOptions);
|
|
74
74
|
}
|
|
75
75
|
validate(args) {
|
|
76
|
-
if (!
|
|
76
|
+
if (!utils_1.validation.isValidGuid(args.options.name)) {
|
|
77
77
|
return `${args.options.name} is not a valid GUID`;
|
|
78
78
|
}
|
|
79
79
|
return true;
|
|
@@ -5,7 +5,7 @@ const fs = require("fs");
|
|
|
5
5
|
const path = require("path");
|
|
6
6
|
const uuid_1 = require("uuid");
|
|
7
7
|
const Command_1 = require("../../../../Command");
|
|
8
|
-
const
|
|
8
|
+
const utils_1 = require("../../../../utils");
|
|
9
9
|
const AnonymousCommand_1 = require("../../../base/AnonymousCommand");
|
|
10
10
|
const commands_1 = require("../../commands");
|
|
11
11
|
const template_instantiator_1 = require("../../template-instantiator");
|
|
@@ -84,14 +84,14 @@ class PaPcfInitCommand extends AnonymousCommand_1.default {
|
|
|
84
84
|
return 'PowerApps component framework project creation failed. The current directory already contains a project. Please create a new directory and retry the operation.';
|
|
85
85
|
}
|
|
86
86
|
const workingDirectoryName = path.basename(process.cwd());
|
|
87
|
-
if (!
|
|
87
|
+
if (!utils_1.validation.isValidFileName(workingDirectoryName)) {
|
|
88
88
|
return `Empty or invalid project name '${workingDirectoryName}'`;
|
|
89
89
|
}
|
|
90
90
|
if (args.options.name) {
|
|
91
91
|
if (!/^(?!\d)[a-zA-Z0-9]+$/i.test(args.options.name)) {
|
|
92
92
|
return `Value of 'name' is invalid. Only characters within the ranges [A - Z], [a - z] or [0 - 9] are allowed. The first character may not be a number.`;
|
|
93
93
|
}
|
|
94
|
-
if (
|
|
94
|
+
if (utils_1.validation.isJavaScriptReservedWord(args.options.name)) {
|
|
95
95
|
return `The value '${args.options.name}' passed for 'name' is a reserved word.`;
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -102,7 +102,7 @@ class PaPcfInitCommand extends AnonymousCommand_1.default {
|
|
|
102
102
|
if (!/^(?!\.|\d)(?!.*\.$)(?!.*?\.\d)(?!.*?\.\.)[a-zA-Z0-9.]+$/i.test(args.options.namespace)) {
|
|
103
103
|
return `Value of 'namespace' is invalid. Only characters within the ranges [A - Z], [a - z], [0 - 9], or '.' are allowed. The first and last character may not be the '.' character. Consecutive '.' characters are not allowed. Numbers are not allowed as the first character or immediately after a period.`;
|
|
104
104
|
}
|
|
105
|
-
if (
|
|
105
|
+
if (utils_1.validation.isJavaScriptReservedWord(args.options.namespace)) {
|
|
106
106
|
return `The value '${args.options.namespace}' passed for 'namespace' is or includes a reserved word.`;
|
|
107
107
|
}
|
|
108
108
|
}
|
|
@@ -5,7 +5,7 @@ const fs = require("fs");
|
|
|
5
5
|
const path = require("path");
|
|
6
6
|
const uuid_1 = require("uuid");
|
|
7
7
|
const Command_1 = require("../../../../Command");
|
|
8
|
-
const
|
|
8
|
+
const utils_1 = require("../../../../utils");
|
|
9
9
|
const AnonymousCommand_1 = require("../../../base/AnonymousCommand");
|
|
10
10
|
const commands_1 = require("../../commands");
|
|
11
11
|
const template_instantiator_1 = require("../../template-instantiator");
|
|
@@ -88,7 +88,7 @@ class PaSolutionInitCommand extends AnonymousCommand_1.default {
|
|
|
88
88
|
return 'CDS project creation failed. The current directory already contains a project. Please create a new directory and retry the operation.';
|
|
89
89
|
}
|
|
90
90
|
const workingDirectoryName = path.basename(process.cwd());
|
|
91
|
-
if (!
|
|
91
|
+
if (!utils_1.validation.isValidFileName(workingDirectoryName)) {
|
|
92
92
|
return `Empty or invalid project name '${workingDirectoryName}'`;
|
|
93
93
|
}
|
|
94
94
|
if (args.options.publisherPrefix) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class PlannerBucketAddCommand extends GraphCommand_1.default {
|
|
@@ -127,7 +127,7 @@ class PlannerBucketAddCommand extends GraphCommand_1.default {
|
|
|
127
127
|
if (args.options.planName && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
128
128
|
return 'Specify either ownerGroupId or ownerGroupName when using planName but not both';
|
|
129
129
|
}
|
|
130
|
-
if (args.options.ownerGroupId && !
|
|
130
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
131
131
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
132
132
|
}
|
|
133
133
|
return true;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
5
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
|
-
class PlannerBucketListCommand extends
|
|
7
|
+
class PlannerBucketListCommand extends GraphCommand_1.default {
|
|
8
8
|
get name() {
|
|
9
9
|
return commands_1.default.BUCKET_LIST;
|
|
10
10
|
}
|
|
@@ -25,9 +25,9 @@ class PlannerBucketListCommand extends GraphItemsListCommand_1.GraphItemsListCom
|
|
|
25
25
|
commandAction(logger, args, cb) {
|
|
26
26
|
this
|
|
27
27
|
.getPlanId(args)
|
|
28
|
-
.then((planId) =>
|
|
29
|
-
.then(() => {
|
|
30
|
-
logger.log(
|
|
28
|
+
.then((planId) => utils_1.odata.getAllItems(`${this.resource}/v1.0/planner/plans/${planId}/buckets`, logger))
|
|
29
|
+
.then((buckets) => {
|
|
30
|
+
logger.log(buckets);
|
|
31
31
|
cb();
|
|
32
32
|
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
33
33
|
}
|
|
@@ -107,7 +107,7 @@ class PlannerBucketListCommand extends GraphItemsListCommand_1.GraphItemsListCom
|
|
|
107
107
|
if (args.options.planName && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
108
108
|
return 'Specify either ownerGroupId or ownerGroupName when using planName but not both';
|
|
109
109
|
}
|
|
110
|
-
if (args.options.ownerGroupId && !
|
|
110
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
111
111
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
112
112
|
}
|
|
113
113
|
return true;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class PlannerPlanAddCommand extends GraphCommand_1.default {
|
|
@@ -85,7 +85,7 @@ class PlannerPlanAddCommand extends GraphCommand_1.default {
|
|
|
85
85
|
if (args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
86
86
|
return 'Specify either ownerGroupId or ownerGroupName but not both';
|
|
87
87
|
}
|
|
88
|
-
if (args.options.ownerGroupId && !
|
|
88
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
89
89
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
90
90
|
}
|
|
91
91
|
return true;
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const request_1 = require("../../../../request");
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
|
+
const commands_1 = require("../../commands");
|
|
7
|
+
class PlannerPlanDetailsGetCommand extends GraphCommand_1.default {
|
|
8
|
+
constructor() {
|
|
9
|
+
super(...arguments);
|
|
10
|
+
this.groupId = '';
|
|
11
|
+
}
|
|
12
|
+
get name() {
|
|
13
|
+
return commands_1.default.PLAN_DETAILS_GET;
|
|
14
|
+
}
|
|
15
|
+
get description() {
|
|
16
|
+
return 'Get details of a Microsoft Planner plan';
|
|
17
|
+
}
|
|
18
|
+
getTelemetryProperties(args) {
|
|
19
|
+
const telemetryProps = super.getTelemetryProperties(args);
|
|
20
|
+
telemetryProps.planId = typeof args.options.planId !== 'undefined';
|
|
21
|
+
telemetryProps.planTitle = typeof args.options.planTitle !== 'undefined';
|
|
22
|
+
telemetryProps.ownerGroupId = typeof args.options.ownerGroupId !== 'undefined';
|
|
23
|
+
telemetryProps.ownerGroupName = typeof args.options.ownerGroupName !== 'undefined';
|
|
24
|
+
return telemetryProps;
|
|
25
|
+
}
|
|
26
|
+
commandAction(logger, args, cb) {
|
|
27
|
+
this
|
|
28
|
+
.getGroupId(args)
|
|
29
|
+
.then((groupId) => {
|
|
30
|
+
this.groupId = groupId;
|
|
31
|
+
return this.getPlanId(args, logger);
|
|
32
|
+
})
|
|
33
|
+
.then((planId) => {
|
|
34
|
+
args.options.planId = planId;
|
|
35
|
+
return this.getPlanDetails(args);
|
|
36
|
+
})
|
|
37
|
+
.then((res) => {
|
|
38
|
+
logger.log(res);
|
|
39
|
+
cb();
|
|
40
|
+
}, (err) => this.handleRejectedODataJsonPromise(err, logger, cb));
|
|
41
|
+
}
|
|
42
|
+
getGroupId(args) {
|
|
43
|
+
if (args.options.planId) {
|
|
44
|
+
return Promise.resolve('');
|
|
45
|
+
}
|
|
46
|
+
if (args.options.ownerGroupId) {
|
|
47
|
+
return Promise.resolve(args.options.ownerGroupId);
|
|
48
|
+
}
|
|
49
|
+
const requestOptions = {
|
|
50
|
+
url: `${this.resource}/v1.0/groups?$filter=displayName eq '${encodeURIComponent(args.options.ownerGroupName)}'`,
|
|
51
|
+
headers: {
|
|
52
|
+
accept: 'application/json;odata.metadata=none'
|
|
53
|
+
},
|
|
54
|
+
responseType: 'json'
|
|
55
|
+
};
|
|
56
|
+
return request_1.default
|
|
57
|
+
.get(requestOptions)
|
|
58
|
+
.then(response => {
|
|
59
|
+
const groupItem = response.value[0];
|
|
60
|
+
if (!groupItem) {
|
|
61
|
+
return Promise.reject(`The specified ownerGroup does not exist`);
|
|
62
|
+
}
|
|
63
|
+
if (response.value.length > 1) {
|
|
64
|
+
return Promise.reject(`Multiple ownerGroups with name ${args.options.ownerGroupName} found: Please choose between the following IDs ${response.value.map(x => x.id)}`);
|
|
65
|
+
}
|
|
66
|
+
return Promise.resolve(groupItem.id);
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
getPlanId(args, logger) {
|
|
70
|
+
if (args.options.planId) {
|
|
71
|
+
return Promise.resolve(args.options.planId);
|
|
72
|
+
}
|
|
73
|
+
return utils_1.odata
|
|
74
|
+
.getAllItems(`${this.resource}/v1.0/groups/${this.groupId}/planner/plans`, logger)
|
|
75
|
+
.then((plans) => {
|
|
76
|
+
const plansMatchingName = plans.filter((plan) => plan.title === args.options.planTitle);
|
|
77
|
+
if (plansMatchingName && plansMatchingName.length > 0) {
|
|
78
|
+
if (plansMatchingName.length > 1) {
|
|
79
|
+
return Promise.reject(`Multiple plans with name ${args.options.planTitle} found: ${plansMatchingName.map(x => x.id)}`);
|
|
80
|
+
}
|
|
81
|
+
return Promise.resolve(plansMatchingName[0].id);
|
|
82
|
+
}
|
|
83
|
+
return Promise.reject(`The specified plan title does not exist`);
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
getPlanDetails(args) {
|
|
87
|
+
const requestOptions = {
|
|
88
|
+
url: `${this.resource}/v1.0/planner/plans/${args.options.planId}/details`,
|
|
89
|
+
headers: {
|
|
90
|
+
'accept': 'application/json;odata.metadata=none'
|
|
91
|
+
},
|
|
92
|
+
responseType: 'json'
|
|
93
|
+
};
|
|
94
|
+
return request_1.default.get(requestOptions);
|
|
95
|
+
}
|
|
96
|
+
options() {
|
|
97
|
+
const options = [
|
|
98
|
+
{
|
|
99
|
+
option: '-i, --planId [planId]'
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
option: '-t, --planTitle [planTitle]'
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
option: '--ownerGroupId [ownerGroupId]'
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
option: '--ownerGroupName [ownerGroupName]'
|
|
109
|
+
}
|
|
110
|
+
];
|
|
111
|
+
const parentOptions = super.options();
|
|
112
|
+
return options.concat(parentOptions);
|
|
113
|
+
}
|
|
114
|
+
validate(args) {
|
|
115
|
+
if (!args.options.planId && !args.options.planTitle) {
|
|
116
|
+
return 'Specify either planId or planTitle';
|
|
117
|
+
}
|
|
118
|
+
if (args.options.planId && args.options.planTitle) {
|
|
119
|
+
return 'Specify either planId or planTitle';
|
|
120
|
+
}
|
|
121
|
+
if (args.options.planTitle && !args.options.ownerGroupId && !args.options.ownerGroupName) {
|
|
122
|
+
return 'Specify either ownerGroupId or ownerGroupName';
|
|
123
|
+
}
|
|
124
|
+
if (args.options.planTitle && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
125
|
+
return 'Specify either ownerGroupId or ownerGroupName but not both';
|
|
126
|
+
}
|
|
127
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
128
|
+
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
129
|
+
}
|
|
130
|
+
return true;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
module.exports = new PlannerPlanDetailsGetCommand();
|
|
134
|
+
//# sourceMappingURL=plan-details-get.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
5
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
|
-
class PlannerPlanGetCommand extends
|
|
7
|
+
class PlannerPlanGetCommand extends GraphCommand_1.default {
|
|
8
8
|
get name() {
|
|
9
9
|
return commands_1.default.PLAN_GET;
|
|
10
10
|
}
|
|
@@ -34,9 +34,9 @@ class PlannerPlanGetCommand extends GraphItemsListCommand_1.GraphItemsListComman
|
|
|
34
34
|
else {
|
|
35
35
|
this
|
|
36
36
|
.getGroupId(args)
|
|
37
|
-
.then((groupId) =>
|
|
38
|
-
.then(() => {
|
|
39
|
-
const filteredPlan =
|
|
37
|
+
.then((groupId) => utils_1.odata.getAllItems(`${this.resource}/v1.0/groups/${groupId}/planner/plans`, logger, 'minimal'))
|
|
38
|
+
.then((plans) => {
|
|
39
|
+
const filteredPlan = plans.filter((plan) => plan.title === args.options.title);
|
|
40
40
|
if (filteredPlan && filteredPlan.length > 0) {
|
|
41
41
|
logger.log(filteredPlan);
|
|
42
42
|
}
|
|
@@ -106,7 +106,7 @@ class PlannerPlanGetCommand extends GraphItemsListCommand_1.GraphItemsListComman
|
|
|
106
106
|
if (args.options.title && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
107
107
|
return 'Specify either ownerGroupId or ownerGroupName but not both';
|
|
108
108
|
}
|
|
109
|
-
if (args.options.ownerGroupId && !
|
|
109
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
110
110
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
111
111
|
}
|
|
112
112
|
return true;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class PlannerPlanListCommand extends GraphCommand_1.default {
|
|
@@ -80,7 +80,7 @@ class PlannerPlanListCommand extends GraphCommand_1.default {
|
|
|
80
80
|
if (args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
81
81
|
return 'Specify either ownerGroupId or ownerGroupName but not both';
|
|
82
82
|
}
|
|
83
|
-
if (args.options.ownerGroupId && !
|
|
83
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
84
84
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
85
85
|
}
|
|
86
86
|
return true;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const utils_1 = require("../../../../utils");
|
|
5
5
|
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
6
6
|
const commands_1 = require("../../commands");
|
|
7
7
|
class PlannerTaskAddCommand extends GraphCommand_1.default {
|
|
@@ -199,7 +199,7 @@ class PlannerTaskAddCommand extends GraphCommand_1.default {
|
|
|
199
199
|
let userIds = [];
|
|
200
200
|
const promises = userArr.map(user => {
|
|
201
201
|
const requestOptions = {
|
|
202
|
-
url: `${this.resource}/v1.0/users?$filter=userPrincipalName eq '${
|
|
202
|
+
url: `${this.resource}/v1.0/users?$filter=userPrincipalName eq '${utils_1.formatting.encodeQueryParameter(user)}'&$select=id,userPrincipalName`,
|
|
203
203
|
headers: {
|
|
204
204
|
'content-type': 'application/json'
|
|
205
205
|
},
|
|
@@ -254,7 +254,7 @@ class PlannerTaskAddCommand extends GraphCommand_1.default {
|
|
|
254
254
|
if (args.options.planName && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
255
255
|
return 'Specify either ownerGroupId or ownerGroupName when using planName but not both';
|
|
256
256
|
}
|
|
257
|
-
if (args.options.ownerGroupId && !
|
|
257
|
+
if (args.options.ownerGroupId && !utils_1.validation.isValidGuid(args.options.ownerGroupId)) {
|
|
258
258
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
259
259
|
}
|
|
260
260
|
if (!args.options.bucketId && !args.options.bucketName) {
|
|
@@ -263,10 +263,10 @@ class PlannerTaskAddCommand extends GraphCommand_1.default {
|
|
|
263
263
|
if (args.options.bucketId && args.options.bucketName) {
|
|
264
264
|
return 'Specify either bucketId or bucketName but not both';
|
|
265
265
|
}
|
|
266
|
-
if (args.options.startDateTime && !
|
|
266
|
+
if (args.options.startDateTime && !utils_1.validation.isValidISODateTime(args.options.startDateTime)) {
|
|
267
267
|
return 'The startDateTime is not a valid ISO date string';
|
|
268
268
|
}
|
|
269
|
-
if (args.options.dueDateTime && !
|
|
269
|
+
if (args.options.dueDateTime && !utils_1.validation.isValidISODateTime(args.options.dueDateTime)) {
|
|
270
270
|
return 'The dueDateTime is not a valid ISO date string';
|
|
271
271
|
}
|
|
272
272
|
if (args.options.percentComplete && isNaN(args.options.percentComplete)) {
|
|
@@ -275,7 +275,7 @@ class PlannerTaskAddCommand extends GraphCommand_1.default {
|
|
|
275
275
|
if (args.options.percentComplete && (args.options.percentComplete < 0 || args.options.percentComplete > 100)) {
|
|
276
276
|
return `percentComplete should be between 0 and 100 `;
|
|
277
277
|
}
|
|
278
|
-
if (args.options.assignedToUserIds && !
|
|
278
|
+
if (args.options.assignedToUserIds && !utils_1.validation.isValidGuidArray(args.options.assignedToUserIds.split(','))) {
|
|
279
279
|
return 'assignedToUserIds contains invalid GUID';
|
|
280
280
|
}
|
|
281
281
|
if (args.options.assignedToUserIds && args.options.assignedToUserNames) {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const request_1 = require("../../../../request");
|
|
4
|
-
const
|
|
4
|
+
const GraphCommand_1 = require("../../../base/GraphCommand");
|
|
5
5
|
const commands_1 = require("../../commands");
|
|
6
|
-
class PlannerTaskDetailsGetCommand extends
|
|
6
|
+
class PlannerTaskDetailsGetCommand extends GraphCommand_1.default {
|
|
7
7
|
get name() {
|
|
8
8
|
return commands_1.default.TASK_DETAILS_GET;
|
|
9
9
|
}
|