Commit 30c53ba2 authored by Oleksii Savran's avatar Oleksii Savran
Browse files

Pasting descriptors

Added correct template
parent 2dbf49e6
Pipeline #7082 passed with stages
in 5 minutes and 23 seconds
......@@ -88,7 +88,7 @@ class DescriptorParser extends React.Component<IDescriptorParser, any> {
CSV.parse(csvText, config, {
headers: [
'crop', 'versionTag', 'title', 'category', '_keyDescriptor', 'description', 'dataType',
'crop', 'versionTag', 'title', 'category', 'description', 'dataType',
'integerOnly', 'minValue', 'maxValue', 'vocabularyId', 'code', 'code_title', 'code_description',
'published', 'columnName', 'uom', 'headingNumber'] })
......@@ -97,10 +97,6 @@ class DescriptorParser extends React.Component<IDescriptorParser, any> {
if (jsonObj.minValue) { jsonObj.minValue = +jsonObj.minValue; }
if (jsonObj.maxValue) { jsonObj.maxValue = +jsonObj.maxValue; }
if (jsonObj.integerOnly) { jsonObj.integerOnly = jsonObj.integerOnly === 'TRUE'; }
if (jsonObj._keyDescriptor) {
jsonObj.key = jsonObj._keyDescriptor === 'TRUE';
delete jsonObj._keyDescriptor;
}
if (jsonObj.category) {
jsonObj.category = jsonObj.category.toUpperCase();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment