mirror of
https://github.com/sasjs/adapter.git
synced 2026-01-14 23:50:06 +00:00
feat(create-context): add the ability to modify attributes
This commit is contained in:
@@ -323,7 +323,11 @@ export class SASViyaApiClient {
|
|||||||
const updateContextRequest: RequestInit = {
|
const updateContextRequest: RequestInit = {
|
||||||
method: 'PUT',
|
method: 'PUT',
|
||||||
headers,
|
headers,
|
||||||
body: JSON.stringify({ ...context, ...updatedContext })
|
body: JSON.stringify({
|
||||||
|
...context,
|
||||||
|
...updatedContext,
|
||||||
|
attributes: { ...context.attributes, ...updatedContext.attributes }
|
||||||
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
return await this.request<Context>(
|
return await this.request<Context>(
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ export interface Context {
|
|||||||
id: string
|
id: string
|
||||||
createdBy: string
|
createdBy: string
|
||||||
version: number
|
version: number
|
||||||
|
attributes?: any
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface EditContextInput {
|
export interface EditContextInput {
|
||||||
@@ -10,6 +11,7 @@ export interface EditContextInput {
|
|||||||
description?: string
|
description?: string
|
||||||
launchContext?: { name: string }
|
launchContext?: { name: string }
|
||||||
environment?: { options?: string[]; autoExecLines?: string[] }
|
environment?: { options?: string[]; autoExecLines?: string[] }
|
||||||
|
attributes?: any
|
||||||
authorizedUsers?: string[]
|
authorizedUsers?: string[]
|
||||||
authorizeAllAuthenticatedUsers?: boolean
|
authorizeAllAuthenticatedUsers?: boolean
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user