Ejemplo n.º 1
0
def completeHit(uid, code):
    hit = Hit.get(Hit.code == code)
    if hit.uid == uid:
        hit.status = 'TERMINATED'
        hit.save()
        return hit.target
    return False
Ejemplo n.º 2
0
def reassignHit(current, new):
    hit = Hit.get(Hit.uid == current)
    hit.uid = new
    hit.save()
    return {
        hit.target: {
            hit.status,
            hit.weapon.desc,
            hit.location.desc,
        }
    }