Beispiel #1
0
def render_javascripts(context):
    context.caller_stack._push_frame()
    try:
        _import_ns = {}
        _mako_get_namespace(context, '__anon_0x7f5a30573590')._populate(
            _import_ns, [u'render_individual_tagging_element'])
        h = _import_ns.get('h', context.get('h', UNDEFINED))
        trans = _import_ns.get('trans', context.get('trans', UNDEFINED))
        stored = _import_ns.get('stored', context.get('stored', UNDEFINED))
        parent = _import_ns.get('parent', context.get('parent', UNDEFINED))
        __M_writer = context.writer()
        # SOURCE LINE 10
        __M_writer(u'\n\n    ')
        # SOURCE LINE 12
        __M_writer(unicode(parent.javascripts()))
        __M_writer(
            u'\n\n    <!--[if lt IE 9]>\n      <script type=\'text/javascript\' src="'
        )
        # SOURCE LINE 15
        __M_writer(unicode(h.url_for('/static/scripts/libs/IE/excanvas.js')))
        __M_writer(u'"></script>\n    <![endif]-->\n\n    ')
        # SOURCE LINE 18
        __M_writer(
            unicode(
                h.js("libs/jquery/jquery.event.drag",
                     "libs/jquery/jquery.event.drop",
                     "libs/jquery/jquery.event.hover",
                     "libs/jquery/jquery.form", "libs/jquery/jstorage",
                     "galaxy.workflow_editor.canvas",
                     "libs/jquery/jquery.autocomplete",
                     "galaxy.autocom_tagging", "galaxy.workflows")))
        # SOURCE LINE 26
        __M_writer(
            u'\n\n    <!--[if lt IE 7]>\n    <script type=\'text/javascript\'>\n    window.lt_ie_7 = true;\n    </script>\n    <![endif]-->\n\n    <script type=\'text/javascript\'>\n        // Globals\n        workflow = null;\n        canvas_manager = null;\n        active_ajax_call = false;\n\n        var workflow_id = "'
        )
        # SOURCE LINE 40
        __M_writer(unicode(trans.security.encode_id(stored.id)))
        __M_writer(
            u'";\n\n        // URLs used by galaxy.workflows.js\n        var tool_search_url = "'
        )
        # SOURCE LINE 43
        __M_writer(unicode(h.url_for(controller='root', action='tool_search')))
        __M_writer(u'",\n            get_datatypes_url = "')
        # SOURCE LINE 44
        __M_writer(
            unicode(h.url_for(controller='workflow', action='get_datatypes')))
        __M_writer(u'",\n            load_workflow_url = "')
        # SOURCE LINE 45
        __M_writer(
            unicode(h.url_for(controller='workflow', action='load_workflow')))
        __M_writer(u'",\n            run_workflow_url = "')
        # SOURCE LINE 46
        __M_writer(
            unicode(
                h.url_for(controller='root',
                          action='index',
                          workflow_id=trans.security.encode_id(stored.id))))
        __M_writer(u'",\n            rename_async_url = "')
        # SOURCE LINE 47
        __M_writer(
            unicode(
                h.url_for(controller='workflow',
                          action='rename_async',
                          id=trans.security.encode_id(stored.id))))
        __M_writer(u'",\n            annotate_async_url = "')
        # SOURCE LINE 48
        __M_writer(
            unicode(
                h.url_for(controller='workflow',
                          action='annotate_async',
                          id=trans.security.encode_id(stored.id))))
        __M_writer(u'",\n            get_new_module_info_url = "')
        # SOURCE LINE 49
        __M_writer(
            unicode(
                h.url_for(controller='workflow',
                          action='get_new_module_info')))
        __M_writer(u'",\n            workflow_index_url = "')
        # SOURCE LINE 50
        __M_writer(unicode(h.url_for(controller='workflow', action='index')))
        __M_writer(u'",\n            save_workflow_url = "')
        # SOURCE LINE 51
        __M_writer(
            unicode(h.url_for(controller='workflow', action='save_workflow')))
        __M_writer(u'";\n\n    ')
        # SOURCE LINE 53

        from galaxy.jobs.actions.post import ActionBox

        # SOURCE LINE 55
        __M_writer(
            u'\n        // Post-job action vars.\n        var pja_list = "')
        # SOURCE LINE 57
        __M_writer(unicode(ActionBox.get_add_list()))
        __M_writer(
            u'",\n            get_pja_form = function(pja, node) {\n                var p_str = \'\';\n                // FIXME: this writes JS code; this logic should be codified in galaxy.workflows.js\n                '
        )
        # SOURCE LINE 61
        __M_writer(unicode(ActionBox.get_forms(trans)))
        __M_writer(
            u'\n                return p_str;\n            };\n\n        // NOTE: code to initialize and edit workflows is in galaxy.workflows.js\n    </script>\n'
        )
        return ''
    finally:
        context.caller_stack._pop_frame()
