Korrektur spec_Z_03 und neu spec_B_E16
This commit is contained in:
parent
828dbfcb9c
commit
7f8c238d3c
|
@ -63,9 +63,6 @@ checkpoint "Transform"; echo
|
||||||
# ----------------------------- Spalten sortieren ---------------------------- #
|
# ----------------------------- Spalten sortieren ---------------------------- #
|
||||||
|
|
||||||
# damit Records-Mode erhalten bleibt
|
# damit Records-Mode erhalten bleibt
|
||||||
# - M|MEDGR > Facet > Text facet > eBook
|
|
||||||
# -- show as: records
|
|
||||||
# --- All > Edit rows > Remove all matching rows
|
|
||||||
|
|
||||||
echo "Spalten sortieren: Beginnen mit 1. M|MEDNR, 2. E|EXNR, 3. File..."
|
echo "Spalten sortieren: Beginnen mit 1. M|MEDNR, 2. E|EXNR, 3. File..."
|
||||||
if curl -fs \
|
if curl -fs \
|
||||||
|
@ -77,20 +74,17 @@ if curl -fs \
|
||||||
{
|
{
|
||||||
"op": "core/column-move",
|
"op": "core/column-move",
|
||||||
"columnName": "File",
|
"columnName": "File",
|
||||||
"index": 0,
|
"index": 0
|
||||||
"description": "Move column File to position 0"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"op": "core/column-move",
|
"op": "core/column-move",
|
||||||
"columnName": "E|EXNR",
|
"columnName": "E|EXNR",
|
||||||
"index": 0,
|
"index": 0
|
||||||
"description": "Move column E|EXNR to position 0"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"op": "core/column-move",
|
"op": "core/column-move",
|
||||||
"columnName": "M|MEDNR",
|
"columnName": "M|MEDNR",
|
||||||
"index": 0,
|
"index": 0
|
||||||
"description": "Move column M|MEDNR to position 0"
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
JSON
|
JSON
|
||||||
|
@ -210,9 +204,7 @@ echo
|
||||||
# ------------------------- Makulierte Medien löschen ------------------------ #
|
# ------------------------- Makulierte Medien löschen ------------------------ #
|
||||||
|
|
||||||
# spec_Z_03
|
# spec_Z_03
|
||||||
# - E|EXSTA > Facet > Text facet > "M"
|
# löscht alle Titel+Exemplare, die ausschließlich makulierte Ex. enthalten
|
||||||
# -- show as: rows
|
|
||||||
# --- All > Edit rows > Remove all matching rows
|
|
||||||
|
|
||||||
echo "Makulierte Medien löschen..."
|
echo "Makulierte Medien löschen..."
|
||||||
if curl -fs \
|
if curl -fs \
|
||||||
|
@ -228,7 +220,7 @@ if curl -fs \
|
||||||
{
|
{
|
||||||
"type": "list",
|
"type": "list",
|
||||||
"name": "E|EXSTA",
|
"name": "E|EXSTA",
|
||||||
"expression": "value",
|
"expression": "grel:row.record.cells[columnName].value.uniques().join(',') == 'M'",
|
||||||
"columnName": "E|EXSTA",
|
"columnName": "E|EXSTA",
|
||||||
"invert": false,
|
"invert": false,
|
||||||
"omitBlank": false,
|
"omitBlank": false,
|
||||||
|
@ -236,8 +228,8 @@ if curl -fs \
|
||||||
"selection": [
|
"selection": [
|
||||||
{
|
{
|
||||||
"v": {
|
"v": {
|
||||||
"v": "M",
|
"v": true,
|
||||||
"l": "M"
|
"l": "true"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
@ -245,7 +237,7 @@ if curl -fs \
|
||||||
"selectError": false
|
"selectError": false
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"mode": "row-based"
|
"mode": "record-based"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
@ -410,8 +402,8 @@ echo
|
||||||
|
|
||||||
# ----------------------------------- 7100f ---------------------------------- #
|
# ----------------------------------- 7100f ---------------------------------- #
|
||||||
|
|
||||||
# spec_B_E_13
|
# spec_B_E_13, spec_Z_03
|
||||||
echo "Zweigstelle 7100f..."
|
echo "Zweigstelle 7100f"
|
||||||
if curl -fs \
|
if curl -fs \
|
||||||
--data project="${projects[$p]}" \
|
--data project="${projects[$p]}" \
|
||||||
--data-urlencode "operations@-" \
|
--data-urlencode "operations@-" \
|
||||||
|
@ -555,14 +547,17 @@ echo
|
||||||
|
|
||||||
# ----------------------------------- E0XXb ---------------------------------- #
|
# ----------------------------------- E0XXb ---------------------------------- #
|
||||||
|
|
||||||
# spec_B_E_14
|
# spec_B_E_14, spec_Z_03, spec_B_E16
|
||||||
|
# leer für Exemplare, die nicht konvertiert werden sollen:
|
||||||
|
# - makulierte Exemplare
|
||||||
|
# - ACQ-Datensätze
|
||||||
echo "Selektionsschlüssel E0XXb..."
|
echo "Selektionsschlüssel E0XXb..."
|
||||||
if curl -fs \
|
if curl -fs \
|
||||||
--data project="${projects[$p]}" \
|
--data project="${projects[$p]}" \
|
||||||
--data-urlencode "operations@-" \
|
--data-urlencode "operations@-" \
|
||||||
"${endpoint}/command/core/apply-operations$(refine_csrf)" > /dev/null \
|
"${endpoint}/command/core/apply-operations$(refine_csrf)" > /dev/null \
|
||||||
<< "JSON"
|
<< "JSON"
|
||||||
[
|
[
|
||||||
{
|
{
|
||||||
"op": "core/column-addition",
|
"op": "core/column-addition",
|
||||||
"engineConfig": {
|
"engineConfig": {
|
||||||
|
@ -585,17 +580,55 @@ if curl -fs \
|
||||||
],
|
],
|
||||||
"selectBlank": false,
|
"selectBlank": false,
|
||||||
"selectError": false
|
"selectError": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "list",
|
||||||
|
"name": "E|EXSTA",
|
||||||
|
"expression": "value",
|
||||||
|
"columnName": "E|EXSTA",
|
||||||
|
"invert": true,
|
||||||
|
"omitBlank": false,
|
||||||
|
"omitError": false,
|
||||||
|
"selection": [
|
||||||
|
{
|
||||||
|
"v": {
|
||||||
|
"v": "M",
|
||||||
|
"l": "M"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"selectBlank": false,
|
||||||
|
"selectError": false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"type": "list",
|
||||||
|
"name": "E|MEKZ",
|
||||||
|
"expression": "value",
|
||||||
|
"columnName": "E|MEKZ",
|
||||||
|
"invert": true,
|
||||||
|
"omitBlank": false,
|
||||||
|
"omitError": false,
|
||||||
|
"selection": [
|
||||||
|
{
|
||||||
|
"v": {
|
||||||
|
"v": "ACQ",
|
||||||
|
"l": "ACQ"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"selectBlank": false,
|
||||||
|
"selectError": false
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"mode": "row-based"
|
"mode": "row-based"
|
||||||
},
|
},
|
||||||
"baseColumnName": "File",
|
"baseColumnName": "File",
|
||||||
"expression": "grel:with(if(value=='DD',forNonBlank(cells['E|ZWGST'].value,v,v,value),value),x,x.toLowercase())",
|
"expression": "grel:with(if(value=='DD',forNonBlank(cells['E|ZWGST'].value,v,v,value),value),x,'n'+x.toLowercase())",
|
||||||
"onError": "set-to-blank",
|
"onError": "set-to-blank",
|
||||||
"newColumnName": "E0XXb",
|
"newColumnName": "E0XXb",
|
||||||
"columnInsertIndex": 3
|
"columnInsertIndex": 3
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
JSON
|
JSON
|
||||||
then
|
then
|
||||||
log "transformed ${p} (${projects[$p]})"
|
log "transformed ${p} (${projects[$p]})"
|
||||||
|
|
|
@ -539,9 +539,9 @@ if(row.index - row.record.fromRowIndex == 0,
|
||||||
+ forNonBlank(cells['4000'].value, v, '021A' + ' a' + v + '\n', '')
|
+ forNonBlank(cells['4000'].value, v, '021A' + ' a' + v + '\n', '')
|
||||||
,'')
|
,'')
|
||||||
}}{{
|
}}{{
|
||||||
if(isNonBlank(cells['7100f'].value),
|
if(isNonBlank(cells['E0XXb'].value),
|
||||||
with(with(rowIndex - row.record.fromRowIndex + 1, i, '00'[0,2-i.length()] + i),exnr,
|
with(with(rowIndex - row.record.fromRowIndex + 1, i, '00'[0,2-i.length()] + i),exnr,
|
||||||
'208@/' + exnr + ' a' + cells['E0XX'].value + 'bn' + cells['E0XXb'].value + '\n'
|
'208@/' + exnr + ' a' + cells['E0XX'].value + 'b' + cells['E0XXb'].value + '\n'
|
||||||
+ '209A/' + exnr + ' b4736' + 'j' + cells['7100j'].value + 'f' + cells['7100f'].value + forNonBlank(cells['7100a'].value, v, 'a' + v, '') + forNonBlank(cells['7100d'].value, v, 'd' + v, '') + 'x00' + '\n'
|
+ '209A/' + exnr + ' b4736' + 'j' + cells['7100j'].value + 'f' + cells['7100f'].value + forNonBlank(cells['7100a'].value, v, 'a' + v, '') + forNonBlank(cells['7100d'].value, v, 'd' + v, '') + 'x00' + '\n'
|
||||||
+ forNonBlank(cells['8011'].value, v, '209B/' + exnr + ' a' + v + 'x11' + '\n', '')
|
+ forNonBlank(cells['8011'].value, v, '209B/' + exnr + ' a' + v + 'x11' + '\n', '')
|
||||||
+ forNonBlank(cells['8100'].value, v, '209C/' + exnr + ' a' + v + '\n', '')
|
+ forNonBlank(cells['8100'].value, v, '209C/' + exnr + ' a' + v + '\n', '')
|
||||||
|
|
Loading…
Reference in New Issue