UNPKG

2.06 kBTypeScriptView Raw
1import { ISiteGroups, ISiteGroup } from "./types.js";
2import "../security/web.js";
3declare module "../webs/types" {
4 interface _Web {
5 readonly siteGroups: ISiteGroups;
6 readonly associatedOwnerGroup: ISiteGroup;
7 readonly associatedMemberGroup: ISiteGroup;
8 readonly associatedVisitorGroup: ISiteGroup;
9 createDefaultAssociatedGroups(groupNameSeed: string, siteOwner: string, copyRoleAssignments?: boolean, clearSubscopes?: boolean, siteOwner2?: string): Promise<void>;
10 }
11 interface IWeb {
12 /**
13 * Returns the site groups of this web
14 */
15 readonly siteGroups: ISiteGroups;
16 /**
17 * The web's owner group
18 */
19 readonly associatedOwnerGroup: ISiteGroup;
20 /**
21 * The web's member group
22 */
23 readonly associatedMemberGroup: ISiteGroup;
24 /**
25 * The web's visitor group
26 */
27 readonly associatedVisitorGroup: ISiteGroup;
28 /**
29 * Creates the default associated groups (Members, Owners, Visitors) and gives them the default permissions on the site.
30 * The target site must have unique permissions and no associated members / owners / visitors groups
31 *
32 * @param groupNameSeed The base group name. E.g. 'TestSite' would produce 'TestSite Members' etc.
33 * @param siteOwner The user login name to be added to the site Owners group. Default is the current user
34 * @param copyRoleAssignments Optional. If true the permissions are copied from the current parent scope
35 * @param clearSubscopes Optional. true to make all child securable objects inherit role assignments from the current object
36 * @param siteOwner2 Optional. The second user login name to be added to the site Owners group. Default is empty
37 */
38 createDefaultAssociatedGroups(groupNameSeed: string, siteOwner: string, copyRoleAssignments?: boolean, clearSubscopes?: boolean, siteOwner2?: string): Promise<void>;
39 }
40}
41//# sourceMappingURL=web.d.ts.map
\No newline at end of file