Bläddra i källkod

[closes #161] added read mode, work mode + refactor for layout structure

Come 7 år sedan
förälder
incheckning
883e72b6f5

+ 84 - 4
tracim/tracim/public/assets/css/dashboard.css Visa fil

@@ -60,6 +60,7 @@ body {
60 60
     top: 51px;
61 61
     bottom: 0;
62 62
     left: 0;
63
+    width: 260px;
63 64
     z-index: 1000;
64 65
     display: block;
65 66
     padding: 20px;
@@ -73,13 +74,30 @@ body {
73 74
 
74 75
   }
75 76
 }
77
+.fixed-width-sidebar {
78
+  width: auto;
79
+  min-width: 260px;
80
+  max-width: 50%;
81
+}
82
+
83
+.content__wrapper {
84
+  width: auto;
85
+  margin: 0 260px; /* When changing this value, also change the corresponding in main.js */
86
+}
87
+.content__data {
88
+  padding: 0 15px;
89
+}
76 90
 
77 91
 #sidebar-right {
92
+  left: auto;
93
+  right: 0;
78 94
   overflow-x: visible;
79 95
   overflow-y: auto;
80 96
     background-color: #F5F5F5;
81 97
     border-left: 1px solid #CCC;
82
-
98
+}
99
+.navbar-right {
100
+  margin-right: 0px;
83 101
 }
84 102
 
85 103
 /* Sidebar navigation */
@@ -99,6 +117,20 @@ body {
99 117
   background-color: #428bca;
100 118
 }
101 119
 
120
+.header__navbar__switch-mode {
121
+  float: right;
122
+  display: inline-block;
123
+  padding: 15px;
124
+  cursor: pointer;
125
+}
126
+.header__navbar__switch-mode > i {
127
+  margin-right: 5px;
128
+  font-size: 16px;
129
+}
130
+.header__navbar__switch-mode.switch-work-mode {
131
+    background-color: #eee;
132
+    color: #333;
133
+}
102 134
 
103 135
 /*
104 136
  * Main content
@@ -144,7 +176,6 @@ iframe { border: 5px solid #b3e7ff; }
144 176
 .pod-selected-item {background-color: #EEE;}
145 177
 .pod-empty {color: #999;}
146 178
 .pod-inline-form {
147
-    margin-left: 12px;
148 179
     border: 6px solid #428BCA;
149 180
     padding: 0.5em;
150 181
 }
@@ -295,6 +326,7 @@ div.t-page-metadata-row, div.t-metadata-row {
295 326
 
296 327
 #sidebar-left-menu {
297 328
     margin-bottom: 20px; /* add a margin between menu bottom and footer top */
329
+    overflow: hidden;
298 330
 }
299 331
 
300 332
 h1.page-header {
@@ -350,10 +382,15 @@ h1.page-header {
350 382
 #sidebar-right h4 { color: #555; margin: 1.5em 0 1em 0; }
351 383
 
352 384
 #t-full-app-alert-message-id {
385
+    top: 0;
386
+    position: absolute;
353 387
     z-index: 10001;
388
+    width: 100%;
354 389
     padding: 0;
355
-    position: absolute;
356
-    top: 0;
390
+}
391
+#t-full-app-alert-message-id > div {
392
+  width: 75%;
393
+  margin: 1em auto 0 auto;
357 394
 }
358 395
 
359 396
 #t-full-app-alert-message-id > div.alert {
