本文整理匯總了TypeScript中dotcms-js.CoreWebService類的典型用法代碼示例。如果您正苦於以下問題:TypeScript CoreWebService類的具體用法?TypeScript CoreWebService怎麽用?TypeScript CoreWebService使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了CoreWebService類的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1: updateUser
public updateUser(user: AccountUser): Observable<ResponseView> {
return this.coreWebService.requestView({
body: user,
method: RequestMethod.Put,
url: 'v1/users/current'
});
}
示例2: dismissNotifications
dismissNotifications(items: Object): Observable<any> {
return this.coreWebService.request({
body: items,
method: RequestMethod.Put,
url: this.urls.dismissNotificationsUrl
});
}
示例3: unlock
/**
* Unlock a content asset
*
* @param string inode
* @returns Observable<any>
* @memberof PageViewService
*/
unlock(inode: string): Observable<any> {
return this.coreWebService
.requestView({
method: RequestMethod.Put,
url: `content/unlock/inode/${inode}`
})
.pipe(pluck('bodyJsonObject'));
}
示例4: get
/**
* Get Theme information based on the inode.
*
* @param string inode
* @returns Observable<DotTheme>
* @memberof DotThemesService
*/
get(inode: string): Observable<DotTheme> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: 'v1/themes/id/' + inode
})
.pipe(pluck('entity'));
}
示例5: loadFieldTypes
loadFieldTypes(): Observable<FieldType[]> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: 'v1/fieldTypes'
})
.pipe(pluck('entity'));
}
示例6: fireWorkflowAction
/**
* Updates the workflow actions for a page asset
*
* @param string inode
* @returns Observable<any> // contentlet
* @memberof DotWorkflowService
*/
fireWorkflowAction(inode: string, actionId: string): Observable<any> {
return this.coreWebService
.requestView({
method: RequestMethod.Put,
url: `v1/workflow/actions/${actionId}/fire?inode=${inode}`
})
.pipe(pluck('entity'));
}
示例7: getContentWorkflowActions
/**
* Returns the wokflow or workflow actions for a page asset
*
* @param string inode
* @returns Observable<DotWorkflowAction[]>
* @memberof DotWorkflowService
*/
getContentWorkflowActions(inode: string): Observable<DotWorkflowAction[]> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: `v1/workflow/contentlet/${inode}/actions`
})
.pipe(pluck('entity'));
}
示例8: get
/**
* Method to get Workflows
* @param string id
* @returns Observable<SelectItem[]>
* @memberof DotWorkflowService
*/
get(): Observable<DotWorkflow[]> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: 'v1/workflow/schemes'
})
.pipe(pluck('entity'));
}
示例9: getContentTypes
/**
*Get the content types from the endpoint
*
* @returns {Observable<StructureTypeView[]>}
* @memberof DotContentTypeService
*/
getContentTypes(): Observable<StructureTypeView[]> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: 'v1/contenttype/basetypes'
})
.pipe(pluck('entity'));
}
示例10: getLicense
private getLicense(): Observable<any> {
return this.coreWebService
.requestView({
method: RequestMethod.Get,
url: this.licenseURL
})
.pipe(pluck('entity', 'config', 'license'));
}