Changeset - 9c90be87ae05
[Not reviewed]
beta
0 3 0
Marcin Kuzminski - 13 years ago 2012-09-07 17:53:14
marcin@python-works.com
fixed issue #560 require push ssl checkbox wasn't shown when option was enabled
3 files changed with 9 insertions and 2 deletions:
0 comments (0 inline, 0 general)
rhodecode/controllers/admin/settings.py
Show inline comments
 
@@ -51,6 +51,7 @@ from rhodecode.model.user import UserMod
 
from rhodecode.model.db import User
 
from rhodecode.model.notification import EmailNotificationModel
 
from rhodecode.model.meta import Session
 
from rhodecode.lib.utils2 import str2bool
 

	
 
log = logging.getLogger(__name__)
 

	
 
@@ -471,6 +472,9 @@ class SettingsController(BaseController)
 
            if k == '/':
 
                k = 'root_path'
 

	
 
            if k == 'push_ssl':
 
                v = str2bool(v)
 

	
 
            if k.find('.') != -1:
 
                k = k.replace('.', '_')
 

	
 
@@ -478,5 +482,4 @@ class SettingsController(BaseController)
 
                v = each.ui_active
 

	
 
            settings[each.ui_section + '_' + k] = v
 

	
 
        return settings
rhodecode/model/db.py
Show inline comments
 
@@ -278,6 +278,10 @@ class RhodeCodeUi(Base, BaseModel):
 

	
 
        Session().add(new_ui)
 

	
 
    def __repr__(self):
 
        return '<DB:%s[%s:%s]>' % (self.__class__.__name__, self.ui_key,
 
                                   self.ui_value)
 

	
 

	
 
class User(Base, BaseModel):
 
    __tablename__ = 'users'
rhodecode/templates/admin/settings/settings.html
Show inline comments
 
@@ -186,7 +186,7 @@
 
                </div>
 
                <div class="checkboxes">
 
					<div class="checkbox">
 
						${h.checkbox('web_push_ssl','true')}
 
						${h.checkbox('web_push_ssl', 'True')}
 
						<label for="web_push_ssl">${_('require ssl for vcs operations')}</label>
 
					</div>
 
                    <span class="help-block">${_('RhodeCode will require SSL for pushing or pulling. If SSL is missing it will return HTTP Error 406: Not Acceptable')}</span>
0 comments (0 inline, 0 general)