From 987595854671660af86a768a560af398c0f2eb09 Mon Sep 17 00:00:00 2001 From: erikvw Date: Mon, 25 Mar 2024 02:14:24 -0500 Subject: [PATCH 1/2] update paths --- edc_export/archive_exporter.py | 2 +- edc_export/model_exporter/model_exporter.py | 2 +- edc_export/tests/tests/test_model_exporter.py | 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/edc_export/archive_exporter.py b/edc_export/archive_exporter.py index c8f696e..564332a 100644 --- a/edc_export/archive_exporter.py +++ b/edc_export/archive_exporter.py @@ -3,7 +3,7 @@ from tempfile import mkdtemp from typing import TYPE_CHECKING, Type -from edc_pdutils import CsvModelExporter +from edc_pdutils.df_exporters import CsvModelExporter from edc_sites.site import sites from edc_utils import get_utcnow diff --git a/edc_export/model_exporter/model_exporter.py b/edc_export/model_exporter/model_exporter.py index 3c0da5e..245d0ed 100644 --- a/edc_export/model_exporter/model_exporter.py +++ b/edc_export/model_exporter/model_exporter.py @@ -4,7 +4,7 @@ from django.apps import apps as django_apps from django.core.exceptions import ValidationError -from edc_pdutils import ValueGetter +from edc_pdutils.model_to_dataframe import ValueGetter from edc_utils import get_utcnow from ..utils import get_export_folder diff --git a/edc_export/tests/tests/test_model_exporter.py b/edc_export/tests/tests/test_model_exporter.py index 084970d..42eeebb 100644 --- a/edc_export/tests/tests/test_model_exporter.py +++ b/edc_export/tests/tests/test_model_exporter.py @@ -3,7 +3,8 @@ from django.test import TestCase, override_settings from edc_facility.import_holidays import import_holidays -from edc_pdutils import CsvModelExporter, ModelToDataframe +from edc_pdutils.df_exporters import CsvModelExporter +from edc_pdutils.model_to_dataframe import ModelToDataframe from edc_utils import get_utcnow from edc_visit_schedule.site_visit_schedules import site_visit_schedules From f384eca23b9320fb56d3fc3a2370b9777b6cdf29 Mon Sep 17 00:00:00 2001 From: erikvw Date: Mon, 25 Mar 2024 02:16:00 -0500 Subject: [PATCH 2/2] fix test models --- export_app/models.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/export_app/models.py b/export_app/models.py index 83dd9e4..b20d7cc 100644 --- a/export_app/models.py +++ b/export_app/models.py @@ -3,6 +3,7 @@ from django.db import models from django.db.models.deletion import PROTECT from django_crypto_fields.fields import EncryptedCharField +from edc_consent.managers import ConsentObjectsByCdefManager, CurrentSiteByCdefManager from edc_constants.constants import YES from edc_crf.model_mixins import CrfWithActionModelMixin from edc_identifier.managers import SubjectIdentifierManager @@ -65,6 +66,9 @@ class SubjectConsent( class SubjectConsentV1(SubjectConsent): + on_site = CurrentSiteByCdefManager() + objects = ConsentObjectsByCdefManager() + class Meta: proxy = True