diff --git a/tests/fixtures/timeseries/timeseries_contributors.json b/tests/fixtures/timeseries/timeseries_contributors.json new file mode 100644 index 0000000000000000000000000000000000000000..d010d1015498d3bae7560bd8931f81910c0f811d --- /dev/null +++ b/tests/fixtures/timeseries/timeseries_contributors.json @@ -0,0 +1,6 @@ +[ + { + "request_id": "7f0df73a-bd0f-48b9-bb17-d5cd36f89598", + "timeseries_ids": [1, 2] + } +] diff --git a/toardb/timeseries/models_contributor.py b/toardb/timeseries/models_contributor.py new file mode 100644 index 0000000000000000000000000000000000000000..228f25932f22f48e6ba814f5be177d940a10aa8f --- /dev/null +++ b/toardb/timeseries/models_contributor.py @@ -0,0 +1,16 @@ +# SPDX-FileCopyrightText: 2021 Forschungszentrum Jülich GmbH +# SPDX-License-Identifier: MIT + +""" +class TimeseriesContributorList (Base) +====================================== +""" +from sqlalchemy import Column, Integer, String, ARRAY, Table +from toardb.base import Base + + +s1_contributors_table = Table('services.s1_contributors', Base.metadata, + Column('request_id', String(32), primary_key=True, nullable=False), + Column('timeseries_ids',ARRAY(Integer)) +) +