<%namespace file="../lib.html" import="fillform"/> <%namespace file="../lib.html" import="script_tags"/> <%namespace file="../lib.html" import="stylesheet_tags"/> <%namespace file="../lib.html" import="csrf_hidden_input"/> <%namespace file="_helpers.html" import="generateFormRow"/> <%namespace name="helpers" file="_helpers.html"/> <% sessionId = cherrypy.session.id import splunk.auth import splunk.entity as en from splunk.appserver.mrsparkle.lib.msg_pool import MsgPoolMgr, UI_MSG_POOL %> <%call expr="stylesheet_tags(cssFiles)"> % if uiHelper: % endif <% msg_obj = MsgPoolMgr.get_poolmgr_instance()[UI_MSG_POOL].pop(msgid) %> % if msg_obj: <%helpers:message content="${msg_obj.text}" level="${msg_obj.severity}"/> % endif
${_('Loading...')}
% if form_defaults: <% if isCloneAction: save_to = "_new" else: save_to = entity_name %> <% actionPath = make_url(["manager", namespace, endpoint_base, en.quoteEntity(save_to)]) eaiAttributes = form_defaults['eai:attributes'] edit_links = filter((lambda x: x[0] == 'edit'), entity.links) entity['__ns'] = entity.namespace if isCloneAction: isEditable = entity.isClonable else: isEditable = not (entity.name != '_new' and not edit_links) %> % if not isEditable: ${_("You do not have permissions to edit this configuration.")} % endif ## Used to display errors inside a popup window instead of using the messenger
% if not '__ns' in uiHelper_elements: % endif % if isCloneAction: % elif entity.name == '_new': % else: % endif ## pass through index page filter settings % for key in kwargs.keys(): % if key.startswith('f_'): % endif % endfor % if isCloneAction and 'eai:type' in form_defaults and form_defaults['eai:type'] == 'html': % endif % if uiHelper: <%call expr="fillform(form_defaults, form_errors)"> % for element in uiHelper["elements"]: <% if not isEditable: element['disabled'] = '1' %> <%call expr="generateFormRow(element, eaiAttributes, form_defaults)"> % endfor ${csrf_hidden_input()} % if not eleOnly:
% if edit_links and entity.name != "_new" and not isCloneAction: % endif % if isEditable: % endif
% endif % if kwargs.get('redirect_override') : % endif % endif
% endif