def completeHit(uid, code): hit = Hit.get(Hit.code == code) if hit.uid == uid: hit.status = 'TERMINATED' hit.save() return hit.target return False
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, } }