sp-js-provisioning
Version:
SharePoint provisioning with pure JavaScript
44 lines (43 loc) • 1.35 kB
TypeScript
import { IWeb } from '@pnp/sp/presets/all';
import { JsomContext } from 'spfx-jsom';
import { IProvisioningConfig } from '../provisioningconfig';
import { ProvisioningContext } from '../provisioningcontext';
import { IContentType } from '../schema';
import { HandlerBase } from './handlerbase';
/**
* Describes the Content Types Object Handler
*/
export declare class ContentTypes extends HandlerBase {
jsomContext: JsomContext;
context: ProvisioningContext;
/**
* Creates a new instance of the ObjectSiteFields class
*/
constructor(config: IProvisioningConfig);
/**
* Provisioning Content Types
*
* @param web - The web
* @param contentTypes - The content types
* @param context - Provisioning context
*/
ProvisionObjects(web: IWeb, contentTypes: IContentType[], context: ProvisioningContext): Promise<void>;
/**
* Provision a content type
*
* @param contentType - Content type
*/
private processContentType;
private createContentType;
private getExistingFieldLink;
private normalizeGuid;
private getCurrentFieldLinks;
/**
* Adding content type field refs
*
* @param contentType - Content type
* @param spContentType - SP content type
*/
private processContentTypeFieldRefs;
private _initContext;
}