Ignore:
Timestamp:
28 Jan 2014, 15:32:58 (11 years ago)
Author:
uli
Message:

Use twbs 3.x tabs.

Location:
main/waeup.kofa/branches/uli-diazo-themed
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/branches/uli-diazo-themed/layout/theme.html

    r10994 r10995  
    1313    <link href="bootstrap/css/bootstrap-theme.min.css"
    1414          rel="stylesheet">
    15 
    1615    <link href="static/css/jquery.dataTables.css"
    1716          rel="stylesheet">
    18 
    1917    <link href="static/css/base.css" rel="stylesheet">
    2018
     
    105103                <li><a href="#">Personal Data</a></li>
    106104                <li><a href="#">Study Course</a></li>
    107                 <li><a href="#"">Payments</a></li>
     105                <li><a href="#">Payments</a></li>
    108106                <li><a href="#">Accommodation</a></li>
    109107                <li><a href="#">History</a></li>
     
    124122          </div> <!-- /well -->
    125123        </div> <!-- /kofa-sidebar -->
     124
    126125        <div class="col-md-10 content kofa-content-narrow">
    127126          <div class="well">
     
    149148              </div>
    150149              <h1>WAeUP.Kofa Theme</h1>
    151               <p class="kofa-content-desc">A sample Diazo theme for WAeUP.Kofa
    152               <br>
    153               Fusce dapibus, tellus ac cursus commodo.
     150
     151              <p class="kofa-content-desc">
     152                A sample Diazo theme for WAeUP.Kofa
     153                <br />
     154                Fusce dapibus, tellus ac cursus commodo.
    154155              </p>
    155156              <p>
     
    161162              </p>
    162163              <img src="static/img/bg.png" />
     164
     165              <!-- Tabs... -->
     166              <br /><br />
     167              <h3>Sample Tabs</h3>
     168              <ul id="tabs" class="tabs nav nav-tabs" data-tabs="tabs">
     169                <li class="active">
     170                  <a href="#tab-1" data-toggle="tab">Tab 1</a>
     171                </li>
     172                <li class="">
     173                  <a href="#tab-2" data-toggle="tab">Tab 2</a>
     174                </li>
     175                <li class="">
     176                  <a href="#tab-3" data-toggle="tab">Tab 3</a>
     177                </li>
     178              </ul>
     179              <div class="tab-content">
     180                <div id="tab-1" class="tab-pane active">
     181                  <br />
     182                  <p>
     183                    Tab 1 content...<br />  Donec id elit non mi porta
     184                    gravida at eget metus. Fusce dapibus, tellus ac
     185                    cursus commodo.
     186                  </p>
     187                </div>
     188                <div id="tab-2" class="tab-pane">
     189                  <br />
     190                  <p>
     191                    Tab 2 content...<br />  Tortor mauris condimentum
     192                    nibh, ut fermentum massa justo sit amet
     193                    risus. Etiam porta sem malesuada.
     194                  </p>
     195                </div>
     196                <div id="tab-3" class="tab-pane">
     197                  <br />
     198                  <p>
     199                    Tab 3 content...<br /> Magna mollis euismod. Donec
     200                    sed odio dui.
     201                  </p>
     202                </div>
     203              </div><!-- /tab-content -->
     204
     205              <script type="text/javascript"
     206                      class="kofa-script kofa-script-tabs">
     207                $('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
     208                console.log('showing tab ' + e.target); // Active Tab
     209                console.log('showing tab ' + e.relatedTarget); // Previous Tab
     210                });
     211              </script>
     212
    163213            </div> <!-- /kofa-content -->
    164214          </div> <!-- /well -->
     
    402452                "aoColumnDefs":[{ "bSortable": false, "aTargets": [ 0 ] }]
    403453        } );
     454
     455        //* activate current tab, if any... */
     456        $('a[href="' + window.location.hash + '"]').trigger('click');
    404457      });
    405458    </script>
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/pages.py

    r10685 r10995  
    8686    if user is None or localrole is None:
    8787        view.flash('No user selected.')
    88         view.redirect(view.url(view.context, '@@manage')+'?tab%s' % tab)
     88        view.redirect(view.url(view.context, '@@manage')+'#tab%s' % tab)
    8989        return
    9090    role_manager = IPrincipalRoleManager(view.context)
     
    9494    grok.getSite().logger.info(
    9595        '%s - added: %s|%s' % (ob_class, user, localrole))
    96     view.redirect(view.url(view.context, u'@@manage')+'?tab%s' % tab)
     96    view.redirect(view.url(view.context, u'@@manage')+'#tab%s' % tab)
    9797    return
    9898
     
    101101    if child_ids is None:
    102102        view.flash(_('No local role selected.'))
    103         view.redirect(view.url(view.context, '@@manage')+'?tab%s' % tab)
     103        view.redirect(view.url(view.context, '@@manage')+'#tab%s' % tab)
    104104        return
    105105    if not isinstance(child_ids, list):
     
    125125        grok.getSite().logger.info(
    126126            '%s - removed: %s' % (ob_class, ', '.join(deleted)))
    127     view.redirect(view.url(view.context, u'@@manage')+'?tab%s' % tab)
     127    view.redirect(view.url(view.context, u'@@manage')+'#tab%s' % tab)
    128128    return
    129129
     
    135135        view.flash(_('No item selected.'))
    136136        if tab:
    137             view.redirect(view.url(view.context, redirect)+'?tab%s' % tab)
     137            view.redirect(view.url(view.context, redirect)+'#tab%s' % tab)
    138138        else:
    139139            view.redirect(view.url(view.context, redirect))
     
    160160            '%s - removed: %s' % (ob_class, ', '.join(deleted)))
    161161    if tab:
    162         view.redirect(view.url(view.context, redirect)+'?tab%s' % tab)
     162        view.redirect(view.url(view.context, redirect)+'#tab%s' % tab)
    163163    else:
    164164        view.redirect(view.url(view.context, redirect))
     
    770770    form_fields['frontpage'].custom_widget = HTMLDisplayWidget
    771771
     772
    772773class ConfigurationContainerManageFormPage(KofaEditFormPage):
    773774    """Manage page of the configuration container. We always use the
     
    784785        _('Add session configuration'),
    785786        _('Remove selected')]
    786     form_fields = grok.AutoFields(IConfigurationContainer).omit('frontpage_dict')
     787    form_fields = grok.AutoFields(IConfigurationContainer).omit(
     788        'frontpage_dict')
    787789
    788790    def update(self):
    789         tabs.need()
    790         self.tab1 = self.tab2 = ''
    791         qs = self.request.get('QUERY_STRING', '')
    792         if not qs:
    793             qs = 'tab1'
    794         setattr(self, qs, 'active')
    795791        datatable.need()
    796792        warning.need()
     
    859855            self.flash(_('The session chosen already exists.'))
    860856            return
    861         self.redirect(self.url(self.context, '@@index')+'?tab2')
     857        self.redirect(self.url(self.context, '@@index')+'#tab2')
    862858        return
    863859
    864860    @action(_('Cancel'), validator=NullValidator)
    865861    def cancel(self):
    866         self.redirect(self.url(self.context, '@@index')+'?tab2')
     862        self.redirect(self.url(self.context, '@@index')+'#tab2')
    867863        return
    868864
     
    885881    def save(self, **data):
    886882        msave(self, **data)
    887         self.redirect(self.url(self.context.__parent__, '@@index')+'?tab2')
     883        self.redirect(self.url(self.context.__parent__, '@@index')+'#tab2')
    888884        return
    889885
    890886    @action(_('Cancel'), validator=NullValidator)
    891887    def cancel(self):
    892         self.redirect(self.url(self.context.__parent__, '@@index')+'?tab2')
     888        self.redirect(self.url(self.context.__parent__, '@@index')+'#tab2')
    893889        return
    894890
     
    17631759        self.context.__parent__.logger.info(
    17641760            '%s - added: %s' % (ob_class, faculty.code))
    1765         self.redirect(self.url(self.context, u'@@manage')+'?tab1')
     1761        self.redirect(self.url(self.context, u'@@manage')+'#tab1')
    17661762        return
    17671763
     
    18071803
    18081804    def update(self):
    1809         tabs.need()
    1810         self.tab1 = self.tab2 = self.tab3 = ''
    1811         qs = self.request.get('QUERY_STRING', '')
    1812         if not qs:
    1813             qs = 'tab1'
    1814         setattr(self, qs, 'active')
    18151805        warning.need()
    18161806        datatable.need()
     
    19211911        self.context.__parent__.__parent__.logger.info(
    19221912            '%s - added: %s' % (ob_class, data['code']))
    1923         self.redirect(self.url(self.context, u'@@manage')+'?tab2')
     1913        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
    19241914        return
    19251915
     
    19421932
    19431933    def update(self):
    1944         tabs.need()
    19451934        datatable.need()
    19461935        super(DepartmentPage, self).update()
     
    19981987
    19991988    def update(self):
    2000         tabs.need()
    2001         self.tab1 = self.tab2 = self.tab3 = self.tab4 = ''
    2002         qs = self.request.get('QUERY_STRING', '')
    2003         if not qs:
    2004             qs = 'tab1'
    2005         setattr(self, qs, 'active')
    20061989        warning.need()
    20071990        datatable.need()
     
    20842067        self.context.__parent__.__parent__.__parent__.logger.info(
    20852068            '%s - added: %s' % (ob_class, data['code']))
    2086         self.redirect(self.url(self.context, u'@@manage')+'?tab2')
     2069        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
    20872070        return
    20882071
     
    21252108        self.context.__parent__.__parent__.__parent__.logger.info(
    21262109            '%s - added: %s' % (ob_class, data['code']))
    2127         self.redirect(self.url(self.context, u'@@manage')+'?tab3')
     2110        self.redirect(self.url(self.context, u'@@manage')+'#tab3')
    21282111        return
    21292112
     
    21662149
    21672150    def update(self):
    2168         tabs.need()
    2169         self.tab1 = self.tab2 = ''
    2170         qs = self.request.get('QUERY_STRING', '')
    2171         if not qs:
    2172             qs = 'tab1'
    2173         setattr(self, qs, 'active')
    21742151        warning.need()
    21752152        datatable.need()
     
    22392216
    22402217    def update(self):
    2241         tabs.need()
    2242         self.tab1 = self.tab2 = self.tab3 = ''
    2243         qs = self.request.get('QUERY_STRING', '')
    2244         if not qs:
    2245             qs = 'tab1'
    2246         setattr(self, qs, 'active')
    22472218        warning.need()
    22482219        datatable.need()
     
    23012272        ob_class = self.__implemented__.__name__.replace('waeup.kofa.','')
    23022273        grok.getSite().logger.info('%s - added: %s' % (ob_class, code))
    2303         self.redirect(self.url(self.context, u'@@manage')+'?tab2')
     2274        self.redirect(self.url(self.context, u'@@manage')+'#tab2')
    23042275        return
    23052276
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/certificatemanagepage.pt

    r9320 r10995  
    22      enctype="multipart/form-data" i18n:domain="waeup.kofa">
    33
    4   <ul class="tabs" data-tabs="tabs">
    5     <li tal:attributes="class view/tab1"><a href="#tab-1" i18n:translate="">Settings</a></li>
    6     <li tal:attributes="class view/tab2"><a href="#tab-2" i18n:translate="">Certificate Courses</a></li>
    7     <li tal:attributes="class view/tab3"><a href="#tab-3" i18n:translate="">Local Roles</a></li>
     4  <ul class="tabs nav nav-tabs" data-tabs="tabs">
     5    <li class="active">
     6      <a href="#tab1" data-toggle="tab" i18n:translate="">Settings</a>
     7    </li>
     8    <li>
     9      <a href="#tab2" data-toggle="tab"
     10         i18n:translate="">Certificate Courses</a>
     11    </li>
     12    <li>
     13      <a href="#tab3" data-toggle="tab" i18n:translate="">Local Roles</a>
     14    </li>
    815  </ul>
    916
    1017  <div class="tab-content">
    11     <div id="tab-1" tal:attributes="class view/tab1">
    12     <table class="form-table">
    13       <tbody>
    14         <tal:widgets content="structure provider:widgets" />
    15       </tbody>
    16     </table>
    17     <div tal:condition="view/availableActions">
    18       <span tal:repeat="action view/actions"
    19             tal:omit-tag="">
    20         <input tal:condition="python:action.label in view.taboneactions"
    21                tal:replace="structure action/render"/>
    22       </span>
     18    <div id="tab1" class="active tab-pane">
     19      <table class="form-table">
     20        <tbody>
     21          <tal:widgets content="structure provider:widgets" />
     22        </tbody>
     23      </table>
     24      <div tal:condition="view/availableActions">
     25        <span tal:repeat="action view/actions"
     26              tal:omit-tag="">
     27          <input tal:condition="python:action.label in view.taboneactions"
     28                 tal:replace="structure action/render"/>
     29        </span>
     30      </div>
    2331    </div>
    24     </div>
    25     <div id="tab-2" tal:attributes="class view/tab2">
     32    <div id="tab2" class="tab-pane">
    2633      <h3>
    2734        <span tal:content="context/__name__">Code</span>
     
    4249        <tbody>
    4350          <tr tal:repeat="cc context/values" class="gradeC">
    44              <td>
     51            <td>
    4552              <input type="checkbox" name="val_id"
    46                         tal:attributes="value cc/__name__" />
     53                    tal:attributes="value cc/__name__" />
    4754            </td>
    48              <td>
     55            <td>
    4956              <span tal:content="cc/level">
    50                    LEVEL
     57                LEVEL
    5158              </span>
    5259            </td>
     
    5461            <td>
    5562              <a tal:attributes="href python: view.url(cc)"
    56                      tal:content="cc/__name__">
     63                 tal:content="cc/__name__">
    5764                REFERRER CODE
    5865              </a>
     
    6067            <td>
    6168              <a tal:attributes="href python:view.url(cc.course)"
    62                      tal:content="cc/course/code">
     69                 tal:content="cc/course/code">
    6370                COURSE CODE
    6471              </a>
     
    6673            <td>
    6774              <span tal:content="cc/course/title">
    68                    COURSE TITLE
     75                COURSE TITLE
    6976              </span>
    7077            </td>
    7178            <td>
    7279              <span tal:content="cc/mandatory">
    73                    REQUIRED
     80                REQUIRED
    7481              </span>
    7582            </td>
     
    8592      </div>
    8693    </div>
    87     <div id="tab-3" tal:attributes="class view/tab3"> <br />
     94    <div id="tab3" class="tab-pane">
     95      <br />
    8896      <table class="display dataTableManage">
    8997        <thead>
     
    101109        <tbody>
    102110          <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC"> <td>
    103               <input type="checkbox" name="role_id"
    104                 tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
     111            <input type="checkbox" name="role_id"
     112                   tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
    105113            <td tal:content="entry/user_name"> USERNAME </td>
    106114            <td tal:content="entry/user_title"> USERTITLE </td>
     
    112120        <span tal:repeat="action view/actions" tal:omit-tag="">
    113121          <input tal:condition="python:action.label in view.tabthreeactions1"
    114             tal:replace="structure action/render"/>
     122                 tal:replace="structure action/render"/>
    115123        </span>
    116       </div><br /><br />
    117       <table class="form-table">
    118         <tr> <td>
     124        </div><br /><br />
     125        <table class="form-table">
     126          <tr> <td>
    119127            <select id="user" name="user">
    120128              <option tal:repeat="user view/getUsers"
    121                 tal:attributes="value user/name">
    122               <span tal:replace="user/val/title">USERTITLE
    123               </span>
     129                      tal:attributes="value user/name">
     130                <span tal:replace="user/val/title">USERTITLE
     131                </span>
    124132              </option>
    125             </select> </td> <td>
    126             <select id="local_role" name="local_role">
    127               <option tal:repeat="localrole view/getLocalRoles"
    128                 tal:attributes="value localrole/name">
    129               <span tal:replace="localrole/title">LOCALROLETITLE
    130               </span>
    131               </option>
    132             </select> </td> <td>
    133             <div tal:condition="view/availableActions">
    134               <span tal:repeat="action view/actions" tal:omit-tag="">
    135                 <input tal:condition="python:action.label in view.tabthreeactions2"
    136                   tal:replace="structure action/render"/>
    137               </span>
    138             </div> </td>
    139         </tr>
    140       </table>
     133              </select> </td> <td>
     134              <select id="local_role" name="local_role">
     135                <option tal:repeat="localrole view/getLocalRoles"
     136                        tal:attributes="value localrole/name">
     137                  <span tal:replace="localrole/title">LOCALROLETITLE
     138                  </span>
     139                </option>
     140                </select> </td> <td>
     141                <div tal:condition="view/availableActions">
     142                  <span tal:repeat="action view/actions" tal:omit-tag="">
     143                    <input tal:condition="python:action.label in view.tabthreeactions2"
     144                           tal:replace="structure action/render"/>
     145                  </span>
     146                </div>
     147              </td>
     148          </tr>
     149        </table>
    141150    </div>
    142151  </div>
    143152</form>
    144 
    145 
    146 
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/configurationmanagepage.pt

    r7811 r10995  
    11<form action="." tal:attributes="action request/URL" method="POST"
    2   enctype="multipart/form-data" i18n:domain="waeup.kofa">
    3     <ul class="tabs" data-tabs="tabs">
    4       <li tal:attributes="class view/tab1">
    5       <a href="#tab-1" i18n:translate="">Site Settings</a>
    6       </li>
    7       <li tal:attributes="class view/tab2">
    8       <a href="#tab-2" i18n:translate="">Session Configurations</a>
    9       </li>
    10     </ul>
    11     <div class="tab-content">
    12     <div id="tab-1" tal:attributes="class view/tab1">
     2      enctype="multipart/form-data" i18n:domain="waeup.kofa">
     3  <ul class="tabs nav nav-tabs" data-tabs="tabs">
     4    <li class="active">
     5      <a href="#tab1" data-toggle="tab"
     6         i18n:translate="">Site Settings</a>
     7    </li>
     8    <li>
     9      <a href="#tab2"  data-toggle="tab"
     10         i18n:translate="">Session Configurations</a>
     11    </li>
     12  </ul>
     13  <div class="tab-content">
     14    <div id="tab1" class="active tab-pane">
    1315      <table class="form-table">
    1416        <tbody>
     
    2325      </div>
    2426    </div>
    25     <div id="tab-2" tal:attributes="class view/tab2"> <br />
     27    <div id="tab2" class="tab-pane">
     28      <br />
    2629      <table class="display dataTableManage">
    2730        <thead>
     
    3437        </thead>
    3538        <tbody>
    36           <tr tal:repeat="entry view/getSessionConfigurations" class="gradeC"> <td>
    37               <input type="checkbox" name="val_id" tal:attributes="value entry/name" /> </td> <td>
    38               <a href="" tal:attributes="href entry/url" tal:content="entry/title">Name</a> </td>
     39          <tr tal:repeat="entry view/getSessionConfigurations"
     40              class="gradeC"> <td>
     41            <input type="checkbox" name="val_id"
     42                   tal:attributes="value entry/name" /> </td> <td>
     43            <a href="" tal:attributes="href entry/url"
     44               tal:content="entry/title">Name</a> </td>
    3945          </tr>
    4046        </tbody>
     
    4349        <span tal:repeat="action view/actions" tal:omit-tag="">
    4450          <input tal:condition="python:action.label in view.tabtwoactions"
    45             tal:replace="structure action/render"/>
     51                 tal:replace="structure action/render"/>
    4652        </span>
    4753      </div>
    48     </div>
    49   </div>
     54    </div><!-- /tab2 -->
     55  </div><!-- /tab-content -->
    5056</form>
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/coursemanagepage.pt

    r10540 r10995  
    22      enctype="multipart/form-data" i18n:domain="waeup.kofa">
    33
    4   <ul class="tabs" data-tabs="tabs">
    5     <li tal:attributes="class view/tab1"><a href="#tab-1" i18n:translate="">Settings</a></li>
    6     <li tal:attributes="class view/tab2"><a href="#tab-3" i18n:translate="">Local Roles</a></li>
     4  <ul class="tabs nav nav-tabs" data-tabs="tabs">
     5    <li class="active">
     6      <a href="#tab1" data-toggle="tab" i18n:translate="">Settings</a>
     7    </li>
     8    <li>
     9      <a href="#tab3" data-toggle="tab" i18n:translate="">Local Roles</a>
     10    </li>
    711  </ul>
    812
    913  <div class="tab-content">
    10     <div id="tab-1" tal:attributes="class view/tab1">
    11     <table class="form-table">
    12       <tbody>
    13         <tal:widgets content="structure provider:widgets" />
    14       </tbody>
    15     </table>
    16     <div tal:condition="view/availableActions">
    17       <span tal:repeat="action view/actions"
    18             tal:omit-tag="">
    19         <input tal:condition="python:action.label in view.taboneactions"
    20                tal:replace="structure action/render"/>
    21       </span>
     14    <div id="tab1" class="tab-pane active">
     15      <table class="form-table">
     16        <tbody>
     17          <tal:widgets content="structure provider:widgets" />
     18        </tbody>
     19      </table>
     20      <div tal:condition="view/availableActions">
     21        <span tal:repeat="action view/actions"
     22              tal:omit-tag="">
     23          <input tal:condition="python:action.label in view.taboneactions"
     24                 tal:replace="structure action/render"/>
     25        </span>
     26      </div>
    2227    </div>
    23     </div>
    24     <div id="tab-3" tal:attributes="class view/tab2"> <br />
     28    <div id="tab3" class="tab-pane">
     29      <br />
    2530      <table class="display dataTableManage">
    2631        <thead>
     
    3843        <tbody>
    3944          <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC"> <td>
    40               <input type="checkbox" name="role_id"
    41                 tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
     45            <input type="checkbox" name="role_id"
     46                   tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
    4247            <td tal:content="entry/user_name"> USERNAME </td>
    4348            <td tal:content="entry/user_title"> USERTITLE </td>
     
    4954        <span tal:repeat="action view/actions" tal:omit-tag="">
    5055          <input tal:condition="python:action.label in view.tabtwoactions1"
    51             tal:replace="structure action/render"/>
     56                 tal:replace="structure action/render"/>
    5257        </span>
    53       </div><br /><br />
    54       <table class="form-table">
    55         <tr> <td>
     58        </div><br /><br />
     59        <table class="form-table">
     60          <tr> <td>
    5661            <select id="user" name="user">
    5762              <option tal:repeat="user view/getUsers"
    58                 tal:attributes="value user/name">
    59               <span tal:replace="user/val/title">USERTITLE
    60               </span>
     63                      tal:attributes="value user/name">
     64                <span tal:replace="user/val/title">USERTITLE
     65                </span>
    6166              </option>
    62             </select> </td> <td>
    63             <select id="local_role" name="local_role">
    64               <option tal:repeat="localrole view/getLocalRoles"
    65                 tal:attributes="value localrole/name">
    66               <span tal:replace="localrole/title">LOCALROLETITLE
    67               </span>
    68               </option>
    69             </select> </td> <td>
    70             <div tal:condition="view/availableActions">
    71               <span tal:repeat="action view/actions" tal:omit-tag="">
    72                 <input tal:condition="python:action.label in view.tabtwoactions2"
    73                   tal:replace="structure action/render"/>
    74               </span>
    75             </div> </td>
    76         </tr>
    77       </table>
     67              </select> </td> <td>
     68              <select id="local_role" name="local_role">
     69                <option tal:repeat="localrole view/getLocalRoles"
     70                        tal:attributes="value localrole/name">
     71                  <span tal:replace="localrole/title">LOCALROLETITLE
     72                  </span>
     73                </option>
     74                </select> </td> <td>
     75                <div tal:condition="view/availableActions">
     76                  <span tal:repeat="action view/actions" tal:omit-tag="">
     77                    <input tal:condition="python:action.label in view.tabtwoactions2"
     78                           tal:replace="structure action/render"/>
     79                  </span>
     80                </div> </td>
     81          </tr>
     82        </table>
    7883    </div>
    7984  </div>
    8085</form>
    81 
    82 
    83 
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/departmentmanagepage.pt

    r7811 r10995  
    11<form action="." tal:attributes="action request/URL" method="POST"
    2   i18n:domain="waeup.kofa" enctype="multipart/form-data">
    3   <ul class="tabs" data-tabs="tabs">
    4     <li tal:attributes="class view/tab1">
    5     <a href="#tab-1">
    6       <span i18n:translate="">Settings
    7       </span></a>
     2      i18n:domain="waeup.kofa" enctype="multipart/form-data">
     3  <ul class="tabs nav nav-tabs" data-tabs="tabs">
     4    <li class="active">
     5      <a href="#tab1" data-toggle="tab">
     6      <span i18n:translate="">Settings</span></a>
    87    </li>
    9     <li tal:attributes="class view/tab2">
    10     <a href="#tab-2" i18n:translate="">Courses</a>
     8    <li>
     9      <a href="#tab2"  data-toggle="tab" i18n:translate="">Courses</a>
    1110    </li>
    12     <li tal:attributes="class view/tab3">
    13     <a href="#tab-3" i18n:translate="">Certificates</a>
     11    <li>
     12      <a href="#tab3"  data-toggle="tab" i18n:translate="">Certificates</a>
    1413    </li>
    15     <li tal:attributes="class view/tab4">
    16     <a href="#tab-4" i18n:translate="">Local Roles</a>
     14    <li>
     15      <a href="#tab4"  data-toggle="tab" i18n:translate="">Local Roles</a>
    1716    </li>
    1817  </ul>
    1918  <div class="tab-content">
    20     <div id="tab-1" tal:attributes="class view/tab1">
     19    <div id="tab1" class="active tab-pane">
    2120      <table class="form-table">
    2221        <tbody>
     
    2726        <span tal:repeat="action view/actions" tal:omit-tag="">
    2827          <input tal:condition="python:action.label in view.taboneactions"
    29             tal:replace="structure action/render"/>
     28                 tal:replace="structure action/render"/>
    3029        </span>
    3130      </div>
    3231    </div>
    33     <div id="tab-2" tal:attributes="class view/tab2"> <br />
     32    <div id="tab2" class="tab-pane">
     33      <br />
    3434      <table class="display dataTableManage">
    3535        <thead>
     
    4545        <tbody>
    4646          <tr tal:repeat="entry view/getCourses" class="gradeC"> <td>
    47               <input type="checkbox" name="val_id"
    48                 tal:attributes="value entry/name" /> </td> <td>
    49               <a href="" tal:attributes="href entry/url"
    50                 tal:content="entry/name">Name</a> </td>
     47            <input type="checkbox" name="val_id"
     48                   tal:attributes="value entry/name" /> </td> <td>
     49            <a href="" tal:attributes="href entry/url"
     50               tal:content="entry/name">Name</a> </td>
    5151            <td tal:content="entry/container/title"> Title </td>
    5252          </tr>
     
    5656        <span tal:repeat="action view/actions" tal:omit-tag="">
    5757          <input tal:condition="python:action.label in view.tabtwoactions"
    58             tal:replace="structure action/render"/>
     58                 tal:replace="structure action/render"/>
    5959        </span>
    6060      </div>
    6161    </div>
    62     <div id="tab-3" tal:attributes="class view/tab3"> <br />
     62    <div id="tab3" class="tab-pane">
     63      <br />
    6364      <table class="display dataTableManage">
    6465        <thead>
     
    7475        <tbody>
    7576          <tr tal:repeat="entry view/getCertificates" class="gradeC"> <td>
    76               <input type="checkbox" name="val_id"
    77                 tal:attributes="value entry/name" /> </td> <td>
    78               <a href="" tal:attributes="href entry/url"
    79                 tal:content="entry/name">Name</a> </td>
     77            <input type="checkbox" name="val_id"
     78                   tal:attributes="value entry/name" /> </td> <td>
     79            <a href="" tal:attributes="href entry/url"
     80               tal:content="entry/name">Name</a> </td>
    8081            <td tal:content="entry/container/title"> Title  </td>
    8182          </tr>
     
    8586        <span tal:repeat="action view/actions" tal:omit-tag="">
    8687          <input tal:condition="python:action.label in view.tabthreeactions"
    87             tal:replace="structure action/render"/>
     88                 tal:replace="structure action/render"/>
    8889        </span>
    8990      </div>
    9091    </div>
    91     <div id="tab-4" tal:attributes="class view/tab4"> <br />
    92       <table class="display dataTableManage">
    93         <thead>
    94           <tr>
    95             <th>&nbsp;
    96             </th>
    97             <th i18n:translate="">User Id
    98             </th>
    99             <th i18n:translate="">Name
    100             </th>
    101             <th i18n:translate="">Local Role
    102             </th>
    103           </tr>
    104         </thead>
    105         <tbody>
    106           <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC">
    107             <td> <input type="checkbox" name="role_id"
    108                 tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
    109             <td tal:content="entry/user_name"> USERNAME </td>
    110             <td tal:content="entry/user_title"> USERTITLE </td>
    111             <td tal:content="entry/local_role_title"> LOCAL ROLE </td>
    112           </tr>
    113         </tbody>
    114       </table>
    115       <div tal:condition="view/availableActions">
    116         <span tal:repeat="action view/actions" tal:omit-tag="">
    117           <input tal:condition="python:action.label in view.tabfouractions1"
    118             tal:replace="structure action/render"/>
    119         </span>
     92    <div id="tab4" class="tab-pane"> <br />
     93    <table class="display dataTableManage">
     94      <thead>
     95        <tr>
     96          <th>&nbsp;
     97          </th>
     98          <th i18n:translate="">User Id
     99          </th>
     100          <th i18n:translate="">Name
     101          </th>
     102          <th i18n:translate="">Local Role
     103          </th>
     104        </tr>
     105      </thead>
     106      <tbody>
     107        <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC">
     108          <td> <input type="checkbox" name="role_id"
     109          tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
     110          <td tal:content="entry/user_name"> USERNAME </td>
     111          <td tal:content="entry/user_title"> USERTITLE </td>
     112          <td tal:content="entry/local_role_title"> LOCAL ROLE </td>
     113        </tr>
     114      </tbody>
     115    </table>
     116    <div tal:condition="view/availableActions">
     117      <span tal:repeat="action view/actions" tal:omit-tag="">
     118        <input tal:condition="python:action.label in view.tabfouractions1"
     119               tal:replace="structure action/render"/>
     120      </span>
    120121      </div> <br /><br />
    121122      <table class="form-table">
    122123        <tr> <td>
    123             <select id="user" name="user">
    124               <option tal:attributes="value user/name" tal:repeat="user view/getUsers">
     124          <select id="user" name="user">
     125            <option tal:attributes="value user/name" tal:repeat="user view/getUsers">
    125126              <span tal:replace="user/val/title">USERTITLE
    126127              </span>
    127               </option>
     128            </option>
    128129            </select> </td> <td>
    129130            <select id="local_role" name="local_role">
    130131              <option tal:attributes="value localrole/name"
    131                 tal:repeat="localrole view/getLocalRoles">
    132               <span tal:replace="localrole/title">LOCALROLETITLE
    133               </span>
     132                      tal:repeat="localrole view/getLocalRoles">
     133                <span tal:replace="localrole/title">LOCALROLETITLE
     134                </span>
    134135              </option>
    135             </select> </td> <td>
    136             <div tal:condition="view/availableActions">
    137               <span tal:repeat="action view/actions" tal:omit-tag="">
    138                 <input tal:condition="python:action.label in view.tabfouractions2"
    139                   tal:replace="structure action/render"/>
    140               </span>
    141             </div> </td>
     136              </select> </td> <td>
     137              <div tal:condition="view/availableActions">
     138                <span tal:repeat="action view/actions" tal:omit-tag="">
     139                  <input tal:condition="python:action.label in view.tabfouractions2"
     140                         tal:replace="structure action/render"/>
     141                </span>
     142              </div>
     143            </td>
    142144        </tr>
    143145      </table>
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/departmentpage.pt

    r8481 r10995  
    1 <ul i18n:domain="waeup.kofa" class="tabs" data-tabs="tabs">
    2   <li class="active"><a href="#tab-1">
    3    <span i18n:translate="">Courses</span></a>
     1<ul i18n:domain="waeup.kofa" class="tabs nav nav-tabs" data-tabs="tabs">
     2  <li class="active"><a href="#tab1" data-toggle="tab">
     3    <span i18n:translate="">Courses</span></a>
    44  </li>
    5   <li><a href="#tab-2">
     5  <li><a href="#tab2" data-toggle="tab">
    66    <span i18n:translate="">Certificates</span></a>
    77  </li>
    88</ul>
    9 <div  i18n:domain="waeup.kofa" class="tab-content">
    10     <div id="tab-1" class="active">
     9<div i18n:domain="waeup.kofa" class="tab-content">
     10  <div id="tab1" class="active tab-pane">
    1111    <br />
    1212    <table class="display dataTable">
     
    2020        <tr tal:repeat="entry view/getCourses" class="gradeC">
    2121          <td>
    22                 <a href=""
    23                    tal:attributes="href entry/url"
    24                    tal:content="entry/name">Name</a>
     22            <a href=""
     23               tal:attributes="href entry/url"
     24               tal:content="entry/name">Name</a>
    2525          </td>
    2626          <td tal:content="entry/container/title">
    27                Title
     27            Title
    2828          </td>
    2929        </tr>
    3030      </tbody>
    3131    </table>
    32     </div>
    33     <div id="tab-2">
     32  </div>
     33  <div id="tab2" class="tab-pane">
    3434    <br />
    3535    <table class="display dataTable">
     
    4343        <tr tal:repeat="entry view/getCertificates" class="gradeC">
    4444          <td>
    45                 <a href=""
    46                    tal:attributes="href entry/url"
    47                    tal:content="entry/name">Name</a>
     45            <a href=""
     46               tal:attributes="href entry/url"
     47               tal:content="entry/name">Name</a>
    4848          </td>
    4949          <td tal:content="entry/container/title">
    50                Title
     50            Title
    5151          </td>
    5252        </tr>
    5353      </tbody>
    5454    </table>
    55     </div>
     55  </div>
    5656</div>
  • main/waeup.kofa/branches/uli-diazo-themed/src/waeup/kofa/browser/templates/facultymanagepage.pt

    r7811 r10995  
    11<form action="." tal:attributes="action request/URL"
    22  i18n:domain="waeup.kofa" method="POST" enctype="multipart/form-data">
    3   <ul class="tabs" data-tabs="tabs">
    4     <li tal:attributes="class view/tab1">
    5     <a href="#tab-1">
     3  <ul class="tabs nav nav-tabs" data-tabs="tabs">
     4    <li class="active">
     5    <a href="#tab1" data-toggle="tab">
    66      <span i18n:translate="">Settings
    77      </span></a>
    88    </li>
    9     <li tal:attributes="class view/tab2">
    10     <a href="#tab-2">
     9    <li>
     10    <a href="#tab2" data-toggle="tab">
    1111      <span tal:content="view/subunits">CONTENTS
    1212      </span> </a>
    1313    </li>
    14     <li tal:attributes="class view/tab3">
    15     <a href="#tab-3">
     14    <li>
     15    <a href="#tab3" data-toggle="tab">
    1616      <span i18n:translate="">Local Roles
    1717      </span></a>
     
    1919  </ul>
    2020  <div class="tab-content">
    21     <div id="tab-1" tal:attributes="class view/tab1">
     21    <div id="tab1" class="active tab-pane">
    2222      <table class="form-table">
    2323        <tbody>
     
    3232      </div>
    3333    </div>
    34     <div id="tab-2" tal:attributes="class view/tab2">
     34    <div id="tab2" class="tab-pane">
    3535      <h3 tal:content="view/subunits">DEPARTMENTS</h3>
    3636      <table>
     
    6363      </div>
    6464    </div>
    65     <div id="tab-3" tal:attributes="class view/tab3"> <br />
     65    <div id="tab3" class="tab-pane"> <br />
    6666      <table class="display dataTableManage">
    6767        <thead>
     
    7878        </thead>
    7979        <tbody>
    80           <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC"> <td>
     80          <tr tal:repeat="entry view/getUsersWithLocalRoles" class="gradeC">
     81            <td>
    8182              <input type="checkbox" name="role_id"
    8283              tal:attributes="value python: entry['user_name']+'|'+entry['local_role']" /> </td>
     
    9697        <tr> <td>
    9798            <select id="user" name="user">
    98               <option tal:repeat="user view/getUsers" tal:attributes="value user/name">
     99              <option tal:repeat="user view/getUsers"
     100                      tal:attributes="value user/name">
    99101              <span tal:replace="user/val/title">USERTITLE
    100102              </span>
     
    113115                       tal:replace="structure action/render"/>
    114116              </span>
    115             </div> </td>
     117            </div>
     118          </td>
    116119        </tr>
    117120      </table>
Note: See TracChangeset for help on using the changeset viewer.