src/cm/templates/site/settings_design.html
author Simon Descarpentries <sid@sopinspace.com>
Mon, 21 Oct 2013 16:37:07 +0200
changeset 553 bf26fb47a14c
parent 167 0444040c4877
child 565 95a5c06c4008
permissions -rw-r--r--
To allow scrolling in Safari mobile, we set the content of text_view_comments frame in a jQuery UI layout. So the automated scrolling operations in c_sync.js must be adjustable to the right part to scroll. Also, if a comment have to be shown outside of the current viewport, we scroll the correct part to that viewport and then set the comment top Y offset to juste what it needs to avoid the "Add comment" button after scrolling operation. If not in Safari mobile, we add an offset here to avoid comment to display under the "Add comment" button.

{% extends "site/layout/base_workspace_form.html" %}
{% load i18n %}
{% load com %}

{% block title %}{% blocktrans %}Settings{% endblocktrans %}{% endblock %}

{% block head %}
{% endblock %}

{% block pre_form %}

<script type="text/javascript">
<!--
tb_conf['current_tab'] = 'settings';
-->
</script>

<div id="settings" class="tab-meta">   

<ul class="sub_list">
    <li><a href="{% url settings %}">{% blocktrans %}General{% endblocktrans %}</a></li>
    <li> / </li>
    <li class="active_sub">{% blocktrans %}Appearance{% endblocktrans %}</li>
</ul>

{% endblock %}

{% block buttons %}
    <input name="cancel" type="button" id="cancel_button" value="{% blocktrans %}Cancel{% endblocktrans %}"/>
    &nbsp;|&nbsp; 
    <input name="delete_logo" type="submit" id="delete_logo_button" value="{% blocktrans %}Delete logo{% endblocktrans %}"/>
    <script type="text/javascript">
    <!--

    
    $(document).ready(function(){
        old_state = $("#id_workspace_role_model").attr('value');
        
        $("#id_workspace_role_model").change(function (e) { 
            question = "{% blocktrans %}Are you sure you want to change the role model? All roles (except managers) will be resetted!{% endblocktrans %}";
            if (!confirm(question)) {
            	$("#id_workspace_role_model").attr('value',old_state);
            }
          });
        
        $("#cancel_button").click(function (e) { 
            window.location = "{% url index %}";
            e.stopPropagation(); 
          });                
    }) ;
    -->
    </script>
{% endblock %}

{% block post_form %}
</div>
{% endblock %}