updateComponentObjectNote function

Future<ApiResponse<ComponentObjectNote>> updateComponentObjectNote(
  1. ExsitedClient client,
  2. Object componentUuid,
  3. Object componentObjectId,
  4. Object noteId,
  5. String note, {
  6. Map<String, Object?>? files,
  7. bool? raiseOnError,
  8. String? responseFormat,
})

PATCH /api/{api_version}/components/{component_uuid}/objects/{component_object_id}/notes/{note_id}

Update a note; a form, as the create is.

Implementation

Future<ApiResponse<ComponentObjectNote>> updateComponentObjectNote(
  ExsitedClient client,
  Object componentUuid,
  Object componentObjectId,
  Object noteId,
  String note, {
  Map<String, Object?>? files,
  bool? raiseOnError,
  String? responseFormat,
}) {
  if (note.isEmpty) {
    throw SdkUsageError(
        'note is required: the note text is the body of this request');
  }
  return client.sendPatchRequest(CustomComponentsUrls.componentObjectNote,
      pathParams: {
        'component_uuid': componentUuid,
        'component_object_id': componentObjectId,
        'note_id': noteId
      },
      formData: {'note': note},
      files: files,
      raiseOnError: raiseOnError,
      responseFormat: responseFormat,
      dtoDecoder: ComponentObjectNote.fromMap);
}