Directus / @directus/sdk / rest / updatePanels
Function: updatePanels() ​
updatePanels<
Schema,TQuery>(keys,item,query?):RestCommand<IfAny<Schema,Record<string,any>, { [K in string | number | symbol]: Merge<MappedFunctionFields<Schema, UnpackList<IfAny<Schema, { color: ...; dashboard: ...; date_created: ...; height: ...; icon: ...; id: ...; name: ...; note: ...; options: ...; position_x: ...; position_y: ...; show_header: ...; type: ...; user_created: ...; width: ... }, (...) extends (...) ? (...) : (...)>>> extends FF ? MapFlatFields<UnpackList<IfAny<Schema, { color: ...; dashboard: ...; date_created: ...; height: ...; icon: ...; id: ...; name: ...; note: ...; options: ...; position_x: ...; position_y: ...; show_header: ...; type: ...; user_created: ...; width: ... }, (...) extends (...) ? (...) : (...)>>, FieldsWildcard<UnpackList<IfAny<(...), (...), (...)>>, Exclude<UnpackList<(...)>, (...) extends (...) ? (...) : (...)>>, FF extends Record<string, string> ? FF<FF> : Record<string, string>> : never, PickRelationalFields<UnpackList<Mutable<(...)[(...)]>>> extends never ? never : { [Field in string | number | symbol]: Field extends keyof UnpackList<(...)> ? Extract<(...), (...)> extends RelatedCollection ? IsNullable<(...), (...), (...)> : never : never }>[K] }>[],Schema>
Defined in: rest/commands/update/panels.ts:21
Update multiple existing panels.
Type Parameters ​
• Schema
• TQuery extends Query<Schema, DirectusPanel<Schema>>
Parameters ​
keys ​
DirectusPanel<Schema>["id"][]
item ​
Partial<DirectusPanel<Schema>>
query? ​
TQuery
Returns ​
RestCommand<IfAny<Schema, Record<string, any>, { [K in string | number | symbol]: Merge<MappedFunctionFields<Schema, UnpackList<IfAny<Schema, { color: ...; dashboard: ...; date_created: ...; height: ...; icon: ...; id: ...; name: ...; note: ...; options: ...; position_x: ...; position_y: ...; show_header: ...; type: ...; user_created: ...; width: ... }, (...) extends (...) ? (...) : (...)>>> extends FF ? MapFlatFields<UnpackList<IfAny<Schema, { color: ...; dashboard: ...; date_created: ...; height: ...; icon: ...; id: ...; name: ...; note: ...; options: ...; position_x: ...; position_y: ...; show_header: ...; type: ...; user_created: ...; width: ... }, (...) extends (...) ? (...) : (...)>>, FieldsWildcard<UnpackList<IfAny<(...), (...), (...)>>, Exclude<UnpackList<(...)>, (...) extends (...) ? (...) : (...)>>, FF extends Record<string, string> ? FF<FF> : Record<string, string>> : never, PickRelationalFields<UnpackList<Mutable<(...)[(...)]>>> extends never ? never : { [Field in string | number | symbol]: Field extends keyof UnpackList<(...)> ? Extract<(...), (...)> extends RelatedCollection ? IsNullable<(...), (...), (...)> : never : never }>[K] }>[], Schema>
Returns the panel objects for the updated panels.
Throws ​
Will throw if keys is empty