Changeset - 130df90c8278
[Not reviewed]
Bradley M. Kuhn - 11 years ago 2014-07-03 01:06:06
bkuhn@sfconservancy.org
Rename rhodecode_ini to ini
3 files changed with 14 insertions and 14 deletions:
0 comments (0 inline, 0 general)
kallithea/controllers/admin/settings.py
Show inline comments
 
@@ -365,25 +365,25 @@ class SettingsController(BaseController)
 
            recipients = [test_email] if test_email else None
 

	
 
            run_task(tasks.send_email, recipients, test_email_subj,
 
                     test_email_body, test_email_html_body)
 

	
 
            h.flash(_('Send email task created'), category='success')
 
            return redirect(url('admin_settings_email'))
 

	
 
        defaults = Setting.get_app_settings()
 
        defaults.update(self._get_hg_ui_settings())
 

	
 
        import kallithea
 
        c.rhodecode_ini = kallithea.CONFIG
 
        c.ini = kallithea.CONFIG
 

	
 
        return htmlfill.render(
 
            render('admin/settings/settings.html'),
 
            defaults=defaults,
 
            encoding="UTF-8",
 
            force_defaults=False)
 

	
 
    @HasPermissionAllDecorator('hg.admin')
 
    def settings_hooks(self):
 
        """GET /admin/settings/hooks: All items in the collection"""
 
        # url('admin_settings_hooks')
 
        c.active = 'hooks'
 
@@ -454,25 +454,25 @@ class SettingsController(BaseController)
 
            force_defaults=False)
 

	
 
    @HasPermissionAllDecorator('hg.admin')
 
    def settings_system(self):
 
        """GET /admin/settings/system: All items in the collection"""
 
        # url('admin_settings_system')
 
        c.active = 'system'
 

	
 
        defaults = Setting.get_app_settings()
 
        defaults.update(self._get_hg_ui_settings())
 

	
 
        import kallithea
 
        c.rhodecode_ini = kallithea.CONFIG
 
        c.ini = kallithea.CONFIG
 
        c.rhodecode_update_url = defaults.get('rhodecode_update_url')
 
        server_info = Setting.get_server_info()
 
        for key, val in server_info.iteritems():
 
            setattr(c, key, val)
 

	
 
        return htmlfill.render(
 
            render('admin/settings/settings.html'),
 
            defaults=defaults,
 
            encoding="UTF-8",
 
            force_defaults=False)
 

	
 
    @HasPermissionAllDecorator('hg.admin')
kallithea/templates/admin/settings/settings_email.html
Show inline comments
 
<dl class="dl-horizontal">
 
<%
 
 elems = [
 
    (_('Email prefix'), c.rhodecode_ini.get('email_prefix'), ''),
 
    (_('Kallithea email from'), c.rhodecode_ini.get('app_email_from'), ''),
 
    (_('Error email from'), c.rhodecode_ini.get('error_email_from'), ''),
 
    (_('Error email recipients'), c.rhodecode_ini.get('email_to'), ''),
 
    (_('Email prefix'), c.ini.get('email_prefix'), ''),
 
    (_('Kallithea email from'), c.ini.get('app_email_from'), ''),
 
    (_('Error email from'), c.ini.get('error_email_from'), ''),
 
    (_('Error email recipients'), c.ini.get('email_to'), ''),
 

	
 
    (_('SMTP server'), c.rhodecode_ini.get('smtp_server'), ''),
 
    (_('SMTP username'), c.rhodecode_ini.get('smtp_username'), ''),
 
    (_('SMTP password'), '%s chars' % len(c.rhodecode_ini.get('smtp_password', '')), ''),
 
    (_('SMTP port'), c.rhodecode_ini.get('smtp_port'), ''),
 
    (_('SMTP server'), c.ini.get('smtp_server'), ''),
 
    (_('SMTP username'), c.ini.get('smtp_username'), ''),
 
    (_('SMTP password'), '%s chars' % len(c.ini.get('smtp_password', '')), ''),
 
    (_('SMTP port'), c.ini.get('smtp_port'), ''),
 

	
 
    (_('SMTP use TLS'), c.rhodecode_ini.get('smtp_use_tls'), ''),
 
    (_('SMTP use SSL'), c.rhodecode_ini.get('smtp_use_ssl'), ''),
 
    (_('SMTP auth'), c.rhodecode_ini.get('smtp_auth'), ''),
 
    (_('SMTP use TLS'), c.ini.get('smtp_use_tls'), ''),
 
    (_('SMTP use SSL'), c.ini.get('smtp_use_ssl'), ''),
 
    (_('SMTP auth'), c.ini.get('smtp_auth'), ''),
 
 ]
 
%>
 
%for dt, dd, tt in elems:
 
  <dt style="width:150px; text-align: left">${dt}:</dt>
 
  <dd style="margin-left: 160px" title="${tt}">${dd}</dd>
 
%endfor
 
</dl>
 

	
 
${h.form(url('admin_settings_email'), method='post')}
 
    <div class="form">
 

	
 
        <div class="fields">
kallithea/templates/admin/settings/settings_system.html
Show inline comments
 
<dl class="dl-horizontal">
 
<%
 
 elems = [
 
    (_('Kallithea version'), h.literal('%s <b><span style="color:#036185; text-decoration: underline;cursor: pointer" id="check_for_update" >%s</span></b>' % (c.kallithea_version, _('check for updates'))), ''),
 
    (_('Python version'), c.py_version, ''),
 
    (_('Platform'), c.platform, ''),
 
    (_('GIT version'), c.git_version, ''),
 
    (_('GIT path'), c.rhodecode_ini.get('git_path'), ''),
 
    (_('GIT path'), c.ini.get('git_path'), ''),
 
    (_('Upgrade info endpoint'), h.literal('%s <br/><span style="color:#999999">%s.</span>' % (c.rhodecode_update_url, _('Note: please make sure this server can access this url'))), ''),
 
 ]
 
%>
 

	
 
<div id="update_notice" style="display: none">
 
    <div style="padding: 5px 0px 5px 0px; color: #000000; font-weight: bold">${_('Checking for updates...')}</div>
 
</div>
 
%for dt, dd, tt in elems:
 
  <dt style="width:150px; text-align: left">${dt}:</dt>
 
  <dd style="margin-left: 160px" title="${tt}">${dd}</dd>
 
%endfor
 
</dl>
0 comments (0 inline, 0 general)