@@ -430,3 +467,46 @@ span.info.readonly {
430 467
 .folder__content__list__item__status.deleted i {
431 468
   font-size: 14px;
432 469
 }
470
+
471
+.content__home {
472
+  padding: 0 15px;
473
+}
474
+
475
+.workspace__wrapper {
476
+  padding: 0 15px;
477
+}
478
+.workspace__list table {
479
+  text-align: center;
480
+}
481
+
482
+.workspace__detail__wrapper {
483
+  padding: 0 15px;
484
+}
485
+.workspace__detail__wrapper table {
486
+  text-align: center;
487
+}
488
+
489
+.workspace__detail__user table {
490
+  text-align: center;
491
+}
492
+
493
+.content__detail {
494
+  padding: 0 15px;
495
+}
496
+.content__detail table {
497
+  text-align: center;
498
+}
499
+.anchored-title {
500
+  padding-left: 10px;
501
+}
502
+
503
+.adminuser__wrapper {
504
+  padding: 0 15px;
505
+}
506
+.adminuser__detail {
507
+  padding: 0 15px;
508
+}
509
+.adminuser__detail table {
510
+  text-align: center;
511
+}
512
+

+ 30 - 0
tracim/tracim/public/assets/js/main.js Visa fil

@@ -1,5 +1,35 @@
1 1
 $(document).ready(function () {
2 2
 
3
+  $('#toggle-left-sidebar-width').click( function() {
4
+    sidebar = $('#sidebar-left')
5
+    buttonIcon = $('> i', this)
6
+
7
+    if (sidebar.hasClass('fixed-width-sidebar')) {
8
+      sidebar.removeClass('fixed-width-sidebar')
9
+      buttonIcon.removeClass('fa-angle-double-left').addClass('fa-angle-double-right')
10
+    } else {
11
+      sidebar.addClass('fixed-width-sidebar')
12
+      buttonIcon.removeClass('fa-angle-double-right').addClass('fa-angle-double-left')
13
+    }
14
+  })
15
+
16
+  // Côme - 2017-01-06 - is the code bellow usefull ?
17
+  // $('#current-page-breadcrumb-toggle-button').click( function() {
18
+  //   $('#current-page-breadcrumb').toggle();
19
+  // });
20
+
21
+  // switch btn read/work btn
22
+  $('.header__navbar').on('click', '.header__navbar__switch-mode.switch-read-mode', function () {
23
+    $(this).removeClass('switch-read-mode').addClass('switch-work-mode').html('<i class="fa fa-edit fa-fw"></i> Work mode')
24
+    $('#sidebar-left, #sidebar-right').hide()
25
+    $('.content__wrapper').css({margin: '0'})
26
+  })
27
+  $('.header__navbar').on('click', '.header__navbar__switch-mode.switch-work-mode', function () {
28
+    $(this).removeClass('switch-work-mode').addClass('switch-read-mode').html('<i class="fa fa-eye fa-fw"></i> Read mode')
29
+    $('#sidebar-left, #sidebar-right').show()
30
+    $('.content__wrapper').css({margin: '0 260px'})
31
+  })
32
+
3 33
   // add select2 for admin/workspace/<id> for user selection
4 34
   if ($('#add-role-from-existing-user-form').length > 0) {
5 35
     $('#user_id').select2({

+ 129 - 139
tracim/tracim/templates/admin/user_getall.mak Visa fil

@@ -17,154 +17,144 @@
17 17
 <%def name="TITLE_ROW()">
18 18
     <div class="row-fluid">
19 19
         <div>
20
-            ${ROW.TITLE_ROW(_('Users'), 'fa-user', 'col-md-offset-3 col-md-8', 't-user-color', _('manage users and associated workspaces'))}
20
+            ${ROW.TITLE_ROW(_('Users'), 'fa-user', '', 't-user-color', _('manage users and associated workspaces'))}
21 21
         </div>
22 22
     </div>
23 23
 </%def>
24 24
 
25
-<div class="container-fluid">
26
-    <div class="row-fluid">
27
-        <div>
28
-            ## ADD A USER
29
-            % if fake_api.current_user.profile.id>=2:
30
-                ## FIXME: check if the current_user is a workspace manager (so he is also allowed to create user)
31
-                ## In this case the user is a pod manager, so he is allowed to create users (and to delete them)
32
-                <div class="row">
33
-                    <!-- #### CREATE A USER #### -->
34
-                    <div class="col-md-offset-3 col-md-8">
35
-                        <p class="t-spacer-above">
36
-                            <a class="btn btn-success" data-toggle="collapse" data-target="#create-user-form"><b>${_('Create a user account...')}</b></a>
37
-                        </p>
38
-                        <div id="create-user-form" class="collapse">
39
-                            <div class="pod-inline-form col-md-12" >
40
-                                <form role="form" method="POST" action="${tg.url('/admin/users')}">
41
-                                    <div class="form-group">
42
-                                        <label for="user-name">${_('Name')}</label>
43
-                                        <input name="name" type="text" class="form-control" id="user-name" placeholder="${_('Name')}">
44
-                                    </div>
45
-                                    <div class="form-group">
46
-                                        <label for="user-email">${_('Email')}</label>
47
-                                        <input name="email" type="text" class="form-control" id="user-email" placeholder="${_('Email address')}">
48
-                                    </div>
49
-                                    <div class="form-group">
50
-                                        <label for="user-password">${_('Password')}</label>
51
-                                        <input name="password" type="password" class="form-control" id="user-password" placeholder="${_('Optionnaly choose a password')}">
52
-                                    </div>
53
-                                    <div class="checkbox">
54
-                                      <label>
55
-                                        <input type="checkbox" class="checkbox" name="is_tracim_manager" id="is-tracim-manager"> ${_('This user can create workspaces')}
56
-                                      </label>
57
-                                    </div>
58
-                                    <div class="checkbox disabled">
59
-                                      <label>
60
-                                        <input type="checkbox" class="checkbox" disabled name="is_tracim_admin" id="is-tracim-admin"> ${_('This user is an administrator')}
61
-                                      </label>
62
-                                    </div>
63
-                                    <div class="checkbox">
64
-                                      <label>
65
-                                        <input type="checkbox" class="checkbox" checked name="send_email" id="send-email"> ${_('Send email to user')}
66
-                                      </label>
67
-                                    </div>
68
-
69
-                                    <span class="pull-right" style="margin-top: 0.5em;">
70
-                                        <button type="submit" class="btn btn-small btn-success" title="Add first comment"><i class=" fa fa-check"></i> ${_('Validate')}</button>
71
-                                    </span>
72
-                                    <script>
73
-                                        $(document).ready(function() {
74
-                                            $('#is-tracim-manager').change(function() {
75
-                                                if($('#is-tracim-manager').prop('checked')==true) {
76
-                                                    console.log('now manager is checked');
77
-                                                    $('#is-tracim-admin').removeAttr('disabled');
78
-                                                    $('#is-tracim-admin').parent().parent().removeClass('disabled');
79
-                                                } else {
80
-                                                    console.log('now manager is unchecked');
81
-                                                    $('#is-tracim-admin').prop('checked', false);
82
-                                                    $('#is-tracim-admin').attr('disabled', 'disabled');
83
-                                                    $('#is-tracim-admin').parent().parent().addClass('disabled');
84
-                                                }
85
-                                            });
86
-                                        });
87
-                                    </script>
88
-                                </form>
89
-                                <div style="clear: both;"></div>
90
-                            </div>
91
-                        </div>
25
+<div class="adminuser__wrapper">
26
+    ## ADD A USER
27
+    % if fake_api.current_user.profile.id>=2:
28
+        ## FIXME: check if the current_user is a workspace manager (so he is also allowed to create user)
29
+        ## In this case the user is a pod manager, so he is allowed to create users (and to delete them)
30
+        <!-- #### CREATE A USER #### -->
31
+        <p class="t-spacer-above">
32
+            <a class="btn btn-success" data-toggle="collapse" data-target="#create-user-form"><b>${_('Create a user account...')}</b></a>
33
+        </p>
34
+        <div id="create-user-form" class="collapse">
35
+            <div class="pod-inline-form" >
36
+                <form role="form" method="POST" action="${tg.url('/admin/users')}">
37
+                    <div class="form-group">
38
+                        <label for="user-name">${_('Name')}</label>
39
+                        <input name="name" type="text" class="form-control" id="user-name" placeholder="${_('Name')}">
40
+                    </div>
41
+                    <div class="form-group">
42
+                        <label for="user-email">${_('Email')}</label>
43
+                        <input name="email" type="text" class="form-control" id="user-email" placeholder="${_('Email address')}">
44
+                    </div>
45
+                    <div class="form-group">
46
+                        <label for="user-password">${_('Password')}</label>
47
+                        <input name="password" type="password" class="form-control" id="user-password" placeholder="${_('Optionnaly choose a password')}">
48
+                    </div>
49
+                    <div class="checkbox">
50
+                      <label>
51
+                        <input type="checkbox" class="checkbox" name="is_tracim_manager" id="is-tracim-manager"> ${_('This user can create workspaces')}
52
+                      </label>
53
+                    </div>
54
+                    <div class="checkbox disabled">
55
+                      <label>
56
+                        <input type="checkbox" class="checkbox" disabled name="is_tracim_admin" id="is-tracim-admin"> ${_('This user is an administrator')}
57
+                      </label>
58
+                    </div>
59
+                    <div class="checkbox">
60
+                      <label>
61
+                        <input type="checkbox" class="checkbox" checked name="send_email" id="send-email"> ${_('Send email to user')}
62
+                      </label>
92 63
                     </div>
93
-                    <!-- #### CREATE A USER [END] #### -->
94
-                </div>
95
-            % endif
96
-            ## ADD A USER [END]
97
-
98
-
99
-            ## LIST OF USERS
100
-            <div class="row">
101
-                <div class="col-md-offset-3 col-md-8 t-spacer-above">
102
-                    % if result.user_nb<=0:
103
-                        ${TIM.NO_CONTENT_INFO(_('There are no workspace yet. Start by <a class="alert-link" data-toggle="collapse" data-target="#create-workspace-form">creating a workspace</a>.'))}
104
-                    % else:
105
-                        <table class="table table-striped table-hover">
106
-                            <thead>
107
-                                <tr>
108
-                                    <th></th>
109
-                                    <th>${_('User')}</th>
110
-                                    <th>${_('Email')}</th>
111
-                                    <th>${_('Can create workspaces')}</th>
112
-                                    <th>${_('Administrator')}</th>
113
-                                    <th>${_('Notes')}</th>
114
-                                </tr>
115
-                            </thead>
116
-                            % for user in result.users:
117
-                                <tr class="${('t-less-visible', '')[user.enabled]}">
118
-                                    % if user.enabled:
119
-                                        <td>
120
-                                            ${BUTTON.FA('fa-lightbulb-o fa-lg t-enabled-color', _('User enabled. Click to disable this user'), tg.url('/admin/users/{}/disable'.format(user.id)), fake_api.current_user, 3)}
121
-                                        </td>
122
-                                        <td><a href="${tg.url('/admin/users/{}'.format(user.id))}"><b>${user.name}</b></a></td>
123
-                                        <td><a href="mailto:${user.email}">${user.email}</a></td>
124
-                                        <td>
125
-                                            <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-enabled-color')[user.profile.id>=2] %>
126
-                                            <% linked_profile = ('tracim-profile-manager', 'tracim-profile-user')[user.profile.id>=2] %>
127
-                                            <% linked_text = (_('Click to allow workspace creation'), _('Click to disallow workspace creation'))[user.profile.id>=2] %>
128
-                                            ${BUTTON.FA(icon, linked_text, tg.url('/admin/users/{}/profile/switch?new_role={}'.format(user.id, linked_profile)), fake_api.current_user, 3)}
129
-                                        </td>
130
-                                        <td>
131
-                                            <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-enabled-color')[user.profile.id>=3] %>
132
-                                            <% linked_profile = ('tracim-profile-admin', 'tracim-profile-manager')[user.profile.id>=3] %>
133
-                                            <% linked_text = (_('Click to give super user privileges'), _('Click to remove super user privileges'))[user.profile.id>=3] %>
134
-                                            ${BUTTON.FA(icon, linked_text, tg.url('/admin/users/{}/profile/switch?new_role={}'.format(user.id, linked_profile)), fake_api.current_user, 3)}
135
-                                        </td>
136
-                                    % else:
137
-                                        <td>
138
-                                            ${BUTTON.FA('fa-lightbulb-o fa-lg t-disabled-color', _('User disabled. Click to enable this user'), tg.url('/admin/users/{}/enable'.format(user.id)), fake_api.current_user, 3)}
139
-                                        </td>
140
-                                        <td><a class="t-less-visible" href="${tg.url('/admin/users/{}'.format(user.id))}">${user.name}</a></td>
141
-                                        <td>${user.email}</td>
142
-                                        <td>
143
-                                            <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-disabled-color')[user.profile.id>=2] %>
144
-                                            ${ICON.FA(icon, _('User is disabled. No action allowed'))}
145
-                                        </td>
146
-                                        <td>
147
-                                            <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-disabled-color')[user.profile.id>=3] %>
148
-                                            <% linked_profile = ('tracim-profile-admin', 'tracim-profile-manager')[user.profile.id>=3] %>
149
-                                            ${ICON.FA(icon, _('User is disabled. No action allowed'))}
150
-                                        </td>
151
-                                    % endif
152
-                                    <td>
153
-                                        % if False==user.has_password:
154
-                                            ${ICON.FA_TOOLTIP('fa-key t-less-visible', _('This user has no password.'))}
155
-                                            <span class="t-less-visible">${_('No password defined.')}</span>
156 64
 
157
-                                        % endif
158
-                                    </td>
159
-                                </tr>
160
-                            % endfor
161
-                        </table>
162
-                    % endif
163
-                </div>
65
+                    <span class="pull-right" style="margin-top: 0.5em;">
66
+                        <button type="submit" class="btn btn-small btn-success" title="Add first comment"><i class=" fa fa-check"></i> ${_('Validate')}</button>
67
+                    </span>
68
+                    <script>
69
+                        $(document).ready(function() {
70
+                            $('#is-tracim-manager').change(function() {
71
+                                if($('#is-tracim-manager').prop('checked')==true) {
72
+                                    console.log('now manager is checked');
73
+                                    $('#is-tracim-admin').removeAttr('disabled');
74
+                                    $('#is-tracim-admin').parent().parent().removeClass('disabled');
75
+                                } else {
76
+                                    console.log('now manager is unchecked');
77
+                                    $('#is-tracim-admin').prop('checked', false);
78
+                                    $('#is-tracim-admin').attr('disabled', 'disabled');
79
+                                    $('#is-tracim-admin').parent().parent().addClass('disabled');
80
+                                }
81
+                            });
82
+                        });
83
+                    </script>
84
+                </form>
85
+                <div style="clear: both;"></div>
164 86
             </div>
165
-            ## LIST OF USERS [END]
166 87
         </div>
88
+        <!-- #### CREATE A USER [END] #### -->
89
+    % endif
90
+    ## ADD A USER [END]
91
+
92
+
93
+    ## LIST OF USERS
94
+    <div class="t-spacer-above">
95
+        % if result.user_nb<=0:
96
+            ${TIM.NO_CONTENT_INFO(_('There are no workspace yet. Start by <a class="alert-link" data-toggle="collapse" data-target="#create-workspace-form">creating a workspace</a>.'))}
97
+        % else:
98
+            <table class="table table-striped table-hover">
99
+                <thead>
100
+                    <tr>
101
+                        <th></th>
102
+                        <th>${_('User')}</th>
103
+                        <th>${_('Email')}</th>
104
+                        <th>${_('Can create workspaces')}</th>
105
+                        <th>${_('Administrator')}</th>
106
+                        <th>${_('Notes')}</th>
107
+                    </tr>
108
+                </thead>
109
+                % for user in result.users:
110
+                    <tr class="${('t-less-visible', '')[user.enabled]}">
111
+                        % if user.enabled:
112
+                            <td>
113
+                                ${BUTTON.FA('fa-lightbulb-o fa-lg t-enabled-color', _('User enabled. Click to disable this user'), tg.url('/admin/users/{}/disable'.format(user.id)), fake_api.current_user, 3)}
114
+                            </td>
115
+                            <td><a href="${tg.url('/admin/users/{}'.format(user.id))}"><b>${user.name}</b></a></td>
116
+                            <td><a href="mailto:${user.email}">${user.email}</a></td>
117
+                            <td>
118
+                                <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-enabled-color')[user.profile.id>=2] %>
119
+                                <% linked_profile = ('tracim-profile-manager', 'tracim-profile-user')[user.profile.id>=2] %>
120
+                                <% linked_text = (_('Click to allow workspace creation'), _('Click to disallow workspace creation'))[user.profile.id>=2] %>
121
+                                ${BUTTON.FA(icon, linked_text, tg.url('/admin/users/{}/profile/switch?new_role={}'.format(user.id, linked_profile)), fake_api.current_user, 3)}
122
+                            </td>
123
+                            <td>
124
+                                <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-enabled-color')[user.profile.id>=3] %>
125
+                                <% linked_profile = ('tracim-profile-admin', 'tracim-profile-manager')[user.profile.id>=3] %>
126
+                                <% linked_text = (_('Click to give super user privileges'), _('Click to remove super user privileges'))[user.profile.id>=3] %>
127
+                                ${BUTTON.FA(icon, linked_text, tg.url('/admin/users/{}/profile/switch?new_role={}'.format(user.id, linked_profile)), fake_api.current_user, 3)}
128
+                            </td>
129
+                        % else:
130
+                            <td>
131
+                                ${BUTTON.FA('fa-lightbulb-o fa-lg t-disabled-color', _('User disabled. Click to enable this user'), tg.url('/admin/users/{}/enable'.format(user.id)), fake_api.current_user, 3)}
132
+                            </td>
133
+                            <td><a class="t-less-visible" href="${tg.url('/admin/users/{}'.format(user.id))}">${user.name}</a></td>
134
+                            <td>${user.email}</td>
135
+                            <td>
136
+                                <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-disabled-color')[user.profile.id>=2] %>
137
+                                ${ICON.FA(icon, _('User is disabled. No action allowed'))}
138
+                            </td>
139
+                            <td>
140
+                                <% icon = ('fa-square-o fa-lg t-disabled-color', 'fa-check-square-o fa-lg t-disabled-color')[user.profile.id>=3] %>
141
+                                <% linked_profile = ('tracim-profile-admin', 'tracim-profile-manager')[user.profile.id>=3] %>
142
+                                ${ICON.FA(icon, _('User is disabled. No action allowed'))}
143
+                            </td>
144
+                        % endif
145
+                        <td>
146
+                            % if False==user.has_password:
147
+                                ${ICON.FA_TOOLTIP('fa-key t-less-visible', _('This user has no password.'))}
148
+                                <span class="t-less-visible">${_('No password defined.')}</span>
149
+
150
+                            % endif
151
+                        </td>
152
+                    </tr>
153
+                % endfor
154
+            </table>
155
+        % endif
167 156
     </div>
157
+    ## LIST OF USERS [END]
168 158
 </div>
169 159
 
170 160
 

+ 57 - 65
tracim/tracim/templates/admin/user_getone.mak Visa fil

@@ -21,76 +21,68 @@
21 21
 </%def>
22 22
 
23 23
 <%def name="TITLE_ROW()">
24
-    <div class="row-fluid">
25
-        <div>
26
-            <%
27
-                if result.user.profile.id>=3:
28
-                    subtitle = _('This user is an administrator.')
29
-                elif result.user.profile.id>=2:
30
-                    subtitle = _('This user can create workspaces.')
31
-                else:
32
-                    subtitle = _('This user a standard user.')
33
-            %>
34
-            ${ROW.TITLE_ROW(result.user.name, 'fa-user', 'col-md-offset-3 col-md-7', 't-user-color', subtitle)}
35
-        </div>
24
+    <div>
25
+        <%
26
+            if result.user.profile.id>=3:
27
+                subtitle = _('This user is an administrator.')
28
+            elif result.user.profile.id>=2:
29
+                subtitle = _('This user can create workspaces.')
30
+            else:
31
+                subtitle = _('This user a standard user.')
32
+        %>
33
+        ${ROW.TITLE_ROW(result.user.name, 'fa-user', '', 't-user-color', subtitle)}
36 34
     </div>
37 35
 </%def>
38 36
 
39
-<div class="container-fluid">
40
-    <div class="row-fluid">
37
+<div class="adminuser__detail">
38
+    <div class="" id='user-profile-global-info'>
41 39
         <div>
42
-            <div class="row">
43
-                <div class="col-md-offset-3 col-sm-7" id='user-profile-global-info'>
44
-                    <div>
45
-                        % if not result.user.enabled:
46
-                            <div class="alert alert-warning" style="margin-top: 1em;">
47
-                                <i class="fa fa-lg fa-warning"></i> ${_('This user is disabled')}
48
-                            </div>
49
-                        % endif
50
-                        ## TODO - D.A. - 2015-05-14
51
-                        ## Add extra information like skype, phone, website...
52
-                        <h3 style="margin-top: 1em;">
53
-                            ${ICON.FA('fa-user t-less-visible')}
54
-                            ${_('Contact')}
55
-                        </h3>
56
-                        ${P.USER_CONTACT(result.user)}
57
-                    </div>
58
-                    <div style="margin-top: 4em;">
59
-                        <h3>
60
-                            ${ICON.FA('fa-bar-chart t-less-visible')}
61
-                            ${_('Global profile')}
62
-                        </h3>
63
-                        ${P.USER_PROFILE(fake_api.current_user, result.user)}
64
-                    </div>
65
-                    <div style="margin-top: 4em;">
66
-                        <h3>
67
-                            ${ICON.FA('fa-group t-less-visible')}
68
-                            ${_('Roles')}
69
-                        </h3>
70
-                        % if len(result.user.roles)<=0:
71
-                            ${WIDGETS.EMPTY_CONTENT(_('This user is not member of any workspace.'))}
72
-                        % else:
73
-                            <table class="table">
74
-                                <thead>
75
-                                    <tr>
76
-                                        <th>#</th>
77
-                                        <th>${_('Workspace')}</th>
78
-                                        <th>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</th>
79
-                                        <th>${_('Notifications')}</th>
80
-                                    </tr>
81
-                                </thead>
82
-                                % for role in result.user.roles:
83
-<%
84
-    enable_link = '/admin/users/{user}/workspaces/{workspace}/enable_notifications?next_url=/admin/users/{user}'
85
-    disable_link = '/admin/users/{user}/workspaces/{workspace}/disable_notifications?next_url=/admin/users/{user}'
86
-%>
87
-                                    ${TABLE_ROW.USER_ROLE_IN_WORKSPACE(fake_api.current_user, role, show_id=True, enable_link=enable_link, disable_link=disable_link)}
88
-                                % endfor
89
-                            </table>
90
-                        % endif
91
-                    </div>
40
+            % if not result.user.enabled:
41
+                <div class="alert alert-warning" style="margin-top: 1em;">
42
+                    <i class="fa fa-lg fa-warning"></i> ${_('This user is disabled')}
92 43
                 </div>
93
-            </div>
44
+            % endif
45
+            ## TODO - D.A. - 2015-05-14
46
+            ## Add extra information like skype, phone, website...
47
+            <h3 style="margin-top: 1em;">
48
+                ${ICON.FA('fa-user t-less-visible')}
49
+                ${_('Contact')}
50
+            </h3>
51
+            ${P.USER_CONTACT(result.user)}
52
+        </div>
53
+        <div style="margin-top: 4em;">
54
+            <h3>
55
+                ${ICON.FA('fa-bar-chart t-less-visible')}
56
+                ${_('Global profile')}
57
+            </h3>
58
+            ${P.USER_PROFILE(fake_api.current_user, result.user)}
59
+        </div>
60
+        <div style="margin-top: 4em;">
61
+            <h3>
62
+                ${ICON.FA('fa-group t-less-visible')}
63
+                ${_('Roles')}
64
+            </h3>
65
+            % if len(result.user.roles)<=0:
66
+                ${WIDGETS.EMPTY_CONTENT(_('This user is not member of any workspace.'))}
67
+            % else:
68
+                <table class="table">
69
+                    <thead>
70
+                        <tr>
71
+                            <th>#</th>
72
+                            <th>${_('Workspace')}</th>
73
+                            <th>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</th>
74
+                            <th>${_('Notifications')}</th>
75
+                        </tr>
76
+                    </thead>
77
+                    % for role in result.user.roles:
78
+                        <%
79
+                            enable_link = '/admin/users/{user}/workspaces/{workspace}/enable_notifications?next_url=/admin/users/{user}'
80
+                            disable_link = '/admin/users/{user}/workspaces/{workspace}/disable_notifications?next_url=/admin/users/{user}'
81
+                        %>
82
+                        ${TABLE_ROW.USER_ROLE_IN_WORKSPACE(fake_api.current_user, role, show_id=True, enable_link=enable_link, disable_link=disable_link)}
83
+                    % endfor
84
+                </table>
85
+            % endif
94 86
         </div>
95 87
     </div>
96 88
 </div>

+ 72 - 86
tracim/tracim/templates/admin/workspace_getall.mak Visa fil

@@ -14,100 +14,86 @@
14 14
 </%def>
15 15
 
16 16
 <%def name="TITLE_ROW()">
17
-    <div class="row-fluid">
18
-        <div>
19
-            ${ROW.TITLE_ROW(_('Workspaces'), 'fa-bank', 'col-md-offset-3 col-md-8', 't-user-color', _('manage workspaces and subscribed users'))}
20
-        </div>
21
-    </div>
17
+    ${ROW.TITLE_ROW(_('Workspaces'), 'fa-bank', '', 't-user-color', _('manage workspaces and subscribed users'))}
22 18
 </%def>
23 19
 
24
-<div class="container-fluid">
25
-    <div class="row-fluid">
26
-        <div>
27
-            ## ADD A WORKSPACE
28
-            % if fake_api.current_user.profile.id>=2:
29
-                ## In this case the user is a pod manager, so he is allowed to create workspaces (and to delete them)
30
-                <div class="row">
31
-                    <!-- #### CREATE A WORKSPACE #### -->
32
-                    <div class="col-md-offset-3 col-md-12">
33
-                        <p class="t-spacer-above">
34
-                            <a class="btn btn-success" data-toggle="collapse" data-target="#create-workspace-form"><b>${_('Create a workspace...')}</b></a>
35
-                        </p>
36
-                        <div id="create-workspace-form" class="collapse">
37
-                            <div class="pod-inline-form col-sm-6" >
38
-                                <form role="form" method="POST" action="${tg.url('/admin/workspaces')}">
39
-                                    <div class="form-group">
40
-                                        <label for="workspace-name1">${_('Name')}</label>
41
-                                        <input name="name" type="text" class="form-control" id="workspace-name" placeholder="${_('Name')}">
42
-                                    </div>
43
-                                    <div class="form-group">
44
-                                        <label for="workspaceDescription">${_('Description')}</label>
45
-                                        <textarea name="description" class="form-control" id="workspaceDescription" placeholder="${_('You may add a description of the workspace')}"></textarea>
46
-                                    </div>
47
-                                    <div class="checkbox form-group">
48
-                                        <label for="workspaceCalendarEnabled">
49
-                                            <input id="workspaceCalendarEnabled" name="calendar_enabled" type="checkbox" checked >
50
-                                            <b>${_('Activate associated calendar')}</b>
51
-                                        </label>
52
-                                    </div>
20
+<div class="workspace__wrapper">
21
+## ADD A WORKSPACE
22
+% if fake_api.current_user.profile.id>=2:
23
+    ## In this case the user is a pod manager, so he is allowed to create workspaces (and to delete them)
24
+    <div class="workspace__create">
25
+        <!-- #### CREATE A WORKSPACE #### -->
26
+        <p class="t-spacer-above">
27
+            <a class="btn btn-success" data-toggle="collapse" data-target="#create-workspace-form"><b>${_('Create a workspace...')}</b></a>
28
+        </p>
29
+        <div id="create-workspace-form" class="collapse">
30
+            <div class="pod-inline-form" >
31
+                <form role="form" method="POST" action="${tg.url('/admin/workspaces')}">
32
+                    <div class="form-group">
33
+                        <label for="workspace-name1">${_('Name')}</label>
34
+                        <input name="name" type="text" class="form-control" id="workspace-name" placeholder="${_('Name')}">
35
+                    </div>
36
+                    <div class="form-group">
37
+                        <label for="workspaceDescription">${_('Description')}</label>
38
+                        <textarea name="description" class="form-control" id="workspaceDescription" placeholder="${_('You may add a description of the workspace')}"></textarea>
39
+                    </div>
40
+                    <div class="checkbox form-group">
41
+                        <label for="workspaceCalendarEnabled">
42
+                            <input id="workspaceCalendarEnabled" name="calendar_enabled" type="checkbox" checked >
43
+                            <b>${_('Activate associated calendar')}</b>
44
+                        </label>
45
+                    </div>
53 46
 
54
-                                    <div class="form-group">
55
-                                        <p class="form-control-static">${_('<u>Note</u>: members will be added during next step.')|n}</p>
56
-                                    </div>
57
-                                        
58
-                                    <span class="pull-right" style="margin-top: 0.5em;">
59
-                                        <button type="submit" class="btn btn-small btn-success" title="${_('Validate')}"><i class=" fa fa-check"></i> ${_('Validate')}</button>
60
-                                    </span>
61
-                                        
62
-                                </form>
63
-                                <div style="clear: both;"></div>
64
-                            </div>
65
-                        </div>
47
+                    <div class="form-group">
48
+                        <p class="form-control-static">${_('<u>Note</u>: members will be added during next step.')|n}</p>
66 49
                     </div>
67
-                    <!-- #### CREATE A WORKSPACE [END] #### -->
68
-                </div>
69
-            % endif
70
-            ## ADD A WORKSPACE [END]
71 50
 
72
-            ## LIST OF WORKSPACES
73
-            <div class="row">
74
-                <div class="col-md-offset-3 col-md-8 t-spacer-above">
75
-                    % if result.workspace_nb<=0:
76
-                        ${TIM.NO_CONTENT_INFO(_('There are no workspace yet. Start by <a class="alert-link" data-toggle="collapse" data-target="#create-workspace-form">creating a workspace</a>.'))}
77
-                    % else:
78
-                        <table class="table table-striped table-hover">
79
-                            <thead>
80
-                                <tr>
81
-                                    <th>#</th>
82
-                                    <th>${_('Workspace')}</th>
83
-                                    <th>${_('Description')}</th>
84
-                                    <th>${_('User Nb')}</th>
85
-                                    <th>${_('Calendar')}</th>
86
-                                </tr>
87
-                            </thead>
88
-                            % for workspace in result.workspaces:
89
-                                <tr>
90
-                                    <td>${workspace.id}</td>
91
-                                    <td><a href="${tg.url('/admin/workspaces/{}'.format(workspace.id))}">${workspace.label}</a></td>
92
-                                    <td>${workspace.description}</td>
93
-                                    <td>${workspace.member_nb}</td>
94
-                                    <td class="text-center">
95
-                                        % if workspace.calendar_enabled:
96
-                                            ${ICON.FA('fa-check-square-o fa-lg t-enabled-color')}
97
-                                        % else:
98
-                                            ${ICON.FA('fa-square-o fa-lg t-disabled-color')}
99
-                                        % endif
51
+                    <span class="pull-right" style="margin-top: 0.5em;">
52
+                        <button type="submit" class="btn btn-small btn-success" title="${_('Validate')}"><i class=" fa fa-check"></i> ${_('Validate')}</button>
53
+                    </span>
100 54
 
101
-                                    </td>
102
-                                </tr>
103
-                            % endfor
104
-                        </table>
105
-                    % endif
106
-                </div>
55
+                </form>
56
+                <div style="clear: both;"></div>
107 57
             </div>
108
-            ## LIST OF WORKSPACES [END]
109 58
         </div>
59
+        <!-- #### CREATE A WORKSPACE [END] #### -->
110 60
     </div>
111
-</div>
61
+% endif
62
+## ADD A WORKSPACE [END]
112 63
 
64
+## LIST OF WORKSPACES
65
+    <div class="workspace__list t-spacer-above">
66
+        % if result.workspace_nb<=0:
67
+            ${TIM.NO_CONTENT_INFO(_('There are no workspace yet. Start by <a class="alert-link" data-toggle="collapse" data-target="#create-workspace-form">creating a workspace</a>.'))}
68
+        % else:
69
+            <table class="table table-striped table-hover">
70
+                <thead>
71
+                    <tr>
72
+                        <th>#</th>
73
+                        <th>${_('Workspace')}</th>
74
+                        <th>${_('Description')}</th>
75
+                        <th>${_('User Nb')}</th>
76
+                        <th>${_('Calendar')}</th>
77
+                    </tr>
78
+                </thead>
79
+                % for workspace in result.workspaces:
80
+                    <tr>
81
+                        <td>${workspace.id}</td>
82
+                        <td><a href="${tg.url('/admin/workspaces/{}'.format(workspace.id))}">${workspace.label}</a></td>
83
+                        <td>${workspace.description}</td>
84
+                        <td>${workspace.member_nb}</td>
85
+                        <td class="text-center">
86
+                            % if workspace.calendar_enabled:
87
+                                ${ICON.FA('fa-check-square-o fa-lg t-enabled-color')}
88
+                            % else:
89
+                                ${ICON.FA('fa-square-o fa-lg t-disabled-color')}
90
+                            % endif
113 91
 
92
+                        </td>
93
+                    </tr>
94
+                % endfor
95
+            </table>
96
+        % endif
97
+    </div>
98
+## LIST OF WORKSPACES [END]
99
+</div> <!-- end workspace__wrapper -->

+ 87 - 106
tracim/tracim/templates/admin/workspace_getone.mak Visa fil

@@ -22,119 +22,100 @@
22 22
 </%def>
23 23
 
24 24
 <%def name="TITLE_ROW()">
25
-    <div class="row-fluid">
26
-        <div>
27
-            <% created_localized = h.get_with_timezone(result.workspace.created) %>
28
-            <% subtitle = _('workspace created on {date} at {time}').format(date=h.date(created_localized), time=h.time(created_localized)) %>
29
-            ${ROW.TITLE_ROW(_('Workspace {}').format(result.workspace.label), 'fa-bank', 'col-md-offset-3 col-md-7', 't-user-color', subtitle)}
30
-        </div>
31
-    </div>
25
+    <% created_localized = h.get_with_timezone(result.workspace.created) %>
26
+    <% subtitle = _('workspace created on {date} at {time}').format(date=h.date(created_localized), time=h.time(created_localized)) %>
27
+    ${ROW.TITLE_ROW(_('Workspace {}').format(result.workspace.label), 'fa-bank', '', 't-user-color', subtitle)}
32 28
 </%def>
33 29
 
34
-<div class="container-fluid">
35
-    <div class="row-fluid">
36
-        <div>
37
-            <div class="row">
38
-                <div class="col-sm-7 col-md-offset-3">
39
-                    ${TITLE.H3(_('Detail'), 'fa-align-justify', 'workspace-members')}
40
-                    % if result.workspace.description:
41
-                        <p>${result.workspace.description}</p>
42
-                    % else:
43
-                        <p class="t-less-visible">${_('No description available')}</p>
44
-                    % endif
45
-                </div>
46
-            </div>
30
+<div class="workspace__detail__wrapper">
31
+    <div class="workspace__detail__detail-descr">
32
+        ${TITLE.H3(_('Detail'), 'fa-align-justify', 'workspace-members')}
33
+        % if result.workspace.description:
34
+            <p>${result.workspace.description}</p>
35
+        % else:
36
+            <p class="t-less-visible">${_('No description available')}</p>
37
+        % endif
38
+    </div>
47 39
 
48
-            <div class="row">
49
-                % if not result.workspace.calendar_enabled:
50
-                    <div class="col-sm-7 col-md-offset-3">
51
-                        ${_('The calendar is disabled.')}
52
-                    </div>
53
-                % else:
54
-                    <div class="col-sm-7 col-md-offset-3">
55
-                        ${TITLE.H3(_('Calendar'), 'fa-calendar', 'workspace-members')}
56
-                        <p>${_('This workspace offers a calendar that you can configure in your software: Outlook, Thunderbird, etc.')}</p>
57
-                        <p>${_('The url to configure is the following one:')}</p>
58
-                        <p class="form-control">${result.workspace.calendar_url}</p>
59
-
60
-                    </div>
61
-                % endif
62
-            </div>
40
+    <div class="workspace__detail__calendar">
41
+        % if not result.workspace.calendar_enabled:
42
+            ${_('The calendar is disabled.')}
43
+        % else:
44
+            ${TITLE.H3(_('Calendar'), 'fa-calendar', 'workspace-members')}
45
+            <p>${_('This workspace offers a calendar that you can configure in your software: Outlook, Thunderbird, etc.')}</p>
46
+            <p>${_('The url to configure is the following one:')}</p>
47
+            <p class="form-control">${result.workspace.calendar_url}</p>
48
+        % endif
49
+    </div>
63 50
 
64
-            <div class="row">
65
-                <div class="col-sm-7 col-md-offset-3">
66
-                    <div>
67
-                        <% potential_new_user_nb = sum(1 for user in fake_api.users if user.id not in (user.id for user in result.workspace.members)) %>
68
-                        % if potential_new_user_nb<=0:
69
-                            ${TITLE.H3(_('Members'), 'fa-user', 'workspace-members')}
70
-                        % else:
71
-                            ${TITLE.H3_WITH_BUTTON(fake_api.current_user, result.workspace, 'workspace-members', _('Members'), 'add-role-from-existing-user-form', _('add one...'), 'fa-user')}
72
-
73
-                            <div id="add-role-from-existing-user-form" class="collapse col-sm-9">
74
-                                <div class="pod-inline-form">
75
-                                    <form role="form" method="POST" action="${tg.url('/admin/workspaces/{}/roles'.format(result.workspace.id))}">
76
-                                        <div class="form-group">
77
-                                            <label for="user_id">${_('User')}</label>
78
-                                            <select name="user_id" id="user_id" class="form-control" style="width:100%">
79
-                                                % for user in fake_api.users:
80
-                                                    % if user.id not in (user.id for user in result.workspace.members):
81
-                                                        <option value="${user.id}">${user.name}</option>
82
-                                                    % endif
83
-                                                % endfor
84
-                                            </select>
85
-                                        </div>
86
-
87
-                                        <div class="form-group">
88
-                                            <label>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</label>
89
-                                            % for role in fake_api.role_types:
90
-                                            <div class="radio">
91
-                                              <label>
92
-                                                <% checked = ('', 'checked="checked"')[role.id==1]%>
93
-                                                <input type="radio" name="role_id" id="role-id-${role.id}" value="${role.id}" ${checked}>
94
-                                                <span style="${role.style}"><b>${role.label}</b></span>
95
-                                              </label>
96
-                                            </div>
97
-                                            % endfor
98
-                                        </div>
99
-
100
-                                        <div class="checkbox">
101
-                                            <label>
102
-                                                <input type="checkbox" id="with_notif" name="with_notif" checked="checked"/> ${_('Subscribe to mail notifications')}
103
-                                            </label>
104
-                                        </div>
105
-
106
-                                        <span class="pull-right" style="margin-top: 0.5em;">
107
-                                            <button id="current-document-add-comment-save-button" type="submit" class="btn btn-small btn-success" title="Add first comment"><i class=" fa fa-check"></i> ${_('Validate')}</button>
108
-                                        </span>
109
-                                    </form>
110
-                                    <div style="clear: both;"></div>
111
-                                </div>
112
-                            </div>
113
-                            ## END OF ADD MEMBER FORM
114
-                        % endif
115
-
116
-                        % if result.workspace.member_nb<=0:
117
-                            ${WIDGETS.EMPTY_CONTENT(_('There are no user associated to the current workspace. <a class="alert-link" data-toggle="collapse" data-target="#add-role-from-existing-user-form">Add one</a>.'))}
118
-                        % else:
119
-                            <table class="table">
120
-                                <thead>
121
-                                    <tr>
122
-                                        <th>#</th>
123
-                                        <th>${_('User')}</th>
124
-                                        <th>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</th>
125
-                                        <th>${_('Notifications')}</th>
126
-                                        <th></th>
127
-                                    </tr>
128
-                                </thead>
129
-                                % for member in result.workspace.members:
130
-                                    ${TABLE_ROW.SECURED_MEMBER_IN_WORKSPACE(fake_api.current_user, result.workspace, member, fake_api.role_types)}
51
+    <div class="workspace__detail__user">
52
+        <% potential_new_user_nb = sum(1 for user in fake_api.users if user.id not in (user.id for user in result.workspace.members)) %>
53
+        % if potential_new_user_nb<=0:
54
+            ${TITLE.H3(_('Members'), 'fa-user', 'workspace-members')}
55
+        % else:
56
+            ${TITLE.H3_WITH_BUTTON(fake_api.current_user, result.workspace, 'workspace-members', _('Members'), 'add-role-from-existing-user-form', _('add one...'), 'fa-user')}
57
+
58
+            <div id="add-role-from-existing-user-form" class="collapse col-sm-9">
59
+                <div class="pod-inline-form">
60
+                    <form role="form" method="POST" action="${tg.url('/admin/workspaces/{}/roles'.format(result.workspace.id))}">
61
+                        <div class="form-group">
62
+                            <label for="user_id">${_('User')}</label>
63
+                            <select name="user_id" id="user_id" class="form-control" style="width:100%">
64
+                                % for user in fake_api.users:
65
+                                    % if user.id not in (user.id for user in result.workspace.members):
66
+                                        <option value="${user.id}">${user.name}</option>
67
+                                    % endif
131 68
                                 % endfor
132
-                            </table>
133
-                        % endif
134
-                    </div>
69
+                            </select>
70
+                        </div>
71
+
72
+                        <div class="form-group">
73
+                            <label>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</label>
74
+                            % for role in fake_api.role_types:
75
+                            <div class="radio">
76
+                              <label>
77
+                                <% checked = ('', 'checked="checked"')[role.id==1]%>
78
+                                <input type="radio" name="role_id" id="role-id-${role.id}" value="${role.id}" ${checked}>
79
+                                <span style="${role.style}"><b>${role.label}</b></span>
80
+                              </label>
81
+                            </div>
82
+                            % endfor
83
+                        </div>
84
+
85
+                        <div class="checkbox">
86
+                            <label>
87
+                                <input type="checkbox" id="with_notif" name="with_notif" checked="checked"/> ${_('Subscribe to mail notifications')}
88
+                            </label>
89
+                        </div>
90
+
91
+                        <span class="pull-right" style="margin-top: 0.5em;">
92
+                            <button id="current-document-add-comment-save-button" type="submit" class="btn btn-small btn-success" title="Add first comment"><i class=" fa fa-check"></i> ${_('Validate')}</button>
93
+                        </span>
94
+                    </form>
95
+                    <div style="clear: both;"></div>
135 96
                 </div>
136 97
             </div>
137
-        </div>
98
+            ## END OF ADD MEMBER FORM
99
+        % endif
100
+
101
+        % if result.workspace.member_nb<=0:
102
+            ${WIDGETS.EMPTY_CONTENT(_('There are no user associated to the current workspace. <a class="alert-link" data-toggle="collapse" data-target="#add-role-from-existing-user-form">Add one</a>.'))}
103
+        % else:
104
+            <table class="table">
105
+                <thead>
106
+                    <tr>
107
+                        <th>#</th>
108
+                        <th>${_('User')}</th>
109
+                        <th>${_('Role')} ${BUTTON.HELP_MODAL_DIALOG('user-role-definition', 'margin-left: 0.5em;')}</th>
110
+                        <th>${_('Notifications')}</th>
111
+                        <th></th>
112
+                    </tr>
113
+                </thead>
114
+                % for member in result.workspace.members:
115
+                    ${TABLE_ROW.SECURED_MEMBER_IN_WORKSPACE(fake_api.current_user, result.workspace, member, fake_api.role_types)}
116
+                % endfor
117
+            </table>
118
+        % endif
138 119
     </div>
139 120
 </div>
140 121
 

+ 62 - 84
tracim/tracim/templates/file/getone.mak Visa fil

@@ -37,80 +37,71 @@
37 37
 ############################################################################
38 38
 
39 39
 <div class="content-container ${'not-editable' if not result.file.is_editable else ''} ${'archived' if result.file.is_archived else ''} ${'deleted' if result.file.is_deleted else ''}">
40
-<!--# TODO BS 20161213: Indent content-->
41
-
42
-<div class="row t-page-header-row">
43
-    <div class="col-sm-7 col-sm-offset-3 main">
44
-        <h1 class="page-header t-file-color-border">
45
-            <i class="fa fa-fw fa-lg fa-paperclip tracim-less-visible t-file-color"></i>
46
-            ${result.file.label}
47
-
48
-            <span class="pull-right">
49
-                ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_FILE(fake_api.current_user, result.file.workspace, result.file)}
50
-            </span>
51
-        </h1>
52
-
53
-        <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
54
-            <% created_localized = h.get_with_timezone(result.file.created) %>
55
-          <p>${_('file created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.file.owner.name)|n}</p>
40
+
41
+    <div class="t-page-header-row">
42
+        <div class="main">
43
+            <h1 class="page-header t-file-color-border">
44
+                <i class="fa fa-fw fa-lg fa-paperclip tracim-less-visible t-file-color"></i>
45
+                ${result.file.label}
46
+
47
+                <span class="pull-right">
48
+                    ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_FILE(fake_api.current_user, result.file.workspace, result.file)}
49
+                </span>
50
+            </h1>
51
+
52
+            <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
53
+                <% created_localized = h.get_with_timezone(result.file.created) %>
54
+              <p>${_('file created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.file.owner.name)|n}</p>
55
+            </div>
56 56
         </div>
57 57
     </div>
58
-</div>
59 58
 
60
-% if (result.file.is_archived) :
61
-<div class="row alert alert-info" role="alert">
62
-    <div class="col-sm-7 col-sm-offset-3">
59
+    % if (result.file.is_archived) :
60
+    <div class="alert alert-info" role="alert">
63 61
         <p>
64 62
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
65 63
             ${_('Vous consultez <b>une version archivée</b> de la page courante.')|n}
66 64
         </p>
67 65
     </div>
68
-</div>
69
-% elif (result.file.is_deleted) :
70
-<div class="row alert alert-info" role="alert">
71
-    <div class="col-sm-7 col-sm-offset-3">
66
+    % elif (result.file.is_deleted) :
67
+    <div class="alert alert-info" role="alert">
72 68
         <p>
73 69
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
74 70
             ${_('Vous consultez <b>une version supprimée</b> de la page courante.')|n}
75 71
         </p>
76 72
     </div>
77
-</div>
78
-% endif
79
-
80
-% if result.file.selected_revision!='latest':
81
-    <div class="row alert alert-warning" role="alert">
82
-        <div class="col-sm-7 col-sm-offset-3">
83
-            <p>
84
-                <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
85
-                ${_('You are reading <b>an old revision</b> of the current file. (the shown revision is r{}).').format(result.file.selected_revision)|n}
86
-            </p>
87
-            <a class="pull-right alert-link" href="${tg.url('/workspaces/{}/folders/{}/files/{}').format(result.file.workspace.id, result.file.parent.id, result.file.id)}">${_('Show latest revision')}</a>
88
-        </div>
73
+    % endif
74
+
75
+    % if result.file.selected_revision!='latest':
76
+    <div class="alert alert-warning" role="alert">
77
+        <p>
78
+            <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
79
+            ${_('You are reading <b>an old revision</b> of the current file. (the shown revision is r{}).').format(result.file.selected_revision)|n}
80
+        </p>
81
+        <a class="pull-right alert-link" href="${tg.url('/workspaces/{}/folders/{}/files/{}').format(result.file.workspace.id, result.file.parent.id, result.file.id)}">
82
+            ${_('Show latest revision')}
83
+        </a>
89 84
     </div>
90
-% endif
91
-
92
-% if result.file.status.id=='closed-deprecated':
93
-    <div class="row alert alert-warning" role="alert">
94
-        <div class="col-sm-7 col-sm-offset-3">
95
-            <p>
96
-                <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
97
-                ${_('<b>This file is deprecated</b>')|n}
98
-            </p>
99
-        </div>
85
+    % endif
86
+
87
+    % if result.file.status.id=='closed-deprecated':
88
+    <div class="alert alert-warning" role="alert">
89
+        <p>
90
+            <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
91
+            ${_('<b>This file is deprecated</b>')|n}
92
+        </p>
100 93
     </div>
101
-% endif
94
+    % endif
102 95
 
103
-<div class="row">
104
-    <% download_url = tg.url('/workspaces/{}/folders/{}/files/{}/download?revision_id={}'.format(result.file.workspace.id, result.file.parent.id,result.file.id,result.file.selected_revision)) %>
105
-    <div class="col-sm-1 col-sm-offset-3">
96
+    <div class="content__detail file">
97
+        <% download_url = tg.url('/workspaces/{}/folders/{}/files/{}/download?revision_id={}'.format(result.file.workspace.id, result.file.parent.id,result.file.id,result.file.selected_revision)) %>
106 98
         <div class="t-half-spacer-above download-file-button">
107 99
             <a style="" class="btn btn-default" tittle="${_('Download the file')}"
108 100
                 href="${download_url}" >
109 101
                 ${ICON.FA_FW('fa fa-download fa-2x')}
110 102
             </a>
111 103
         </div>
112
-    </div>
113
-    <div class="col-md-5">
104
+
114 105
         <div class="t-half-spacer-above">
115 106
             <table class="table table-hover table-condensed table-striped table-bordered">
116 107
                 <tr>
@@ -136,48 +127,36 @@
136 127
                 </tr>
137 128
             </table>
138 129
         </div>
139
-    </div>
140
-    <div class="col-md-1">
130
+
141 131
         <div class="t-half-spacer-above">
142 132
             % if result.file.status.id in ('closed-validated', 'closed-unvalidated'):
143 133
                 <span style="font-size: 1.5em;"><i class="pull-right fa fa-4x ${result.file.status.css} ${result.file.status.icon}"></i></span>
144 134
             % endif
145 135
         </div>
146
-    </div>
147
-</div>
148 136
 
149
-% if result.file.content.strip():  # only show desc if really a content
150
-    <div class="row">
151
-        <div class="col-md-7 col-sm-offset-3">
152
-            <div class="well">
153
-                ${result.file.content|n}
154
-            </div>
137
+    % if result.file.content.strip():  # only show desc if really a content
138
+        <div class="well">
139
+            ${result.file.content|n}
155 140
         </div>
156
-    </div>
157
-% endif
158
-
159
-<div class="row">
160
-    <div class="col-md-7 col-sm-offset-3">
161
-        % if result.file.status.id!='open':
162
-            <p class="tracim-less-visible">${_('<b>Note</b>: You need to change status in case you want to upload a new version')|n}</p>
141
+    % endif
142
+
143
+    % if result.file.status.id!='open':
144
+        <p class="tracim-less-visible">${_('<b>Note</b>: You need to change status in case you want to upload a new version')|n}</p>
145
+    % else:
146
+        % if h.user_role(fake_api.current_user, result.file.workspace)<=1: # User must be a contributor to be allowed to upload files
147
+            ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.file.workspace, 'file-revisions', _('File revisions'))}
148
+            <p>${_('This file contains {} revision(s)').format(sum(1 for revision in result.file.revisions if revision.action.id=='revision'))}</p>
163 149
         % else:
164
-            % if h.user_role(fake_api.current_user, result.file.workspace)<=1: # User must be a contributor to be allowed to upload files
165
-                ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.file.workspace, 'file-revisions', _('File revisions'))}
166
-                <p>${_('This file contains {} revision(s)').format(sum(1 for revision in result.file.revisions if revision.action.id=='revision'))}</p>
167
-            % else:
168
-                % if (h.user_role(fake_api.current_user, result.file.workspace)>1 and not result.file.is_archived and not result.file.is_deleted):
169
-                    ${BUTTON.DATA_TARGET_AS_TEXT('new-file-revision', _('upload a new revision and/or comment...'), 'btn btn-success t-spacer-below')}
170
-                    ${FORMS.NEW_FILE_REVISION_WITH_COMMENT_FORM('new-file-revision', result.file.workspace.id, result.file.parent.id, result.file.id)}
171
-                % endif
150
+            % if (h.user_role(fake_api.current_user, result.file.workspace)>1 and not result.file.is_archived and not result.file.is_deleted):
151
+                ${BUTTON.DATA_TARGET_AS_TEXT('new-file-revision', _('upload a new revision and/or comment...'), 'btn btn-success t-spacer-below')}
152
+                ${FORMS.NEW_FILE_REVISION_WITH_COMMENT_FORM('new-file-revision', result.file.workspace.id, result.file.parent.id, result.file.id)}
172 153
             % endif
173 154
         % endif
174
-    </div>
175
-</div>
155
+    % endif
176 156
 
177
-<div class="row t-page-metadata-row t-spacer-above">
178
-    <div class="col-sm-7 col-sm-offset-3">
157
+    <div class="t-page-metadata-row t-spacer-above">
179 158
         <div class="t-spacer-above">
180
-            <span id="associated-revisions" ></span>
159
+            <span id="associated-revisions"></span>
181 160
             <h4 class="anchored-title">${_('File history')}</h4>
182 161
             <div>
183 162
                 <table class="table table-striped table-hover">
@@ -187,7 +166,6 @@
187 166
                 </table>
188 167
             </div>
189 168
         </div>
190
-    </div>
191
-<div/>
169
+    <div/>
192 170
 
193 171
 </div>

+ 53 - 61
tracim/tracim/templates/folder/getone.mak Visa fil

@@ -40,45 +40,38 @@
40 40
 ############################################################################
41 41
 
42 42
 <div class="folder-container ${'not-editable' if not result.folder.is_editable else ''} ${'archived' if result.folder.is_archived else ''} ${'deleted' if result.folder.is_deleted else ''}">
43
-<!--# TODO BS 20161213: Indent content-->
44
-
45
-<div class="row t-page-header-row">
46
-    <div class="col-sm-7 col-sm-offset-3 main">
47
-        <h1 class="page-header t-folder-color-border">
48
-            <i class="fa fa-fw fa-lg fa-folder-open tracim-less-visible" style="color: #CCCC00"></i>
49
-            ${result.folder.label}
50
-        </h1>
51
-
52
-        <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
53
-            <% created_localized = h.get_with_timezone(result.folder.created) %>
54
-          <p>${_('folder created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.folder.owner.name)|n}</p>
43
+
44
+    <div class="t-page-header-row">
45
+        <div class=" main">
46
+            <h1 class="page-header t-folder-color-border">
47
+                <i class="fa fa-fw fa-lg fa-folder-open tracim-less-visible" style="color: #CCCC00"></i>
48
+                ${result.folder.label}
49
+            </h1>
50
+
51
+            <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
52
+                <% created_localized = h.get_with_timezone(result.folder.created) %>
53
+              <p>${_('folder created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.folder.owner.name)|n}</p>
54
+            </div>
55 55
         </div>
56 56
     </div>
57
-</div>
58 57
 
59
-% if (result.folder.is_archived) :
60
-<div class="row alert alert-info" role="alert">
61
-    <div class="col-sm-7 col-sm-offset-3">
58
+    % if (result.folder.is_archived) :
59
+    <div class="alert alert-info" role="alert">
62 60
         <p>
63 61
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
64 62
             ${_('Vous consultez <b>une version archivée</b> de la page courante.')|n}
65 63
         </p>
66 64
     </div>
67
-</div>
68
-% elif (result.folder.is_deleted) :
69
-<div class="row alert alert-info" role="alert">
70
-    <div class="col-sm-7 col-sm-offset-3">
65
+    % elif (result.folder.is_deleted) :
66
+    <div class="alert alert-info" role="alert">
71 67
         <p>
72 68
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
73 69
             ${_('Vous consultez <b>une version supprimée</b> de la page courante.')|n}
74 70
         </p>
75 71
     </div>
76
-</div>
77
-% endif
78
-
79
-<div class="row">
80
-    <div class="col-sm-7 col-sm-offset-3">
72
+    % endif
81 73
 
74
+    <div class="content__detail folder">
82 75
         <% user_role = h.user_role(fake_api.current_user, result.folder.workspace) %>
83 76
 
84 77
         <div class="t-spacer-above">
@@ -164,45 +157,44 @@
164 157
             % endif
165 158
         </div>
166 159
     </div>
167
-</div>
168
-<script>
169
-    $(document).ready(function() {
170
-        $("#current-folder-content-list").DataTable({
171
-            sDom: '',
172
-            pageLength: -1
160
+    <script>
161
+        $(document).ready(function() {
162
+            $("#current-folder-content-list").DataTable({
163
+                sDom: '',
164
+                pageLength: -1
165
+            });
173 166
         });
174
-    });
175 167
 
176
-    $(document).ready(function() {
177
-        $("#toggle-file-visibility").click(function() {
178
-            $('.t-table-row-file').toggle();
179
-            $('#toggle-file-visibility').toggleClass('t-active-color');
180
-            $('#toggle-file-visibility').toggleClass('t-inactive-color');
181
-        });
182
-        $("#toggle-thread-visibility").click(function() {
183
-            $('.t-table-row-thread').toggle();
184
-            $('#toggle-thread-visibility').toggleClass('t-active-color');
185
-            $('#toggle-thread-visibility').toggleClass('t-inactive-color');
186
-        });
187
-        $("#toggle-folder-visibility").click(function() {
188
-            $('.t-table-row-folder').toggle();
189
-            $('#toggle-folder-visibility').toggleClass('t-active-color');
190
-            $('#toggle-folder-visibility').toggleClass('t-inactive-color');
191
-        });
192
-        $("#toggle-page-visibility").click(function() {
193
-            $('.t-table-row-page').toggle();
194
-            $('#toggle-page-visibility').toggleClass('t-active-color');
195
-            $('#toggle-page-visibility').toggleClass('t-inactive-color');
168
+        $(document).ready(function() {
169
+            $("#toggle-file-visibility").click(function() {
170
+                $('.t-table-row-file').toggle();
171
+                $('#toggle-file-visibility').toggleClass('t-active-color');
172
+                $('#toggle-file-visibility').toggleClass('t-inactive-color');
173
+            });
174
+            $("#toggle-thread-visibility").click(function() {
175
+                $('.t-table-row-thread').toggle();
176
+                $('#toggle-thread-visibility').toggleClass('t-active-color');
177
+                $('#toggle-thread-visibility').toggleClass('t-inactive-color');
178
+            });
179
+            $("#toggle-folder-visibility").click(function() {
180
+                $('.t-table-row-folder').toggle();
181
+                $('#toggle-folder-visibility').toggleClass('t-active-color');
182
+                $('#toggle-folder-visibility').toggleClass('t-inactive-color');
183
+            });
184
+            $("#toggle-page-visibility").click(function() {
185
+                $('.t-table-row-page').toggle();
186
+                $('#toggle-page-visibility').toggleClass('t-active-color');
187
+                $('#toggle-page-visibility').toggleClass('t-inactive-color');
188
+            });
196 189
         });
197
-    });
198 190
 
199
-    $(document).ready(function() {
200
-        $("#filtering").on('keyup click', function() {
201
-            $("#current-folder-content-list").DataTable().search(
202
-                $("#filtering").val()
203
-            ).draw();
191
+        $(document).ready(function() {
192
+            $("#filtering").on('keyup click', function() {
193
+                $("#current-folder-content-list").DataTable().search(
194
+                    $("#filtering").val()
195
+                ).draw();
196
+            });
204 197
         });
205
-    });
206
-</script>
198
+    </script>
207 199
 
208
-</div>
200
+</div> <!-- end .folder-container -->

+ 86 - 108
tracim/tracim/templates/home.mak Visa fil

@@ -11,10 +11,8 @@
11 11
 </%def>
12 12
 
13 13
 <%def name="TITLE_ROW()">
14
-    <div class="row-fluid">
15
-        <div>
16
-            ${ROW.TITLE_ROW(_('My Dashboard'), 'fa-home', 'col-md-offset-3 col-md-7', 't-user-color', _('Welcome to your home, {username}.').format(username=fake_api.current_user.name))}
17
-        </div>
14
+    <div class="content__title">
15
+        ${ROW.TITLE_ROW(_('My Dashboard'), 'fa-home', '', 't-user-color', _('Welcome to your home, {username}.').format(username=fake_api.current_user.name))}
18 16
     </div>
19 17
 </%def>
20 18
 
@@ -33,116 +31,96 @@
33 31
     ${TIM.MODAL_DIALOG('user-edit-password-modal-dialog')}
34 32
 </%def>
35 33
 
36
-<div class="container-fluid">
37
-    <div class="row-fluid">
38
-        <div>
39
-            ## NOT READ
40
-            <div class="row" id="unread-content-panel">
41
-                <div class="col-md-offset-3 col-sm-7">
42
-                    <div class="row t-spacer-above">
43
-                        <div class="col-sm-12">
44
-                            <div class="t-half-spacer-above">
45
-                                <div class="panel panel-success">
46
-                                    <div class="panel-heading">
47
-                                        <h3 class="panel-title"><i class="fa fa-fw fa-eye-slash"></i> ${_('Not Read')}</h3>
48
-                                    </div>
49
-                                    <div class="panel-body">
50
-                                        % if fake_api.last_unread.nb <= 0:
51
-                                            ${P.EMPTY_CONTENT(_('No new content.'))}
52
-                                        % else:
53
-                                            <table class="table table-hover">
54
-                                                % for item in fake_api.last_unread.contents:
55
-                                                    <tr>
56
-                                                        <td>
57
-                                                            <i class="${item.type.icon} fa-fw ${item.type.color}"></i>
58
-                                                            <a href="${item.url}">${item.label}</a>
59
-                                                            <br/>
60
-                                                            <span class="t-less-visible">${item.workspace.label}</span>
61
-                                                        </td>
62
-                                                        <td title="${_('Last activity: {datetime}').format(datetime=item.last_activity.label)}">
63
-                                                            ${item.last_activity.delta}
64
-                                                        </td>
65
-                                                    </tr>
66
-                                                % endfor
67
-                                            </table>
68
-                                        % endif
69
-                                     </div>
70
-                                 </div>
71
-                            </div>
72
-                        </div>
73
-                    </div>
34
+<div class="content__home">
35
+    ## NOT READ
36
+    <div class="t-spacer-above" id="unread-content-panel">
37
+        <div class="t-half-spacer-above">
38
+            <div class="panel panel-success">
39
+                <div class="panel-heading">
40
+                    <h3 class="panel-title"><i class="fa fa-fw fa-eye-slash"></i> ${_('Not Read')}</h3>
74 41
                 </div>
75
-            </div>
42
+                <div class="panel-body">
43
+                    % if fake_api.last_unread.nb <= 0:
44
+                        ${P.EMPTY_CONTENT(_('No new content.'))}
45
+                    % else:
46
+                        <table class="table table-hover">
47
+                            % for item in fake_api.last_unread.contents:
48
+                                <tr>
49
+                                    <td>
50
+                                        <i class="${item.type.icon} fa-fw ${item.type.color}"></i>
51
+                                        <a href="${item.url}">${item.label}</a>
52
+                                        <br/>
53
+                                        <span class="t-less-visible">${item.workspace.label}</span>
54
+                                    </td>
55
+                                    <td title="${_('Last activity: {datetime}').format(datetime=item.last_activity.label)}">
56
+                                        ${item.last_activity.delta}
57
+                                    </td>
58
+                                </tr>
59
+                            % endfor
60
+                        </table>
61
+                    % endif
62
+                 </div>
63
+             </div>
64
+        </div>
65
+    </div>
76 66
 
77
-            ## RECENT ACTIVITY
78
-            <div class="row" id="recent-activity-panel">
79
-                <div class="col-md-offset-3 col-sm-7">
80
-                    <div class="row t-spacer-above">
81
-                        <div class="col-sm-12">
82
-                            <div class="t-half-spacer-above">
83
-                                <div class="panel panel-warning">
84
-                                    <div class="panel-heading">
85
-                                        <h3 class="panel-title"><i class="fa fa-fw fa-line-chart"></i> ${_('Recent Activity')}</h3>
86
-                                    </div>
87
-                                    <div class="panel-body">
88
-                                        % if fake_api.last_actives.nb <= 0:
89
-                                            ${P.EMPTY_CONTENT(_('There\'s no activity yet.'))}
90
-                                        % else:
91
-                                            <table class="table table-hover">
92
-                                                % for item in fake_api.last_actives.contents:
93
-                                                    <tr>
94
-                                                        <td>
95
-                                                            <i class="${item.type.icon} fa-fw ${item.type.color}"></i>
96
-                                                            <a href="${item.url}">${item.label}</a>
97
-                                                            <br/>
98
-                                                            <span class="t-less-visible">${item.workspace.label}</span>
99
-                                                        </td>
100
-                                                        <td title="${_('Last activity: {datetime}').format(datetime=item.last_activity.label)}">
101
-                                                            ${item.last_activity.delta}
102
-                                                        </td>
103
-                                                    </tr>
104
-                                                % endfor
105
-                                            </table>
106
-                                        % endif
107
-                                    </div>
108
-                                </div>
109
-                            </div>
110
-                        </div>
111
-                    </div>
67
+    ## RECENT ACTIVITY
68
+    <div class="t-spacer-above" id="recent-activity-panel">
69
+        <div class="t-half-spacer-above">
70
+            <div class="panel panel-warning">
71
+                <div class="panel-heading">
72
+                    <h3 class="panel-title"><i class="fa fa-fw fa-line-chart"></i> ${_('Recent Activity')}</h3>
73
+                </div>
74
+                <div class="panel-body">
75
+                    % if fake_api.last_actives.nb <= 0:
76
+                        ${P.EMPTY_CONTENT(_('There\'s no activity yet.'))}
77
+                    % else:
78
+                        <table class="table table-hover">
79
+                            % for item in fake_api.last_actives.contents:
80
+                                <tr>
81
+                                    <td>
82
+                                        <i class="${item.type.icon} fa-fw ${item.type.color}"></i>
83
+                                        <a href="${item.url}">${item.label}</a>
84
+                                        <br/>
85
+                                        <span class="t-less-visible">${item.workspace.label}</span>
86
+                                    </td>
87
+                                    <td title="${_('Last activity: {datetime}').format(datetime=item.last_activity.label)}">
88
+                                        ${item.last_activity.delta}
89
+                                    </td>
90
+                                </tr>
91
+                            % endfor
92
+                        </table>
93
+                    % endif
112 94
                 </div>
113 95
             </div>
96
+        </div>
97
+    </div>
114 98
 
115
-            ## Workspace list and notifications
116
-            <div class="row t-half-spacer-above" id="workspaces-panel">
117
-                <div class="col-md-offset-3 col-sm-7">
118
-                    <div class="row t-spacer-above">
119
-                        <div class="col-sm-12">
120
-                            <div class="panel panel-info">
121
-                                <div class="panel-heading">
122
-                                    <h3 class="panel-title"><i class="fa fa-bank"></i> ${_('Workspaces')}</h3>
123
-                                </div>
124
-                                <div class="panel-body">
99
+    ## Workspace list and notifications
100
+    <div class="t-half-spacer-above" id="workspaces-panel">
101
+        <div class="t-spacer-above">
102
+            <div class="panel panel-info">
103
+                <div class="panel-heading">
104
+                    <h3 class="panel-title"><i class="fa fa-bank"></i> ${_('Workspaces')}</h3>
105
+                </div>
106
+                <div class="panel-body">
125 107
 
126
-                                    % if len(fake_api.current_user.roles)<=0:
127
-                                        ${P.EMPTY_CONTENT(_('I\'m not member of any workspace.'))}
128
-                                    % else:
129
-                                        <table class="table">
130
-                                            <thead>
131
-                                                <tr>
132
-                                                    <th>${_('Workspace')}</th>
133
-                                                    <th>${_('Role')}</th>
134
-                                                    <th>${_('Email Notifications')}</th>
135
-                                                </tr>
136
-                                            </thead>
137
-                                            % for role in fake_api.current_user.roles:
138
-                                                ${TABLE_ROW.USER_ROLE_IN_WORKSPACE(fake_api.current_user, role, show_id=False, enable_link='/user/me/workspaces/{workspace}/enable_notifications?next_url=/home', disable_link='/user/me/workspaces/{workspace}/disable_notifications?next_url=/home')}
139
-                                            % endfor
140
-                                        </table>
141
-                                    % endif
142
-                                </div>
143
-                            </div>
144
-                        </div>
145
-                    </div>
108
+                    % if len(fake_api.current_user.roles)<=0:
109
+                        ${P.EMPTY_CONTENT(_('I\'m not member of any workspace.'))}
110
+                    % else:
111
+                        <table class="table">
112
+                            <thead>
113
+                                <tr>
114
+                                    <th>${_('Workspace')}</th>
115
+                                    <th>${_('Role')}</th>
116
+                                    <th>${_('Email Notifications')}</th>
117
+                                </tr>
118
+                            </thead>
119
+                            % for role in fake_api.current_user.roles:
120
+                                ${TABLE_ROW.USER_ROLE_IN_WORKSPACE(fake_api.current_user, role, show_id=False, enable_link='/user/me/workspaces/{workspace}/enable_notifications?next_url=/home', disable_link='/user/me/workspaces/{workspace}/disable_notifications?next_url=/home')}
121
+                            % endfor
122
+                        </table>
123
+                    % endif
146 124
                 </div>
147 125
             </div>
148 126
         </div>

+ 17 - 8
tracim/tracim/templates/master_authenticated.mak Visa fil

@@ -26,7 +26,7 @@
26 26
     <body class="${self.body_class()}">
27 27
         <script src="${tg.url('/assets/js/jquery.min.js')}"></script>
28 28
 
29
-        <div class="container-fluid ${container_classes()}">
29
+        <div class="${container_classes()}">
30 30
             ${self.main_menu()}
31 31
             ${self.content_wrapper()}
32 32
             <div id="tracim-footer-separator"></div>
@@ -74,7 +74,7 @@
74 74
 
75 75
 <%def name="main_menu()">
76 76
     <div class="navbar navbar-fixed-top" role="navigation">
77
-        ${TIM.FLASH_MSG('col-sm-7 col-sm-offset-3')}
77
+        ${TIM.FLASH_MSG('')}
78 78
 ##
79 79
 ##         <div class="row" id="flashgordon">
80 80
 ##             <div class="col-sm-7 col-sm-offset-3" style="z-index: 10001; padding: 0; position: absolute; top: 0;">
@@ -96,7 +96,7 @@
96 96
 
97 97
 
98 98
 
99
-        <div class="container-fluid">
99
+        <div class="">
100 100
             <div class="navbar-header">
101 101
                 <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target=".navbar-collapse">
102 102
                     <span class="sr-only">Toggle navigation</span>
@@ -110,16 +110,20 @@
110 110
                 </a>
111 111
             </div>
112 112
 
113
-            <div class="navbar-collapse collapse">
113
+            <div class="header__navbar navbar-collapse collapse">
114 114
                 % if request.identity:
115
-                    <ul class="nav navbar-nav navbar-left">
116
-                        <li class="active"><a href="${tg.url('/home')}">${TIM.FA('fa-home fa-lg')} ${_('My Home')}</a></li>
117
-                        <li class=""><a href="${tg.url('/calendar')}">${TIM.FA('fa-calendar')} ${_('Calendar')}</a></li>
115
+                    <ul class="header__navbar__list nav navbar-nav navbar-left">
116
+                        <li class="header__navbar__list__item active">
117
+                            <a href="${tg.url('/home')}">${TIM.FA('fa-home fa-lg')} ${_('My Home')}</a>
118
+                        </li>
119
+                        <li class="header__navbar__list__item">
120
+                            <a href="${tg.url('/calendar')}">${TIM.FA('fa-calendar')} ${_('Calendar')}</a>
121
+                        </li>
118 122
                         ${NAVBAR_MENU.ADMIN_ITEMS()}
119 123
                     </ul>
120 124
                 % endif
121 125
 
122
-                <ul class="nav navbar-nav navbar-right">
126
+                <ul class="header__navbar__right nav navbar-nav navbar-right">
123 127
 
124 128
                     % if request.identity:
125 129
 
@@ -186,6 +190,11 @@
186 190
 ##                        </ul>
187 191
 ##                    </li>
188 192
                 </ul>
193
+
194
+                <div class="header__navbar__switch-mode switch-read-mode">
195
+                    ${TIM.FA('fa-eye')} ${_('Read mode')}
196
+                </div>
197
+
189 198
             </div>
190 199
         </div>
191 200
     </div>

+ 17 - 46
tracim/tracim/templates/master_authenticated_left_treeview.mak Visa fil

@@ -9,7 +9,7 @@
9 9
 
10 10
 <%def name="SIDEBAR_RIGHT_CONTENT()">
11 11
     ## This is the default right sidebar implementation
12
-    <div id="sidebar-right" class="col-sm-1 col-md-1 col-sm-offset-11 sidebar">
12
+    <div class="sidebar">
13 13
         <div class="btn-group btn-group-vertical">
14 14
         </div>
15 15
         <p></p>
@@ -19,29 +19,24 @@
19 19
 <%def name="FOOTER_CONTENT_LIKE_SCRIPTS_AND_CSS()"></%def>
20 20
 
21 21
 <%def name="content_wrapper()">
22
-    <div class="container-fluid">
23
-        <div class="row-fluid">
24
-
25
-            ## SIDEBAR LEFT
26
-            <div id="sidebar-left" class="fixed-width-sidebar col-sm-3 sidebar" >
27
-                <div class="btn-group" style="position: absolute; right: 2px; top: 4px; ">
28
-                    <button id="toggle-left-sidebar-width" type="button" class="btn btn-link"><i class="fa fa-angle-double-right"></i></button>
29
-                </div>
30
-                ${self.SIDEBAR_LEFT_CONTENT()}
31
-            </div>
32
-            ## SIDEBAR LEFT [END]
22
+    ## SIDEBAR LEFT
23
+    <div id="sidebar-left">
24
+        <div class="btn-group" style="position: absolute; right: 2px; top: 4px; ">
25
+            <button id="toggle-left-sidebar-width" type="button" class="btn btn-link"><i class="fa fa-angle-double-right"></i></button>
26
+        </div>
27
+        ${self.SIDEBAR_LEFT_CONTENT()}
28
+    </div>
29
+    ## SIDEBAR LEFT [END]
33 30
 
34
-            ## SIDEBAR RIGHT
35
-            <div id="sidebar-right" class="col-sm-1 col-md-1 col-sm-offset-11 sidebar">
36
-                ${self.SIDEBAR_RIGHT_CONTENT()}
37
-            </div> <!-- # End of side bar right -->
38
-            ## SIDEBAR RIGHT [END]
31
+    ## SIDEBAR RIGHT
32
+    <div id="sidebar-right" class="sidebar">
33
+        ${self.SIDEBAR_RIGHT_CONTENT()}
34
+    </div> <!-- # End of side bar right -->
35
+    ## SIDEBAR RIGHT [END]
39 36
 
40
-            <div>
41
-                ${self.TITLE_ROW()}
42
-                ${self.body()}
43
-            </div>
44
-        </div>
37
+    <div class="content__wrapper">
38
+        ${self.TITLE_ROW()}
39
+        ${self.body()}
45 40
     </div>
46 41
     ${self.REQUIRED_DIALOGS()}
47 42
 
@@ -53,30 +48,6 @@
53 48
     <script src="${tg.url('/assets/js/jquery.min.js')}"></script>
54 49
     <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
55 50
     <script src="${tg.url('/assets/js/ie10-viewport-bug-workaround.js')}"></script>
56
-    <script>
57
-        $(function () {
58
-            $('#toggle-left-sidebar-width').click( function() {
59
-              sidebar = $('#sidebar-left');
60
-              buttonIcon = $('> i', this);
61
-              if (sidebar.hasClass('fixed-width-sidebar')) {
62
-                sidebar.removeClass('fixed-width-sidebar')
63
-                sidebar.removeClass('col-sm-3');
64
-
65
-                buttonIcon.removeClass('fa-angle-double-right');
66
-                buttonIcon.addClass('fa-angle-double-left');
67
-              } else {
68
-                sidebar.addClass('fixed-width-sidebar')
69
-                sidebar.addClass('col-sm-3');
70
-                buttonIcon.removeClass('fa-angle-double-left');
71
-                buttonIcon.addClass('fa-angle-double-right');
72
-              }
73
-            });
74
-
75
-            $('#current-page-breadcrumb-toggle-button').click( function() {
76
-              $('#current-page-breadcrumb').toggle();
77
-            });
78
-        });
79
-    </script>
80 51
     <!-- TinyMCE ================================================== -->
81 52
     <script src="${tg.url('/assets/tinymce/js/tinymce/tinymce.min.js')}"></script>
82 53
     ${TIM.TINYMCE_INIT_SCRIPT('.pod-rich-textarea')}

+ 18 - 47
tracim/tracim/templates/master_authenticated_left_treeview_right_toolbar.mak Visa fil

@@ -8,32 +8,27 @@
8 8
 <%def name="FOOTER_CONTENT_LIKE_SCRIPTS_AND_CSS()"></%def>
9 9
 
10 10
 <%def name="content_wrapper()">
11
-    <div class="container-fluid">
12
-        <div class="row-fluid">
13
-        
14
-            ## SIDEBAR LEFT
15
-            <div id="sidebar-left" class="fixed-width-sidebar col-sm-3 sidebar" >
16
-                <div class="btn-group" style="position: absolute; right: 2px; top: 4px; ">
17
-                    <button id="toggle-left-sidebar-width" type="button" class="btn btn-link"><i class="fa fa-angle-double-right"></i></button>
18
-                </div>
19
-                ${self.SIDEBAR_LEFT_CONTENT()}
20
-            </div>
21
-            ## SIDEBAR LEFT [END]
22
-
23
-            ## SIDEBAR RIGHT
24
-            <div id="sidebar-right" class="col-sm-2 col-md-2 col-sm-offset-10 sidebar">
25
-                ${self.SIDEBAR_RIGHT_CONTENT()}
26
-            </div> <!-- # End of side bar right -->
27
-            ## SIDEBAR RIGHT [END]
28
-            
29
-            <div>
30
-                ${self.TITLE_ROW()}
31
-                ${self.body()}
32
-            </div>
11
+    ## SIDEBAR LEFT
12
+    <div id="sidebar-left" class="sidebar">
13
+        <div class="btn-group" style="position: absolute; right: 2px; top: 4px; ">
14
+            <button id="toggle-left-sidebar-width" type="button" class="btn btn-link"><i class="fa fa-angle-double-right"></i></button>
33 15
         </div>
16
+        ${self.SIDEBAR_LEFT_CONTENT()}
17
+    </div>
18
+    ## SIDEBAR LEFT [END]
19
+
20
+    ## SIDEBAR RIGHT
21
+    <div id="sidebar-right" class="sidebar">
22
+        ${self.SIDEBAR_RIGHT_CONTENT()}
23
+    </div> <!-- # End of side bar right -->
24
+    ## SIDEBAR RIGHT [END]
25
+
26
+    <div class="content__wrapper">
27
+        ${self.TITLE_ROW()}
28
+        ${self.body()}
34 29
     </div>
35 30
     ${self.REQUIRED_DIALOGS()}
36
-    
31
+
37 32
     ###########################################
38 33
     ##
39 34
     ## GENERIC STUFF LIKE SCRIPTS
@@ -42,30 +37,6 @@
42 37
     <script src="${tg.url('/assets/js/jquery.min.js')}"></script>
43 38
     <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
44 39
     <script src="${tg.url('/assets/js/ie10-viewport-bug-workaround.js')}"></script>
45
-    <script>
46
-        $(function () {
47
-            $('#toggle-left-sidebar-width').click( function() {
48
-              sidebar = $('#sidebar-left');
49
-              buttonIcon = $('> i', this);
50
-              if (sidebar.hasClass('fixed-width-sidebar')) {
51
-                sidebar.removeClass('fixed-width-sidebar')
52
-                sidebar.removeClass('col-sm-3');
53
-                
54
-                buttonIcon.removeClass('fa-angle-double-right');
55
-                buttonIcon.addClass('fa-angle-double-left');
56
-              } else {
57
-                sidebar.addClass('fixed-width-sidebar')
58
-                sidebar.addClass('col-sm-3');
59
-                buttonIcon.removeClass('fa-angle-double-left');
60
-                buttonIcon.addClass('fa-angle-double-right');
61
-              }
62
-            });
63
-
64
-            $('#current-page-breadcrumb-toggle-button').click( function() {
65
-              $('#current-page-breadcrumb').toggle();
66
-            });
67
-        });
68
-    </script>
69 40
     <!-- TinyMCE ================================================== -->
70 41
     <script src="${tg.url('/assets/tinymce/js/tinymce/tinymce.min.js')}"></script>
71 42
     ${TIM.TINYMCE_INIT_SCRIPT('.pod-rich-textarea')}

+ 68 - 78
tracim/tracim/templates/page/getone.mak Visa fil

@@ -35,102 +35,92 @@
35 35
 ############################################################################
36 36
 
37 37
 <div class="content-container ${'not-editable' if not result.page.is_editable else ''} ${'archived' if result.page.is_archived else ''} ${'deleted' if result.page.is_deleted else ''}">
38
-<!--# TODO BS 20161213: Indent content-->
39
-
40
-<div class="row t-page-header-row">
41
-    <div class="col-sm-7 col-sm-offset-3 main">
42
-        <h1 class="page-header t-page-color-border">
43
-            <i class="fa fa-fw fa-lg fa-file-text-o tracim-less-visible t-page-color"></i>
44
-            ${result.page.label}
45
-
46
-            <span class="pull-right">
47
-                ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_PAGE(fake_api.current_user, result.page.workspace, result.page)}
48
-            </span>
49
-        </h1>
50
-
51
-        <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
52
-            <% created_localized = h.get_with_timezone(result.page.created) %>
53
-          <p>${_('page created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.page.owner.name)|n}</p>
38
+
39
+    <div class="t-page-header-row">
40
+        <div class="main">
41
+            <h1 class="page-header t-page-color-border">
42
+                <i class="fa fa-fw fa-lg fa-file-text-o tracim-less-visible t-page-color"></i>
43
+                ${result.page.label}
44
+
45
+                <span class="pull-right">
46
+                    ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_PAGE(fake_api.current_user, result.page.workspace, result.page)}
47
+                </span>
48
+            </h1>
49
+
50
+            <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
51
+                <% created_localized = h.get_with_timezone(result.page.created) %>
52
+              <p>${_('page created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.page.owner.name)|n}</p>
53
+            </div>
54 54
         </div>
55 55
     </div>
56
-</div>
57 56
 
58
-% if (result.page.is_archived) :
59
-<div class="row alert alert-info" role="alert">
60
-    <div class="col-sm-7 col-sm-offset-3">
57
+    % if (result.page.is_archived) :
58
+    <div class="alert alert-info" role="alert">
61 59
         <p>
62 60
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
63 61
             ${_('You are viewing <b>an archived version</b> of the current page.')|n}
64 62
         </p>
65 63
     </div>
66
-</div>
67
-% elif (result.page.is_deleted) :
68
-<div class="row alert alert-info" role="alert">
69
-    <div class="col-sm-7 col-sm-offset-3">
64
+    % elif (result.page.is_deleted) :
65
+    <div class="alert alert-info" role="alert">
70 66
         <p>
71 67
             <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
72 68
             ${_('You are viewing <b>a deleted version</b> of the current page.')|n}
73 69
         </p>
74 70
     </div>
75
-</div>
76
-% endif
77
-
78
-% if result.page.selected_revision!='latest':
79
-    <div class="row alert alert-warning" role="alert">
80
-        <div class="col-sm-7 col-sm-offset-3">
81
-            <p>
82
-                <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
83
-                ${_('You are reading <b>an old revision</b> of the current page. (the shown revision is r{}).').format(result.page.selected_revision)|n}
84
-            </p>
85
-            <a class="pull-right alert-link" href="${tg.url('/workspaces/{}/folders/{}/pages/{}').format(result.page.workspace.id, result.page.parent.id, result.page.id)}">${_('Show latest revision')}</a>
86
-        </div>
87
-    </div>
88
-% endif
89
-
90
-% if result.page.status.id=='closed-deprecated':
91
-    <div class="row alert alert-warning" role="alert">
92
-        <div class="col-sm-7 col-sm-offset-3">
93
-            <p>
94
-                <span class="pull-left">${ICON.FA_FW_2X('fa-history')}</span>
95
-                ${_('<b>This information is deprecated</b>')|n}
96
-            </p>
97
-        </div>
98
-    </div>
99
-% endif
100
-
101
-<div class="row">
102
-    <div class="col-sm-7 col-sm-offset-3">
71
+    % endif
103 72
 
104
-## TODO - 2015-07-22 - D.A. - should we show a breadcrumb or not ?
105
-## <button id="current-page-breadcrumb-toggle-button" class="btn btn-link" title="${_('Show localisation')}"><i class="fa fa-map-marker"></i></button>
106
-## ${WIDGETS.BREADCRUMB('current-page-breadcrumb', fake_api.breadcrumb)}
73
+    % if result.page.selected_revision!='latest':
74
+    <div class="alert alert-warning" role="alert">
75
+        <p>
76
+            <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
77
+            ${_('You are reading <b>an old revision</b> of the current page. (the shown revision is r{}).').format(result.page.selected_revision)|n}
78
+        </p>
79
+        <a class="pull-right alert-link" href="${tg.url('/workspaces/{}/folders/{}/pages/{}').format(result.page.workspace.id, result.page.parent.id, result.page.id)}">
80
+            ${_('Show latest revision')}
81
+        </a>
82
+    </div>
83
+    % endif
107 84
 
108
-        % if not result.page.content.strip():
109
-            <div class="t-spacer-above t-less-visible">
110
-                ${_('This page is empty')}
111
-            </div>
112
-        % else:
113
-            <div class="t-spacer-above">
114
-                ${result.page.content|n}
115
-            </div>
116
-        % endif
85
+    % if result.page.status.id=='closed-deprecated':
86
+    <div class="alert alert-warning" role="alert">
87
+        <p>
88
+            <span class="pull-left">${ICON.FA_FW_2X('fa-history')}</span>
89
+            ${_('<b>This information is deprecated</b>')|n}
90
+        </p>
117 91
     </div>
118
-</div>
92
+    % endif
93
+
94
+    <div class="content__detail page">
95
+        <div class="">
96
+            ## TODO - 2015-07-22 - D.A. - should we show a breadcrumb or not ?
97
+            ## <button id="current-page-breadcrumb-toggle-button" class="btn btn-link" title="${_('Show localisation')}"><i class="fa fa-map-marker"></i></button>
98
+            ## ${WIDGETS.BREADCRUMB('current-page-breadcrumb', fake_api.breadcrumb)}
99
+
100
+            % if not result.page.content.strip():
101
+                <div class="t-spacer-above t-less-visible">
102
+                    ${_('This page is empty')}
103
+                </div>
104
+            % else:
105
+                <div class="t-spacer-above">
106
+                    ${result.page.content|n}
107
+                </div>
108
+            % endif
109
+        </div>
119 110
 
120
-<div class="row t-page-metadata-row t-spacer-above">
121
-    <div class="col-sm-7 col-sm-offset-3">
122
-        <div class="t-spacer-above">
123
-            <span id="associated-revisions" ></span>
124
-            <h4 class="anchored-title">${_('Page history')}</h4>
125
-            <div>
126
-                <table class="table table-striped table-hover">
127
-                    % for event in result.page.history:
128
-                        ${WIDGETS.SECURED_HISTORY_VIRTUAL_EVENT_AS_TABLE_ROW(fake_api.current_user, event, result.page.selected_revision)}
129
-                    % endfor
130
-                </table>
111
+        <div class="t-page-metadata-row t-spacer-above">
112
+            <div class="t-spacer-above">
113
+                <span id="associated-revisions" ></span>
114
+                <h4 class="anchored-title">${_('Page history')}</h4>
115
+                <div>
116
+                    <table class="table table-striped table-hover">
117
+                        % for event in result.page.history:
118
+                            ${WIDGETS.SECURED_HISTORY_VIRTUAL_EVENT_AS_TABLE_ROW(fake_api.current_user, event, result.page.selected_revision)}
119
+                        % endfor
120
+                    </table>
121
+                </div>
131 122
             </div>
132
-        </div>
123
+        <div/>
133 124
     </div>
134
-<div/>
135 125
 
136 126
 </div>

+ 2 - 2
tracim/tracim/templates/pod.mak Visa fil

@@ -116,8 +116,8 @@
116 116
 <%def name="FLASH_MSG(css_class='')">
117 117
     <% flash=tg.flash_obj.render('flash', use_js=False) %>
118 118
     % if flash:
119
-        <div class="row" id="flash-message-to-fade-out">
120
-            <div id="t-full-app-alert-message-id" class="${css_class}">
119
+        <div class="" id="flash-message-to-fade-out">
120
+            <div id="t-full-app-alert-message-id" class="flashmsg__data ${css_class}">
121 121
                 ${flash|n}
122 122
             </div>
123 123
         </div>

+ 61 - 66
tracim/tracim/templates/thread/getone.mak Visa fil

@@ -37,77 +37,72 @@
37 37
 ############################################################################
38 38
 
39 39
 <div class="content-container ${'not-editable' if not result.thread.is_editable else ''} ${'archived' if result.thread.is_archived else ''} ${'deleted' if result.thread.is_deleted else ''}">
40
-<!--# TODO BS 20161213: Indent content-->
41
-
42
-<div class="row t-page-header-row">
43
-    <div class="col-sm-7 col-sm-offset-3 main">
44
-        <h1 class="page-header t-thread-color-border">
45
-            <i class="fa fa-fw fa-lg fa-comments-o tracim-less-visible t-thread-color"></i>
46
-            ${result.thread.label}
47
-
48
-            <span class="pull-right">
49
-                ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_THREAD(fake_api.current_user, result.thread.workspace, result.thread)}
50
-            </span>
51
-        </h1>
52
-
53
-        <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
54
-            <% created_localized = h.get_with_timezone(result.thread.created) %>
55
-          <p>${_('page created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.thread.owner.name)|n}</p>
40
+
41
+    <div class="t-page-header-row">
42
+        <div class="main">
43
+            <h1 class="page-header t-thread-color-border">
44
+                <i class="fa fa-fw fa-lg fa-comments-o tracim-less-visible t-thread-color"></i>
45
+                ${result.thread.label}
46
+
47
+                <span class="pull-right">
48
+                    ${WIDGETS.SECURED_SHOW_CHANGE_STATUS_FOR_THREAD(fake_api.current_user, result.thread.workspace, result.thread)}
49
+                </span>
50
+            </h1>
51
+
52
+            <div style="margin: -1.5em auto -1.5em auto;" class="tracim-less-visible">
53
+                <% created_localized = h.get_with_timezone(result.thread.created) %>
54
+              <p>${_('page created on {date} at {time} by <b>{author}</b>').format(date=h.date(created_localized), time=h.time(created_localized), author=result.thread.owner.name)|n}</p>
55
+            </div>
56 56
         </div>
57 57
     </div>
58
-</div>
59 58
 
60
-% if (result.thread.is_archived) :
61
-<div class="row alert alert-info" role="alert">
62
-    <div class="col-sm-7 col-sm-offset-3">
63
-        <p>
64
-            <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
65
-            ${_('Vous consultez <b>une version archivée</b> de la page courante.')|n}
66
-        </p>
59
+    % if (result.thread.is_archived) :
60
+    <div class="alert alert-info" role="alert">
61
+        <div class="">
62
+            <p>
63
+                <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
64
+                ${_('Vous consultez <b>une version archivée</b> de la page courante.')|n}
65
+            </p>
66
+        </div>
67 67
     </div>
68
-</div>
69
-% elif (result.thread.is_deleted) :
70
-<div class="row alert alert-info" role="alert">
71
-    <div class="col-sm-7 col-sm-offset-3">
72
-        <p>
73
-            <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
74
-            ${_('Vous consultez <b>une version supprimée</b> de la page courante.')|n}
75
-        </p>
68
+    % elif (result.thread.is_deleted) :
69
+    <div class="alert alert-info" role="alert">
70
+        <div class="">
71
+            <p>
72
+                <span class="pull-left"><i class="fa fa-fw fa-2x fa-warning" alt="" title=""></i></span>
73
+                ${_('Vous consultez <b>une version supprimée</b> de la page courante.')|n}
74
+            </p>
75
+        </div>
76 76
     </div>
77
-</div>
78
-% endif
77
+    % endif
79 78
 
80
-% if result.thread.status.id=='closed-deprecated':
81
-    <div class="row alert alert-warning" role="alert">
82
-        <div class="col-sm-7 col-sm-offset-3">
79
+    % if result.thread.status.id=='closed-deprecated':
80
+    <div class="alert alert-warning" role="alert">
81
+        <div class="">
83 82
             <p>
84 83
                 <span class="pull-left">${ICON.FA_FW_2X('fa-warning')}</span>
85 84
                 ${_('<b>This information is deprecated</b>')|n}
86 85
             </p>
87 86
         </div>
88 87
     </div>
89
-% endif
90
-
91
-% if result.thread.content:
92
-    <div class="row">
93
-        <div class="col-sm-7 col-sm-offset-3">
88
+    % endif
94 89
 
95
-    ## TODO - 2015-07-22 - D.A. - should we show a breadcrumb or not ?
96
-    ## <button id="current-page-breadcrumb-toggle-button" class="btn btn-link" title="${_('Show localisation')}"><i class="fa fa-map-marker"></i></button>
97
-    ## ${WIDGETS.BREADCRUMB('current-page-breadcrumb', fake_api.breadcrumb)}
90
+    % if result.thread.content:
91
+    <div class="">
92
+        ## TODO - 2015-07-22 - D.A. - should we show a breadcrumb or not ?
93
+        ## <button id="current-page-breadcrumb-toggle-button" class="btn btn-link" title="${_('Show localisation')}"><i class="fa fa-map-marker"></i></button>
94
+        ## ${WIDGETS.BREADCRUMB('current-page-breadcrumb', fake_api.breadcrumb)}
98 95
 
99
-            <div class="well t-half-spacer-above">
100
-                % if result.thread.status.id in ('closed-validated', 'closed-unvalidated'):
101
-                    <span style="font-size: 1.5em;"><i class="pull-right fa fa-4x ${result.thread.status.css} ${result.thread.status.icon}"></i></span>
102
-                % endif
103
-                ${result.thread.content|n}
104
-            </div>
96
+        <div class="well t-half-spacer-above">
97
+            % if result.thread.status.id in ('closed-validated', 'closed-unvalidated'):
98
+                <span style="font-size: 1.5em;"><i class="pull-right fa fa-4x ${result.thread.status.css} ${result.thread.status.icon}"></i></span>
99
+            % endif
100
+            ${result.thread.content|n}
105 101
         </div>
106 102
     </div>
107
-% endif
103
+    % endif
108 104
 
109
-<div class="row">
110
-    <div class="col-sm-7 col-sm-offset-3">
105
+    <div class="content__detail thread">
111 106
         <div class="threads-history-reverse">
112 107
         % if inverted:
113 108
             <a href="${tg.url('/workspaces/{}/folders/{}/threads/{}'.format(result.thread.workspace.id, result.thread.parent.id, result.thread.id))}">
@@ -134,19 +129,19 @@
134 129
                 % endif
135 130
             % endif
136 131
         % endif
137
-    </div>
138
-</div>
139 132
 
140
-<!-- % for event in reversed(result.thread.history): -->
141
-% for event in result.thread.history:
142
-    ## TODO - D.A. - 2015-08-20
143
-    ## Allow to show full history (with status change and archive/unarchive)
144
-    ${WIDGETS.SECURED_HISTORY_VIRTUAL_EVENT(fake_api.current_user, event)}
145
-% endfor
133
+        <!-- % for event in reversed(result.thread.history): -->
134
+        % for event in result.thread.history:
135
+            ## TODO - D.A. - 2015-08-20
136
+            ## Allow to show full history (with status change and archive/unarchive)
137
+            ${WIDGETS.SECURED_HISTORY_VIRTUAL_EVENT(fake_api.current_user, event)}
138
+        % endfor
146 139
 
147
-## % for comment in result.thread.comments:
148
-##     ${WIDGETS.SECURED_TIMELINE_ITEM(fake_api.current_user, comment)}
149
-## % endfor
150
-##
140
+        ## % for comment in result.thread.comments:
141
+        ##     ${WIDGETS.SECURED_TIMELINE_ITEM(fake_api.current_user, comment)}
142
+        ## % endfor
143
+        ##
144
+
145
+    </div>
151 146
 
152 147
 </div>

+ 10 - 10
tracim/tracim/templates/user_workspace_widgets.mak Visa fil

@@ -22,11 +22,11 @@
22 22
     <h4 id="${dom_id}">
23 23
         ${TIM.ICO(icon_size, icon_path) if icon_path else ''}
24 24
         ${label}
25
-        
25
+
26 26
         ## Button is shown for contributors (or more), not for readers
27
-        % if h.user_role(user, workspace)>1: 
27
+        % if h.user_role(user, workspace)>1:
28 28
             % if action_dom_id and action_label:
29
-                <small style="margin-left: 1em;"> ${DATA_TARGET_BUTTON(action_dom_id, action_label)}</small>    
29
+                <small style="margin-left: 1em;"> ${DATA_TARGET_BUTTON(action_dom_id, action_label)}</small>
30 30
             % endif
31 31
         % endif
32 32
     </h4>
@@ -47,7 +47,7 @@
47 47
                             % if folder.folder_nb.all>=1:
48 48
                                 ${_('{nb_total} subfolder(s)').format(nb_total=folder.folder_nb.all)|n}
49 49
                             % endif
50
-                            
50
+
51 51
                             % if folder.thread_nb.all>=1:
52 52
                                 ${_('{nb_total} thread(s) &mdash; {nb_open} open').format(nb_total=folder.thread_nb.all, nb_open=folder.thread_nb.open)|n}
53 53
                                 <br/>
@@ -214,7 +214,7 @@
214 214
 
215 215
                 ##
216 216
                 ## INFO - D.A. - 2014-10-17
217
-                ## Look comment at top of this function in order to get information about the next if/then/else 
217
+                ## Look comment at top of this function in order to get information about the next if/then/else
218 218
                 ##
219 219
                 % if mode=='link_to_document':
220 220
                     $('#${dom_id}-treeview').on("select_node.jstree", function (e, data) {
@@ -223,7 +223,7 @@
223 223
                         url = $('#'+data.selected[0]+' > a').attr('href');
224 224
                         location.href = url;
225 225
                     });
226
-                % else:              
226
+                % else:
227 227
                     $('#${dom_id}-treeview').on("select_node.jstree", function (e, data) {
228 228
                         // on click, the form hidden field is updated
229 229
                         ## FIXME - REMOVE alert('about to update value of field '+'#${dom_id}-treeview-hidden-field');
@@ -236,7 +236,7 @@
236 236
                         % endif
237 237
                     });
238 238
                 % endif
239
-                
239
+
240 240
                 $('#${dom_id}-treeview').on("loaded.jstree", function () {
241 241
                     nodes = $('#${dom_id}-treeview .jstree-node');
242 242
                     console.log("nodes = "+nodes.length);
@@ -340,8 +340,8 @@
340 340
     <% created_localized = h.get_with_timezone(event.created) %>
341 341
     <% is_new_css_class = 't-is-new-content' if event.is_new else '' %>
342 342
 
343
-    <div class="row t-odd-or-even t-hacky-thread-comment-border-top ${is_new_css_class}">
344
-        <div class="col-sm-7 col-sm-offset-3">
343
+    <div class="t-odd-or-even t-hacky-thread-comment-border-top ${is_new_css_class}">
344
+        <div class="">
345 345
             <div class="t-timeline-item">
346 346
 ##                <i class="fa fa-fw fa-3x fa-comment-o t-less-visible" style="margin-left: -1.5em; float:left;"></i>
347 347
 
@@ -407,4 +407,4 @@
407 407
             </td>
408 408
         % endif
409 409
     </tr>
410
-</%def>
410
+</%def>

+ 1 - 1
tracim/tracim/templates/widgets/row.mak Visa fil

@@ -1,5 +1,5 @@
1 1
 <%def name="TITLE_ROW(label, icon, width_classes, color_classes, subtitle)">
2
-    <div class="row" style="background-color: #F5F5F5; border-bottom: 1px solid #CCC;">
2
+    <div class="" style="background-color: #F5F5F5; border-bottom: 1px solid #CCC;">
3 3
         <div class="${width_classes} main">
4 4
             <h1 class="page-header ${color_classes}">
5 5
                 <i class="fa fa-fw fa-lg ${icon} ${color_classes}"></i>

+ 3 - 3
tracim/tracim/templates/widgets/table_row.mak Visa fil

@@ -5,7 +5,7 @@
5 5
 <%def name="USER_ROLE_IN_WORKSPACE(current_user, role, show_id=True, enable_link=None, disable_link=None, role_types=None)">
6 6
     <tr>
7 7
         % if show_id:
8
-            <td class="text-right">${role.workspace.id}</td>
8
+            <td>${role.workspace.id}</td>
9 9
         % endif
10 10
         <td><a href="${tg.url('/admin/workspaces/{}').format(role.workspace.id)}">${role.workspace.name}</a></td>
11 11
 
@@ -33,8 +33,8 @@
33 33
 
34 34
 <%def name="SECURED_MEMBER_IN_WORKSPACE(current_user, workspace, member, role_types)">
35 35
     <tr>
36
-        <td class="text-right">${member.id}</td>
37
-        <td ><a href="${tg.url('/admin/users/{}'.format(member.id))}">${member.name}</a></td>
36
+        <td>${member.id}</td>
37
+        <td><a href="${tg.url('/admin/users/{}'.format(member.id))}">${member.name}</a></td>
38 38
         <td>${BUTTON.SECURED_ROLE_SELECTOR(fake_api.current_user, result.workspace, member, fake_api.role_types)}</td>
39 39
         <%
40 40
             user_is_himself = current_user.id == member.id

+ 98 - 108
tracim/tracim/templates/workspace/getone.mak Visa fil

@@ -37,8 +37,8 @@
37 37
 ##
38 38
 ############################################################################
39 39
 
40
-<div class="row t-page-header-row">
41
-    <div class="col-sm-7 col-sm-offset-3 main">
40
+<div class="t-page-header-row">
41
+    <div class="main">
42 42
         <h1 class="page-header t-less-visible-border">
43 43
             <i class="fa fa-fw fa-lg fa-bank t-less-visible"></i>
44 44
             ${result.workspace.label}
@@ -53,90 +53,80 @@
53 53
 
54 54
 
55 55
 
56
-<div class="row">
57
-    <div class="col-sm-7 col-md-offset-3">
58
-        ${TITLE.H3(_('Detail'), 'fa-align-justify', 'workspace-members')}
59
-        % if result.workspace.description:
60
-            <p>${result.workspace.description}</p>
61
-        % else:
62
-            <p class="t-less-visible">${_('No description available')}</p>
63
-        % endif
56
+<div class="workspace__detail__wrapper">
57
+    ${TITLE.H3(_('Detail'), 'fa-align-justify', 'workspace-members')}
58
+    % if result.workspace.description:
59
+        <p>${result.workspace.description}</p>
60
+    % else:
61
+        <p class="t-less-visible">${_('No description available')}</p>
62
+    % endif
64 63
 
65
-        <% member_nb = len(result.workspace.members) %>
66
-        <% viewable_members = h.get_viewable_members_for_role(fake_api.current_user_workspace_role, result.workspace.members) %>
67
-        <% viewable_member_nb = len(viewable_members) %>
68
-        % if member_nb<=0:
69
-            ${P.EMPTY_CONTENT(_('There are no members in this workspace'))}
70
-        % else:
71
-            <p>
72
-                % if member_nb == 1:
73
-                    ${_('This workspace has {a_open}one member{a_close}').format(a_open='<a data-toggle="collapse" href="#memberList" aria-expanded="false" aria-controls="memberList">', a_close='</a>')|n}
74
-                % else:
75
-                    ${_('This workspace has {a_open}{member_nb} members{a_close}').format(a_open='<a data-toggle="collapse" href="#memberList" aria-expanded="false" aria-controls="memberList">', member_nb=member_nb, a_close='</a>')|n}
76
-                    % if viewable_member_nb != member_nb:
77
-                        <span id="members-whose" style="display: none;">${ _('whose') }:</span>
78
-                    % endif
64
+    <% member_nb = len(result.workspace.members) %>
65
+    <% viewable_members = h.get_viewable_members_for_role(fake_api.current_user_workspace_role, result.workspace.members) %>
66
+    <% viewable_member_nb = len(viewable_members) %>
67
+    % if member_nb<=0:
68
+        ${P.EMPTY_CONTENT(_('There are no members in this workspace'))}
69
+    % else:
70
+        <p>
71
+            % if member_nb == 1:
72
+                ${_('This workspace has {a_open}one member{a_close}').format(a_open='<a data-toggle="collapse" href="#memberList" aria-expanded="false" aria-controls="memberList">', a_close='</a>')|n}
73
+            % else:
74
+                ${_('This workspace has {a_open}{member_nb} members{a_close}').format(a_open='<a data-toggle="collapse" href="#memberList" aria-expanded="false" aria-controls="memberList">', member_nb=member_nb, a_close='</a>')|n}
75
+                % if viewable_member_nb != member_nb:
76
+                    <span id="members-whose" style="display: none;">${ _('whose') }:</span>
79 77
                 % endif
80
-            </p>
81
-            <div class="collapse" id="memberList">
82
-                <table class="table">
83
-                    % for member in viewable_members:
84
-                        <tr>
85
-                            <td><strong>${member.name}</strong></td>
86
-                            <td>
87
-                                ${TIM.ICO_FA_BADGED('fa fa-fw fa-flag', member.role_description, member.style)}
88
-                                ${member.role_description}
89
-                            </td>
90
-                        </tr>
91
-                    % endfor
92
-                </table>
93
-            </div>
94
-            <script>
95
-                $(document).ready(function(){
96
-                    $('#memberList').on('show.bs.collapse', function() {
97
-                        $('#members-whose').show();
98
-                    });
99
-                    $('#memberList').on('hide.bs.collapse', function() {
100
-                        $('#members-whose').hide();
101
-                    });
78
+            % endif
79
+        </p>
80
+        <div class="collapse" id="memberList">
81
+            <table class="table">
82
+                % for member in viewable_members:
83
+                    <tr>
84
+                        <td><strong>${member.name}</strong></td>
85
+                        <td>
86
+                            ${TIM.ICO_FA_BADGED('fa fa-fw fa-flag', member.role_description, member.style)}
87
+                            ${member.role_description}
88
+                        </td>
89
+                    </tr>
90
+                % endfor
91
+            </table>
92
+        </div>
93
+        <script>
94
+            $(document).ready(function(){
95
+                $('#memberList').on('show.bs.collapse', function() {
96
+                    $('#members-whose').show();
102 97
                 });
103
-            </script>
104
-        % endif
105
-
106
-        % if result.workspace.calendar_enabled:
107
-            <p>
108
-                ${_('This workspace has {a_open}an associated calendar{a_close}').format(a_open='<a data-toggle="collapse" href="#calendarConfig" aria-expanded="false" aria-controls="calendarConfig">', a_close='</a>')|n}
109
-            </p>
110
-            <div class="collapse" id="calendarConfig">
111
-                <p>${_('You can access the calendar using your own software: Outlook, Thunderbird, etc.')}</p>
112
-                <p>${_('The url to setup is the following one:')}</p>
113
-                <p class="form-control">${result.workspace.calendar_url}</p>
114
-            </div>
115
-        % endif
116
-
117
-            <p>
118
-                ${_('This workspace is {a_open}accessible with webdav{a_close}').format(a_open='<a data-toggle="collapse" href="#webdavConfig" aria-expanded="false" aria-controls="webdavConfig">', a_close='</a>')|n}
119
-            </p>
120
-            <div class="collapse" id="webdavConfig">
121
-                <p>${_('Adress to connect to webdav with:')}</p>
122
-                <p>Linux : </p>
123
-                <p class="form-control">dav://${webdav_url}</p>
124
-                <p>Windows : </p>
125
-                <p class="form-control">http://${webdav_url}</p>
126
-            </div>
98
+                $('#memberList').on('hide.bs.collapse', function() {
99
+                    $('#members-whose').hide();
100
+                });
101
+            });
102
+        </script>
103
+    % endif
127 104
 
128
-    </div>
129
-</div>
105
+    % if result.workspace.calendar_enabled:
106
+        <p>
107
+            ${_('This workspace has {a_open}an associated calendar{a_close}').format(a_open='<a data-toggle="collapse" href="#calendarConfig" aria-expanded="false" aria-controls="calendarConfig">', a_close='</a>')|n}
108
+        </p>
109
+        <div class="collapse" id="calendarConfig">
110
+            <p>${_('You can access the calendar using your own software: Outlook, Thunderbird, etc.')}</p>
111
+            <p>${_('The url to setup is the following one:')}</p>
112
+            <p class="form-control">${result.workspace.calendar_url}</p>
113
+        </div>
114
+    % endif
130 115
 
131
-<div class="row">
132
-    <div class="col-sm-7 col-sm-offset-3">
133
-        <div class="t-half-spacer-above t-less-visible">
116
+        <p>
117
+            ${_('This workspace is {a_open}accessible with webdav{a_close}').format(a_open='<a data-toggle="collapse" href="#webdavConfig" aria-expanded="false" aria-controls="webdavConfig">', a_close='</a>')|n}
118
+        </p>
119
+        <div class="collapse" id="webdavConfig">
120
+            <p>${_('Adress to connect to webdav with:')}</p>
121
+            <p>Linux : </p>
122
+            <p class="form-control">dav://${webdav_url}</p>
123
+            <p>Windows : </p>
124
+            <p class="form-control">http://${webdav_url}</p>
134 125
         </div>
135
-    </div>
136
-</div>
137 126
 
138
-<div class="row">
139
-    <div class="col-sm-7 col-sm-offset-3">
127
+    <div class="t-half-spacer-above t-less-visible"></div>
128
+
129
+    <div class="">
140 130
         <div class="t-half-spacer-above">
141 131
             <% user_role = h.user_role(fake_api.current_user, result.workspace) %>
142 132
 
@@ -160,17 +150,17 @@
160 150
                                 <li>${BUTTON.DATA_TARGET_AS_TEXT_AND_ICON_MODAL_WITH_REMOTE_CONTENT(modal_dialog_id, content_type.label, new_form_content_url, icon_classes)}</li>
161 151
                             % else:
162 152
                                 <li>${BUTTON.DATA_TARGET_AS_TEXT_AND_ICON_MODAL_WITH_REMOTE_CONTENT('', _('You are not allowed to create content'), '', 't-less-visible fa fa-ban')}</li>
163
-## Show new content entries in the menu is currently not available at root of a workspace
164
-## TODO - D.A. - 2015-08-20 - Allow to put content at root (and show related entry in the menu
165
-##                             % if user_role == 2:
166
-##                                 ## Only show 'new folder' to content managers
167
-##                                 <%
168
-##                                     new_form_content_url = tg.url('/workspaces/{}/folders/{}/{}s/new'.format(result.folder.workspace.id, result.folder.id, content_type.id), params={'workspace_id': result.folder.workspace.id, 'parent_id': result.folder.id})
169
-##                                     modal_dialog_id = '{content_type}-new-modal-dialog'.format(content_type=content_type.id)
170
-##                                     icon_classes = content_type.icon+' '+content_type.color
171
-##                                 %>
172
-##                                 <li>${BUTTON.DATA_TARGET_AS_TEXT_AND_ICON_MODAL_WITH_REMOTE_CONTENT(modal_dialog_id, content_type.label, new_form_content_url, icon_classes)}</li>
173
-##                             % endif
153
+    ## Show new content entries in the menu is currently not available at root of a workspace
154
+    ## TODO - D.A. - 2015-08-20 - Allow to put content at root (and show related entry in the menu
155
+    ##                             % if user_role == 2:
156
+    ##                                 ## Only show 'new folder' to content managers
157
+    ##                                 <%
158
+    ##                                     new_form_content_url = tg.url('/workspaces/{}/folders/{}/{}s/new'.format(result.folder.workspace.id, result.folder.id, content_type.id), params={'workspace_id': result.folder.workspace.id, 'parent_id': result.folder.id})
159
+    ##                                     modal_dialog_id = '{content_type}-new-modal-dialog'.format(content_type=content_type.id)
160
+    ##                                     icon_classes = content_type.icon+' '+content_type.color
161
+    ##                                 %>
162
+    ##                                 <li>${BUTTON.DATA_TARGET_AS_TEXT_AND_ICON_MODAL_WITH_REMOTE_CONTENT(modal_dialog_id, content_type.label, new_form_content_url, icon_classes)}</li>
163
+    ##                             % endif
174 164
                             % endif
175 165
                         % endfor
176 166
                     </ul>
@@ -218,24 +208,24 @@
218 208
                 </table>
219 209
             % endif
220 210
 
221
-##             % if h.user_role(fake_api.current_user, result.workspace)<=2: # User must be a content manager to be allowed to create folders
222
-##                 ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.workspace, 'sub-folders', _('Folders'))}
223
-##             % else:
224
-##                 ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.workspace, 'sub-folders', _('Folders'), 'folder-new', _('Add a folder...'))}
225
-##                 {FORMS.NEW_FOLDER_FORM('folder-new', result.workspace.id)}
226
-##             % endif
227
-##
228
-##             <p>
229
-##                 ${WIDGETS.FOLDER_LIST('subfolder-list', result.workspace.id, fake_api.current_workspace_folders)}
230
-##             </p>
231
-##             % if len(fake_api.current_workspace_folders)<=0 and fake_api.current_user:
232
-##                 % if h.user_role(fake_api.current_user, result.workspace)>2: # User must be a content manager to be allowed to create folders
233
-##                     <p>
234
-##                         ${_('You need folders to organize your content.')}
235
-##                         <a class="btn btn-small btn-primary" data-toggle="collapse" data-target="#folder-new"><i class="fa fa-check"></i> <b>${_('Create a folder now')}</b></a>
236
-##                     </p>
237
-##                 % endif
238
-##             % endif
211
+    ##             % if h.user_role(fake_api.current_user, result.workspace)<=2: # User must be a content manager to be allowed to create folders
212
+    ##                 ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.workspace, 'sub-folders', _('Folders'))}
213
+    ##             % else:
214
+    ##                 ${WIDGETS.SECURED_SECTION_TITLE(fake_api.current_user, result.workspace, 'sub-folders', _('Folders'), 'folder-new', _('Add a folder...'))}
215
+    ##                 {FORMS.NEW_FOLDER_FORM('folder-new', result.workspace.id)}
216
+    ##             % endif
217
+    ##
218
+    ##             <p>
219
+    ##                 ${WIDGETS.FOLDER_LIST('subfolder-list', result.workspace.id, fake_api.current_workspace_folders)}
220
+    ##             </p>
221
+    ##             % if len(fake_api.current_workspace_folders)<=0 and fake_api.current_user:
222
+    ##                 % if h.user_role(fake_api.current_user, result.workspace)>2: # User must be a content manager to be allowed to create folders
223
+    ##                     <p>
224
+    ##                         ${_('You need folders to organize your content.')}
225
+    ##                         <a class="btn btn-small btn-primary" data-toggle="collapse" data-target="#folder-new"><i class="fa fa-check"></i> <b>${_('Create a folder now')}</b></a>
226
+    ##                     </p>
227
+    ##                 % endif
228
+    ##             % endif
239 229
         </div>
240 230
     </div>
241 231
 </div>