コード例 #1
0
ファイル: sync.py プロジェクト: reneluria/tapiriik
def sync_trigger_partial_sync_callback(req, service):
    from sync_remote_triggers import trigger_remote
    svc = Service.FromID(service)
    affected_connection_external_ids = svc.ExternalIDsForPartialSyncTrigger(req)

    trigger_remote.apply_async(args=[service, affected_connection_external_ids])
    return HttpResponse(status=204)
コード例 #2
0
ファイル: sync.py プロジェクト: zegerk/tapiriik
def sync_trigger_partial_sync_callback(req, service):
    from sync_remote_triggers import trigger_remote
    svc = Service.FromID(service)
    affected_connection_external_ids = svc.ExternalIDsForPartialSyncTrigger(
        req)

    trigger_remote.apply_async(
        args=[service, affected_connection_external_ids])
    return HttpResponse(status=204)
コード例 #3
0
def sync_trigger_partial_sync_callback(req, service):
    svc = Service.FromID(service)
    if req.method == "POST":
        from sync_remote_triggers import trigger_remote
        affected_connection_external_ids = svc.ExternalIDsForPartialSyncTrigger(req)
        trigger_remote.apply_async(args=[service, affected_connection_external_ids])
        return HttpResponse(status=204)
    elif req.method == "GET":
        return svc.PartialSyncTriggerGET(req)
    else:
        return HttpResponse(status=400)