Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Provides a wide range of tools to update one or more filtered segments in batch. The batch operations include: Change text, Find & Replace, Change status and bookmarks, Pre-translate from memories etc.This method permits to join a sub-segment with either its predecessor or its successor.

DOC: Move "join" properties to root

URL

(POSTPUT) /resources/segments/view/actions/batchjoin

PARAMETERS

The parameters are a JSON object included in the request body:

scope

The scope object. The segment must be within the scope.

NOTE: This method does not support the Global Search scope.

Mandatory
layout

The editor grid layout. Only fields included in the layout can be updated by the batch operationsThe layout describes how the resulting split (sub-)segments are returned.

If not set specified then a the default layout will be created that covers only a minimal set of columns (typically source and target text)2 column layout is applied.

Optional
queryAn optional query object. This allows to delimit the operation to a subset of the scope's segments.Optional
actionsA JSON object describing the actions to apply. See below.Optional
doSave

Optional, default is true. True: Changes are saved. False: Changes are not saved.

The latter permits to obtain statistics about what data the operation will update without actually updating.

Optional

 

The actions property is an object configuring the actual actions to apply:

An array with one or more actions to apply. The structure of each element is described below.

The action type is contained in property type. See the following links for details on each action type:

children

items

join

Properties of the segment to be joined:

dsid: The document set ID of the segment

did: The document ID of the segment

bsid: The bee segment ID of the segment

bssid: The bee sub-segment ID of the segment (0 = first, 1 = second, ...)

mergeNext: True to merge sub-segment with next sub-segment. False to merge with previous sub-segment.

 

 

MandatoryonChangeBookmark

 

...

Optional.

When a segment text or a property of the text is updated by an operation then optionally update the bookmark value as follows:

  • null: Leave bookmarks unchanged
  • 0: Reset bookmark
  • 1: Set blue bookmark
  • 2: Set red bookmark

 

...

Optional.

When a segment text or a property of the text is updated by an operation then optionally update the status of the text as follows:

  • null: Leave status unchanged
  • 0: Reset status
  • 1: Set status to OK (green)
  • 2: Set status to Error (red)

...

 

RESULTS

A JSON with these properties:

...

 

...

 

...

RESULTS

After executing the join, the system returns a spreadsheet with all sub-segments of the segment.

result

Contains these properties:

rows: Array with all sub-segments sharing the same bsid value

docs: Array with document details for the segment. Will contain a single element.

users: Users that edited properties of the segments (revisions, comments etc.)

object