@pnp/cli-microsoft365 7.0.0-beta.f1037e1 → 7.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.cjs +1 -3
- package/README.md +4 -4
- package/dist/Auth.js +12 -2
- package/dist/Command.js +3 -3
- package/dist/GlobalOptions.js +1 -7
- package/dist/cli/Cli.js +24 -7
- package/dist/m365/aad/commands/app/app-add.js +8 -8
- package/dist/m365/aad/commands/app/app-get.js +4 -1
- package/dist/m365/aad/commands/app/app-remove.js +3 -1
- package/dist/m365/aad/commands/app/app-role-add.js +9 -6
- package/dist/m365/aad/commands/app/app-role-list.js +4 -1
- package/dist/m365/aad/commands/app/app-role-remove.js +5 -2
- package/dist/m365/aad/commands/app/app-set.js +13 -10
- package/dist/m365/aad/commands/approleassignment/approleassignment-add.js +11 -6
- package/dist/m365/aad/commands/approleassignment/approleassignment-remove.js +4 -4
- package/dist/m365/aad/commands/group/group-get.js +4 -4
- package/dist/m365/aad/commands/group/group-list.js +1 -23
- package/dist/m365/aad/commands/group/group-remove.js +98 -0
- package/dist/m365/aad/commands/{o365group/o365group-add.js → m365group/m365group-add.js} +38 -29
- package/dist/m365/aad/commands/{o365group/o365group-conversation-list.js → m365group/m365group-conversation-list.js} +15 -10
- package/dist/m365/aad/commands/{o365group/o365group-conversation-post-list.js → m365group/m365group-conversation-post-list.js} +18 -14
- package/dist/m365/aad/commands/{o365group/o365group-get.js → m365group/m365group-get.js} +14 -10
- package/dist/m365/aad/commands/{o365group/o365group-list.js → m365group/m365group-list.js} +13 -28
- package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-clear.js → m365group/m365group-recyclebinitem-clear.js} +15 -15
- package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-list.js → m365group/m365group-recyclebinitem-list.js} +10 -10
- package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-remove.js → m365group/m365group-recyclebinitem-remove.js} +17 -15
- package/dist/m365/aad/commands/{o365group/o365group-recyclebinitem-restore.js → m365group/m365group-recyclebinitem-restore.js} +18 -15
- package/dist/m365/aad/commands/{o365group/o365group-remove.js → m365group/m365group-remove.js} +17 -12
- package/dist/m365/aad/commands/{o365group/o365group-renew.js → m365group/m365group-renew.js} +15 -10
- package/dist/m365/aad/commands/{o365group/o365group-report-activitycounts.js → m365group/m365group-report-activitycounts.js} +4 -4
- package/dist/m365/aad/commands/{o365group/o365group-report-activitydetail.js → m365group/m365group-report-activitydetail.js} +4 -4
- package/dist/m365/aad/commands/{o365group/o365group-report-activityfilecounts.js → m365group/m365group-report-activityfilecounts.js} +4 -4
- package/dist/m365/aad/commands/{o365group/o365group-report-activitygroupcounts.js → m365group/m365group-report-activitygroupcounts.js} +4 -4
- package/dist/m365/aad/commands/{o365group/o365group-report-activitystorage.js → m365group/m365group-report-activitystorage.js} +4 -4
- package/dist/m365/aad/commands/{o365group/o365group-set.js → m365group/m365group-set.js} +22 -17
- package/dist/m365/aad/commands/{o365group/o365group-teamify.js → m365group/m365group-teamify.js} +28 -20
- package/dist/m365/aad/commands/{o365group/o365group-user-add.js → m365group/m365group-user-add.js} +19 -14
- package/dist/m365/aad/commands/{o365group/o365group-user-list.js → m365group/m365group-user-list.js} +17 -12
- package/dist/m365/aad/commands/{o365group/o365group-user-remove.js → m365group/m365group-user-remove.js} +19 -14
- package/dist/m365/aad/commands/{o365group/o365group-user-set.js → m365group/m365group-user-set.js} +20 -15
- package/dist/m365/aad/commands/policy/policy-list.js +5 -5
- package/dist/m365/aad/commands/sp/sp-add.js +4 -1
- package/dist/m365/aad/commands/sp/sp-get.js +4 -1
- package/dist/m365/aad/commands/user/user-get.js +7 -2
- package/dist/m365/aad/commands.js +23 -22
- package/dist/m365/booking/commands/business/business-get.js +4 -1
- package/dist/m365/cli/commands/cli-issue.js +5 -5
- package/dist/m365/cli/commands/config/config-get.js +5 -5
- package/dist/m365/cli/commands/config/config-list.js +16 -0
- package/dist/m365/cli/commands/config/config-reset.js +5 -5
- package/dist/m365/cli/commands/config/config-set.js +5 -5
- package/dist/m365/cli/commands.js +1 -0
- package/dist/m365/commands/login.js +7 -7
- package/dist/m365/commands/request.js +1 -1
- package/dist/m365/flow/commands/flow-export.js +13 -13
- package/dist/m365/flow/commands/owner/owner-ensure.js +5 -5
- package/dist/m365/graph/commands/subscription/subscription-add.js +5 -5
- package/dist/m365/outlook/commands/message/message-list.js +4 -2
- package/dist/m365/outlook/commands/message/message-move.js +4 -2
- package/dist/m365/pa/commands/app/app-export.js +7 -7
- package/dist/m365/pa/commands/app/app-owner-set.js +5 -5
- package/dist/m365/pa/commands/app/app-permission-ensure.js +162 -0
- package/dist/m365/pa/commands/app/app-permission-list.js +2 -2
- package/dist/m365/pa/commands/app/app-permission-remove.js +153 -0
- package/dist/m365/pa/commands/connector/connector-export.js +5 -5
- package/dist/m365/pa/commands.js +3 -4
- package/dist/m365/planner/commands/bucket/bucket-add.js +6 -3
- package/dist/m365/planner/commands/bucket/bucket-get.js +11 -4
- package/dist/m365/planner/commands/bucket/bucket-list.js +6 -3
- package/dist/m365/planner/commands/bucket/bucket-remove.js +9 -4
- package/dist/m365/planner/commands/bucket/bucket-set.js +10 -4
- package/dist/m365/planner/commands/plan/plan-add.js +4 -1
- package/dist/m365/planner/commands/plan/plan-get.js +5 -3
- package/dist/m365/planner/commands/plan/plan-list.js +8 -6
- package/dist/m365/planner/commands/plan/plan-remove.js +4 -1
- package/dist/m365/planner/commands/plan/plan-set.js +6 -3
- package/dist/m365/planner/commands/roster/roster-get.js +4 -1
- package/dist/m365/planner/commands/roster/roster-member-add.js +4 -1
- package/dist/m365/planner/commands/roster/roster-member-get.js +4 -1
- package/dist/m365/planner/commands/roster/roster-member-list.js +4 -1
- package/dist/m365/planner/commands/roster/roster-member-remove.js +4 -1
- package/dist/m365/planner/commands/roster/roster-plan-list.js +4 -1
- package/dist/m365/planner/commands/roster/roster-remove.js +4 -1
- package/dist/m365/planner/commands/task/task-add.js +21 -12
- package/dist/m365/planner/commands/task/task-checklistitem-add.js +4 -1
- package/dist/m365/planner/commands/task/task-checklistitem-list.js +4 -1
- package/dist/m365/planner/commands/task/task-checklistitem-remove.js +4 -1
- package/dist/m365/planner/commands/task/task-get.js +46 -28
- package/dist/m365/planner/commands/task/task-list.js +34 -19
- package/dist/m365/planner/commands/task/task-reference-add.js +4 -1
- package/dist/m365/planner/commands/task/task-reference-list.js +4 -1
- package/dist/m365/planner/commands/task/task-reference-remove.js +4 -1
- package/dist/m365/planner/commands/task/task-remove.js +49 -38
- package/dist/m365/planner/commands/task/task-set.js +38 -23
- package/dist/m365/pp/commands/aibuildermodel/aibuildermodel-get.js +4 -1
- package/dist/m365/pp/commands/card/card-get.js +3 -5
- package/dist/m365/pp/commands/chatbot/chatbot-get.js +3 -1
- package/dist/m365/pp/commands/chatbot/chatbot-list.js +2 -2
- package/dist/m365/pp/commands/managementapp/managementapp-add.js +4 -1
- package/dist/m365/purview/commands/retentionlabel/retentionlabel-add.js +14 -14
- package/dist/m365/search/commands/externalconnection/externalconnection-remove.js +3 -1
- package/dist/m365/spfx/commands/package/package-generate.js +15 -15
- package/dist/m365/spfx/commands/project/DeployWorkflow.js +55 -0
- package/dist/m365/spfx/commands/project/project-doctor/{doctor-1.18.0-beta.1.js → doctor-1.18.0.js} +2 -2
- package/dist/m365/spfx/commands/project/project-doctor.js +9 -9
- package/dist/m365/spfx/commands/project/project-externalize/rules/PnPJsRule.js +2 -2
- package/dist/m365/spfx/commands/project/project-github-workflow-add.js +157 -0
- package/dist/m365/spfx/commands/project/project-github-workflow-model.js +2 -0
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN001022_DEP_office_ui_fabric_react.js +1 -1
- package/dist/m365/spfx/commands/project/project-upgrade/rules/FN002028_DEVDEP_microsoft_rush_stack_compiler_4_7.js +13 -0
- package/dist/m365/spfx/commands/project/project-upgrade/upgrade-1.15.2.js +1 -1
- package/dist/m365/spfx/commands/project/project-upgrade/{upgrade-1.18.0-beta.1.js → upgrade-1.18.0.js} +35 -27
- package/dist/m365/spfx/commands/project/project-upgrade.js +26 -28
- package/dist/m365/spfx/commands/spfx-doctor.js +76 -106
- package/dist/m365/spfx/commands.js +1 -0
- package/dist/m365/spo/commands/app/SpoAppBaseCommand.js +27 -26
- package/dist/m365/spo/commands/app/app-add.js +9 -9
- package/dist/m365/spo/commands/applicationcustomizer/applicationcustomizer-add.js +5 -5
- package/dist/m365/spo/commands/applicationcustomizer/applicationcustomizer-get.js +5 -3
- package/dist/m365/spo/commands/applicationcustomizer/applicationcustomizer-list.js +5 -5
- package/dist/m365/spo/commands/applicationcustomizer/applicationcustomizer-remove.js +2 -2
- package/dist/m365/spo/commands/applicationcustomizer/applicationcustomizer-set.js +3 -2
- package/dist/m365/spo/commands/commandset/commandset-add.js +11 -11
- package/dist/m365/spo/commands/commandset/commandset-get.js +12 -10
- package/dist/m365/spo/commands/commandset/commandset-list.js +5 -5
- package/dist/m365/spo/commands/commandset/commandset-remove.js +7 -6
- package/dist/m365/spo/commands/commandset/commandset-set.js +14 -12
- package/dist/m365/spo/commands/customaction/customaction-get.js +5 -2
- package/dist/m365/spo/commands/customaction/customaction-remove.js +3 -1
- package/dist/m365/spo/commands/eventreceiver/eventreceiver-get.js +3 -1
- package/dist/m365/spo/commands/file/file-add.js +13 -13
- package/dist/m365/spo/commands/file/file-checkin.js +1 -1
- package/dist/m365/spo/commands/file/file-checkout.js +1 -1
- package/dist/m365/spo/commands/file/file-copy.js +36 -4
- package/dist/m365/spo/commands/file/file-get.js +11 -8
- package/dist/m365/spo/commands/file/file-list.js +4 -4
- package/dist/m365/spo/commands/file/file-move.js +74 -98
- package/dist/m365/spo/commands/file/file-remove.js +8 -8
- package/dist/m365/spo/commands/file/file-rename.js +2 -2
- package/dist/m365/spo/commands/file/file-retentionlabel-ensure.js +1 -1
- package/dist/m365/spo/commands/file/file-retentionlabel-remove.js +1 -1
- package/dist/m365/spo/commands/file/file-roleassignment-add.js +1 -1
- package/dist/m365/spo/commands/file/file-roleassignment-remove.js +1 -1
- package/dist/m365/spo/commands/file/file-roleinheritance-break.js +1 -1
- package/dist/m365/spo/commands/file/file-roleinheritance-reset.js +1 -1
- package/dist/m365/spo/commands/file/file-sharinglink-add.js +8 -8
- package/dist/m365/spo/commands/file/file-sharinglink-list.js +5 -5
- package/dist/m365/spo/commands/file/file-version-clear.js +3 -3
- package/dist/m365/spo/commands/file/file-version-get.js +3 -3
- package/dist/m365/spo/commands/file/file-version-list.js +3 -3
- package/dist/m365/spo/commands/file/file-version-remove.js +3 -3
- package/dist/m365/spo/commands/file/file-version-restore.js +3 -3
- package/dist/m365/spo/commands/folder/folder-add.js +2 -4
- package/dist/m365/spo/commands/folder/folder-copy.js +89 -45
- package/dist/m365/spo/commands/folder/folder-get.js +1 -1
- package/dist/m365/spo/commands/folder/folder-list.js +2 -2
- package/dist/m365/spo/commands/folder/folder-move.js +89 -47
- package/dist/m365/spo/commands/folder/folder-remove.js +7 -4
- package/dist/m365/spo/commands/folder/folder-rename.js +13 -17
- package/dist/m365/spo/commands/folder/folder-retentionlabel-ensure.js +1 -1
- package/dist/m365/spo/commands/folder/folder-retentionlabel-remove.js +1 -1
- package/dist/m365/spo/commands/folder/folder-roleassignment-add.js +1 -1
- package/dist/m365/spo/commands/folder/folder-roleassignment-remove.js +1 -1
- package/dist/m365/spo/commands/folder/folder-roleinheritance-break.js +1 -1
- package/dist/m365/spo/commands/folder/folder-roleinheritance-reset.js +1 -1
- package/dist/m365/spo/commands/group/group-list.js +0 -1
- package/dist/m365/spo/commands/group/group-member-add.js +24 -24
- package/dist/m365/spo/commands/hubsite/hubsite-connect.js +7 -4
- package/dist/m365/spo/commands/hubsite/hubsite-disconnect.js +4 -1
- package/dist/m365/spo/commands/hubsite/hubsite-get.js +3 -1
- package/dist/m365/spo/commands/list/list-add.js +4 -4
- package/dist/m365/spo/commands/list/list-retentionlabel-ensure.js +2 -24
- package/dist/m365/spo/commands/list/list-set.js +4 -4
- package/dist/m365/spo/commands/listitem/listitem-add.js +1 -0
- package/dist/m365/spo/commands/listitem/listitem-attachment-add.js +127 -0
- package/dist/m365/spo/commands/listitem/listitem-attachment-get.js +97 -0
- package/dist/m365/spo/commands/listitem/listitem-attachment-remove.js +121 -0
- package/dist/m365/spo/commands/listitem/listitem-attachment-set.js +115 -0
- package/dist/m365/spo/commands/listitem/listitem-set.js +3 -2
- package/dist/m365/spo/commands/navigation/navigation-node-set.js +2 -2
- package/dist/m365/spo/commands/orgassetslibrary/orgassetslibrary-add.js +34 -5
- package/dist/m365/spo/commands/page/clientsidepages.js +19 -81
- package/dist/m365/spo/commands/page/page-get.js +1 -0
- package/dist/m365/spo/commands/page/page-list.js +4 -3
- package/dist/m365/spo/commands/page/page-section-add.js +56 -21
- package/dist/m365/spo/commands/page/page-set.js +13 -2
- package/dist/m365/spo/commands/propertybag/propertybag-base.js +63 -59
- package/dist/m365/spo/commands/propertybag/propertybag-remove.js +28 -31
- package/dist/m365/spo/commands/serviceprincipal/serviceprincipal-set.js +30 -32
- package/dist/m365/spo/commands/site/FlowsPolicy.js +7 -0
- package/dist/m365/spo/commands/site/site-add.js +114 -161
- package/dist/m365/spo/commands/site/site-apppermission-add.js +15 -18
- package/dist/m365/spo/commands/site/site-apppermission-remove.js +34 -38
- package/dist/m365/spo/commands/site/site-apppermission-set.js +11 -14
- package/dist/m365/spo/commands/site/site-commsite-enable.js +34 -5
- package/dist/m365/spo/commands/site/site-ensure.js +14 -67
- package/dist/m365/spo/commands/site/site-hubsite-disconnect.js +22 -22
- package/dist/m365/spo/commands/site/site-list.js +25 -43
- package/dist/m365/spo/commands/site/site-recyclebinitem-list.js +6 -6
- package/dist/m365/spo/commands/site/site-remove.js +166 -210
- package/dist/m365/spo/commands/site/site-set.js +178 -199
- package/dist/m365/spo/commands/tenant/tenant-appcatalog-add.js +1 -1
- package/dist/m365/spo/commands/tenant/tenant-applicationcustomizer-get.js +12 -7
- package/dist/m365/spo/commands/tenant/tenant-applicationcustomizer-list.js +3 -2
- package/dist/m365/spo/commands/tenant/tenant-applicationcustomizer-remove.js +2 -1
- package/dist/m365/spo/commands/tenant/tenant-applicationcustomizer-set.js +3 -2
- package/dist/m365/spo/commands/tenant/tenant-commandset-add.js +8 -8
- package/dist/m365/spo/commands/tenant/tenant-commandset-get.js +8 -3
- package/dist/m365/spo/commands/tenant/tenant-commandset-list.js +3 -2
- package/dist/m365/spo/commands/tenant/tenant-commandset-remove.js +3 -1
- package/dist/m365/spo/commands/tenant/tenant-commandset-set.js +8 -8
- package/dist/m365/spo/commands/tenant/tenant-settings-set.js +4 -4
- package/dist/m365/spo/commands/term/term-get.js +6 -6
- package/dist/m365/spo/commands/theme/theme-list.js +1 -9
- package/dist/m365/spo/commands/theme/theme-remove.js +24 -24
- package/dist/m365/spo/commands/theme/theme-set.js +0 -1
- package/dist/m365/spo/commands/user/user-get.js +10 -10
- package/dist/m365/spo/commands/user/user-remove.js +27 -27
- package/dist/m365/spo/commands/web/web-reindex.js +35 -42
- package/dist/m365/spo/commands/web/web-remove.js +21 -21
- package/dist/m365/spo/commands/web/web-roleassignment-add.js +16 -31
- package/dist/m365/spo/commands/web/web-roleassignment-remove.js +33 -44
- package/dist/m365/spo/commands/web/web-roleinheritance-break.js +18 -18
- package/dist/m365/spo/commands/web/web-roleinheritance-reset.js +19 -19
- package/dist/m365/spo/commands/web/web-set.js +5 -5
- package/dist/m365/spo/commands.js +4 -0
- package/dist/m365/teams/commands/app/app-list.js +5 -5
- package/dist/m365/teams/commands/app/app-remove.js +49 -15
- package/dist/m365/teams/commands/channel/channel-add.js +5 -1
- package/dist/m365/teams/commands/channel/channel-member-add.js +12 -10
- package/dist/m365/teams/commands/channel/channel-member-remove.js +3 -1
- package/dist/m365/teams/commands/channel/channel-member-set.js +4 -1
- package/dist/m365/teams/commands/chat/chat-get.js +7 -10
- package/dist/m365/teams/commands/chat/chat-member-add.js +5 -5
- package/dist/m365/teams/commands/chat/chat-message-send.js +8 -10
- package/dist/m365/teams/commands/funsettings/funsettings-set.js +4 -4
- package/dist/m365/teams/commands/guestsettings/guestsettings-set.js +4 -4
- package/dist/m365/teams/commands/meeting/meeting-list.js +101 -51
- package/dist/m365/teams/commands/membersettings/membersettings-set.js +4 -4
- package/dist/m365/teams/commands/messagingsettings/messagingsettings-set.js +5 -5
- package/dist/m365/teams/commands/team/team-clone.js +5 -10
- package/dist/m365/teams/commands/team/team-list.js +94 -30
- package/dist/m365/teams/commands/team/team-set.js +3 -3
- package/dist/m365/tenant/commands/info/info-get.js +83 -0
- package/dist/m365/tenant/commands.js +1 -0
- package/dist/m365/todo/commands/task/task-add.js +6 -6
- package/dist/m365/yammer/commands/message/message-like-set.js +27 -28
- package/dist/m365/yammer/commands/message/message-list.js +67 -86
- package/dist/m365/yammer/commands/message/message-remove.js +18 -18
- package/dist/m365/yammer/commands/yammer-search.js +58 -74
- package/dist/utils/aadGroup.js +39 -3
- package/dist/utils/formatting.js +7 -0
- package/dist/utils/fsUtil.js +5 -0
- package/dist/utils/planner.js +4 -3
- package/dist/utils/powerPlatform.js +1 -1
- package/dist/utils/spo.js +595 -54
- package/dist/utils/validation.js +0 -3
- package/docs/docs/_clisettings.mdx +2 -2
- package/docs/docs/cmd/_global.mdx +1 -1
- package/docs/docs/cmd/aad/app/app-set.mdx +15 -15
- package/docs/docs/cmd/aad/approleassignment/approleassignment-add.mdx +9 -9
- package/docs/docs/cmd/aad/approleassignment/approleassignment-remove.mdx +10 -10
- package/docs/docs/cmd/aad/group/group-get.mdx +5 -5
- package/docs/docs/cmd/aad/group/group-list.mdx +0 -11
- package/docs/docs/cmd/aad/group/group-remove.mdx +44 -0
- package/docs/docs/cmd/aad/{o365group/o365group-add.mdx → m365group/m365group-add.mdx} +25 -15
- package/docs/docs/cmd/aad/{o365group/o365group-conversation-list.mdx → m365group/m365group-conversation-list.mdx} +4 -4
- package/docs/docs/cmd/aad/{o365group/o365group-conversation-post-list.mdx → m365group/m365group-conversation-post-list.mdx} +8 -8
- package/docs/docs/cmd/aad/{o365group/o365group-get.mdx → m365group/m365group-get.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-list.mdx → m365group/m365group-list.mdx} +12 -29
- package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-clear.mdx → m365group/m365group-recyclebinitem-clear.mdx} +5 -5
- package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-list.mdx → m365group/m365group-recyclebinitem-list.mdx} +8 -8
- package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-remove.mdx → m365group/m365group-recyclebinitem-remove.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-recyclebinitem-restore.mdx → m365group/m365group-recyclebinitem-restore.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-remove.mdx → m365group/m365group-remove.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-renew.mdx → m365group/m365group-renew.mdx} +4 -4
- package/docs/docs/cmd/aad/{o365group/o365group-report-activitycounts.mdx → m365group/m365group-report-activitycounts.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-report-activitydetail.mdx → m365group/m365group-report-activitydetail.mdx} +7 -7
- package/docs/docs/cmd/aad/{o365group/o365group-report-activityfilecounts.mdx → m365group/m365group-report-activityfilecounts.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-report-activitygroupcounts.mdx → m365group/m365group-report-activitygroupcounts.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-report-activitystorage.mdx → m365group/m365group-report-activitystorage.mdx} +6 -6
- package/docs/docs/cmd/aad/{o365group/o365group-set.mdx → m365group/m365group-set.mdx} +8 -8
- package/docs/docs/cmd/aad/{o365group/o365group-teamify.mdx → m365group/m365group-teamify.mdx} +5 -5
- package/docs/docs/cmd/aad/{o365group/o365group-user-add.mdx → m365group/m365group-user-add.mdx} +5 -5
- package/docs/docs/cmd/aad/{o365group/o365group-user-list.mdx → m365group/m365group-user-list.mdx} +7 -7
- package/docs/docs/cmd/aad/{o365group/o365group-user-remove.mdx → m365group/m365group-user-remove.mdx} +5 -5
- package/docs/docs/cmd/aad/{o365group/o365group-user-set.mdx → m365group/m365group-user-set.mdx} +5 -5
- package/docs/docs/cmd/aad/policy/policy-list.mdx +5 -5
- package/docs/docs/cmd/aad/user/user-set.mdx +1 -1
- package/docs/docs/cmd/cli/config/config-list.mdx +78 -0
- package/docs/docs/cmd/flow/flow-enable.mdx +2 -2
- package/docs/docs/cmd/flow/flow-export.mdx +11 -11
- package/docs/docs/cmd/graph/subscription/subscription-add.mdx +10 -10
- package/docs/docs/cmd/login.mdx +6 -0
- package/docs/docs/cmd/pa/app/app-export.mdx +5 -5
- package/docs/docs/cmd/pa/app/app-permission-ensure.mdx +85 -0
- package/docs/docs/cmd/pa/app/app-permission-remove.mdx +74 -0
- package/docs/docs/cmd/pa/connector/connector-export.mdx +3 -3
- package/docs/docs/cmd/planner/plan/plan-add.mdx +1 -1
- package/docs/docs/cmd/planner/task/task-add.mdx +22 -7
- package/docs/docs/cmd/planner/task/task-get.mdx +13 -4
- package/docs/docs/cmd/planner/task/task-list.mdx +22 -7
- package/docs/docs/cmd/planner/task/task-remove.mdx +25 -8
- package/docs/docs/cmd/planner/task/task-set.mdx +22 -7
- package/docs/docs/cmd/pp/chatbot/chatbot-list.mdx +4 -4
- package/docs/docs/cmd/pp/dataverse/dataverse-table-get.mdx +2 -2
- package/docs/docs/cmd/pp/dataverse/dataverse-table-list.mdx +2 -2
- package/docs/docs/cmd/pp/dataverse/dataverse-table-remove.mdx +3 -3
- package/docs/docs/cmd/pp/solution/solution-publisher-get.mdx +2 -2
- package/docs/docs/cmd/pp/solution/solution-publisher-remove.mdx +2 -2
- package/docs/docs/cmd/spfx/project/project-github-workflow-add.mdx +94 -0
- package/docs/docs/cmd/spfx/project/project-upgrade.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-add.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-checkin.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-checkout-undo.mdx +1 -9
- package/docs/docs/cmd/spo/file/file-checkout.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-copy.mdx +20 -16
- package/docs/docs/cmd/spo/file/file-get.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-list.mdx +2 -2
- package/docs/docs/cmd/spo/file/file-move.mdx +36 -18
- package/docs/docs/cmd/spo/file/file-remove.mdx +10 -10
- package/docs/docs/cmd/spo/file/file-rename.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-retentionlabel-ensure.mdx +2 -2
- package/docs/docs/cmd/spo/file/file-retentionlabel-remove.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-roleassignment-add.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-roleassignment-remove.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-roleinheritance-break.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-roleinheritance-reset.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinginfo-get.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-add.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-clear.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-get.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-list.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-remove.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-sharinglink-set.mdx +1 -1
- package/docs/docs/cmd/spo/file/file-version-clear.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-version-get.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-version-list.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-version-remove.mdx +3 -3
- package/docs/docs/cmd/spo/file/file-version-restore.mdx +3 -3
- package/docs/docs/cmd/spo/folder/folder-add.mdx +76 -1
- package/docs/docs/cmd/spo/folder/folder-copy.mdx +39 -12
- package/docs/docs/cmd/spo/folder/folder-get.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-list.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-move.mdx +40 -13
- package/docs/docs/cmd/spo/folder/folder-remove.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-rename.mdx +5 -1
- package/docs/docs/cmd/spo/folder/folder-retentionlabel-ensure.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-retentionlabel-remove.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-roleassignment-add.mdx +2 -2
- package/docs/docs/cmd/spo/folder/folder-roleassignment-remove.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-roleinheritance-break.mdx +1 -1
- package/docs/docs/cmd/spo/folder/folder-roleinheritance-reset.mdx +1 -1
- package/docs/docs/cmd/spo/group/group-member-add.mdx +27 -27
- package/docs/docs/cmd/spo/list/list-contenttype-remove.mdx +1 -1
- package/docs/docs/cmd/spo/list/list-retentionlabel-ensure.mdx +2 -11
- package/docs/docs/cmd/spo/listitem/listitem-add.mdx +2 -5
- package/docs/docs/cmd/spo/listitem/listitem-attachment-add.mdx +110 -0
- package/docs/docs/cmd/spo/listitem/listitem-attachment-get.mdx +104 -0
- package/docs/docs/cmd/spo/listitem/listitem-attachment-list.mdx +1 -1
- package/docs/docs/cmd/spo/listitem/listitem-attachment-remove.mdx +58 -0
- package/docs/docs/cmd/spo/listitem/listitem-attachment-set.mdx +58 -0
- package/docs/docs/cmd/spo/listitem/listitem-set.mdx +2 -5
- package/docs/docs/cmd/spo/orgassetslibrary/orgassetslibrary-add.mdx +14 -1
- package/docs/docs/cmd/spo/page/page-get.mdx +0 -1
- package/docs/docs/cmd/spo/page/page-list.mdx +0 -1
- package/docs/docs/cmd/spo/page/page-section-add.mdx +25 -1
- package/docs/docs/cmd/spo/page/page-set.mdx +23 -0
- package/docs/docs/cmd/spo/site/site-add.mdx +1 -1
- package/docs/docs/cmd/spo/site/site-commsite-enable.mdx +11 -2
- package/docs/docs/cmd/spo/site/site-ensure.mdx +1 -1
- package/docs/docs/cmd/spo/site/site-list.mdx +3 -78
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-add.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-get.mdx +2 -2
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-list.mdx +3 -5
- package/docs/docs/cmd/spo/tenant/tenant-applicationcustomizer-remove.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-add.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-list.mdx +2 -4
- package/docs/docs/cmd/spo/tenant/tenant-commandset-remove.mdx +1 -1
- package/docs/docs/cmd/spo/tenant/tenant-commandset-set.mdx +1 -1
- package/docs/docs/cmd/spo/user/user-get.mdx +8 -8
- package/docs/docs/cmd/teams/app/app-remove.mdx +9 -6
- package/docs/docs/cmd/teams/channel/channel-member-add.mdx +4 -4
- package/docs/docs/cmd/teams/meeting/meeting-list.mdx +135 -92
- package/docs/docs/cmd/teams/team/team-add.mdx +1 -1
- package/docs/docs/cmd/teams/team/team-clone.mdx +3 -3
- package/docs/docs/cmd/teams/team/team-list.mdx +47 -22
- package/docs/docs/cmd/tenant/info/info-get.mdx +101 -0
- package/docs/docs/cmd/yammer/network/network-list.mdx +1 -1
- package/npm-shrinkwrap.json +310 -1433
- package/package.json +23 -28
- package/dist/m365/pa/cds-project-mutator.js +0 -91
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/generated/ManifestTypes.d.ts +0 -11
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/template_ControlManifest.Input.xml +0 -31
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/dataset-template/template_index.ts +0 -51
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/generated/ManifestTypes.d.ts +0 -12
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/template_ControlManifest.Input.xml +0 -37
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/field-template/template_index.ts +0 -48
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/index.ts +0 -0
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-dataset-template/template_ControlManifest.Input.xml +0 -31
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-dataset-template/template_index.tsx +0 -58
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-field-template/template_ControlManifest.Input.xml +0 -37
- package/dist/m365/pa/commands/pcf/pcf-init/assets/control/virtual-field-template/template_index.tsx +0 -55
- package/dist/m365/pa/commands/pcf/pcf-init/assets/package.json +0 -19
- package/dist/m365/pa/commands/pcf/pcf-init/assets/pcfconfig.json +0 -3
- package/dist/m365/pa/commands/pcf/pcf-init/assets/template_.gitignore +0 -14
- package/dist/m365/pa/commands/pcf/pcf-init/assets/template_pcfprojecttype.pcfproj +0 -45
- package/dist/m365/pa/commands/pcf/pcf-init/pcf-init-variables.js +0 -2
- package/dist/m365/pa/commands/pcf/pcf-init.js +0 -120
- package/dist/m365/pa/commands/solution/solution-init/assets/Other/Customizations.xml +0 -18
- package/dist/m365/pa/commands/solution/solution-init/assets/Other/Relationships.xml +0 -2
- package/dist/m365/pa/commands/solution/solution-init/assets/Other/template_Solution.xml +0 -94
- package/dist/m365/pa/commands/solution/solution-init/assets/template_.gitignore +0 -2
- package/dist/m365/pa/commands/solution/solution-init/assets/template_solutionprojecttype.cdsproj +0 -44
- package/dist/m365/pa/commands/solution/solution-init/solution-init-variables.js +0 -2
- package/dist/m365/pa/commands/solution/solution-init.js +0 -126
- package/dist/m365/pa/commands/solution/solution-reference-add.js +0 -88
- package/dist/m365/pa/template-instantiator.js +0 -57
- package/docs/docs/cmd/pa/pcf/pcf-init.mdx +0 -56
- package/docs/docs/cmd/pa/solution/solution-init.mdx +0 -46
- package/docs/docs/cmd/pa/solution/solution-reference-add.mdx +0 -42
- /package/dist/m365/aad/commands/{o365group → m365group}/GroupExtended.js +0 -0
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskChecklistItemRemoveCommand_instances, _PlannerTaskChecklistItemRemoveCommand_initTelemetry, _PlannerTaskChecklistItemRemoveCommand_initOptions;
|
|
6
|
+
var _PlannerTaskChecklistItemRemoveCommand_instances, _PlannerTaskChecklistItemRemoveCommand_initTelemetry, _PlannerTaskChecklistItemRemoveCommand_initOptions, _PlannerTaskChecklistItemRemoveCommand_initTypes;
|
|
7
7
|
import { Cli } from '../../../../cli/Cli.js';
|
|
8
8
|
import request from '../../../../request.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
@@ -21,6 +21,7 @@ class PlannerTaskChecklistItemRemoveCommand extends GraphCommand {
|
|
|
21
21
|
_PlannerTaskChecklistItemRemoveCommand_instances.add(this);
|
|
22
22
|
__classPrivateFieldGet(this, _PlannerTaskChecklistItemRemoveCommand_instances, "m", _PlannerTaskChecklistItemRemoveCommand_initTelemetry).call(this);
|
|
23
23
|
__classPrivateFieldGet(this, _PlannerTaskChecklistItemRemoveCommand_instances, "m", _PlannerTaskChecklistItemRemoveCommand_initOptions).call(this);
|
|
24
|
+
__classPrivateFieldGet(this, _PlannerTaskChecklistItemRemoveCommand_instances, "m", _PlannerTaskChecklistItemRemoveCommand_initTypes).call(this);
|
|
24
25
|
}
|
|
25
26
|
async commandAction(logger, args) {
|
|
26
27
|
if (args.options.force) {
|
|
@@ -83,6 +84,8 @@ _PlannerTaskChecklistItemRemoveCommand_instances = new WeakSet(), _PlannerTaskCh
|
|
|
83
84
|
});
|
|
84
85
|
}, _PlannerTaskChecklistItemRemoveCommand_initOptions = function _PlannerTaskChecklistItemRemoveCommand_initOptions() {
|
|
85
86
|
this.options.unshift({ option: '-i, --id <id>' }, { option: '--taskId <taskId>' }, { option: '-f, --force' });
|
|
87
|
+
}, _PlannerTaskChecklistItemRemoveCommand_initTypes = function _PlannerTaskChecklistItemRemoveCommand_initTypes() {
|
|
88
|
+
this.types.string.push('id', 'taskId');
|
|
86
89
|
};
|
|
87
90
|
export default new PlannerTaskChecklistItemRemoveCommand();
|
|
88
91
|
//# sourceMappingURL=task-checklistitem-remove.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskGetCommand_instances, _PlannerTaskGetCommand_initTelemetry, _PlannerTaskGetCommand_initOptions, _PlannerTaskGetCommand_initValidators, _PlannerTaskGetCommand_initOptionSets;
|
|
6
|
+
var _PlannerTaskGetCommand_instances, _PlannerTaskGetCommand_initTelemetry, _PlannerTaskGetCommand_initOptions, _PlannerTaskGetCommand_initValidators, _PlannerTaskGetCommand_initOptionSets, _PlannerTaskGetCommand_initTypes;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { aadGroup } from '../../../../utils/aadGroup.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
@@ -11,6 +11,7 @@ import { planner } from '../../../../utils/planner.js';
|
|
|
11
11
|
import { validation } from '../../../../utils/validation.js';
|
|
12
12
|
import GraphCommand from '../../../base/GraphCommand.js';
|
|
13
13
|
import commands from '../../commands.js';
|
|
14
|
+
import { Cli } from '../../../../cli/Cli.js';
|
|
14
15
|
class PlannerTaskGetCommand extends GraphCommand {
|
|
15
16
|
get name() {
|
|
16
17
|
return commands.TASK_GET;
|
|
@@ -25,6 +26,7 @@ class PlannerTaskGetCommand extends GraphCommand {
|
|
|
25
26
|
__classPrivateFieldGet(this, _PlannerTaskGetCommand_instances, "m", _PlannerTaskGetCommand_initOptions).call(this);
|
|
26
27
|
__classPrivateFieldGet(this, _PlannerTaskGetCommand_instances, "m", _PlannerTaskGetCommand_initValidators).call(this);
|
|
27
28
|
__classPrivateFieldGet(this, _PlannerTaskGetCommand_instances, "m", _PlannerTaskGetCommand_initOptionSets).call(this);
|
|
29
|
+
__classPrivateFieldGet(this, _PlannerTaskGetCommand_instances, "m", _PlannerTaskGetCommand_initTypes).call(this);
|
|
28
30
|
}
|
|
29
31
|
async commandAction(logger, args) {
|
|
30
32
|
try {
|
|
@@ -78,7 +80,9 @@ class PlannerTaskGetCommand extends GraphCommand {
|
|
|
78
80
|
throw `The specified task ${options.title} does not exist`;
|
|
79
81
|
}
|
|
80
82
|
if (tasks.length > 1) {
|
|
81
|
-
|
|
83
|
+
const resultAsKeyValuePair = formatting.convertArrayToHashTable('id', tasks);
|
|
84
|
+
const result = (await Cli.handleMultipleResultsFound(`Multiple tasks with title '${options.title}' found.`, resultAsKeyValuePair));
|
|
85
|
+
return result.id;
|
|
82
86
|
}
|
|
83
87
|
return tasks[0].id;
|
|
84
88
|
}
|
|
@@ -101,7 +105,9 @@ class PlannerTaskGetCommand extends GraphCommand {
|
|
|
101
105
|
throw `The specified bucket ${options.bucketName} does not exist`;
|
|
102
106
|
}
|
|
103
107
|
if (buckets.length > 1) {
|
|
104
|
-
|
|
108
|
+
const resultAsKeyValuePair = formatting.convertArrayToHashTable('id', buckets);
|
|
109
|
+
const result = await Cli.handleMultipleResultsFound(`Multiple buckets with name '${options.bucketName}' found.`, resultAsKeyValuePair);
|
|
110
|
+
return result.id;
|
|
105
111
|
}
|
|
106
112
|
return buckets[0].id;
|
|
107
113
|
}
|
|
@@ -109,9 +115,15 @@ class PlannerTaskGetCommand extends GraphCommand {
|
|
|
109
115
|
if (options.planId) {
|
|
110
116
|
return options.planId;
|
|
111
117
|
}
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
118
|
+
if (options.rosterId) {
|
|
119
|
+
const plan = await planner.getPlanByRosterId(options.rosterId);
|
|
120
|
+
return plan.id;
|
|
121
|
+
}
|
|
122
|
+
else {
|
|
123
|
+
const groupId = await this.getGroupId(options);
|
|
124
|
+
const plan = await planner.getPlanByTitle(options.planTitle, groupId);
|
|
125
|
+
return plan.id;
|
|
126
|
+
}
|
|
115
127
|
}
|
|
116
128
|
async getGroupId(options) {
|
|
117
129
|
if (options.ownerGroupId) {
|
|
@@ -129,46 +141,52 @@ _PlannerTaskGetCommand_instances = new WeakSet(), _PlannerTaskGetCommand_initTel
|
|
|
129
141
|
bucketId: typeof args.options.bucketId !== 'undefined',
|
|
130
142
|
bucketName: typeof args.options.bucketName !== 'undefined',
|
|
131
143
|
planId: typeof args.options.planId !== 'undefined',
|
|
144
|
+
planTitle: typeof args.options.planTitle !== 'undefined',
|
|
145
|
+
rosterId: typeof args.options.rosterId !== 'undefined',
|
|
132
146
|
ownerGroupId: typeof args.options.ownerGroupId !== 'undefined',
|
|
133
147
|
ownerGroupName: typeof args.options.ownerGroupName !== 'undefined'
|
|
134
148
|
});
|
|
135
149
|
});
|
|
136
150
|
}, _PlannerTaskGetCommand_initOptions = function _PlannerTaskGetCommand_initOptions() {
|
|
137
|
-
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' });
|
|
151
|
+
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--rosterId [rosterId]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' });
|
|
138
152
|
}, _PlannerTaskGetCommand_initValidators = function _PlannerTaskGetCommand_initValidators() {
|
|
139
153
|
this.validators.push(async (args) => {
|
|
140
154
|
if (args.options.id) {
|
|
141
155
|
if (args.options.bucketId || args.options.bucketName ||
|
|
142
|
-
args.options.planId || args.options.
|
|
156
|
+
args.options.planId || args.options.planTitle || args.options.rosterId ||
|
|
143
157
|
args.options.ownerGroupId || args.options.ownerGroupName) {
|
|
144
|
-
return 'Don\'t specify bucketId, bucketName, planId, planTitle, ownerGroupId or ownerGroupName when using id';
|
|
158
|
+
return 'Don\'t specify bucketId, bucketName, planId, planTitle, rosterId, ownerGroupId or ownerGroupName when using id';
|
|
145
159
|
}
|
|
146
160
|
}
|
|
147
|
-
if (args.options.title && !args.options.bucketId && !args.options.bucketName) {
|
|
148
|
-
return 'Specify either bucketId or bucketName when using title';
|
|
149
|
-
}
|
|
150
|
-
if (args.options.title && args.options.bucketId && args.options.bucketName) {
|
|
151
|
-
return 'Specify either bucketId or bucketName when using title but not both';
|
|
152
|
-
}
|
|
153
|
-
if (args.options.bucketName && !args.options.planId && !args.options.planTitle) {
|
|
154
|
-
return 'Specify either planId or planTitle when using bucketName';
|
|
155
|
-
}
|
|
156
|
-
if (args.options.bucketName && args.options.planId && args.options.planTitle) {
|
|
157
|
-
return 'Specify either planId or planTitle when using bucketName but not both';
|
|
158
|
-
}
|
|
159
|
-
if (args.options.planTitle && !args.options.ownerGroupId && !args.options.ownerGroupName) {
|
|
160
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle';
|
|
161
|
-
}
|
|
162
|
-
if (args.options.planTitle && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
163
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle but not both';
|
|
164
|
-
}
|
|
165
161
|
if (args.options.ownerGroupId && !validation.isValidGuid(args.options.ownerGroupId)) {
|
|
166
162
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
167
163
|
}
|
|
168
164
|
return true;
|
|
169
165
|
});
|
|
170
166
|
}, _PlannerTaskGetCommand_initOptionSets = function _PlannerTaskGetCommand_initOptionSets() {
|
|
171
|
-
this.optionSets.push({ options: ['id', 'title'] }
|
|
167
|
+
this.optionSets.push({ options: ['id', 'title'] }, {
|
|
168
|
+
options: ['planId', 'planTitle', 'rosterId'],
|
|
169
|
+
runsWhen: (args) => {
|
|
170
|
+
return args.options.id === undefined;
|
|
171
|
+
}
|
|
172
|
+
}, {
|
|
173
|
+
options: ['bucketId', 'bucketName'],
|
|
174
|
+
runsWhen: (args) => {
|
|
175
|
+
return args.options.title !== undefined;
|
|
176
|
+
}
|
|
177
|
+
}, {
|
|
178
|
+
options: ['planId', 'planTitle'],
|
|
179
|
+
runsWhen: (args) => {
|
|
180
|
+
return args.options.bucketName !== undefined && args.options.rosterId === undefined;
|
|
181
|
+
}
|
|
182
|
+
}, {
|
|
183
|
+
options: ['ownerGroupId', 'ownerGroupName'],
|
|
184
|
+
runsWhen: (args) => {
|
|
185
|
+
return args.options.planTitle !== undefined;
|
|
186
|
+
}
|
|
187
|
+
});
|
|
188
|
+
}, _PlannerTaskGetCommand_initTypes = function _PlannerTaskGetCommand_initTypes() {
|
|
189
|
+
this.types.string.push('id', 'title', 'planId', 'planTitle', 'ownerGroupId', 'ownerGroupName', 'bucketId', 'bucketName', 'rosterId');
|
|
172
190
|
};
|
|
173
191
|
export default new PlannerTaskGetCommand();
|
|
174
192
|
//# sourceMappingURL=task-get.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskListCommand_instances, _PlannerTaskListCommand_initTelemetry, _PlannerTaskListCommand_initOptions, _PlannerTaskListCommand_initValidators;
|
|
6
|
+
var _PlannerTaskListCommand_instances, _PlannerTaskListCommand_initTelemetry, _PlannerTaskListCommand_initOptions, _PlannerTaskListCommand_initValidators, _PlannerTaskListCommand_initOptionSets, _PlannerTaskListCommand_initTypes;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { aadGroup } from '../../../../utils/aadGroup.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
@@ -28,6 +28,8 @@ class PlannerTaskListCommand extends GraphCommand {
|
|
|
28
28
|
__classPrivateFieldGet(this, _PlannerTaskListCommand_instances, "m", _PlannerTaskListCommand_initTelemetry).call(this);
|
|
29
29
|
__classPrivateFieldGet(this, _PlannerTaskListCommand_instances, "m", _PlannerTaskListCommand_initOptions).call(this);
|
|
30
30
|
__classPrivateFieldGet(this, _PlannerTaskListCommand_instances, "m", _PlannerTaskListCommand_initValidators).call(this);
|
|
31
|
+
__classPrivateFieldGet(this, _PlannerTaskListCommand_instances, "m", _PlannerTaskListCommand_initOptionSets).call(this);
|
|
32
|
+
__classPrivateFieldGet(this, _PlannerTaskListCommand_instances, "m", _PlannerTaskListCommand_initTypes).call(this);
|
|
31
33
|
}
|
|
32
34
|
async commandAction(logger, args) {
|
|
33
35
|
const bucketName = args.options.bucketName;
|
|
@@ -91,9 +93,15 @@ class PlannerTaskListCommand extends GraphCommand {
|
|
|
91
93
|
if (args.options.planId) {
|
|
92
94
|
return formatting.encodeQueryParameter(args.options.planId);
|
|
93
95
|
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
96
|
+
if (args.options.rosterId) {
|
|
97
|
+
const plan = await planner.getPlanByRosterId(args.options.rosterId);
|
|
98
|
+
return plan.id;
|
|
99
|
+
}
|
|
100
|
+
else {
|
|
101
|
+
const groupId = await this.getGroupId(args);
|
|
102
|
+
const plan = await planner.getPlanByTitle(args.options.planTitle, groupId);
|
|
103
|
+
return plan.id;
|
|
104
|
+
}
|
|
97
105
|
}
|
|
98
106
|
async getGroupId(args) {
|
|
99
107
|
if (args.options.ownerGroupId) {
|
|
@@ -121,6 +129,7 @@ _PlannerTaskListCommand_instances = new WeakSet(), _PlannerTaskListCommand_initT
|
|
|
121
129
|
bucketName: typeof args.options.bucketName !== 'undefined',
|
|
122
130
|
planId: typeof args.options.planId !== 'undefined',
|
|
123
131
|
planTitle: typeof args.options.planTitle !== 'undefined',
|
|
132
|
+
rosterId: typeof args.options.rosterId !== 'undefined',
|
|
124
133
|
ownerGroupId: typeof args.options.ownerGroupId !== 'undefined',
|
|
125
134
|
ownerGroupName: typeof args.options.ownerGroupName !== 'undefined'
|
|
126
135
|
});
|
|
@@ -134,6 +143,8 @@ _PlannerTaskListCommand_instances = new WeakSet(), _PlannerTaskListCommand_initT
|
|
|
134
143
|
option: '--planId [planId]'
|
|
135
144
|
}, {
|
|
136
145
|
option: '--planTitle [planTitle]'
|
|
146
|
+
}, {
|
|
147
|
+
option: '--rosterId [rosterId]'
|
|
137
148
|
}, {
|
|
138
149
|
option: '--ownerGroupId [ownerGroupId]'
|
|
139
150
|
}, {
|
|
@@ -141,26 +152,30 @@ _PlannerTaskListCommand_instances = new WeakSet(), _PlannerTaskListCommand_initT
|
|
|
141
152
|
});
|
|
142
153
|
}, _PlannerTaskListCommand_initValidators = function _PlannerTaskListCommand_initValidators() {
|
|
143
154
|
this.validators.push(async (args) => {
|
|
144
|
-
if (args.options.bucketId && args.options.bucketName) {
|
|
145
|
-
return 'To retrieve tasks from a bucket, specify bucketId or bucketName, but not both';
|
|
146
|
-
}
|
|
147
|
-
if (args.options.bucketName && !args.options.planId && !args.options.planTitle) {
|
|
148
|
-
return 'Specify either planId or planTitle when using bucketName';
|
|
149
|
-
}
|
|
150
|
-
if (args.options.planId && args.options.planTitle) {
|
|
151
|
-
return 'Specify either planId or planTitle but not both';
|
|
152
|
-
}
|
|
153
|
-
if (args.options.planTitle && !args.options.ownerGroupId && !args.options.ownerGroupName) {
|
|
154
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle';
|
|
155
|
-
}
|
|
156
|
-
if (args.options.planTitle && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
157
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle but not both';
|
|
158
|
-
}
|
|
159
155
|
if (args.options.ownerGroupId && !validation.isValidGuid(args.options.ownerGroupId)) {
|
|
160
156
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
161
157
|
}
|
|
162
158
|
return true;
|
|
163
159
|
});
|
|
160
|
+
}, _PlannerTaskListCommand_initOptionSets = function _PlannerTaskListCommand_initOptionSets() {
|
|
161
|
+
this.optionSets.push({
|
|
162
|
+
options: ['bucketId', 'bucketName'],
|
|
163
|
+
runsWhen: (args) => {
|
|
164
|
+
return args.options.bucketId !== undefined || args.options.bucketName !== undefined;
|
|
165
|
+
}
|
|
166
|
+
}, {
|
|
167
|
+
options: ['planId', 'planTitle'],
|
|
168
|
+
runsWhen: (args) => {
|
|
169
|
+
return args.options.bucketName !== undefined && args.options.rosterId === undefined;
|
|
170
|
+
}
|
|
171
|
+
}, {
|
|
172
|
+
options: ['ownerGroupId', 'ownerGroupName'],
|
|
173
|
+
runsWhen: (args) => {
|
|
174
|
+
return args.options.planTitle !== undefined;
|
|
175
|
+
}
|
|
176
|
+
});
|
|
177
|
+
}, _PlannerTaskListCommand_initTypes = function _PlannerTaskListCommand_initTypes() {
|
|
178
|
+
this.types.string.push('planId', 'planTitle', 'ownerGroupId', 'ownerGroupName', 'bucketId', 'bucketName', 'rosterId');
|
|
164
179
|
};
|
|
165
180
|
export default new PlannerTaskListCommand();
|
|
166
181
|
//# sourceMappingURL=task-list.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskReferenceAddCommand_instances, _PlannerTaskReferenceAddCommand_initTelemetry, _PlannerTaskReferenceAddCommand_initOptions, _PlannerTaskReferenceAddCommand_initValidators;
|
|
6
|
+
var _PlannerTaskReferenceAddCommand_instances, _PlannerTaskReferenceAddCommand_initTelemetry, _PlannerTaskReferenceAddCommand_initOptions, _PlannerTaskReferenceAddCommand_initValidators, _PlannerTaskReferenceAddCommand_initTypes;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { formatting } from '../../../../utils/formatting.js';
|
|
9
9
|
import GraphCommand from '../../../base/GraphCommand.js';
|
|
@@ -21,6 +21,7 @@ class PlannerTaskReferenceAddCommand extends GraphCommand {
|
|
|
21
21
|
__classPrivateFieldGet(this, _PlannerTaskReferenceAddCommand_instances, "m", _PlannerTaskReferenceAddCommand_initTelemetry).call(this);
|
|
22
22
|
__classPrivateFieldGet(this, _PlannerTaskReferenceAddCommand_instances, "m", _PlannerTaskReferenceAddCommand_initOptions).call(this);
|
|
23
23
|
__classPrivateFieldGet(this, _PlannerTaskReferenceAddCommand_instances, "m", _PlannerTaskReferenceAddCommand_initValidators).call(this);
|
|
24
|
+
__classPrivateFieldGet(this, _PlannerTaskReferenceAddCommand_instances, "m", _PlannerTaskReferenceAddCommand_initTypes).call(this);
|
|
24
25
|
}
|
|
25
26
|
async commandAction(logger, args) {
|
|
26
27
|
try {
|
|
@@ -82,6 +83,8 @@ _PlannerTaskReferenceAddCommand_instances = new WeakSet(), _PlannerTaskReference
|
|
|
82
83
|
}
|
|
83
84
|
return true;
|
|
84
85
|
});
|
|
86
|
+
}, _PlannerTaskReferenceAddCommand_initTypes = function _PlannerTaskReferenceAddCommand_initTypes() {
|
|
87
|
+
this.types.string.push('taskId', 'url', 'alias', 'type');
|
|
85
88
|
};
|
|
86
89
|
export default new PlannerTaskReferenceAddCommand();
|
|
87
90
|
//# sourceMappingURL=task-reference-add.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskReferenceListCommand_instances, _PlannerTaskReferenceListCommand_initOptions;
|
|
6
|
+
var _PlannerTaskReferenceListCommand_instances, _PlannerTaskReferenceListCommand_initOptions, _PlannerTaskReferenceListCommand_initTypes;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { formatting } from '../../../../utils/formatting.js';
|
|
9
9
|
import GraphCommand from '../../../base/GraphCommand.js';
|
|
@@ -19,6 +19,7 @@ class PlannerTaskReferenceListCommand extends GraphCommand {
|
|
|
19
19
|
super();
|
|
20
20
|
_PlannerTaskReferenceListCommand_instances.add(this);
|
|
21
21
|
__classPrivateFieldGet(this, _PlannerTaskReferenceListCommand_instances, "m", _PlannerTaskReferenceListCommand_initOptions).call(this);
|
|
22
|
+
__classPrivateFieldGet(this, _PlannerTaskReferenceListCommand_instances, "m", _PlannerTaskReferenceListCommand_initTypes).call(this);
|
|
22
23
|
}
|
|
23
24
|
async commandAction(logger, args) {
|
|
24
25
|
const requestOptions = {
|
|
@@ -41,6 +42,8 @@ _PlannerTaskReferenceListCommand_instances = new WeakSet(), _PlannerTaskReferenc
|
|
|
41
42
|
this.options.unshift({
|
|
42
43
|
option: '-i, --taskId <taskId>'
|
|
43
44
|
});
|
|
45
|
+
}, _PlannerTaskReferenceListCommand_initTypes = function _PlannerTaskReferenceListCommand_initTypes() {
|
|
46
|
+
this.types.string.push('taskId');
|
|
44
47
|
};
|
|
45
48
|
export default new PlannerTaskReferenceListCommand();
|
|
46
49
|
//# sourceMappingURL=task-reference-list.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskReferenceRemoveCommand_instances, _PlannerTaskReferenceRemoveCommand_initTelemetry, _PlannerTaskReferenceRemoveCommand_initOptions, _PlannerTaskReferenceRemoveCommand_initValidators, _PlannerTaskReferenceRemoveCommand_initOptionSets;
|
|
6
|
+
var _PlannerTaskReferenceRemoveCommand_instances, _PlannerTaskReferenceRemoveCommand_initTelemetry, _PlannerTaskReferenceRemoveCommand_initOptions, _PlannerTaskReferenceRemoveCommand_initValidators, _PlannerTaskReferenceRemoveCommand_initOptionSets, _PlannerTaskReferenceRemoveCommand_initTypes;
|
|
7
7
|
import { Cli } from '../../../../cli/Cli.js';
|
|
8
8
|
import request from '../../../../request.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
@@ -23,6 +23,7 @@ class PlannerTaskReferenceRemoveCommand extends GraphCommand {
|
|
|
23
23
|
__classPrivateFieldGet(this, _PlannerTaskReferenceRemoveCommand_instances, "m", _PlannerTaskReferenceRemoveCommand_initOptions).call(this);
|
|
24
24
|
__classPrivateFieldGet(this, _PlannerTaskReferenceRemoveCommand_instances, "m", _PlannerTaskReferenceRemoveCommand_initValidators).call(this);
|
|
25
25
|
__classPrivateFieldGet(this, _PlannerTaskReferenceRemoveCommand_instances, "m", _PlannerTaskReferenceRemoveCommand_initOptionSets).call(this);
|
|
26
|
+
__classPrivateFieldGet(this, _PlannerTaskReferenceRemoveCommand_instances, "m", _PlannerTaskReferenceRemoveCommand_initTypes).call(this);
|
|
26
27
|
}
|
|
27
28
|
async commandAction(logger, args) {
|
|
28
29
|
if (args.options.force) {
|
|
@@ -112,6 +113,8 @@ _PlannerTaskReferenceRemoveCommand_instances = new WeakSet(), _PlannerTaskRefere
|
|
|
112
113
|
});
|
|
113
114
|
}, _PlannerTaskReferenceRemoveCommand_initOptionSets = function _PlannerTaskReferenceRemoveCommand_initOptionSets() {
|
|
114
115
|
this.optionSets.push({ options: ['url', 'alias'] });
|
|
116
|
+
}, _PlannerTaskReferenceRemoveCommand_initTypes = function _PlannerTaskReferenceRemoveCommand_initTypes() {
|
|
117
|
+
this.types.string.push('url', 'taskId', 'alias');
|
|
115
118
|
};
|
|
116
119
|
export default new PlannerTaskReferenceRemoveCommand();
|
|
117
120
|
//# sourceMappingURL=task-reference-remove.js.map
|
|
@@ -3,8 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskRemoveCommand_instances, _PlannerTaskRemoveCommand_initTelemetry, _PlannerTaskRemoveCommand_initOptions, _PlannerTaskRemoveCommand_initValidators, _PlannerTaskRemoveCommand_initOptionSets;
|
|
7
|
-
import os from 'os';
|
|
6
|
+
var _PlannerTaskRemoveCommand_instances, _PlannerTaskRemoveCommand_initTelemetry, _PlannerTaskRemoveCommand_initOptions, _PlannerTaskRemoveCommand_initValidators, _PlannerTaskRemoveCommand_initOptionSets, _PlannerTaskRemoveCommand_initTypes;
|
|
8
7
|
import { Cli } from '../../../../cli/Cli.js';
|
|
9
8
|
import request from '../../../../request.js';
|
|
10
9
|
import { aadGroup } from '../../../../utils/aadGroup.js';
|
|
@@ -13,6 +12,7 @@ import { planner } from '../../../../utils/planner.js';
|
|
|
13
12
|
import { validation } from '../../../../utils/validation.js';
|
|
14
13
|
import GraphCommand from '../../../base/GraphCommand.js';
|
|
15
14
|
import commands from '../../commands.js';
|
|
15
|
+
import { formatting } from '../../../../utils/formatting.js';
|
|
16
16
|
class PlannerTaskRemoveCommand extends GraphCommand {
|
|
17
17
|
get name() {
|
|
18
18
|
return commands.TASK_REMOVE;
|
|
@@ -27,6 +27,7 @@ class PlannerTaskRemoveCommand extends GraphCommand {
|
|
|
27
27
|
__classPrivateFieldGet(this, _PlannerTaskRemoveCommand_instances, "m", _PlannerTaskRemoveCommand_initOptions).call(this);
|
|
28
28
|
__classPrivateFieldGet(this, _PlannerTaskRemoveCommand_instances, "m", _PlannerTaskRemoveCommand_initValidators).call(this);
|
|
29
29
|
__classPrivateFieldGet(this, _PlannerTaskRemoveCommand_instances, "m", _PlannerTaskRemoveCommand_initOptionSets).call(this);
|
|
30
|
+
__classPrivateFieldGet(this, _PlannerTaskRemoveCommand_instances, "m", _PlannerTaskRemoveCommand_initTypes).call(this);
|
|
30
31
|
}
|
|
31
32
|
async commandAction(logger, args) {
|
|
32
33
|
const removeTask = async () => {
|
|
@@ -81,7 +82,8 @@ class PlannerTaskRemoveCommand extends GraphCommand {
|
|
|
81
82
|
throw `The specified task ${title} does not exist`;
|
|
82
83
|
}
|
|
83
84
|
if (filteredtasks.length > 1) {
|
|
84
|
-
|
|
85
|
+
const resultAsKeyValuePair = formatting.convertArrayToHashTable('id', filteredtasks);
|
|
86
|
+
return await Cli.handleMultipleResultsFound(`Multiple tasks with title '${title}' found.`, resultAsKeyValuePair);
|
|
85
87
|
}
|
|
86
88
|
return filteredtasks[0];
|
|
87
89
|
}
|
|
@@ -104,18 +106,26 @@ class PlannerTaskRemoveCommand extends GraphCommand {
|
|
|
104
106
|
throw `The specified bucket ${bucketName} does not exist`;
|
|
105
107
|
}
|
|
106
108
|
if (filteredBuckets.length > 1) {
|
|
107
|
-
|
|
109
|
+
const resultAsKeyValuePair = formatting.convertArrayToHashTable('id', filteredBuckets);
|
|
110
|
+
const result = await Cli.handleMultipleResultsFound(`Multiple buckets with name '${bucketName}' found.`, resultAsKeyValuePair);
|
|
111
|
+
return result.id;
|
|
108
112
|
}
|
|
109
113
|
return filteredBuckets[0].id;
|
|
110
114
|
}
|
|
111
115
|
async getPlanId(options) {
|
|
112
|
-
const { planId, planTitle } = options;
|
|
116
|
+
const { planId, planTitle, rosterId } = options;
|
|
113
117
|
if (planId) {
|
|
114
118
|
return planId;
|
|
115
119
|
}
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
120
|
+
if (options.rosterId) {
|
|
121
|
+
const plan = await planner.getPlanByRosterId(rosterId);
|
|
122
|
+
return plan.id;
|
|
123
|
+
}
|
|
124
|
+
else {
|
|
125
|
+
const groupId = await this.getGroupId(options);
|
|
126
|
+
const plan = await planner.getPlanByTitle(planTitle, groupId);
|
|
127
|
+
return plan.id;
|
|
128
|
+
}
|
|
119
129
|
}
|
|
120
130
|
async getGroupId(options) {
|
|
121
131
|
const { ownerGroupId, ownerGroupName } = options;
|
|
@@ -135,51 +145,52 @@ _PlannerTaskRemoveCommand_instances = new WeakSet(), _PlannerTaskRemoveCommand_i
|
|
|
135
145
|
bucketName: typeof args.options.bucketName !== 'undefined',
|
|
136
146
|
planId: typeof args.options.planId !== 'undefined',
|
|
137
147
|
planTitle: typeof args.options.planTitle !== 'undefined',
|
|
148
|
+
rosterId: typeof args.options.rosterId !== 'undefined',
|
|
138
149
|
ownerGroupId: typeof args.options.ownerGroupId !== 'undefined',
|
|
139
150
|
ownerGroupName: typeof args.options.ownerGroupName !== 'undefined',
|
|
140
151
|
force: !!args.options.force
|
|
141
152
|
});
|
|
142
153
|
});
|
|
143
154
|
}, _PlannerTaskRemoveCommand_initOptions = function _PlannerTaskRemoveCommand_initOptions() {
|
|
144
|
-
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' }, { option: '-f, --force' });
|
|
155
|
+
this.options.unshift({ option: '-i, --id [id]' }, { option: '-t, --title [title]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--rosterId [rosterId]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' }, { option: '-f, --force' });
|
|
145
156
|
}, _PlannerTaskRemoveCommand_initValidators = function _PlannerTaskRemoveCommand_initValidators() {
|
|
146
157
|
this.validators.push(async (args) => {
|
|
147
158
|
if (args.options.id) {
|
|
148
|
-
if (args.options.bucketId || args.options.bucketName ||
|
|
149
|
-
|
|
159
|
+
if (args.options.bucketId || args.options.bucketName ||
|
|
160
|
+
args.options.planId || args.options.planTitle || args.options.rosterId ||
|
|
161
|
+
args.options.ownerGroupId || args.options.ownerGroupName) {
|
|
162
|
+
return 'Don\'t specify bucketId,bucketName, planId, planTitle, rosterId, ownerGroupId, or ownerGroupName when using id';
|
|
150
163
|
}
|
|
151
164
|
}
|
|
152
|
-
if (args.options.
|
|
153
|
-
|
|
154
|
-
return 'Specify either bucketId or bucketName when using title';
|
|
155
|
-
}
|
|
156
|
-
if (args.options.bucketId && args.options.bucketName) {
|
|
157
|
-
return 'Specify either bucketId or bucketName when using title but not both';
|
|
158
|
-
}
|
|
159
|
-
if (args.options.bucketName) {
|
|
160
|
-
if (!args.options.planId && !args.options.planTitle) {
|
|
161
|
-
return 'Specify either planId or planTitle when using bucketName';
|
|
162
|
-
}
|
|
163
|
-
if (args.options.planId && args.options.planTitle) {
|
|
164
|
-
return 'Specify either planId or planTitle when using bucketName but not both';
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
if (args.options.planTitle) {
|
|
168
|
-
if (!args.options.ownerGroupId && !args.options.ownerGroupName) {
|
|
169
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle';
|
|
170
|
-
}
|
|
171
|
-
if (args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
172
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle but not both';
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
if (args.options.ownerGroupId && !validation.isValidGuid(args.options.ownerGroupId)) {
|
|
176
|
-
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
177
|
-
}
|
|
165
|
+
if (args.options.ownerGroupId && !validation.isValidGuid(args.options.ownerGroupId)) {
|
|
166
|
+
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
178
167
|
}
|
|
179
168
|
return true;
|
|
180
169
|
});
|
|
181
170
|
}, _PlannerTaskRemoveCommand_initOptionSets = function _PlannerTaskRemoveCommand_initOptionSets() {
|
|
182
|
-
this.optionSets.push({ options: ['id', 'title'] }
|
|
171
|
+
this.optionSets.push({ options: ['id', 'title'] }, {
|
|
172
|
+
options: ['planId', 'planTitle', 'rosterId'],
|
|
173
|
+
runsWhen: (args) => {
|
|
174
|
+
return args.options.id === undefined;
|
|
175
|
+
}
|
|
176
|
+
}, {
|
|
177
|
+
options: ['bucketId', 'bucketName'],
|
|
178
|
+
runsWhen: (args) => {
|
|
179
|
+
return args.options.title !== undefined;
|
|
180
|
+
}
|
|
181
|
+
}, {
|
|
182
|
+
options: ['planId', 'planTitle'],
|
|
183
|
+
runsWhen: (args) => {
|
|
184
|
+
return args.options.bucketName !== undefined && args.options.rosterId === undefined;
|
|
185
|
+
}
|
|
186
|
+
}, {
|
|
187
|
+
options: ['ownerGroupId', 'ownerGroupName'],
|
|
188
|
+
runsWhen: (args) => {
|
|
189
|
+
return args.options.planTitle !== undefined;
|
|
190
|
+
}
|
|
191
|
+
});
|
|
192
|
+
}, _PlannerTaskRemoveCommand_initTypes = function _PlannerTaskRemoveCommand_initTypes() {
|
|
193
|
+
this.types.string.push('id', 'title', 'planId', 'planTitle', 'ownerGroupId', 'ownerGroupName', 'bucketId', 'bucketName', 'rosterId');
|
|
183
194
|
};
|
|
184
195
|
export default new PlannerTaskRemoveCommand();
|
|
185
196
|
//# sourceMappingURL=task-remove.js.map
|
|
@@ -3,7 +3,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
3
3
|
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
|
-
var _PlannerTaskSetCommand_instances, _PlannerTaskSetCommand_initTelemetry, _PlannerTaskSetCommand_initOptions, _PlannerTaskSetCommand_initValidators;
|
|
6
|
+
var _PlannerTaskSetCommand_instances, _PlannerTaskSetCommand_initTelemetry, _PlannerTaskSetCommand_initOptions, _PlannerTaskSetCommand_initValidators, _PlannerTaskSetCommand_initOptionSets, _PlannerTaskSetCommand_initTypes;
|
|
7
7
|
import request from '../../../../request.js';
|
|
8
8
|
import { aadGroup } from '../../../../utils/aadGroup.js';
|
|
9
9
|
import { formatting } from '../../../../utils/formatting.js';
|
|
@@ -26,6 +26,8 @@ class PlannerTaskSetCommand extends GraphCommand {
|
|
|
26
26
|
__classPrivateFieldGet(this, _PlannerTaskSetCommand_instances, "m", _PlannerTaskSetCommand_initTelemetry).call(this);
|
|
27
27
|
__classPrivateFieldGet(this, _PlannerTaskSetCommand_instances, "m", _PlannerTaskSetCommand_initOptions).call(this);
|
|
28
28
|
__classPrivateFieldGet(this, _PlannerTaskSetCommand_instances, "m", _PlannerTaskSetCommand_initValidators).call(this);
|
|
29
|
+
__classPrivateFieldGet(this, _PlannerTaskSetCommand_instances, "m", _PlannerTaskSetCommand_initOptionSets).call(this);
|
|
30
|
+
__classPrivateFieldGet(this, _PlannerTaskSetCommand_instances, "m", _PlannerTaskSetCommand_initTypes).call(this);
|
|
29
31
|
}
|
|
30
32
|
async commandAction(logger, args) {
|
|
31
33
|
try {
|
|
@@ -170,9 +172,15 @@ class PlannerTaskSetCommand extends GraphCommand {
|
|
|
170
172
|
if (options.planId) {
|
|
171
173
|
return options.planId;
|
|
172
174
|
}
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
175
|
+
if (options.rosterId) {
|
|
176
|
+
const plan = await planner.getPlanByRosterId(options.rosterId);
|
|
177
|
+
return plan.id;
|
|
178
|
+
}
|
|
179
|
+
else {
|
|
180
|
+
const groupId = await this.getGroupId(options);
|
|
181
|
+
const plan = await planner.getPlanByTitle(options.planTitle, groupId);
|
|
182
|
+
return plan.id;
|
|
183
|
+
}
|
|
176
184
|
}
|
|
177
185
|
async getGroupId(options) {
|
|
178
186
|
if (options.ownerGroupId) {
|
|
@@ -222,6 +230,7 @@ _PlannerTaskSetCommand_instances = new WeakSet(), _PlannerTaskSetCommand_initTel
|
|
|
222
230
|
title: typeof args.options.title !== 'undefined',
|
|
223
231
|
planId: typeof args.options.planId !== 'undefined',
|
|
224
232
|
planTitle: typeof args.options.planTitle !== 'undefined',
|
|
233
|
+
rosterId: typeof args.options.rosterId !== 'undefined',
|
|
225
234
|
ownerGroupId: typeof args.options.ownerGroupId !== 'undefined',
|
|
226
235
|
ownerGroupName: typeof args.options.ownerGroupName !== 'undefined',
|
|
227
236
|
bucketId: typeof args.options.bucketId !== 'undefined',
|
|
@@ -239,24 +248,9 @@ _PlannerTaskSetCommand_instances = new WeakSet(), _PlannerTaskSetCommand_initTel
|
|
|
239
248
|
});
|
|
240
249
|
});
|
|
241
250
|
}, _PlannerTaskSetCommand_initOptions = function _PlannerTaskSetCommand_initOptions() {
|
|
242
|
-
this.options.unshift({ option: '-i, --id <id>' }, { option: '-t, --title [title]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--startDateTime [startDateTime]' }, { option: '--dueDateTime [dueDateTime]' }, { option: '--percentComplete [percentComplete]' }, { option: '--assignedToUserIds [assignedToUserIds]' }, { option: '--assignedToUserNames [assignedToUserNames]' }, { option: '--assigneePriority [assigneePriority]' }, { option: '--description [description]' }, { option: '--appliedCategories [appliedCategories]' }, { option: '--orderHint [orderHint]' }, { option: '--priority [priority]', autocomplete: taskPriority.priorityValues });
|
|
251
|
+
this.options.unshift({ option: '-i, --id <id>' }, { option: '-t, --title [title]' }, { option: '--planId [planId]' }, { option: '--planTitle [planTitle]' }, { option: '--rosterId [rosterId]' }, { option: '--ownerGroupId [ownerGroupId]' }, { option: '--ownerGroupName [ownerGroupName]' }, { option: '--bucketId [bucketId]' }, { option: '--bucketName [bucketName]' }, { option: '--startDateTime [startDateTime]' }, { option: '--dueDateTime [dueDateTime]' }, { option: '--percentComplete [percentComplete]' }, { option: '--assignedToUserIds [assignedToUserIds]' }, { option: '--assignedToUserNames [assignedToUserNames]' }, { option: '--assigneePriority [assigneePriority]' }, { option: '--description [description]' }, { option: '--appliedCategories [appliedCategories]' }, { option: '--orderHint [orderHint]' }, { option: '--priority [priority]', autocomplete: taskPriority.priorityValues });
|
|
243
252
|
}, _PlannerTaskSetCommand_initValidators = function _PlannerTaskSetCommand_initValidators() {
|
|
244
253
|
this.validators.push(async (args) => {
|
|
245
|
-
if (args.options.bucketId && args.options.bucketName) {
|
|
246
|
-
return 'Specify either bucketId or bucketName but not both';
|
|
247
|
-
}
|
|
248
|
-
if (args.options.bucketName && !args.options.planId && !args.options.planTitle) {
|
|
249
|
-
return 'Specify either planId or planTitle when using bucketName';
|
|
250
|
-
}
|
|
251
|
-
if (args.options.bucketName && args.options.planId && args.options.planTitle) {
|
|
252
|
-
return 'Specify either planId or planTitle when using bucketName but not both';
|
|
253
|
-
}
|
|
254
|
-
if (args.options.planTitle && !args.options.ownerGroupId && !args.options.ownerGroupName) {
|
|
255
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle';
|
|
256
|
-
}
|
|
257
|
-
if (args.options.planTitle && args.options.ownerGroupId && args.options.ownerGroupName) {
|
|
258
|
-
return 'Specify either ownerGroupId or ownerGroupName when using planTitle but not both';
|
|
259
|
-
}
|
|
260
254
|
if (args.options.ownerGroupId && !validation.isValidGuid(args.options.ownerGroupId)) {
|
|
261
255
|
return `${args.options.ownerGroupId} is not a valid GUID`;
|
|
262
256
|
}
|
|
@@ -275,9 +269,6 @@ _PlannerTaskSetCommand_instances = new WeakSet(), _PlannerTaskSetCommand_initTel
|
|
|
275
269
|
if (args.options.assignedToUserIds && !validation.isValidGuidArray(args.options.assignedToUserIds.split(','))) {
|
|
276
270
|
return 'assignedToUserIds contains invalid GUID';
|
|
277
271
|
}
|
|
278
|
-
if (args.options.assignedToUserIds && args.options.assignedToUserNames) {
|
|
279
|
-
return 'Specify either assignedToUserIds or assignedToUserNames but not both';
|
|
280
|
-
}
|
|
281
272
|
if (args.options.appliedCategories && args.options.appliedCategories.split(',').filter(category => this.allowedAppliedCategories.indexOf(category.toLocaleLowerCase()) < 0).length !== 0) {
|
|
282
273
|
return 'The appliedCategories contains invalid value. Specify either category1, category2, category3, category4, category5 and/or category6 as properties';
|
|
283
274
|
}
|
|
@@ -293,6 +284,30 @@ _PlannerTaskSetCommand_instances = new WeakSet(), _PlannerTaskSetCommand_initTel
|
|
|
293
284
|
}
|
|
294
285
|
return true;
|
|
295
286
|
});
|
|
287
|
+
}, _PlannerTaskSetCommand_initOptionSets = function _PlannerTaskSetCommand_initOptionSets() {
|
|
288
|
+
this.optionSets.push({
|
|
289
|
+
options: ['bucketId', 'bucketName'],
|
|
290
|
+
runsWhen: (args) => {
|
|
291
|
+
return args.options.bucketId || args.options.bucketName;
|
|
292
|
+
}
|
|
293
|
+
}, {
|
|
294
|
+
options: ['planId', 'planTitle', 'rosterId'],
|
|
295
|
+
runsWhen: (args) => {
|
|
296
|
+
return args.options.bucketName !== undefined;
|
|
297
|
+
}
|
|
298
|
+
}, {
|
|
299
|
+
options: ['ownerGroupId', 'ownerGroupName'],
|
|
300
|
+
runsWhen: (args) => {
|
|
301
|
+
return args.options.planTitle !== undefined;
|
|
302
|
+
}
|
|
303
|
+
}, {
|
|
304
|
+
options: ['assignedToUserIds', 'assignedToUserNames'],
|
|
305
|
+
runsWhen: (args) => {
|
|
306
|
+
return args.options.assignedToUserIds || args.options.assignedToUserNames;
|
|
307
|
+
}
|
|
308
|
+
});
|
|
309
|
+
}, _PlannerTaskSetCommand_initTypes = function _PlannerTaskSetCommand_initTypes() {
|
|
310
|
+
this.types.string.push('id', 'title', 'planId', 'planTitle', 'ownerGroupId', 'ownerGroupName', 'bucketId', 'bucketName', 'description', 'assigneePriority', 'orderHint', 'rosterId', 'startDateTime', 'dueDateTime', 'assignedToUserIds', 'assignedToUserNames', 'assignments', 'appliedCategories');
|
|
296
311
|
};
|
|
297
312
|
export default new PlannerTaskSetCommand();
|
|
298
313
|
//# sourceMappingURL=task-set.js.map
|
|
@@ -4,7 +4,9 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
4
4
|
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
5
5
|
};
|
|
6
6
|
var _PpAiBuilderModelGetCommand_instances, _PpAiBuilderModelGetCommand_initTelemetry, _PpAiBuilderModelGetCommand_initOptions, _PpAiBuilderModelGetCommand_initOptionSets, _PpAiBuilderModelGetCommand_initValidators;
|
|
7
|
+
import { Cli } from '../../../../cli/Cli.js';
|
|
7
8
|
import request from '../../../../request.js';
|
|
9
|
+
import { formatting } from '../../../../utils/formatting.js';
|
|
8
10
|
import { powerPlatform } from '../../../../utils/powerPlatform.js';
|
|
9
11
|
import { validation } from '../../../../utils/validation.js';
|
|
10
12
|
import PowerPlatformCommand from '../../../base/PowerPlatformCommand.js';
|
|
@@ -58,7 +60,8 @@ class PpAiBuilderModelGetCommand extends PowerPlatformCommand {
|
|
|
58
60
|
throw `The specified AI builder model '${options.name}' does not exist.`;
|
|
59
61
|
}
|
|
60
62
|
if (result.value.length > 1) {
|
|
61
|
-
|
|
63
|
+
const resultAsKeyValuePair = formatting.convertArrayToHashTable('msdyn_aimodelid', result.value);
|
|
64
|
+
return await Cli.handleMultipleResultsFound(`Multiple AI builder models with name '${options.name}' found.`, resultAsKeyValuePair);
|
|
62
65
|
}
|
|
63
66
|
return result.value[0];
|
|
64
67
|
}
|