diff --git a/alephino/config/main/T_3210.json b/alephino/config/main/T_3210.json new file mode 100644 index 0000000..6b50461 --- /dev/null +++ b/alephino/config/main/T_3210.json @@ -0,0 +1,166 @@ +[ + { + "op": "core/column-addition", + "engineConfig": { + "facets": [], + "mode": "row-based" + }, + "baseColumnName": "M|IDN", + "expression": "grel:filter(cells['M|303'].value.split('\u001f'), v, v.startsWith('t'))[0].slice(1)", + "onError": "set-to-blank", + "newColumnName": "3210", + "columnInsertIndex": 3, + "description": "Create column 3210" + }, + { + "op": "core/text-transform", + "engineConfig": { + "facets": [ + { + "type": "list", + "name": "3210", + "expression": "isBlank(value)", + "columnName": "3210", + "invert": false, + "omitBlank": false, + "omitError": false, + "selection": [ + { + "v": { + "v": false, + "l": "false" + } + } + ], + "selectBlank": false, + "selectError": false + } + ], + "mode": "row-based" + }, + "columnName": "3210", + "expression": "grel:value + forNonBlank(filter(cells['M|303'].value.split('\u001f'), v, v.startsWith('u'))[0].slice(1), x, '\u001fp' + x, '')", + "onError": "keep-original", + "repeat": false, + "repeatCount": 10, + "description": "Text transform on cells in column 3210 using expression grel:value + forNonBlank(filter(cells['M|303'].value.split('\u001f'), v, v.startsWith('u'))[0].slice(1), x, '\u001fp' + x, '')" + }, + { + "op": "core/text-transform", + "engineConfig": { + "facets": [ + { + "type": "list", + "name": "3210", + "expression": "isBlank(value)", + "columnName": "3210", + "invert": false, + "omitBlank": false, + "omitError": false, + "selection": [ + { + "v": { + "v": true, + "l": "true" + } + } + ], + "selectBlank": false, + "selectError": false + }, + { + "type": "list", + "name": "M|304", + "expression": "isBlank(value)", + "columnName": "M|304", + "invert": false, + "omitBlank": false, + "omitError": false, + "selection": [ + { + "v": { + "v": false, + "l": "false" + } + } + ], + "selectBlank": false, + "selectError": false + } + ], + "mode": "row-based" + }, + "columnName": "3210", + "expression": "grel:cells['M|304'].value", + "onError": "keep-original", + "repeat": false, + "repeatCount": 10, + "description": "Text transform on cells in column 3210 using expression grel:cells['M|304'].value" + }, + { + "op": "core/text-transform", + "engineConfig": { + "facets": [ + { + "type": "list", + "name": "3210", + "expression": "isBlank(value)", + "columnName": "3210", + "invert": false, + "omitBlank": false, + "omitError": false, + "selection": [ + { + "v": { + "v": false, + "l": "false" + } + } + ], + "selectBlank": false, + "selectError": false + } + ], + "mode": "row-based" + }, + "columnName": "3210", + "expression": "grel:value.replace('¬', '')", + "onError": "keep-original", + "repeat": false, + "repeatCount": 10, + "description": "Text transform on cells in column 3210 using expression grel:value.replace('¬', '')" + }, + { + "op": "core/text-transform", + "engineConfig": { + "facets": [ + { + "type": "list", + "name": "3210", + "expression": "isBlank(value)", + "columnName": "3210", + "invert": false, + "omitBlank": false, + "omitError": false, + "selection": [ + { + "v": { + "v": false, + "l": "false" + } + } + ], + "selectBlank": false, + "selectError": false + } + ], + "mode": "row-based" + }, + "columnName": "3210", + "expression": "grel:with(['a', 'das', 'dem', 'den', 'der', 'des', 'die', 'ein', 'eine', 'einem', 'einen', 'einer', 'eines', 'the'], x, if(inArray(x, value.split(' ')[0].toLowercase()), value.split(' ')[0] + ' @' + value.split(' ').slice(1).join(' '), value))", + "onError": "keep-original", + "repeat": false, + "repeatCount": 10, + "description": "Text transform on cells in column 3210" + } +] diff --git a/alephino/config/main/template.txt b/alephino/config/main/template.txt index a4bc3e7..b847fd6 100644 --- a/alephino/config/main/template.txt +++ b/alephino/config/main/template.txt @@ -9,6 +9,7 @@ if(row.index - row.record.fromRowIndex == 0, + forNonBlank(cells['1131'].value, v, forEach(v.split('␟'),x,'013D ' + '' + x + '\n').join(''), '') + forNonBlank(cells['1140'].value, v, '013H ' + 'a' + v + '\n', '') + forNonBlank(cells['1700'].value, v, '019@ ' + forEach(v.split('‡'),x,'a' + x).join('') + '\n', '') ++ forNonBlank(cells['3210'].value, v, '022A/00 ' + 'a' + v + '\n', '') + forNonBlank(cells['3000'].value, v, '028A ' + v + '\n', '') + forNonBlank(cells['3010'].value, v, forEach(v.split('␟'), x, '028C ' + x + '\n').join(''), '') + forNonBlank(cells['3100'].value, v, '029A ' + v + '\n', '')