def get_status_string(record):
    """Get the status label given a record of either data format or component"""
    if "when_revoked" not in record or "when_published" not in record or \
        "when_added" not in record:
        return None

    if record["when_revoked"] is not None:
        return "revoked"
    elif record["when_published"] is not None:
        return "published"
    else:
        return "staged"