示例#1
0
def refresh_caches(org, caches):

    if OrgCache.boundaries in caches:
        Boundary.fetch_boundaries(org)

    if OrgCache.main_polls in caches:
        refresh_main_poll.delay(org.pk)

    if OrgCache.brick_polls in caches:
        refresh_brick_polls.delay(org.pk)

    if OrgCache.other_polls in caches:
        refresh_other_polls.delay(org.pk)

    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)
示例#2
0
def refresh_caches(org, caches):

    if OrgCache.boundaries in caches:
        Boundary.fetch_boundaries(org)

    if OrgCache.main_polls in caches:
        refresh_main_poll.delay(org.pk)

    if OrgCache.brick_polls in caches:
        refresh_brick_polls.delay(org.pk)

    if OrgCache.other_polls in caches:
        refresh_other_polls.delay(org.pk)

    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)

    if OrgCache.recent_reporters in caches:
        fetch_contacts_task.delay(org.pk)

    if OrgCache.all_reporters in caches:
        fetch_contacts_task.delay(org.pk, True)
示例#3
0
def refresh_caches(org, caches):

    if OrgCache.boundaries in caches:
        Org.rebuild_org_boundaries_task(org)

    if OrgCache.main_polls in caches:
        refresh_main_poll.delay(org.pk)

    if OrgCache.brick_polls in caches:
        refresh_brick_polls.delay(org.pk)

    if OrgCache.other_polls in caches:
        refresh_other_polls.delay(org.pk)

    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)

    if OrgCache.reporters in caches:
        refresh_org_reporters.delay(org.pk)

    if OrgCache.graphs_data in caches:
        refresh_org_graphs_data.delay(org.pk)
示例#4
0
def refresh_caches(org, caches):

    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)
示例#5
0
def refresh_caches(org, caches):
    from ureport.polls.tasks import refresh_org_flows

    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)
示例#6
0
def refresh_caches(org, caches):
    from ureport.polls.tasks import refresh_org_flows
    if OrgCache.flows in caches:
        refresh_org_flows.delay(org.pk)