index.html 1.52 KB
Newer Older
1 2
{{extend 'db_layout.html'}}

3 4 5 6 7 8
{{('message' in globals())}}
{{if 'message' in globals():}}

<div>
    <h3>{{=message}}</h3>
    
Marc Duez's avatar
Marc Duez committed
9 10 11 12
    <div id="db_table_container">
        <table class="db_table" id="table">
            <thead>
                <tr><td class="column2"> name </td>
Marc Duez's avatar
Marc Duez committed
13 14
                    <td class="column1"> program </td>
                    <td class="column2"> command </td>
Marc Duez's avatar
Marc Duez committed
15
                    <td> info </td>
16 17
                    
                    <td class="column5"> </td>
Marc Duez's avatar
Marc Duez committed
18 19 20 21 22 23 24 25
                    <td class="column5"> </td>
                    <td class="column5"> </td>
                </tr>
            </thead>
           {{ 
           c_id = ""
           for row in query :}}
                <tr>
Marc Duez's avatar
Marc Duez committed
26
                    <td> {{=row.name }} </td>
Marc Duez's avatar
Marc Duez committed
27
                    <td> {{=row.program }} </td>
Marc Duez's avatar
Marc Duez committed
28
                    <td> {{=row.command }} </td>
Marc Duez's avatar
Marc Duez committed
29
                    <td> {{=row.info }} </td>
30 31
                    
   {{if isAdmin:}} <td onclick="db.call('config/permission', {'id' :'{{=row.id}}'} )" > p </td> {{else:}} <td></td> {{pass}}
Marc Duez's avatar
Marc Duez committed
32 33
                    <td onclick="db.call('config/edit', {'id' :'{{=row.id}}'} )" > e </td>
                    <td onclick="db.call('config/confirm', {'id' :'{{=row.id}}'} )" > X </td>
Marc Duez's avatar
Marc Duez committed
34 35 36 37 38 39
                </tr>
            {{pass}}
        </table>
        <table class="db_table" id="db_fixed_header"></table>
    </div>
    
Marc Duez's avatar
Marc Duez committed
40
    <span class="button2" onclick="db.call('config/add')"> + new config </span>
41 42 43 44 45 46 47
</div>

{{elif 'content' in globals():}}
{{=content}}
{{else:}}
{{=BEAUTIFY(response._vars)}}
{{pass}}