예제 #1
0
def started(call: APICall, company_id, req_model: UpdateRequest):
    res = StartedResponse(
        **set_task_status_from_call(req_model,
                                    company_id,
                                    new_status=TaskStatus.in_progress,
                                    started=datetime.utcnow()))
    res.started = res.updated
    call.result.data_model = res
예제 #2
0
def started(call: APICall, company_id, req_model: UpdateRequest):
    res = StartedResponse(**set_task_status_from_call(
        req_model,
        company_id,
        new_status=TaskStatus.in_progress,
        min__started=datetime.utcnow(
        ),  # don't override a previous, smaller "started" field value
    ))
    res.started = res.updated
    call.result.data_model = res