asana_hub/transport.py
def format_task_numbers_with_links(tasks):
    """Returns formatting for the tasks section of asana."""

    project_id = data.get('asana-project', None)

    def _task_format(task_id):
        if project_id:
            asana_url = tool.ToolApp.make_asana_url(project_id, task_id)
            return "[#%d](%s)" % (task_id, asana_url)
        else:
            return "#%d" % task_id

    return "\n".join([_task_format(tid) for tid in tasks])
def format_task_numbers_with_links(tasks):
    project_id = data.get('asana-project', None)

    def _task_format(task_id):
        if project_id:
            asana_url = tool.ToolApp.make_asana_url(project_id, task_id)
            return "[#%d](%s)" % (task_id, asana_url)
        else:
            return "#%d" % task_id

    return "\n".join([_task_format(tid) for tid in tasks])
def format_task_numbers_with_links ( tasks ) : project_id = data . get ( 'asana-project' , None ) def _task_format ( task_id ) : if project_id : asana_url = tool . ToolApp . make_asana_url ( project_id , task_id ) return "[#%d](%s)" % ( task_id , asana_url ) else : return "#%d" % task_id return "\n" . join ( [ _task_format ( tid ) for tid in tasks ] )
Returns formatting for the tasks section of asana.
Returns formatting for the tasks section of asana .