clinicedc 2.0.6__py3-none-any.whl → 2.0.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of clinicedc might be problematic. Click here for more details.
- {clinicedc-2.0.6.dist-info → clinicedc-2.0.8.dist-info}/METADATA +2 -2
- {clinicedc-2.0.6.dist-info → clinicedc-2.0.8.dist-info}/RECORD +489 -441
- {clinicedc-2.0.6.dist-info → clinicedc-2.0.8.dist-info}/WHEEL +1 -1
- edc_action_item/action.py +1 -1
- edc_action_item/action_item_notification.py +2 -2
- edc_action_item/auths.py +37 -32
- edc_action_item/create_action_item.py +1 -1
- edc_action_item/decorators.py +1 -1
- edc_action_item/migrations/0001_initial.py +21 -22
- edc_action_item/migrations/0006_auto_20180707_1659.py +4 -4
- edc_action_item/migrations/0008_auto_20180809_0303.py +4 -4
- edc_action_item/migrations/0015_auto_20190114_0250.py +4 -4
- edc_action_item/migrations/0017_auto_20190305_0123.py +11 -30
- edc_action_item/migrations/0030_edcpermissions.py +3 -2
- edc_action_item/migrations/0039_alter_actionitem_auto_created_comment_and_more.py +398 -0
- edc_action_item/migrations/0040_alter_actionitem_report_datetime_and_more.py +34 -0
- edc_action_item/models/action_item.py +9 -4
- edc_action_item/models/action_model_mixin.py +5 -6
- edc_action_item/models/reference.py +2 -2
- edc_action_item/models/signals.py +22 -23
- edc_action_item/post_migrate_signals.py +1 -1
- edc_action_item/send_email.py +0 -85
- edc_action_item/site_action_items.py +5 -9
- edc_action_item/utils.py +3 -3
- edc_adherence/migrations/0005_alter_nonadherencereasons_extra_value_and_more.py +36 -0
- edc_adherence/model_mixins.py +1 -1
- edc_adverse_event/auths.py +55 -51
- edc_adverse_event/migrations/0001_initial.py +5 -4
- edc_adverse_event/migrations/0002_auto_20190802_0059.py +3 -2
- edc_adverse_event/migrations/0008_auto_20220825_0451.py +3 -2
- edc_adverse_event/migrations/0009_auto_20220907_0157.py +3 -2
- edc_adverse_event/migrations/0016_alter_aeactionclassification_device_created_and_more.py +285 -0
- edc_adverse_event/model_mixins/ae_followup/ae_followup_fields_model_mixin.py +2 -2
- edc_adverse_event/model_mixins/ae_initial/ae_initial_fields_model_mixin.py +6 -5
- edc_adverse_event/model_mixins/ae_special_interest/aesi_fields_model_mixin.py +2 -2
- edc_adverse_event/model_mixins/ae_susar/ae_susar_fields_model_mixin.py +2 -2
- edc_adverse_event/model_mixins/ae_tmg/ae_tmg_fields_model_mixin.py +15 -11
- edc_adverse_event/model_mixins/ae_tmg/ae_tmg_methods_model_mixin.py +2 -4
- edc_adverse_event/model_mixins/death_report/death_report_model_mixin.py +5 -4
- edc_adverse_event/model_mixins/death_report/death_report_tmg_model_mixin.py +6 -3
- edc_adverse_event/model_mixins/death_report/simple_death_report_model_mixin.py +2 -2
- edc_adverse_event/model_mixins/hospitaization/hospitalization_model_mixin.py +4 -3
- edc_adverse_event/modeladmin_mixins/death_report_admin_mixin.py +3 -3
- edc_adverse_event/models/signals.py +7 -7
- edc_adverse_event/templatetags/edc_adverse_event_extras.py +5 -4
- edc_adverse_event/view_mixins/ae/ae_listboard_view_mixin.py +3 -5
- edc_adverse_event/view_mixins/ae/death_report_listboard_view_mixin.py +6 -8
- edc_adverse_event/view_mixins/tmg/tmg_ae_listboard_view_mixin.py +2 -2
- edc_adverse_event/views/tmg/summary_listboard_view.py +3 -2
- edc_appointment/admin/appointment_admin.py +2 -2
- edc_appointment/admin/list_filters.py +2 -2
- edc_appointment/auths.py +14 -10
- edc_appointment/creators/appointment_creator.py +1 -1
- edc_appointment/creators/appointments_creator.py +1 -1
- edc_appointment/form_validators/appointment_form_validator.py +108 -82
- edc_appointment/migrations/0003_auto_20161127_2226.py +5 -6
- edc_appointment/migrations/0006_auto_20170106_2118.py +5 -5
- edc_appointment/migrations/0018_auto_20190305_0123.py +5 -12
- edc_appointment/migrations/0050_alter_appointment_appt_type_and_more.py +220 -0
- edc_appointment/model_mixins/appointment_fields_model_mixin.py +1 -2
- edc_appointment/model_mixins/appointment_methods_model_mixin.py +2 -3
- edc_appointment/model_mixins/appointment_model_mixin.py +31 -28
- edc_appointment/model_mixins/window_period_model_mixin.py +6 -7
- edc_appointment/models/appointment.py +1 -1
- edc_appointment/models/signals.py +44 -35
- edc_appointment/utils.py +19 -24
- edc_appointment/view_utils/appointment_button.py +2 -2
- edc_auth/admin/user_admin.py +1 -1
- edc_auth/auth_objects/__init__.py +2 -20
- edc_auth/auth_objects/default_groups.py +13 -11
- edc_auth/auth_objects/default_roles.py +26 -24
- edc_auth/auth_updater/auth_updater.py +13 -2
- edc_auth/auth_updater/group_updater.py +12 -10
- edc_auth/auth_updater/role_updater.py +2 -2
- edc_auth/constants.py +10 -0
- edc_auth/import_users.py +3 -3
- edc_auth/migrations/0001_squashed_0033_alter_userprofile_is_multisite_viewer.py +5 -5
- edc_auth/migrations/0012_auto_20191026_0034.py +3 -2
- edc_auth/migrations/0013_auto_20191026_0055.py +3 -2
- edc_auth/migrations/0025_permissions.py +3 -2
- edc_auth/migrations/0035_alter_edcpermissions_device_created_and_more.py +85 -0
- edc_auth/models/user_profile.py +14 -11
- edc_auth/post_migrate_signals.py +1 -1
- edc_auth/site_auths.py +80 -67
- edc_consent/actions.py +4 -5
- edc_consent/auths.py +18 -12
- edc_consent/migrations/0001_initial.py +3 -2
- edc_consent/migrations/0006_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_consent/model_mixins/consent_extension_model_mixin.py +4 -5
- edc_consent/model_mixins/requires_consent_fields_model_mixin.py +2 -2
- edc_consent/utils.py +1 -1
- edc_constants/constants.py +1 -0
- edc_crf/auths.py +5 -0
- edc_crf/migrations/0001_initial.py +3 -2
- edc_crf/migrations/0009_alter_crfstatus_device_created_and_more.py +54 -0
- edc_dashboard/auths.py +10 -6
- edc_dashboard/migrations/0001_initial.py +3 -2
- edc_dashboard/migrations/0006_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_dashboard/templatetags/edc_dashboard_extras.py +3 -2
- edc_dashboard/url_config.py +92 -83
- edc_dashboard/url_names.py +4 -4
- edc_dashboard/view_mixins/url_request_context_mixin.py +6 -5
- edc_data_manager/action_items.py +4 -6
- edc_data_manager/admin/actions.py +5 -5
- edc_data_manager/admin/data_query_admin.py +12 -11
- edc_data_manager/auths.py +37 -34
- edc_data_manager/handlers/handlers.py +6 -7
- edc_data_manager/migrations/0001_initial.py +19 -19
- edc_data_manager/migrations/0025_edcpermissions.py +3 -2
- edc_data_manager/migrations/0040_alter_datadictionary_device_created_and_more.py +327 -0
- edc_data_manager/migrations/0041_alter_dataquery_dm_user_and_more.py +164 -0
- edc_data_manager/models/data_query.py +5 -5
- edc_data_manager/models/model_mixins.py +8 -8
- edc_data_manager/rule/query_rule_wrapper.py +7 -7
- edc_data_manager/rule/rule_runner.py +4 -3
- edc_document_status/model_mixins.py +1 -1
- edc_egfr/egfr.py +11 -7
- edc_egfr/model_mixins/egfr_model_mixin.py +3 -7
- edc_export/admin/data_request_admin.py +2 -2
- edc_export/archive_exporter.py +7 -5
- edc_export/auths.py +32 -28
- edc_export/files_archiver.py +3 -2
- edc_export/migrations/0001_initial.py +26 -26
- edc_export/migrations/0004_auto_20190305_0123.py +25 -72
- edc_export/migrations/0013_edcpermissions.py +3 -2
- edc_export/migrations/0022_alter_datarequest_description_and_more.py +611 -0
- edc_export/migrations/0023_alter_datarequesthistory_archive_filename_and_more.py +29 -0
- edc_export/model_exporter/file_history_updater.py +10 -10
- edc_export/model_exporter/model_exporter.py +17 -15
- edc_export/model_exporter/object_history_helpers.py +2 -2
- edc_export/models/data_request_history.py +4 -4
- edc_export/utils.py +10 -15
- edc_facility/auths.py +8 -3
- edc_facility/facility.py +16 -22
- edc_facility/import_holidays.py +13 -13
- edc_facility/migrations/0005_healthfacility_healthfacilitytypes_and_more.py +8 -7
- edc_facility/migrations/0016_alter_healthfacility_device_created_and_more.py +139 -0
- edc_facility/migrations/0017_alter_healthfacility_gps_and_more.py +54 -0
- edc_facility/model_mixins.py +5 -5
- edc_form_label/custom_label_condition.py +11 -8
- edc_form_label/form_label.py +1 -1
- edc_form_runners/auths.py +11 -6
- edc_form_runners/form_runner.py +3 -5
- edc_form_runners/migrations/0001_initial.py +3 -2
- edc_form_runners/migrations/0005_alter_issue_device_created_and_more.py +49 -0
- edc_form_validators/applicable_field_validator.py +7 -6
- edc_form_validators/base_form_validator.py +8 -9
- edc_form_validators/other_specify_field_validator.py +2 -8
- edc_form_validators/required_field_validator.py +19 -16
- edc_identifier/migrations/0001_squashed_0018_auto_20180128_1054.py +3 -3
- edc_identifier/migrations/0002_auto_20190305_0123.py +3 -6
- edc_identifier/migrations/0006_auto_20161127_2226.py +15 -15
- edc_identifier/migrations/0007_auto_20161204_2227.py +3 -3
- edc_identifier/migrations/0009_auto_20161221_2323.py +3 -5
- edc_identifier/migrations/0010_auto_20170112_0602.py +17 -17
- edc_identifier/migrations/0011_alter_identifiermodel_device_created_and_more.py +79 -0
- edc_identifier/model_mixins.py +1 -1
- edc_identifier/models.py +9 -9
- edc_identifier/research_identifier.py +11 -10
- edc_identifier/simple_identifier.py +9 -5
- edc_identifier/subject_identifier.py +3 -2
- edc_lab/auths.py +26 -23
- edc_lab/lab/aliquot_creator.py +5 -8
- edc_lab/lab/primary_aliquot.py +14 -5
- edc_lab/migrations/0001_initial.py +29 -29
- edc_lab/migrations/0008_auto_20170921_0719.py +3 -3
- edc_lab/migrations/0010_auto_20171127_1541.py +15 -15
- edc_lab/migrations/0012_auto_20180114_1438.py +3 -3
- edc_lab/migrations/0019_auto_20190305_0123.py +43 -127
- edc_lab/migrations/0036_alter_aliquot_comment_alter_aliquot_device_created_and_more.py +1139 -0
- edc_lab/migrations/0037_alter_historicalorder_order_datetime_and_more.py +31 -0
- edc_lab/model_mixins/aliquot/aliquot_identifier_model_mixin.py +2 -2
- edc_lab/model_mixins/aliquot/aliquot_model_mixin.py +2 -2
- edc_lab/model_mixins/panel_model_mixin.py +18 -7
- edc_lab/model_mixins/requisition/crf_with_requisition_model_mixin.py +2 -4
- edc_lab/model_mixins/requisition/requisition_model_mixin.py +13 -16
- edc_lab/model_mixins/requisition/requisition_verify_model_mixin.py +1 -1
- edc_lab/model_mixins/result/result_item_model_mixin.py +4 -4
- edc_lab/model_mixins/shipping/manifest_model_mixin.py +4 -5
- edc_lab/model_mixins/shipping/verify_model_mixin.py +4 -6
- edc_lab/models/aliquot.py +2 -2
- edc_lab/models/box.py +1 -1
- edc_lab/models/box_item.py +6 -7
- edc_lab/models/manifest/manifest.py +3 -3
- edc_lab/models/manifest/manifest_item.py +7 -7
- edc_lab/models/manifest/shipper.py +3 -4
- edc_lab/models/order.py +6 -4
- edc_lab/models/panel.py +4 -4
- edc_lab/models/result.py +2 -2
- edc_lab/models/result_item.py +2 -2
- edc_lab_dashboard/auths.py +16 -11
- edc_lab_dashboard/migrations/0001_initial.py +3 -2
- edc_lab_dashboard/migrations/0005_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_lab_dashboard/views/action_views/receive_view.py +2 -2
- edc_lab_dashboard/views/action_views/verify_box_item_view.py +2 -2
- edc_lab_results/calculate_missing.py +8 -8
- edc_lab_results/form_validator_mixins/blood_results_form_validator_mixin.py +2 -2
- edc_lab_results/get_summary.py +26 -25
- edc_lab_results/model_mixins/blood_result_model_mixin.py +9 -7
- edc_lab_results/model_mixins/fbg_model_mixin.py +3 -3
- edc_lab_results/model_mixins/glucose_model_mixin.py +3 -3
- edc_lab_results/model_mixins/hba1c_model_mixin.py +3 -3
- edc_label/auths.py +6 -1
- edc_label/label_template.py +8 -8
- edc_label/migrations/0001_initial.py +3 -2
- edc_label/migrations/0007_alter_zpllabeltemplates_device_created_and_more.py +49 -0
- edc_list_data/list_model_maker.py +2 -2
- edc_list_data/load_list_data.py +11 -14
- edc_list_data/load_model_data.py +3 -3
- edc_list_data/model_mixins.py +12 -4
- edc_list_data/post_migrate_signals.py +1 -1
- edc_list_data/preload_data.py +4 -4
- edc_list_data/row.py +1 -1
- edc_list_data/site_list_data.py +6 -5
- edc_listboard/migrations/0001_initial.py +3 -2
- edc_listboard/migrations/0007_alter_listboard_device_created_and_more.py +49 -0
- edc_locator/auths.py +18 -13
- edc_locator/migrations/0001_initial.py +7 -7
- edc_locator/migrations/0018_auto_20190305_0123.py +5 -12
- edc_locator/migrations/0040_alter_historicalsubjectlocator_action_identifier_and_more.py +187 -0
- edc_locator/migrations/0041_alter_historicalsubjectlocator_report_datetime_and_more.py +27 -0
- edc_locator/model_mixins/locator_model_mixin.py +2 -2
- edc_locator/model_mixins/subject_contact_fields_mixin.py +1 -1
- edc_locator/modeladmin_mixins.py +5 -4
- edc_ltfu/model_mixins.py +7 -5
- edc_metadata/auths.py +11 -7
- edc_metadata/metadata/metadata.py +1 -1
- edc_metadata/metadata_rules/crf/crf_rule.py +1 -1
- edc_metadata/metadata_rules/decorators.py +1 -1
- edc_metadata/metadata_rules/metadata_rule_evaluator.py +5 -3
- edc_metadata/metadata_rules/rule.py +2 -3
- edc_metadata/metadata_rules/rule_evaluator.py +1 -1
- edc_metadata/migrations/0002_auto_20161127_2226.py +5 -5
- edc_metadata/migrations/0005_auto_20170112_0602.py +5 -5
- edc_metadata/migrations/0011_auto_20190305_0123.py +5 -12
- edc_metadata/migrations/0031_alter_crfmetadata_device_created_and_more.py +120 -0
- edc_metadata/model_mixins/updates/updates_crf_metadata_model_mixin.py +7 -4
- edc_metadata/model_mixins/updates/updates_requisition_metadata_model_mixin.py +5 -2
- edc_metadata/models/crf_metadata.py +5 -5
- edc_metadata/models/crf_metadata_model_mixin.py +4 -5
- edc_metadata/models/requisition_metadata.py +6 -6
- edc_metadata/models/signals.py +10 -11
- edc_metadata/views/refresh_metadata_actions_view.py +3 -3
- edc_model/models/address_mixin.py +6 -6
- edc_model/models/fields/initials_field.py +2 -1
- edc_model/models/historical_records.py +2 -9
- edc_model/models/url_model_mixin.py +2 -2
- edc_model/validators/date.py +7 -8
- edc_model_admin/list_filters/future_date_list_filter.py +3 -3
- edc_model_admin/list_filters/past_date_list_filter.py +3 -3
- edc_model_admin/mixins/model_admin_protect_pii_mixin.py +4 -5
- edc_model_fields/fields/other_charfield.py +2 -2
- edc_navbar/auths.py +18 -13
- edc_navbar/migrations/0004_auto_20220825_0451.py +3 -2
- edc_navbar/migrations/0009_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_notification/auths.py +9 -4
- edc_notification/migrations/0001_initial.py +3 -3
- edc_notification/migrations/0004_auto_20190305_0123.py +3 -6
- edc_notification/migrations/0011_alter_notification_device_created_and_more.py +59 -0
- edc_notification/models/notification.py +1 -1
- edc_notification/notification/graded_event_notification.py +2 -2
- edc_notification/notification/model_notification.py +3 -30
- edc_notification/notification/new_model_notification.py +1 -1
- edc_notification/notification/notification.py +12 -12
- edc_notification/notification/updated_model_notification.py +2 -2
- edc_offstudy/auths.py +12 -7
- edc_offstudy/migrations/0001_initial.py +4 -4
- edc_offstudy/migrations/0002_auto_20180921_0434.py +4 -4
- edc_offstudy/migrations/0005_auto_20190305_0123.py +5 -12
- edc_offstudy/migrations/0023_alter_historicalsubjectoffstudy_action_identifier_and_more.py +188 -0
- edc_offstudy/migrations/0024_alter_historicalsubjectoffstudy_offstudy_datetime_and_more.py +43 -0
- edc_offstudy/model_mixins/offstudy_model_mixin.py +3 -2
- edc_pdutils/df_exporters/csv_exporter.py +33 -37
- edc_pdutils/df_exporters/csv_model_exporter.py +7 -3
- edc_pdutils/migrations/0001_initial.py +8 -8
- edc_pharmacy/admin/prescription/rx_refill_admin.py +4 -3
- edc_pharmacy/admin/reports/stock_availability_admin.py +5 -6
- edc_pharmacy/auths.py +19 -15
- edc_pharmacy/migrations/0001_initial.py +64 -63
- edc_pharmacy/migrations/0015_auto_20220913_2139.py +26 -26
- edc_pharmacy/migrations/0024_allocation_assignment_containerunits_dispense_and_more.py +81 -86
- edc_pharmacy/migrations/0037_remove_historicalstock_confirmed_at_site_by_and_more.py +5 -5
- edc_pharmacy/migrations/0039_remove_dispense_registered_subject_and_more.py +7 -8
- edc_pharmacy/migrations/0049_remove_stocktransferconfirmation_stock_and_more.py +12 -12
- edc_pharmacy/migrations/0050_remove_stocktransferconfirmation2_location_and_more.py +5 -5
- edc_pharmacy/migrations/0051_alter_historicalstocktransferconfirmationitem_options_and_more.py +3 -4
- edc_pharmacy/migrations/0053_alter_location_managers_alter_historicalstock_lot_and_more.py +3 -3
- edc_pharmacy/migrations/0057_scanduplicates.py +3 -3
- edc_pharmacy/migrations/0060_alter_container_max_per_subject_and_more.py +13 -15
- edc_pharmacy/migrations/0068_stockout.py +2 -3
- edc_pharmacy/migrations/0076_historicalstockadjustment_stockadjustment.py +5 -5
- edc_pharmacy/migrations/0077_historicalstockadjustment_adjustment_datetime_and_more.py +3 -4
- edc_pharmacy/migrations/0081_historicalconfirmation_confirmation.py +8 -8
- edc_pharmacy/migrations/0084_confirmationatsiteitem_and_more.py +0 -2
- edc_pharmacy/migrations/0089_alter_allocation_allocated_by_and_more.py +3284 -0
- edc_pharmacy/migrations/0090_alter_allocation_allocation_datetime_and_more.py +227 -0
- edc_pharmacy/model_mixins/study_medication_refill_model_mixin.py +2 -2
- edc_pharmacy/models/medication/formulation.py +5 -7
- edc_pharmacy/models/medication/medication.py +3 -3
- edc_pharmacy/models/model_mixins.py +10 -11
- edc_pharmacy/models/prescription/rx.py +13 -12
- edc_pharmacy/models/prescription/rx_refill.py +0 -1
- edc_pharmacy/models/stock/allocation.py +3 -3
- edc_pharmacy/models/stock/confirmation.py +3 -3
- edc_pharmacy/models/stock/confirmation_at_site.py +3 -2
- edc_pharmacy/models/stock/confirmation_at_site_item.py +3 -4
- edc_pharmacy/models/stock/dispense.py +5 -6
- edc_pharmacy/models/stock/dispense_item.py +2 -2
- edc_pharmacy/models/stock/location.py +3 -4
- edc_pharmacy/models/stock/lot.py +6 -7
- edc_pharmacy/models/stock/order.py +1 -1
- edc_pharmacy/models/stock/receive.py +3 -3
- edc_pharmacy/models/stock/receive_item.py +4 -4
- edc_pharmacy/models/stock/repack_request.py +2 -2
- edc_pharmacy/models/stock/stock.py +12 -18
- edc_pharmacy/models/stock/stock_adjustment.py +4 -4
- edc_pharmacy/models/stock/stock_request.py +2 -2
- edc_pharmacy/models/stock/stock_request_item.py +2 -2
- edc_pharmacy/models/stock/stock_transfer.py +3 -3
- edc_pharmacy/models/stock/stock_transfer_item.py +2 -2
- edc_pharmacy/models/stock/storage_bin.py +3 -4
- edc_pharmacy/models/stock/storage_bin_item.py +2 -2
- edc_pharmacy/models/stock/supplier.py +3 -4
- edc_pharmacy/models/storage/box.py +2 -2
- edc_pharmacy/models/storage/items/container_model_mixin.py +3 -4
- edc_pharmacy/models/storage/items/pill_bottle_model_mixin.py +2 -2
- edc_pharmacy/models/storage/items/subject_pill_bottle.py +1 -1
- edc_pharmacy/models/storage/room.py +2 -2
- edc_pharmacy/models/storage/shelf.py +2 -2
- edc_pharmacy/models/storage/utils.py +1 -1
- edc_pharmacy/prescribe/create_prescription.py +3 -3
- edc_pharmacy/utils/allocate_stock.py +2 -3
- edc_pharmacy/utils/confirm_stock.py +3 -4
- edc_pharmacy/utils/confirm_stock_at_site.py +4 -5
- edc_pharmacy/utils/dispense.py +3 -4
- edc_pharmacy/utils/process_repack_request.py +4 -5
- edc_pharmacy/utils/stock_request/bulk_create_stock_request_items.py +2 -3
- edc_pharmacy/utils/transfer_stock.py +2 -3
- edc_pharmacy/views/add_to_storage_bin_view.py +2 -2
- edc_pharmacy/views/allocate_to_subject_view.py +2 -2
- edc_pharmacy/views/confirmation_at_site_view.py +6 -9
- edc_pharmacy/views/dispense_view.py +2 -2
- edc_pharmacy/views/move_to_storage_bin_view.py +2 -3
- edc_pharmacy/views/print_labels_view.py +2 -2
- edc_prn/admin_site.py +5 -0
- edc_prn/prn.py +10 -11
- edc_prn/urls.py +11 -0
- edc_protocol/research_protocol_config.py +2 -3
- edc_protocol_incident/action_items.py +4 -4
- edc_protocol_incident/auths.py +27 -20
- edc_protocol_incident/migrations/0001_initial.py +7 -7
- edc_protocol_incident/migrations/0001_squashed_0015_auto_20220927_0401.py +13 -13
- edc_protocol_incident/migrations/0005_protocolincident_historicalprotocolincident_and_more.py +7 -7
- edc_protocol_incident/migrations/0024_alter_actionsrequired_extra_value_and_more.py +625 -0
- edc_protocol_incident/migrations/0025_alter_historicalprotocoldeviationviolation_report_datetime_and_more.py +42 -0
- edc_protocol_incident/model_mixins/protocol_deviation_violation_model_mixin.py +18 -11
- edc_protocol_incident/model_mixins/protocol_incident_model_mixin.py +26 -11
- edc_pylabels/actions.py +3 -5
- edc_pylabels/auths.py +6 -1
- edc_pylabels/migrations/0002_alter_label_options_label_created_and_more.py +3 -7
- edc_pylabels/migrations/0005_labelconfiguration_delete_label_and_more.py +3 -3
- edc_pylabels/migrations/0013_alter_labelconfiguration_device_created_and_more.py +49 -0
- edc_qareports/auths.py +11 -7
- edc_qareports/migrations/0001_initial.py +4 -5
- edc_qareports/migrations/0005_edcpermissions.py +3 -3
- edc_qareports/migrations/0006_qareportlog.py +2 -3
- edc_qareports/migrations/0019_alter_edcpermissions_device_created_and_more.py +102 -0
- edc_qareports/migrations/0020_alter_note_report_datetime_and_more.py +24 -0
- edc_qareports/model_mixins/note_model_mixin.py +7 -4
- edc_qareports/model_mixins/on_study_missing_values_model_mixin.py +4 -4
- edc_qareports/model_mixins/qa_report_model_mixin.py +2 -3
- edc_qareports/models/note.py +4 -4
- edc_qareports/models/qa_reports_log.py +2 -3
- edc_randomization/admin.py +30 -24
- edc_randomization/auths.py +12 -7
- edc_randomization/decorators.py +1 -1
- edc_randomization/migrations/0001_initial.py +3 -2
- edc_randomization/migrations/0002_historicalrandomizationlist.py +3 -2
- edc_randomization/migrations/0009_edcpermissions.py +3 -2
- edc_randomization/migrations/0014_alter_edcpermissions_device_created_and_more.py +141 -0
- edc_randomization/model_mixins.py +9 -9
- edc_randomization/randomizer.py +22 -20
- edc_randomization/utils.py +19 -18
- edc_refusal/auths.py +7 -2
- edc_refusal/migrations/0001_initial.py +4 -4
- edc_refusal/migrations/0002_historicalsubjectrefusal.py +4 -4
- edc_refusal/migrations/0012_alter_historicalsubjectrefusal_comment_and_more.py +122 -0
- edc_refusal/migrations/0013_alter_historicalsubjectrefusal_report_datetime_and_more.py +28 -0
- edc_refusal/model_mixins.py +4 -4
- edc_registration/auths.py +28 -23
- edc_registration/migrations/0002_auto_20161127_2226.py +3 -4
- edc_registration/migrations/0005_auto_20170111_1809.py +4 -2
- edc_registration/migrations/0016_historicalregisteredsubject.py +3 -2
- edc_registration/migrations/0017_auto_20190305_0123.py +5 -12
- edc_registration/migrations/0033_alter_historicalregisteredsubject_additional_key_and_more.py +302 -0
- edc_registration/model_mixins/updates_or_creates_registered_subject_model_mixin.py +15 -7
- edc_registration/models/registered_subject.py +28 -27
- edc_reportable/age_evaluator.py +4 -2
- edc_reportable/formula.py +5 -5
- edc_reportable/migrations/0001_initial.py +7 -7
- edc_reportable/migrations/0003_referencerangecollection_grade1_and_more.py +3 -3
- edc_reportable/migrations/0004_alter_referencerangecollection_grade3_and_more.py +5 -5
- edc_reportable/migrations/0006_alter_gradingdata_revision_and_more.py +5 -6
- edc_reportable/migrations/0007_alter_gradingdata_age_phrase_and_more.py +509 -0
- edc_reportable/models/normal_data.py +4 -5
- edc_reportable/models/reference_model_mixins.py +10 -11
- edc_reportable/models/reference_range_collection.py +12 -13
- edc_reportable/post_migrate_signals.py +1 -1
- edc_reportable/utils/convert_units.py +11 -45
- edc_reportable/utils/get_normal_data_or_raise.py +2 -2
- edc_reportable/utils/get_reference_range_collection.py +2 -3
- edc_reportable/utils/load_data.py +4 -4
- edc_reportable/utils/update_grading_data.py +5 -5
- edc_review_dashboard/auths.py +23 -18
- edc_review_dashboard/migrations/0001_initial.py +3 -2
- edc_review_dashboard/migrations/0006_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_screening/age_evaluator.py +6 -6
- edc_screening/auths.py +35 -30
- edc_screening/eligibility.py +1 -1
- edc_screening/gender_evaluator.py +1 -1
- edc_screening/migrations/0001_initial.py +3 -2
- edc_screening/migrations/0005_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_screening/model_mixins/eligibility_model_mixin.py +3 -6
- edc_screening/model_mixins/screening_fields_model_mixin.py +6 -8
- edc_screening/model_mixins/screening_methods_model_mixin.py +1 -1
- edc_screening/screening_eligibility.py +2 -4
- edc_screening/utils.py +9 -9
- edc_search/generate_slug.py +26 -0
- edc_search/model_mixins.py +10 -22
- edc_sites/auths.py +8 -3
- edc_sites/migrations/0007_edcpermissions.py +3 -2
- edc_sites/migrations/0010_alter_edcpermissions_device_created_and_more.py +69 -0
- edc_sites/model_mixins/site_model_mixin.py +2 -2
- edc_sites/site.py +5 -5
- edc_sites/system_checks.py +1 -1
- edc_subject_dashboard/auths.py +27 -22
- edc_subject_dashboard/migrations/0001_initial.py +3 -2
- edc_subject_dashboard/migrations/0005_alter_edcpermissions_device_created_and_more.py +49 -0
- edc_subject_dashboard/requisition_report.py +6 -4
- edc_subject_dashboard/requisition_verifier.py +6 -6
- edc_subject_dashboard/templatetags/edc_subject_dashboard_extras.py +2 -2
- edc_subject_dashboard/view_mixins/subject_visit_view_mixin.py +7 -8
- edc_subject_dashboard/view_utils/subject_consent_listboard_button.py +3 -2
- edc_subject_dashboard/view_utils/timepoint_status_button.py +2 -2
- edc_timepoint/apps.py +0 -21
- edc_timepoint/model_mixins.py +22 -20
- edc_transfer/model_mixins.py +4 -4
- edc_transfer/modeladmin_mixins.py +1 -1
- edc_unblinding/auths.py +9 -4
- edc_unblinding/migrations/0001_initial.py +13 -13
- edc_unblinding/migrations/0014_alter_historicalunblindingrequest_action_identifier_and_more.py +291 -0
- edc_unblinding/migrations/0015_alter_historicalunblindingrequest_report_datetime_and_more.py +45 -0
- edc_unblinding/models/unblinding_request.py +2 -2
- edc_unblinding/models/unblinding_review.py +3 -3
- edc_utils/__init__.py +3 -1
- edc_utils/age.py +10 -16
- edc_utils/show_urls.py +29 -2
- edc_visit_schedule/auths.py +6 -1
- edc_visit_schedule/migrations/0001_initial.py +3 -3
- edc_visit_schedule/migrations/0002_auto_20190305_0123.py +3 -6
- edc_visit_schedule/migrations/0003_historicalvisitschedule_visitschedule.py +5 -4
- edc_visit_schedule/migrations/0015_historicalonschedule_offschedule_onschedule.py +10 -10
- edc_visit_schedule/migrations/0019_alter_historicalonschedule_device_created_and_more.py +229 -0
- edc_visit_schedule/migrations/0020_alter_historicalonschedule_onschedule_datetime_and_more.py +65 -0
- edc_visit_schedule/model_mixins/off_schedule_model_mixin.py +5 -4
- edc_visit_schedule/model_mixins/on_schedule_model_mixin.py +5 -4
- edc_visit_schedule/model_mixins/visit_schedule/visit_code_fields_model_mixin.py +1 -1
- edc_visit_schedule/models/subject_schedule_history.py +6 -6
- edc_visit_schedule/schedule/visit_collection.py +1 -1
- edc_visit_schedule/site_visit_schedules.py +2 -2
- edc_visit_schedule/subject_schedule.py +5 -4
- edc_visit_schedule/view_mixins.py +2 -3
- edc_visit_schedule/visit/visit.py +3 -2
- edc_visit_tracking/migrations/0004_subjectvisit_subjectvisitmissedreasons_extra_value_and_more.py +13 -13
- edc_visit_tracking/migrations/0009_alter_historicalsubjectvisit_comments_and_more.py +450 -0
- edc_visit_tracking/migrations/0010_alter_historicalsubjectvisit_report_datetime_and_more.py +68 -0
- edc_visit_tracking/model_mixins/base/visit_methods_model_mixin.py +3 -3
- edc_visit_tracking/model_mixins/crfs/visit_tracking_crf_model_mixin.py +2 -2
- edc_visit_tracking/model_mixins/requisitions/visit_tracking_requisition_model_mixin.py +2 -2
- edc_visit_tracking/model_mixins/subject_visit_missed_model_mixin.py +2 -2
- edc_visit_tracking/model_mixins/visit_model_mixin/caretaker_fields_mixin.py +2 -3
- edc_visit_tracking/model_mixins/visit_model_mixin/previous_visit_model_mixin.py +1 -1
- edc_visit_tracking/model_mixins/visit_model_mixin/visit_model_fields_mixin.py +8 -11
- edc_visit_tracking/model_mixins/visit_model_mixin/visit_model_mixin.py +1 -1
- edc_visit_tracking/models/signals.py +3 -3
- edc_visit_tracking/models/subject_visit.py +1 -1
- edc_vitals/calculators/bmi.py +7 -5
- edc_vitals/utils.py +1 -1
- edc_form_label/models.py +0 -0
- edc_search/constants.py +0 -1
- edc_search/models.py +0 -0
- edc_search/search_slug.py +0 -50
- edc_search/updater.py +0 -30
- edc_search/wsgi.py +0 -7
- {clinicedc-2.0.6.dist-info → clinicedc-2.0.8.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
from __future__ import annotations
|
|
2
2
|
|
|
3
|
+
import contextlib
|
|
3
4
|
from typing import TYPE_CHECKING, Any
|
|
4
5
|
|
|
5
6
|
from django.core.exceptions import ObjectDoesNotExist
|
|
7
|
+
from django.utils import timezone
|
|
6
8
|
|
|
7
|
-
from edc_utils import get_utcnow
|
|
8
9
|
from edc_visit_schedule.models import VisitSchedule
|
|
9
10
|
|
|
10
11
|
if TYPE_CHECKING:
|
|
@@ -46,8 +47,8 @@ class SubjectVisitViewMixin:
|
|
|
46
47
|
self._related_visit = self.appointment.related_visit
|
|
47
48
|
except AttributeError as e:
|
|
48
49
|
raise SubjectVisitViewMixinError(
|
|
49
|
-
"Visit model must have a OneToOne relation to appointment.
|
|
50
|
-
)
|
|
50
|
+
f"Visit model must have a OneToOne relation to appointment. Got {e}"
|
|
51
|
+
) from e
|
|
51
52
|
return self._related_visit
|
|
52
53
|
|
|
53
54
|
def get_visit_schedule(self) -> VisitSchedule | None:
|
|
@@ -60,10 +61,8 @@ class SubjectVisitViewMixin:
|
|
|
60
61
|
schedule_name=self.appointment.schedule_name,
|
|
61
62
|
visit_code=self.appointment.visit_code,
|
|
62
63
|
)
|
|
63
|
-
|
|
64
|
+
with contextlib.suppress(ObjectDoesNotExist):
|
|
64
65
|
visit_schedule = VisitSchedule.objects.get(**opts)
|
|
65
|
-
except ObjectDoesNotExist:
|
|
66
|
-
pass
|
|
67
66
|
return visit_schedule
|
|
68
67
|
|
|
69
68
|
@property
|
|
@@ -76,7 +75,7 @@ class SubjectVisitViewMixin:
|
|
|
76
75
|
try:
|
|
77
76
|
self._report_datetime = self.appointment.appt_datetime
|
|
78
77
|
except AttributeError:
|
|
79
|
-
self._report_datetime =
|
|
78
|
+
self._report_datetime = timezone.now()
|
|
80
79
|
return self._report_datetime
|
|
81
80
|
|
|
82
81
|
def has_appointment_attr_or_raise(self) -> None:
|
|
@@ -89,5 +88,5 @@ class SubjectVisitViewMixin:
|
|
|
89
88
|
if "appointment" in str(e):
|
|
90
89
|
raise SubjectVisitViewMixinError(
|
|
91
90
|
f"Mixin must be declared together with AppointmentViewMixin. Got {e}"
|
|
92
|
-
)
|
|
91
|
+
) from e
|
|
93
92
|
raise
|
|
@@ -5,10 +5,11 @@ from dataclasses import dataclass, field
|
|
|
5
5
|
from typing import TYPE_CHECKING, TypeVar
|
|
6
6
|
from uuid import UUID
|
|
7
7
|
|
|
8
|
+
from django.utils import timezone
|
|
9
|
+
|
|
8
10
|
from edc_consent import site_consents
|
|
9
11
|
from edc_pdutils.site import Site
|
|
10
12
|
from edc_protocol.research_protocol_config import ResearchProtocolConfig
|
|
11
|
-
from edc_utils import get_utcnow
|
|
12
13
|
from edc_view_utils import ModelButton
|
|
13
14
|
|
|
14
15
|
if TYPE_CHECKING:
|
|
@@ -42,7 +43,7 @@ class SubjectConsentListboardButton(ModelButton):
|
|
|
42
43
|
|
|
43
44
|
def __post_init__(self):
|
|
44
45
|
cdef = site_consents.get_consent_definition(
|
|
45
|
-
report_datetime=
|
|
46
|
+
report_datetime=timezone.now(),
|
|
46
47
|
screening_model=self.screening_obj._meta.label_lower,
|
|
47
48
|
)
|
|
48
49
|
self.model_cls = cdef.model_cls
|
|
@@ -3,6 +3,7 @@ from __future__ import annotations
|
|
|
3
3
|
from dataclasses import dataclass, field
|
|
4
4
|
from typing import TYPE_CHECKING, TypeVar
|
|
5
5
|
|
|
6
|
+
from django.utils import timezone
|
|
6
7
|
from django.utils.translation import gettext as _
|
|
7
8
|
|
|
8
9
|
from edc_appointment.constants import (
|
|
@@ -13,7 +14,6 @@ from edc_appointment.constants import (
|
|
|
13
14
|
SKIPPED_APPT,
|
|
14
15
|
)
|
|
15
16
|
from edc_appointment.view_utils import AppointmentButton
|
|
16
|
-
from edc_utils import get_utcnow
|
|
17
17
|
|
|
18
18
|
if TYPE_CHECKING:
|
|
19
19
|
from edc_visit_tracking.model_mixins import VisitModelMixin
|
|
@@ -79,7 +79,7 @@ class TimepointStatusButton(AppointmentButton):
|
|
|
79
79
|
elif self.model_obj.appt_status == INCOMPLETE_APPT:
|
|
80
80
|
color = self.colors[INCOMPLETE] # default / grey
|
|
81
81
|
elif self.model_obj.appt_status == NEW_APPT:
|
|
82
|
-
if self.model_obj.appt_datetime <=
|
|
82
|
+
if self.model_obj.appt_datetime <= timezone.now():
|
|
83
83
|
color = self.colors[NEW_LATE] # warning / orange
|
|
84
84
|
else:
|
|
85
85
|
color = self.colors[NEW]
|
edc_timepoint/apps.py
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import sys
|
|
2
2
|
|
|
3
3
|
from django.apps import AppConfig as DjangoAppConfig
|
|
4
|
-
from django.conf import settings
|
|
5
4
|
|
|
6
5
|
from edc_appointment.constants import COMPLETE_APPT
|
|
7
6
|
|
|
@@ -35,23 +34,3 @@ class AppConfig(DjangoAppConfig):
|
|
|
35
34
|
for model in self.timepoints:
|
|
36
35
|
sys.stdout.write(f" * '{model}' is a timepoint model.\n")
|
|
37
36
|
sys.stdout.write(f" Done loading {self.verbose_name}.\n")
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
if settings.APP_NAME == "edc_timepoint":
|
|
41
|
-
from dateutil.relativedelta import FR, MO, SA, SU, TH, TU, WE
|
|
42
|
-
|
|
43
|
-
from edc_facility.apps import AppConfig as BaseEdcFacilityAppConfig
|
|
44
|
-
|
|
45
|
-
class EdcFacilityAppConfig(BaseEdcFacilityAppConfig):
|
|
46
|
-
definitions = {
|
|
47
|
-
"7-day-clinic": dict(
|
|
48
|
-
days=[MO, TU, WE, TH, FR, SA, SU],
|
|
49
|
-
slots=[100, 100, 100, 100, 100, 100, 100],
|
|
50
|
-
),
|
|
51
|
-
"5-day-clinic": dict(days=[MO, TU, WE, TH, FR], slots=[100, 100, 100, 100, 100]),
|
|
52
|
-
"3-day-clinic": dict(
|
|
53
|
-
days=[TU, WE, TH],
|
|
54
|
-
slots=[100, 100, 100],
|
|
55
|
-
best_effort_available_datetime=True,
|
|
56
|
-
),
|
|
57
|
-
}
|
edc_timepoint/model_mixins.py
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
from django.apps import apps as django_apps
|
|
2
2
|
from django.core.exceptions import ImproperlyConfigured
|
|
3
3
|
from django.db import models
|
|
4
|
-
|
|
5
|
-
from edc_utils import get_utcnow
|
|
4
|
+
from django.utils import timezone
|
|
6
5
|
|
|
7
6
|
from .choices import TIMEPOINT_STATUS
|
|
8
7
|
from .constants import CLOSED_TIMEPOINT, FEEDBACK, OPEN_TIMEPOINT
|
|
@@ -12,10 +11,17 @@ from .timepoint_lookup import TimepointLookup
|
|
|
12
11
|
from .utils import get_enable_timepoint_checks
|
|
13
12
|
|
|
14
13
|
|
|
15
|
-
class UnableToCloseTimepoint(Exception):
|
|
14
|
+
class UnableToCloseTimepoint(Exception): # noqa: N818
|
|
16
15
|
pass
|
|
17
16
|
|
|
18
17
|
|
|
18
|
+
MODEL_NOT_REGISTERED = (
|
|
19
|
+
"Model not registered. Model '{label_lower}' is not registered "
|
|
20
|
+
"in AppConfig as a timepoint. "
|
|
21
|
+
"See AppConfig for 'edc_timepoint'."
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
|
|
19
25
|
class TimepointLookupModelMixin(models.Model):
|
|
20
26
|
"""Makes a model lookup the timepoint model instance on `save`
|
|
21
27
|
and check if it is a closed before allowing a create or update.
|
|
@@ -59,15 +65,14 @@ class TimepointModelMixin(models.Model):
|
|
|
59
65
|
timepoint_closed_datetime = models.DateTimeField(null=True, editable=False)
|
|
60
66
|
|
|
61
67
|
def save(self, *args, **kwargs):
|
|
62
|
-
if self.enabled_as_timepoint
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
)
|
|
70
|
-
self.timepoint_open_or_raise()
|
|
68
|
+
if self.enabled_as_timepoint and (
|
|
69
|
+
kwargs.get("update_fields") != ["timepoint_status"]
|
|
70
|
+
and kwargs.get("update_fields")
|
|
71
|
+
!= ["timepoint_opened_datetime", "timepoint_status"]
|
|
72
|
+
and kwargs.get("update_fields")
|
|
73
|
+
!= ["timepoint_closed_datetime", "timepoint_status"]
|
|
74
|
+
):
|
|
75
|
+
self.timepoint_open_or_raise()
|
|
71
76
|
super().save(*args, **kwargs)
|
|
72
77
|
|
|
73
78
|
def update_timepoint(self):
|
|
@@ -95,12 +100,10 @@ class TimepointModelMixin(models.Model):
|
|
|
95
100
|
app_config = django_apps.get_app_config("edc_timepoint")
|
|
96
101
|
try:
|
|
97
102
|
timepoint = app_config.timepoints.get(self._meta.label_lower)
|
|
98
|
-
except KeyError:
|
|
103
|
+
except KeyError as e:
|
|
99
104
|
raise TimepointConfigError(
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
f"See AppConfig for 'edc_timepoint'."
|
|
103
|
-
)
|
|
105
|
+
MODEL_NOT_REGISTERED.format(label_lower=self._meta.label_lower)
|
|
106
|
+
) from e
|
|
104
107
|
if getattr(self, timepoint.status_field) != timepoint.closed_status:
|
|
105
108
|
self.timepoint_status = OPEN_TIMEPOINT
|
|
106
109
|
self.timepoint_closed_datetime = None
|
|
@@ -122,7 +125,7 @@ class TimepointModelMixin(models.Model):
|
|
|
122
125
|
status = getattr(self, timepoint.status_field)
|
|
123
126
|
if status == timepoint.closed_status:
|
|
124
127
|
self.timepoint_status = CLOSED_TIMEPOINT
|
|
125
|
-
self.timepoint_closed_datetime =
|
|
128
|
+
self.timepoint_closed_datetime = timezone.now()
|
|
126
129
|
self.save(update_fields=["timepoint_status"])
|
|
127
130
|
else:
|
|
128
131
|
raise UnableToCloseTimepoint(
|
|
@@ -146,8 +149,7 @@ class TimepointModelMixin(models.Model):
|
|
|
146
149
|
return '<span style="color:red;">Closed</span>'
|
|
147
150
|
if self.timepoint_status == FEEDBACK:
|
|
148
151
|
return '<span style="color:orange;">Feedback</span>'
|
|
149
|
-
|
|
150
|
-
# timepoint.allow_tags = True
|
|
152
|
+
return None
|
|
151
153
|
|
|
152
154
|
class Meta:
|
|
153
155
|
abstract = True
|
edc_transfer/model_mixins.py
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
from django.conf import settings
|
|
2
2
|
from django.db import models
|
|
3
|
+
from django.utils import timezone
|
|
3
4
|
from django_crypto_fields.fields import EncryptedTextField
|
|
4
5
|
|
|
5
6
|
from edc_action_item.models import ActionModelMixin
|
|
@@ -8,7 +9,6 @@ from edc_identifier.model_mixins import UniqueSubjectIdentifierFieldMixin
|
|
|
8
9
|
from edc_model import models as edc_models
|
|
9
10
|
from edc_sites.model_mixins import SiteModelMixin
|
|
10
11
|
from edc_utils import convert_php_dateformat
|
|
11
|
-
from edc_utils.date import get_utcnow
|
|
12
12
|
|
|
13
13
|
from .choices import TRANSFER_INITIATORS
|
|
14
14
|
from .constants import SUBJECT_TRANSFER_ACTION
|
|
@@ -23,10 +23,10 @@ class SubjectTransferModelMixin(
|
|
|
23
23
|
action_name = SUBJECT_TRANSFER_ACTION
|
|
24
24
|
|
|
25
25
|
report_datetime = models.DateTimeField(
|
|
26
|
-
verbose_name="Report Date and Time", default=
|
|
26
|
+
verbose_name="Report Date and Time", default=timezone.now
|
|
27
27
|
)
|
|
28
28
|
|
|
29
|
-
transfer_date = models.DateField(verbose_name="Transfer date", default=
|
|
29
|
+
transfer_date = models.DateField(verbose_name="Transfer date", default=timezone.now)
|
|
30
30
|
|
|
31
31
|
initiated_by = models.CharField(
|
|
32
32
|
verbose_name="Who initiated the transfer request",
|
|
@@ -53,7 +53,7 @@ class SubjectTransferModelMixin(
|
|
|
53
53
|
)
|
|
54
54
|
|
|
55
55
|
may_contact = models.CharField(
|
|
56
|
-
verbose_name=
|
|
56
|
+
verbose_name="Is the participant willing to be contacted at the end of the study?",
|
|
57
57
|
max_length=15,
|
|
58
58
|
choices=YES_NO,
|
|
59
59
|
)
|
edc_unblinding/auths.py
CHANGED
|
@@ -9,7 +9,12 @@ from .auth_objects import (
|
|
|
9
9
|
unblinding_reviewers,
|
|
10
10
|
)
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
site_auths.
|
|
15
|
-
site_auths.
|
|
12
|
+
|
|
13
|
+
def update_site_auths() -> None:
|
|
14
|
+
site_auths.add_group(*unblinding_requestors, name=UNBLINDING_REQUESTORS)
|
|
15
|
+
site_auths.add_group(*unblinding_reviewers, name=UNBLINDING_REVIEWERS)
|
|
16
|
+
site_auths.add_role(UNBLINDING_REQUESTORS, name=UNBLINDING_REQUESTORS_ROLE)
|
|
17
|
+
site_auths.add_role(UNBLINDING_REVIEWERS, name=UNBLINDING_REVIEWERS_ROLE)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
update_site_auths()
|
|
@@ -17,7 +17,7 @@ from django.db import migrations, models
|
|
|
17
17
|
|
|
18
18
|
import edc_identifier.managers
|
|
19
19
|
import edc_sites.models
|
|
20
|
-
import
|
|
20
|
+
import django.utils.timezone
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
class Migration(migrations.Migration):
|
|
@@ -81,14 +81,14 @@ class Migration(migrations.Migration):
|
|
|
81
81
|
"created",
|
|
82
82
|
models.DateTimeField(
|
|
83
83
|
blank=True,
|
|
84
|
-
default=
|
|
84
|
+
default=django.utils.timezone.now,
|
|
85
85
|
),
|
|
86
86
|
),
|
|
87
87
|
(
|
|
88
88
|
"modified",
|
|
89
89
|
models.DateTimeField(
|
|
90
90
|
blank=True,
|
|
91
|
-
default=
|
|
91
|
+
default=django.utils.timezone.now,
|
|
92
92
|
),
|
|
93
93
|
),
|
|
94
94
|
(
|
|
@@ -163,7 +163,7 @@ class Migration(migrations.Migration):
|
|
|
163
163
|
(
|
|
164
164
|
"report_datetime",
|
|
165
165
|
models.DateTimeField(
|
|
166
|
-
default=
|
|
166
|
+
default=django.utils.timezone.now,
|
|
167
167
|
verbose_name="Report Date and Time",
|
|
168
168
|
),
|
|
169
169
|
),
|
|
@@ -257,14 +257,14 @@ class Migration(migrations.Migration):
|
|
|
257
257
|
"created",
|
|
258
258
|
models.DateTimeField(
|
|
259
259
|
blank=True,
|
|
260
|
-
default=
|
|
260
|
+
default=django.utils.timezone.now,
|
|
261
261
|
),
|
|
262
262
|
),
|
|
263
263
|
(
|
|
264
264
|
"modified",
|
|
265
265
|
models.DateTimeField(
|
|
266
266
|
blank=True,
|
|
267
|
-
default=
|
|
267
|
+
default=django.utils.timezone.now,
|
|
268
268
|
),
|
|
269
269
|
),
|
|
270
270
|
(
|
|
@@ -339,7 +339,7 @@ class Migration(migrations.Migration):
|
|
|
339
339
|
(
|
|
340
340
|
"report_datetime",
|
|
341
341
|
models.DateTimeField(
|
|
342
|
-
default=
|
|
342
|
+
default=django.utils.timezone.now,
|
|
343
343
|
verbose_name="Report Date and Time",
|
|
344
344
|
),
|
|
345
345
|
),
|
|
@@ -452,14 +452,14 @@ class Migration(migrations.Migration):
|
|
|
452
452
|
"created",
|
|
453
453
|
models.DateTimeField(
|
|
454
454
|
blank=True,
|
|
455
|
-
default=
|
|
455
|
+
default=django.utils.timezone.now,
|
|
456
456
|
),
|
|
457
457
|
),
|
|
458
458
|
(
|
|
459
459
|
"modified",
|
|
460
460
|
models.DateTimeField(
|
|
461
461
|
blank=True,
|
|
462
|
-
default=
|
|
462
|
+
default=django.utils.timezone.now,
|
|
463
463
|
),
|
|
464
464
|
),
|
|
465
465
|
(
|
|
@@ -542,7 +542,7 @@ class Migration(migrations.Migration):
|
|
|
542
542
|
(
|
|
543
543
|
"report_datetime",
|
|
544
544
|
models.DateTimeField(
|
|
545
|
-
default=
|
|
545
|
+
default=django.utils.timezone.now,
|
|
546
546
|
verbose_name="Report Date and Time",
|
|
547
547
|
),
|
|
548
548
|
),
|
|
@@ -661,14 +661,14 @@ class Migration(migrations.Migration):
|
|
|
661
661
|
"created",
|
|
662
662
|
models.DateTimeField(
|
|
663
663
|
blank=True,
|
|
664
|
-
default=
|
|
664
|
+
default=django.utils.timezone.now,
|
|
665
665
|
),
|
|
666
666
|
),
|
|
667
667
|
(
|
|
668
668
|
"modified",
|
|
669
669
|
models.DateTimeField(
|
|
670
670
|
blank=True,
|
|
671
|
-
default=
|
|
671
|
+
default=django.utils.timezone.now,
|
|
672
672
|
),
|
|
673
673
|
),
|
|
674
674
|
(
|
|
@@ -751,7 +751,7 @@ class Migration(migrations.Migration):
|
|
|
751
751
|
(
|
|
752
752
|
"report_datetime",
|
|
753
753
|
models.DateTimeField(
|
|
754
|
-
default=
|
|
754
|
+
default=django.utils.timezone.now,
|
|
755
755
|
verbose_name="Report Date and Time",
|
|
756
756
|
),
|
|
757
757
|
),
|
edc_unblinding/migrations/0014_alter_historicalunblindingrequest_action_identifier_and_more.py
ADDED
|
@@ -0,0 +1,291 @@
|
|
|
1
|
+
# Generated by Django 5.2.6 on 2025-09-17 16:53
|
|
2
|
+
|
|
3
|
+
from django.db import migrations, models
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class Migration(migrations.Migration):
|
|
7
|
+
|
|
8
|
+
dependencies = [
|
|
9
|
+
("edc_unblinding", "0013_alter_historicalunblindingrequest_revision_and_more"),
|
|
10
|
+
]
|
|
11
|
+
|
|
12
|
+
operations = [
|
|
13
|
+
migrations.AlterField(
|
|
14
|
+
model_name="historicalunblindingrequest",
|
|
15
|
+
name="action_identifier",
|
|
16
|
+
field=models.CharField(
|
|
17
|
+
blank=True, db_index=True, default="", max_length=50
|
|
18
|
+
),
|
|
19
|
+
),
|
|
20
|
+
migrations.AlterField(
|
|
21
|
+
model_name="historicalunblindingrequest",
|
|
22
|
+
name="action_item_reason",
|
|
23
|
+
field=models.TextField(default="", editable=False),
|
|
24
|
+
),
|
|
25
|
+
migrations.AlterField(
|
|
26
|
+
model_name="historicalunblindingrequest",
|
|
27
|
+
name="device_created",
|
|
28
|
+
field=models.CharField(
|
|
29
|
+
blank=True, default="", max_length=10, verbose_name="Device created"
|
|
30
|
+
),
|
|
31
|
+
),
|
|
32
|
+
migrations.AlterField(
|
|
33
|
+
model_name="historicalunblindingrequest",
|
|
34
|
+
name="device_modified",
|
|
35
|
+
field=models.CharField(
|
|
36
|
+
blank=True, default="", max_length=10, verbose_name="Device modified"
|
|
37
|
+
),
|
|
38
|
+
),
|
|
39
|
+
migrations.AlterField(
|
|
40
|
+
model_name="historicalunblindingrequest",
|
|
41
|
+
name="locale_created",
|
|
42
|
+
field=models.CharField(
|
|
43
|
+
blank=True,
|
|
44
|
+
default="",
|
|
45
|
+
help_text="Auto-updated by Modeladmin",
|
|
46
|
+
max_length=10,
|
|
47
|
+
verbose_name="Locale created",
|
|
48
|
+
),
|
|
49
|
+
),
|
|
50
|
+
migrations.AlterField(
|
|
51
|
+
model_name="historicalunblindingrequest",
|
|
52
|
+
name="locale_modified",
|
|
53
|
+
field=models.CharField(
|
|
54
|
+
blank=True,
|
|
55
|
+
default="",
|
|
56
|
+
help_text="Auto-updated by Modeladmin",
|
|
57
|
+
max_length=10,
|
|
58
|
+
verbose_name="Locale modified",
|
|
59
|
+
),
|
|
60
|
+
),
|
|
61
|
+
migrations.AlterField(
|
|
62
|
+
model_name="historicalunblindingrequest",
|
|
63
|
+
name="parent_action_identifier",
|
|
64
|
+
field=models.CharField(
|
|
65
|
+
blank=True,
|
|
66
|
+
default="",
|
|
67
|
+
help_text="action identifier that links to parent reference model instance.",
|
|
68
|
+
max_length=30,
|
|
69
|
+
),
|
|
70
|
+
),
|
|
71
|
+
migrations.AlterField(
|
|
72
|
+
model_name="historicalunblindingrequest",
|
|
73
|
+
name="related_action_identifier",
|
|
74
|
+
field=models.CharField(
|
|
75
|
+
blank=True,
|
|
76
|
+
default="",
|
|
77
|
+
help_text="action identifier that links to related reference model instance.",
|
|
78
|
+
max_length=30,
|
|
79
|
+
),
|
|
80
|
+
),
|
|
81
|
+
migrations.AlterField(
|
|
82
|
+
model_name="historicalunblindingreview",
|
|
83
|
+
name="action_identifier",
|
|
84
|
+
field=models.CharField(
|
|
85
|
+
blank=True, db_index=True, default="", max_length=50
|
|
86
|
+
),
|
|
87
|
+
),
|
|
88
|
+
migrations.AlterField(
|
|
89
|
+
model_name="historicalunblindingreview",
|
|
90
|
+
name="action_item_reason",
|
|
91
|
+
field=models.TextField(default="", editable=False),
|
|
92
|
+
),
|
|
93
|
+
migrations.AlterField(
|
|
94
|
+
model_name="historicalunblindingreview",
|
|
95
|
+
name="comment",
|
|
96
|
+
field=models.TextField(default="", verbose_name="Comment"),
|
|
97
|
+
),
|
|
98
|
+
migrations.AlterField(
|
|
99
|
+
model_name="historicalunblindingreview",
|
|
100
|
+
name="device_created",
|
|
101
|
+
field=models.CharField(
|
|
102
|
+
blank=True, default="", max_length=10, verbose_name="Device created"
|
|
103
|
+
),
|
|
104
|
+
),
|
|
105
|
+
migrations.AlterField(
|
|
106
|
+
model_name="historicalunblindingreview",
|
|
107
|
+
name="device_modified",
|
|
108
|
+
field=models.CharField(
|
|
109
|
+
blank=True, default="", max_length=10, verbose_name="Device modified"
|
|
110
|
+
),
|
|
111
|
+
),
|
|
112
|
+
migrations.AlterField(
|
|
113
|
+
model_name="historicalunblindingreview",
|
|
114
|
+
name="locale_created",
|
|
115
|
+
field=models.CharField(
|
|
116
|
+
blank=True,
|
|
117
|
+
default="",
|
|
118
|
+
help_text="Auto-updated by Modeladmin",
|
|
119
|
+
max_length=10,
|
|
120
|
+
verbose_name="Locale created",
|
|
121
|
+
),
|
|
122
|
+
),
|
|
123
|
+
migrations.AlterField(
|
|
124
|
+
model_name="historicalunblindingreview",
|
|
125
|
+
name="locale_modified",
|
|
126
|
+
field=models.CharField(
|
|
127
|
+
blank=True,
|
|
128
|
+
default="",
|
|
129
|
+
help_text="Auto-updated by Modeladmin",
|
|
130
|
+
max_length=10,
|
|
131
|
+
verbose_name="Locale modified",
|
|
132
|
+
),
|
|
133
|
+
),
|
|
134
|
+
migrations.AlterField(
|
|
135
|
+
model_name="historicalunblindingreview",
|
|
136
|
+
name="parent_action_identifier",
|
|
137
|
+
field=models.CharField(
|
|
138
|
+
blank=True,
|
|
139
|
+
default="",
|
|
140
|
+
help_text="action identifier that links to parent reference model instance.",
|
|
141
|
+
max_length=30,
|
|
142
|
+
),
|
|
143
|
+
),
|
|
144
|
+
migrations.AlterField(
|
|
145
|
+
model_name="historicalunblindingreview",
|
|
146
|
+
name="related_action_identifier",
|
|
147
|
+
field=models.CharField(
|
|
148
|
+
blank=True,
|
|
149
|
+
default="",
|
|
150
|
+
help_text="action identifier that links to related reference model instance.",
|
|
151
|
+
max_length=30,
|
|
152
|
+
),
|
|
153
|
+
),
|
|
154
|
+
migrations.AlterField(
|
|
155
|
+
model_name="unblindingrequest",
|
|
156
|
+
name="action_identifier",
|
|
157
|
+
field=models.CharField(blank=True, default="", max_length=50, unique=True),
|
|
158
|
+
),
|
|
159
|
+
migrations.AlterField(
|
|
160
|
+
model_name="unblindingrequest",
|
|
161
|
+
name="action_item_reason",
|
|
162
|
+
field=models.TextField(default="", editable=False),
|
|
163
|
+
),
|
|
164
|
+
migrations.AlterField(
|
|
165
|
+
model_name="unblindingrequest",
|
|
166
|
+
name="device_created",
|
|
167
|
+
field=models.CharField(
|
|
168
|
+
blank=True, default="", max_length=10, verbose_name="Device created"
|
|
169
|
+
),
|
|
170
|
+
),
|
|
171
|
+
migrations.AlterField(
|
|
172
|
+
model_name="unblindingrequest",
|
|
173
|
+
name="device_modified",
|
|
174
|
+
field=models.CharField(
|
|
175
|
+
blank=True, default="", max_length=10, verbose_name="Device modified"
|
|
176
|
+
),
|
|
177
|
+
),
|
|
178
|
+
migrations.AlterField(
|
|
179
|
+
model_name="unblindingrequest",
|
|
180
|
+
name="locale_created",
|
|
181
|
+
field=models.CharField(
|
|
182
|
+
blank=True,
|
|
183
|
+
default="",
|
|
184
|
+
help_text="Auto-updated by Modeladmin",
|
|
185
|
+
max_length=10,
|
|
186
|
+
verbose_name="Locale created",
|
|
187
|
+
),
|
|
188
|
+
),
|
|
189
|
+
migrations.AlterField(
|
|
190
|
+
model_name="unblindingrequest",
|
|
191
|
+
name="locale_modified",
|
|
192
|
+
field=models.CharField(
|
|
193
|
+
blank=True,
|
|
194
|
+
default="",
|
|
195
|
+
help_text="Auto-updated by Modeladmin",
|
|
196
|
+
max_length=10,
|
|
197
|
+
verbose_name="Locale modified",
|
|
198
|
+
),
|
|
199
|
+
),
|
|
200
|
+
migrations.AlterField(
|
|
201
|
+
model_name="unblindingrequest",
|
|
202
|
+
name="parent_action_identifier",
|
|
203
|
+
field=models.CharField(
|
|
204
|
+
blank=True,
|
|
205
|
+
default="",
|
|
206
|
+
help_text="action identifier that links to parent reference model instance.",
|
|
207
|
+
max_length=30,
|
|
208
|
+
),
|
|
209
|
+
),
|
|
210
|
+
migrations.AlterField(
|
|
211
|
+
model_name="unblindingrequest",
|
|
212
|
+
name="related_action_identifier",
|
|
213
|
+
field=models.CharField(
|
|
214
|
+
blank=True,
|
|
215
|
+
default="",
|
|
216
|
+
help_text="action identifier that links to related reference model instance.",
|
|
217
|
+
max_length=30,
|
|
218
|
+
),
|
|
219
|
+
),
|
|
220
|
+
migrations.AlterField(
|
|
221
|
+
model_name="unblindingreview",
|
|
222
|
+
name="action_identifier",
|
|
223
|
+
field=models.CharField(blank=True, default="", max_length=50, unique=True),
|
|
224
|
+
),
|
|
225
|
+
migrations.AlterField(
|
|
226
|
+
model_name="unblindingreview",
|
|
227
|
+
name="action_item_reason",
|
|
228
|
+
field=models.TextField(default="", editable=False),
|
|
229
|
+
),
|
|
230
|
+
migrations.AlterField(
|
|
231
|
+
model_name="unblindingreview",
|
|
232
|
+
name="comment",
|
|
233
|
+
field=models.TextField(default="", verbose_name="Comment"),
|
|
234
|
+
),
|
|
235
|
+
migrations.AlterField(
|
|
236
|
+
model_name="unblindingreview",
|
|
237
|
+
name="device_created",
|
|
238
|
+
field=models.CharField(
|
|
239
|
+
blank=True, default="", max_length=10, verbose_name="Device created"
|
|
240
|
+
),
|
|
241
|
+
),
|
|
242
|
+
migrations.AlterField(
|
|
243
|
+
model_name="unblindingreview",
|
|
244
|
+
name="device_modified",
|
|
245
|
+
field=models.CharField(
|
|
246
|
+
blank=True, default="", max_length=10, verbose_name="Device modified"
|
|
247
|
+
),
|
|
248
|
+
),
|
|
249
|
+
migrations.AlterField(
|
|
250
|
+
model_name="unblindingreview",
|
|
251
|
+
name="locale_created",
|
|
252
|
+
field=models.CharField(
|
|
253
|
+
blank=True,
|
|
254
|
+
default="",
|
|
255
|
+
help_text="Auto-updated by Modeladmin",
|
|
256
|
+
max_length=10,
|
|
257
|
+
verbose_name="Locale created",
|
|
258
|
+
),
|
|
259
|
+
),
|
|
260
|
+
migrations.AlterField(
|
|
261
|
+
model_name="unblindingreview",
|
|
262
|
+
name="locale_modified",
|
|
263
|
+
field=models.CharField(
|
|
264
|
+
blank=True,
|
|
265
|
+
default="",
|
|
266
|
+
help_text="Auto-updated by Modeladmin",
|
|
267
|
+
max_length=10,
|
|
268
|
+
verbose_name="Locale modified",
|
|
269
|
+
),
|
|
270
|
+
),
|
|
271
|
+
migrations.AlterField(
|
|
272
|
+
model_name="unblindingreview",
|
|
273
|
+
name="parent_action_identifier",
|
|
274
|
+
field=models.CharField(
|
|
275
|
+
blank=True,
|
|
276
|
+
default="",
|
|
277
|
+
help_text="action identifier that links to parent reference model instance.",
|
|
278
|
+
max_length=30,
|
|
279
|
+
),
|
|
280
|
+
),
|
|
281
|
+
migrations.AlterField(
|
|
282
|
+
model_name="unblindingreview",
|
|
283
|
+
name="related_action_identifier",
|
|
284
|
+
field=models.CharField(
|
|
285
|
+
blank=True,
|
|
286
|
+
default="",
|
|
287
|
+
help_text="action identifier that links to related reference model instance.",
|
|
288
|
+
max_length=30,
|
|
289
|
+
),
|
|
290
|
+
),
|
|
291
|
+
]
|