{
+ return conditions.sort((a, b) => (a.conditionSummary > b.conditionSummary ? 1 : -1));
+};
+
+export const crossReferencesSort = (crossReferences) => {
+ return crossReferences.sort((a, b) =>
+ a.displayName > b.displayName ? 1 : a.resourceDescriptorPage.name === b.resourceDescriptorPage.name ? 1 : -1
+ );
+};
+
+export const diseaseQualifiersSort = (qualifiers) => qualifiers.sort((a, b) => (a.name > b.name ? 1 : -1));
+
+export const evidenceCodesSort = (evidenceCodes) => {
+ return evidenceCodes.sort((a, b) => (a.abbreviation > b.abbreviation ? 1 : a.curie === b.curie ? 1 : -1));
+};
diff --git a/src/main/cliapp/src/constants/FilterFields.js b/src/main/cliapp/src/constants/FilterFields.js
index b75e08beb..acc2a8c70 100644
--- a/src/main/cliapp/src/constants/FilterFields.js
+++ b/src/main/cliapp/src/constants/FilterFields.js
@@ -326,14 +326,33 @@ export const FIELD_SETS = Object.freeze({
filterName: 'geneSystematicNameFilter',
fields: ['geneSystematicName.displayText', 'geneSystematicName.formatText'],
},
- geneticModifiersFieldSet: {
- filterName: 'geneticModifiersFilter',
+ geneticModifierAgmsFieldSet: {
+ filterName: 'geneticModifierAgmsFilter',
fields: [
- 'diseaseGeneticModifiers.symbol',
- 'diseaseGeneticModifiers.name',
- 'diseaseGeneticModifiers.curie',
- 'diseaseGeneticModifiers.modEntityId',
- 'diseaseGeneticModifiers.modInternalId',
+ 'diseaseGeneticModifierAgms.name',
+ 'diseaseGeneticModifierAgms.curie',
+ 'diseaseGeneticModifierAgms.modEntityId',
+ 'diseaseGeneticModifierAgms.modInternalId',
+ ],
+ },
+ geneticModifierAllelesFieldSet: {
+ filterName: 'geneticModifierAllelesFilter',
+ fields: [
+ 'diseaseGeneticModifierAlleles.alleleSymbol.displayText',
+ 'diseaseGeneticModifierAlleles.alleleSymbol.formatText',
+ 'diseaseGeneticModifierAlleles.curie',
+ 'diseaseGeneticModifierAlleles.modEntityId',
+ 'diseaseGeneticModifierAlleles.modInternalId',
+ ],
+ },
+ geneticModifierGenesFieldSet: {
+ filterName: 'geneticModifierGenesFilter',
+ fields: [
+ 'diseaseGeneticModifierGenes.geneSymbol.displayText',
+ 'diseaseGeneticModifierGenes.geneSymbol.formatText',
+ 'diseaseGeneticModifierGenes.curie',
+ 'diseaseGeneticModifierGenes.modEntityId',
+ 'diseaseGeneticModifierGenes.modInternalId',
],
},
geneticModifierRelationFieldSet: {
@@ -793,7 +812,18 @@ export const FILTER_CONFIGS = Object.freeze({
geneSynonymsFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.geneSynonymsFieldSet] },
geneSystematicNameFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.geneSystematicNameFieldSet] },
geneTypeFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.geneTypeFieldSet] },
- geneticModifiersFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.geneticModifiersFieldSet] },
+ geneticModifierAgmsFilterConfig: {
+ filterComponentType: 'input',
+ fieldSets: [FIELD_SETS.geneticModifierAgmsFieldSet],
+ },
+ geneticModifierAllelesFilterConfig: {
+ filterComponentType: 'input',
+ fieldSets: [FIELD_SETS.geneticModifierAllelesFieldSet],
+ },
+ geneticModifierGenesFilterConfig: {
+ filterComponentType: 'input',
+ fieldSets: [FIELD_SETS.geneticModifierGenesFieldSet],
+ },
idExampleFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.idExampleFieldSet] },
idPatternFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.idPatternFieldSet] },
inchiFilterConfig: { filterComponentType: 'input', fieldSets: [FIELD_SETS.inchiFieldSet] },
diff --git a/src/main/cliapp/src/constants/SortFields.js b/src/main/cliapp/src/constants/SortFields.js
index 4e7f7ed92..a9fe4ed27 100644
--- a/src/main/cliapp/src/constants/SortFields.js
+++ b/src/main/cliapp/src/constants/SortFields.js
@@ -19,7 +19,9 @@ export const SORT_FIELDS = Object.freeze([
'sgdStrainBackground.name',
'annotationType.name',
'diseaseGeneticModifierRelation.name',
- 'diseaseGeneticModifiers.symbol',
+ 'diseaseGeneticModifierAgms.name',
+ 'diseaseGeneticModifierAlleles.alleleSymbol.displayText',
+ 'diseaseGeneticModifierGenes.geneSymbol.displayText',
'inferredGene.geneSymbol.displayText',
'assertedGenes.geneSymbol.displayText',
'inferredAllele.alleleSymbol.displayText',
diff --git a/src/main/cliapp/src/containers/affectedGenomicModelPage/AffectedGenomicModelTable.js b/src/main/cliapp/src/containers/affectedGenomicModelPage/AffectedGenomicModelTable.js
index 0052e4816..94f94c218 100644
--- a/src/main/cliapp/src/containers/affectedGenomicModelPage/AffectedGenomicModelTable.js
+++ b/src/main/cliapp/src/containers/affectedGenomicModelPage/AffectedGenomicModelTable.js
@@ -3,15 +3,16 @@ import { GenericDataTable } from '../../components/GenericDataTable/GenericDataT
import { Toast } from 'primereact/toast';
import { getDefaultTableState } from '../../service/TableStateService';
import { FILTER_CONFIGS } from '../../constants/FilterFields';
-import { NameTemplate } from '../../components/Templates/NameTemplate';
-import { TaxonTemplate } from '../../components/Templates/TaxonTemplate';
+import { StringTemplate } from '../../components/Templates/StringTemplate';
import { IdTemplate } from '../../components/Templates/IdTemplate';
import { BooleanTemplate } from '../../components/Templates/BooleanTemplate';
-import { CrossReferencesTemplate } from '../../components/Templates/CrossReferencesTemplate';
+import { ObjectListTemplate } from '../../components/Templates/ObjectListTemplate';
import { useGetTableData } from '../../service/useGetTableData';
import { useGetUserSettings } from '../../service/useGetUserSettings';
import { SearchService } from '../../service/SearchService';
+import { crossReferencesSort } from '../../components/Templates/utils/sortMethods';
+import { OntologyTermTemplate } from '../../components/Templates/OntologyTermTemplate';
export const AffectedGenomicModelTable = () => {
const [isInEditMode, setIsInEditMode] = useState(false);
@@ -48,13 +49,14 @@ export const AffectedGenomicModelTable = () => {
{
field: 'name',
header: 'Name',
- body: (rowData) =>
,
+ body: (rowData) =>
,
sortable: true,
filterConfig: FILTER_CONFIGS.nameFilterConfig,
},
{
field: 'subtype.name',
header: 'Sub Type',
+ body: (rowData) =>
,
sortable: true,
filterConfig: FILTER_CONFIGS.subtypeFilterConfig,
},
@@ -62,7 +64,7 @@ export const AffectedGenomicModelTable = () => {
field: 'taxon.name',
header: 'Taxon',
sortable: true,
- body: (rowData) =>
,
+ body: (rowData) =>
,
filterConfig: FILTER_CONFIGS.taxonFilterConfig,
},
{
@@ -76,12 +78,19 @@ export const AffectedGenomicModelTable = () => {
header: 'Cross References',
sortable: true,
filterConfig: FILTER_CONFIGS.crossReferencesFilterConfig,
- body: (rowData) =>
,
+ body: (rowData) => (
+
`${item.displayName} (${item.resourceDescriptorPage.name})`}
+ />
+ ),
},
{
field: 'updatedBy.uniqueId',
header: 'Updated By',
sortable: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.updatedByFilterConfig,
},
{
@@ -89,6 +98,7 @@ export const AffectedGenomicModelTable = () => {
header: 'Date Updated',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dateUpdatedFilterConfig,
},
{
@@ -96,6 +106,7 @@ export const AffectedGenomicModelTable = () => {
header: 'Created By',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.createdByFilterConfig,
},
{
@@ -103,6 +114,7 @@ export const AffectedGenomicModelTable = () => {
header: 'Date Created',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dataCreatedFilterConfig,
},
{
diff --git a/src/main/cliapp/src/containers/allelesPage/AllelesTable.js b/src/main/cliapp/src/containers/allelesPage/AllelesTable.js
index 471566ee7..a99c8570d 100644
--- a/src/main/cliapp/src/containers/allelesPage/AllelesTable.js
+++ b/src/main/cliapp/src/containers/allelesPage/AllelesTable.js
@@ -25,12 +25,11 @@ import { BooleanTableEditor } from '../../components/Editors/boolean/BooleanTabl
import { TruncatedReferencesTemplate } from '../../components/Templates/reference/TruncatedReferencesTemplate';
import { IdTemplate } from '../../components/Templates/IdTemplate';
import { BooleanTemplate } from '../../components/Templates/BooleanTemplate';
-import { TaxonTemplate } from '../../components/Templates/TaxonTemplate';
import { TextDialogTemplate } from '../../components/Templates/dialog/TextDialogTemplate';
import { ListDialogTemplate } from '../../components/Templates/dialog/ListDialogTemplate';
import { NestedListDialogTemplate } from '../../components/Templates/dialog/NestedListDialogTemplate';
import { CountDialogTemplate } from '../../components/Templates/dialog/CountDialogTemplate';
-import { CrossReferencesTemplate } from '../../components/Templates/CrossReferencesTemplate';
+import { ObjectListTemplate } from '../../components/Templates/ObjectListTemplate';
import { Tooltip } from 'primereact/tooltip';
import { Toast } from 'primereact/toast';
@@ -38,6 +37,9 @@ import { Button } from 'primereact/button';
import { EditMessageTooltip } from '../../components/EditMessageTooltip';
import { getDefaultTableState } from '../../service/TableStateService';
import { FILTER_CONFIGS } from '../../constants/FilterFields';
+import { crossReferencesSort } from '../../components/Templates/utils/sortMethods';
+import { StringTemplate } from '../../components/Templates/StringTemplate';
+import { OntologyTermTemplate } from '../../components/Templates/OntologyTermTemplate';
export const AllelesTable = () => {
const [isInEditMode, setIsInEditMode] = useState(false);
@@ -1076,7 +1078,6 @@ export const AllelesTable = () => {
{
field: 'alleleSecondaryIds.secondaryId',
header: 'Secondary IDs',
- //todo
body: (rowData) => (
{
{
field: 'taxon.name',
header: 'Taxon',
- body: (rowData) => ,
sortable: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.taxonFilterConfig,
editor: (props) => ,
},
@@ -1200,6 +1201,7 @@ export const AllelesTable = () => {
field: 'inCollection.name',
header: 'In Collection',
sortable: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.inCollectionFilterConfig,
editor: (props) => ,
},
@@ -1234,12 +1236,19 @@ export const AllelesTable = () => {
header: 'Cross References',
sortable: true,
filterConfig: FILTER_CONFIGS.crossReferencesFilterConfig,
- body: (rowData) => ,
+ body: (rowData) => (
+ `${item.displayName} (${item.resourceDescriptorPage.name})`}
+ />
+ ),
},
{
field: 'updatedBy.uniqueId',
header: 'Updated By',
sortable: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.updatedByFilterConfig,
},
{
@@ -1247,6 +1256,7 @@ export const AllelesTable = () => {
header: 'Date Updated',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dateUpdatedFilterConfig,
},
{
@@ -1254,6 +1264,7 @@ export const AllelesTable = () => {
header: 'Created By',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.createdByFilterConfig,
},
{
@@ -1261,6 +1272,7 @@ export const AllelesTable = () => {
header: 'Date Created',
sortable: true,
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dataCreatedFilterConfig,
},
{
diff --git a/src/main/cliapp/src/containers/conditionRelationPage/ConditionRelationTable.js b/src/main/cliapp/src/containers/conditionRelationPage/ConditionRelationTable.js
index 26d72cd3c..497b655b2 100644
--- a/src/main/cliapp/src/containers/conditionRelationPage/ConditionRelationTable.js
+++ b/src/main/cliapp/src/containers/conditionRelationPage/ConditionRelationTable.js
@@ -6,9 +6,6 @@ import { Messages } from 'primereact/messages';
import { ControlledVocabularyDropdown } from '../../components/ControlledVocabularySelector';
import { ErrorMessageComponent } from '../../components/Error/ErrorMessageComponent';
import { useControlledVocabularyService } from '../../service/useControlledVocabularyService';
-import { EllipsisTableCell } from '../../components/EllipsisTableCell';
-import { ListTableCell } from '../../components/ListTableCell';
-import { Tooltip } from 'primereact/tooltip';
import { Button } from 'primereact/button';
import { ConditionRelationService } from '../../service/ConditionRelationService';
import { AutocompleteEditor } from '../../components/Autocomplete/AutocompleteEditor';
@@ -31,6 +28,9 @@ import { getDefaultTableState } from '../../service/TableStateService';
import { FILTER_CONFIGS } from '../../constants/FilterFields';
import { useGetTableData } from '../../service/useGetTableData';
import { useGetUserSettings } from '../../service/useGetUserSettings';
+import { ObjectListTemplate } from '../../components/Templates/ObjectListTemplate';
+import { SingleReferenceTemplate } from '../../components/Templates/reference/SingleReferenceTemplate';
+import { conditionsSort } from '../../components/Templates/utils/sortMethods';
export const ConditionRelationTable = () => {
const [isInEditMode, setIsInEditMode] = useState(false);
@@ -126,19 +126,6 @@ export const ConditionRelationTable = () => {
);
};
- const conditionTemplate = (rowData) => {
- if (rowData.conditions) {
- const listTemplate = (condition) => {
- return {condition.conditionSummary};
- };
- return (
-
-
-
- );
- }
- };
-
const onConditionRelationValueChange = (event, setFieldValue, props) => {
multipleAutocompleteOnChange(props, event, 'conditions', setFieldValue);
};
@@ -186,29 +173,6 @@ export const ConditionRelationTable = () => {
);
};
- const singleReferenceBodyTemplate = (rowData) => {
- if (rowData && rowData.singleReference) {
- let refString = getRefString(rowData.singleReference);
- return (
- <>
-
-
-
-
- >
- );
- }
- };
-
const columns = [
{
field: 'handle',
@@ -224,7 +188,7 @@ export const ConditionRelationTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.singleReferenceFilterConfig,
editor: (props) => referenceEditorTemplate(props),
- body: singleReferenceBodyTemplate,
+ body: (rowData) => ,
},
{
field: 'conditionRelationType.name',
@@ -237,7 +201,14 @@ export const ConditionRelationTable = () => {
field: 'conditions.conditionSummary',
header: 'Experimental Conditions',
sortable: true,
- body: conditionTemplate,
+ body: (rowData) => (
+ item.conditionSummary}
+ showBullets={true}
+ />
+ ),
filterConfig: FILTER_CONFIGS.experimentalConditionFilterConfig,
editor: (props) => conditionRelationTemplate(props),
},
diff --git a/src/main/cliapp/src/containers/constructsPage/ConstructsTable.js b/src/main/cliapp/src/containers/constructsPage/ConstructsTable.js
index 5bfc45f21..e440dbeaa 100644
--- a/src/main/cliapp/src/containers/constructsPage/ConstructsTable.js
+++ b/src/main/cliapp/src/containers/constructsPage/ConstructsTable.js
@@ -16,6 +16,7 @@ import { ListDialogTemplate } from '../../components/Templates/dialog/ListDialog
import { StringListTemplate } from '../../components/Templates/StringListTemplate';
import { BooleanTemplate } from '../../components/Templates/BooleanTemplate';
import { TruncatedReferencesTemplate } from '../../components/Templates/reference/TruncatedReferencesTemplate';
+import { StringTemplate } from '../../components/Templates/StringTemplate';
import { SearchService } from '../../service/SearchService';
@@ -257,6 +258,7 @@ export const ConstructsTable = () => {
field: 'updatedBy.uniqueId',
header: 'Updated By',
sortable: { isInEditMode },
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.updatedByFilterConfig,
},
{
@@ -264,6 +266,7 @@ export const ConstructsTable = () => {
header: 'Date Updated',
sortable: { isInEditMode },
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dateUpdatedFilterConfig,
},
{
@@ -271,6 +274,7 @@ export const ConstructsTable = () => {
header: 'Created By',
sortable: { isInEditMode },
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.createdByFilterConfig,
},
{
@@ -278,6 +282,7 @@ export const ConstructsTable = () => {
header: 'Date Created',
sortable: { isInEditMode },
filter: true,
+ body: (rowData) => ,
filterConfig: FILTER_CONFIGS.dataCreatedFilterConfig,
},
{
diff --git a/src/main/cliapp/src/containers/controlledVocabularyPage/ControlledVocabularyTable.js b/src/main/cliapp/src/containers/controlledVocabularyPage/ControlledVocabularyTable.js
index aa5955cf2..383b1177b 100644
--- a/src/main/cliapp/src/containers/controlledVocabularyPage/ControlledVocabularyTable.js
+++ b/src/main/cliapp/src/containers/controlledVocabularyPage/ControlledVocabularyTable.js
@@ -19,6 +19,9 @@ import { useGetUserSettings } from '../../service/useGetUserSettings';
import { SearchService } from '../../service/SearchService';
import { setNewEntity } from '../../utils/utils';
import { StringListTemplate } from '../../components/Templates/StringListTemplate';
+import { StringTemplate } from '../../components/Templates/StringTemplate';
+import { IdTemplate } from '../../components/Templates/IdTemplate';
+import { BooleanTemplate } from '../../components/Templates/BooleanTemplate';
export const ControlledVocabularyTable = () => {
const newTermReducer = (state, action) => {
@@ -184,41 +187,12 @@ export const ControlledVocabularyTable = () => {
);
};
- const nameBodyTemplate = (rowData) => {
- if (rowData.name) {
- return {rowData.name}
;
- }
- };
-
- const abbreviationBodyTemplate = (rowData) => {
- if (rowData.abbreviation) {
- return {rowData.abbreviation}
;
- }
- };
-
- const vocabularyBodyTemplate = (rowData) => {
- if (rowData.vocabulary && rowData.vocabulary.name) {
- return {rowData.vocabulary.name}
;
- }
- };
-
- const definitionBodyTemplate = (rowData) => {
- if (rowData.definition) {
- return {rowData.definition}
;
- }
- };
-
- const obsoleteBodyTemplate = (rowData) => {
- if (rowData && rowData.obsolete !== null && rowData.obsolete !== undefined) {
- return {JSON.stringify(rowData.obsolete)}
;
- }
- };
-
const columns = [
{
field: 'id',
header: 'Id',
sortable: false,
+ body: (rowData) => ,
},
{
field: 'name',
@@ -226,7 +200,7 @@ export const ControlledVocabularyTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.nameFilterConfig,
editor: (props) => nameEditorTemplate(props),
- body: nameBodyTemplate,
+ body: (rowData) => ,
},
{
field: 'abbreviation',
@@ -234,7 +208,7 @@ export const ControlledVocabularyTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.abbreviationFilterConfig,
editor: (props) => abbreviationEditorTemplate(props),
- body: abbreviationBodyTemplate,
+ body: (rowData) => ,
},
{
field: 'synonyms',
@@ -249,7 +223,7 @@ export const ControlledVocabularyTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.vocabularyNameFilterConfig,
editor: (props) => vocabularyEditorTemplate(props),
- body: vocabularyBodyTemplate,
+ body: (rowData) => ,
},
{
field: 'definition',
@@ -257,7 +231,7 @@ export const ControlledVocabularyTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.definitionFilterConfig,
editor: (props) => definitionEditorTemplate(props),
- body: definitionBodyTemplate,
+ body: (rowData) => ,
},
{
field: 'obsolete',
@@ -265,7 +239,7 @@ export const ControlledVocabularyTable = () => {
sortable: true,
filterConfig: FILTER_CONFIGS.obsoleteFilterConfig,
editor: (props) => obsoleteEditorTemplate(props),
- body: obsoleteBodyTemplate,
+ body: (rowData) => ,
},
];
diff --git a/src/main/cliapp/src/containers/dataLoadsPage/DataLoadsComponent.js b/src/main/cliapp/src/containers/dataLoadsPage/DataLoadsComponent.js
index 360ec99b7..936baa078 100644
--- a/src/main/cliapp/src/containers/dataLoadsPage/DataLoadsComponent.js
+++ b/src/main/cliapp/src/containers/dataLoadsPage/DataLoadsComponent.js
@@ -1,6 +1,7 @@
import React, { useReducer, useRef, useState, useContext } from 'react';
import { useQuery } from '@tanstack/react-query';
import { DataTable } from 'primereact/datatable';
+import Moment from 'react-moment';
import { Column } from 'primereact/column';
import { FileUpload } from 'primereact/fileupload';
import { Toast } from 'primereact/toast';
@@ -19,6 +20,8 @@ import { HistoryDialog } from './HistoryDialog';
import { useQueryClient } from '@tanstack/react-query';
import { SiteContext } from '../layout/SiteContext';
import { LoadingOverlay } from '../../components/LoadingOverlay';
+import moment from 'moment-timezone';
+import { NumberTemplate } from '../../components/Templates/NumberTemplate';
export const DataLoadsComponent = () => {
const { authState } = useOktaAuth();
@@ -45,7 +48,7 @@ export const DataLoadsComponent = () => {
const [bulkLoadDialog, setBulkLoadDialog] = useState(false);
const [expandedGroupRows, setExpandedGroupRows] = useState(null);
const [expandedLoadRows, setExpandedLoadRows] = useState(null);
- const [expandedFileRows, setExpandedFileRows] = useState(null);
+ //const [expandedFileRows, setExpandedFileRows] = useState(null);
const [expandedErrorLoadRows, setExpandedErrorLoadRows] = useState(null);
const [disableFormFields, setDisableFormFields] = useState(false);
const errorMessage = useRef(null);
@@ -81,7 +84,10 @@ export const DataLoadsComponent = () => {
'GeneDTO',
'AlleleDTO',
'AffectedGenomicModelDTO',
+ // 'VariantDTO',
'ConstructDTO',
+ 'AlleleGeneAssociationDTO',
+ 'ConstructGenomicEntityAssociationDTO',
],
],
['DISEASE_ANNOTATION', ['GeneDiseaseAnnotationDTO', 'AlleleDiseaseAnnotationDTO', 'AGMDiseaseAnnotationDTO']],
@@ -91,7 +97,7 @@ export const DataLoadsComponent = () => {
['GENE', ['GeneDTO']],
['ALLELE', ['AlleleDTO']],
['AGM', ['AffectedGenomicModelDTO']],
- ['VARIANT', ['VariantDTO']],
+ // ['VARIANT', ['VariantDTO']],
['CONSTRUCT', ['ConstructDTO']],
['ALLELE_ASSOCIATION', ['AlleleGeneAssociationDTO']],
['CONSTRUCT_ASSOCIATION', ['ConstructGenomicEntityAssociationDTO']],
@@ -105,8 +111,8 @@ export const DataLoadsComponent = () => {
if (group.loads) {
for (let load of group.loads) {
load.group = group.id;
- if (load.loadFiles) {
- let sortedFiles = sortFilesByDate(load.loadFiles);
+ if (load.history) {
+ let sortedFiles = sortFilesByDate(load.history);
if (sortedFiles[0].bulkloadStatus === 'FAILED') {
_errorLoads.push(load);
}
@@ -161,7 +167,7 @@ export const DataLoadsComponent = () => {
};
const urlTemplate = (rowData) => {
- return Download;
+ return Download;
};
const refresh = () => {
@@ -170,15 +176,15 @@ export const DataLoadsComponent = () => {
const runLoad = (rowData) => {
getService()
- .restartLoad(rowData.type, rowData.id)
+ .restartLoad(rowData.id)
.then((response) => {
queryClient.invalidateQueries(['bulkloadtable']);
});
};
- const runLoadFile = (rowData) => {
+ const runHistoryLoad = (rowData) => {
getService()
- .restartLoadFile(rowData.id)
+ .restartHistoryLoad(rowData.id)
.then((response) => {
queryClient.invalidateQueries(['bulkloadtable']);
});
@@ -190,9 +196,9 @@ export const DataLoadsComponent = () => {
setDisableFormFields(true);
};
- const deleteLoadFile = (rowData) => {
+ const deleteLoadFileHistory = (rowData) => {
getService()
- .deleteLoadFile(rowData.id)
+ .deleteLoadFileHistory(rowData.id)
.then((response) => {
queryClient.invalidateQueries(['bulkloadtable']);
});
@@ -236,12 +242,13 @@ export const DataLoadsComponent = () => {
}*/}
- {rowData.failedRecords > 0 && (
-
- )}
+ {rowData.counts &&
+ Object.values(rowData.counts).some((field) => field.failed !== undefined && field.failed > 0) && (
+
+ )}
);
};
@@ -276,21 +283,25 @@ export const DataLoadsComponent = () => {
setUploadConfirmDialog(false);
};
- const loadFileActionBodyTemplate = (rowData) => {
+ const loadFileActionBodyTemplate = (rowData, bulkload) => {
let ret = [];
+ // console.log(rowData);
if (
!rowData.bulkloadStatus ||
rowData.bulkloadStatus === 'FINISHED' ||
rowData.bulkloadStatus === 'FAILED' ||
rowData.bulkloadStatus === 'STOPPED'
) {
- if (fileWithinSchemaRange(rowData.linkMLSchemaVersion, rowData.loadType)) {
+ if (
+ fileWithinSchemaRange(rowData.bulkLoadFile.linkMLSchemaVersion, bulkload.backendBulkLoadType) ||
+ exemptTypes(bulkload.backendBulkLoadType)
+ ) {
ret.push(
);
};
+*/
const loadTable = (group) => {
let sortedLoads = [];
@@ -599,7 +675,7 @@ export const DataLoadsComponent = () => {
responsiveLayout="scroll"
expandedRows={expandedLoadRows}
onRowToggle={(e) => setExpandedLoadRows(e.data)}
- rowExpansionTemplate={fileTable}
+ rowExpansionTemplate={historyTable}
dataKey="id"
>