def import_patients(): """ Uses the Reporting REST API to import patients """ for domain_name in find_domains_with_toggle_enabled( toggles.OPENMRS_INTEGRATION): import_patients_to_domain(domain_name)
def track_changes(): """ Uses the OpenMRS Atom Feed to track changes """ domains = find_domains_with_toggle_enabled(toggles.OPENMRS_INTEGRATION) for domain in domains: poll_openmrs_atom_feeds.delay(domain)
def track_changes(): """ Uses the OpenMRS Atom Feed to track changes """ domains = find_domains_with_toggle_enabled(toggles.OPENMRS_INTEGRATION) for domain in domains: poll_openmrs_atom_feeds.delay(domain)
def test_find_domains_with_toggle_enabled(self): domain_toggle = StaticToggle( 'domain_toggle', 'A test toggle', TAG_CUSTOM, [NAMESPACE_USER] ) domain, = find_domains_with_toggle_enabled(domain_toggle) self.assertEqual(domain, self.domain)
def test_find_domains_with_toggle_enabled(self): domain_toggle = StaticToggle( 'domain_toggle', 'A test toggle', TAG_CUSTOM, [NAMESPACE_USER] ) domain, = find_domains_with_toggle_enabled(domain_toggle) self.assertEqual(domain, self.domain)
def send_datasets_for_all_domains(): for domain_name in find_domains_with_toggle_enabled( toggles.DHIS2_INTEGRATION): send_datasets(domain_name)
def send_datasets_for_all_domains(): for domain_name in find_domains_with_toggle_enabled(toggles.DHIS2_INTEGRATION): send_datasets(domain_name)
def import_patients(): """ Uses the Reporting REST API to import patients """ for domain_name in find_domains_with_toggle_enabled(toggles.OPENMRS_INTEGRATION): import_patients_to_domain(domain_name)