${_('Built-in Mercurial Hooks (Read-Only)')}

% for hook in c.hooks: <% input_id = hook.ui_key.replace('.', '_') %>
${h.text(hook.ui_key,hook.ui_value,id=input_id,size=60,readonly="readonly",class_='form-control')}
% endfor
% if c.visual.allow_custom_hooks_settings: ${h.form(url('admin_settings_hooks'), method='post')}

${_('Custom Hooks')}

${_('Hooks can be used to trigger actions on certain events such as push / pull. They can trigger Python functions or external applications.')} %for hook in c.custom_hooks:
<% input_id = hook.ui_key.replace('.', '_') %>
${h.hidden('hook_ui_key',hook.ui_key,id='hook_ui_key_'+input_id)} ${h.hidden('hook_ui_value',hook.ui_value,id='hook_ui_value_'+input_id)} ${h.text('hook_ui_value_new',hook.ui_value,id=input_id,size=50,class_='form-control')}
%endfor
${h.text('new_hook_ui_value',size=50,class_='form-control')}
${h.submit('save',_('Save'),class_="btn btn-default")}
${h.end_form()} % endif