Skip to main content

resources/segments/view/actions/findAndReplace

Provides find & replace service.

This is functionally identical to the find & replace batch operation. The difference is that this method runs asynchronously and returns the updated segments.

DOC: The result can be a precheck json with "error". Inconsistent behavior. Why allColumns? Needed?

URL

(POST) /resources/segments/view/actions/findAndReplace

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 operations.

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

Optional
queryA mandatory query object. Specifies the segments to change.Mandatory
findAndReplace

A JSON object describing the find & replace action.

See Find And Replace Action for details.

Mandatory
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.

Mandatory
allColumns

If false then the resulting columns are according to the layout property.

If true then the system returns the segments with ALL authorized columns. Not recommended.

Mandatory

 

RESULTS


A JSON with these properties:

layout

Detailed spreadsheet properties including layout, columns and other.

See Spreadsheet Properties (Object) for all the properties.

object
rights

Detailed access rights regarding scope and spreadsheet.

See Rights (Object) for all the properties.

object
status

The details for the operation. See resources/segments/view/actions/batch

object
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
totalTotal segments updatedint

 

 

 

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.