def render_javascripts(context):
    context.caller_stack._push_frame()
    try:
        _import_ns = {}
        _mako_get_namespace(context, '__anon_0x7f5a30573590')._populate(_import_ns, [u'render_individual_tagging_element'])
        h = _import_ns.get('h', context.get('h', UNDEFINED))
        trans = _import_ns.get('trans', context.get('trans', UNDEFINED))
        stored = _import_ns.get('stored', context.get('stored', UNDEFINED))
        parent = _import_ns.get('parent', context.get('parent', UNDEFINED))
        __M_writer = context.writer()
        # SOURCE LINE 10
        __M_writer(u'\n\n    ')
        # SOURCE LINE 12
        __M_writer(unicode(parent.javascripts()))
        __M_writer(u'\n\n    <!--[if lt IE 9]>\n      <script type=\'text/javascript\' src="')
        # SOURCE LINE 15
        __M_writer(unicode(h.url_for('/static/scripts/libs/IE/excanvas.js')))
        __M_writer(u'"></script>\n    <![endif]-->\n\n    ')
        # SOURCE LINE 18
        __M_writer(unicode(h.js( "libs/jquery/jquery.event.drag",
            "libs/jquery/jquery.event.drop",
            "libs/jquery/jquery.event.hover",
            "libs/jquery/jquery.form",
            "libs/jquery/jstorage",
            "galaxy.workflow_editor.canvas",
            "libs/jquery/jquery.autocomplete",
            "galaxy.autocom_tagging",
            "galaxy.workflows" )))
        # SOURCE LINE 26
        __M_writer(u'\n\n    <!--[if lt IE 7]>\n    <script type=\'text/javascript\'>\n    window.lt_ie_7 = true;\n    </script>\n    <![endif]-->\n\n    <script type=\'text/javascript\'>\n        // Globals\n        workflow = null;\n        canvas_manager = null;\n        active_ajax_call = false;\n\n        var workflow_id = "')
        # SOURCE LINE 40
        __M_writer(unicode(trans.security.encode_id( stored.id ) ))
        __M_writer(u'";\n\n        // URLs used by galaxy.workflows.js\n        var tool_search_url = "')
        # SOURCE LINE 43
        __M_writer(unicode(h.url_for( controller='root', action='tool_search' )))
        __M_writer(u'",\n            get_datatypes_url = "')
        # SOURCE LINE 44
        __M_writer(unicode(h.url_for( controller='workflow', action='get_datatypes' )))
        __M_writer(u'",\n            load_workflow_url = "')
        # SOURCE LINE 45
        __M_writer(unicode(h.url_for( controller='workflow', action='load_workflow' )))
        __M_writer(u'",\n            run_workflow_url = "')
        # SOURCE LINE 46
        __M_writer(unicode(h.url_for( controller='root', action='index', workflow_id=trans.security.encode_id(stored.id))))
        __M_writer(u'",\n            rename_async_url = "')
        # SOURCE LINE 47
        __M_writer(unicode(h.url_for( controller='workflow', action='rename_async', id=trans.security.encode_id(stored.id) )))
        __M_writer(u'",\n            annotate_async_url = "')
        # SOURCE LINE 48
        __M_writer(unicode(h.url_for( controller='workflow', action='annotate_async', id=trans.security.encode_id(stored.id) )))
        __M_writer(u'",\n            get_new_module_info_url = "')
        # SOURCE LINE 49
        __M_writer(unicode(h.url_for(controller='workflow', action='get_new_module_info' )))
        __M_writer(u'",\n            workflow_index_url = "')
        # SOURCE LINE 50
        __M_writer(unicode(h.url_for( controller='workflow', action='index' )))
        __M_writer(u'",\n            save_workflow_url = "')
        # SOURCE LINE 51
        __M_writer(unicode(h.url_for(controller='workflow', action='save_workflow' )))
        __M_writer(u'";\n\n    ')
        # SOURCE LINE 53

        from galaxy.jobs.actions.post import ActionBox
            
        
        # SOURCE LINE 55
        __M_writer(u'\n        // Post-job action vars.\n        var pja_list = "')
        # SOURCE LINE 57
        __M_writer(unicode(ActionBox.get_add_list()))
        __M_writer(u'",\n            get_pja_form = function(pja, node) {\n                var p_str = \'\';\n                // FIXME: this writes JS code; this logic should be codified in galaxy.workflows.js\n                ')
        # SOURCE LINE 61
        __M_writer(unicode(ActionBox.get_forms(trans)))
        __M_writer(u'\n                return p_str;\n            };\n\n        // NOTE: code to initialize and edit workflows is in galaxy.workflows.js\n    </script>\n')
        return ''
    finally:
        context.caller_stack._pop_frame()