standard_table

NAML documentation   Watch a video
   Usages of this macro
The source code below doesn't have navigation links because no usage has been compiled yet. Navigation links depend on how and where the macro is used, so first you may try finding all usages of "standard_table".
... in standard_table.naml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<override_macro name="standard_table" dot_parameter="columns">
    <div style="clear:both"></div>
    <table class="main medium-border-color">
        <n.table_header.>
            <tr class="header-row shaded-bg-color">
                <n.columns/>
            </tr>
        </n.table_header.>
        <n.page_node.children_list.
            start="[n.app_index_record/]"
            length="[n.app_rows_per_page/]"
            filter="[n.app_topic_filter/]"
            sort="[n.if.app_is_by_priority][then]priority[/then][else]pinned-and-last-node-date[/else][/n.if.app_is_by_priority]"
        >
            <n.loop.>
                <n.comment.>
                    Here, the current node inside the loop is checked if it can be viewed by the visitor. 
                    If not, we check if there is a next node at the loop and jump to that. I there is no next node, the loop stops
                </n.comment.>                
                
                <n.if.not.current_node.can_be_viewed_by_visitor>
                    <then><n.if.next_node><else><n.break/></else></n.if.next_node></then>
                </n.if.not.current_node.can_be_viewed_by_visitor>                                
                        
                <tr class="[n.even_row_background/] main-row">
                    <n.columns/>
                </tr>
 
                <n.if.next_node>
                    <then>                        
                        <n.if.not.current_node.can_be_viewed_by_visitor>
                            <then><n.if.next_node><else><n.break/></else></n.if.next_node></then>
                        </n.if.not.current_node.can_be_viewed_by_visitor>        
                        
                        <tr class="[n.odd_row_background/] main-row">
                            <n.columns/>
                        </tr>
                    </then>
                </n.if.next_node>
 
            </n.loop.>
        </n.page_node.children_list.>
        <n.if.not.page_node.has_children>
            <then>
                <tr>
                    <td></td>
                    <td colspan="10" style="padding:.8em 0">
                        <t>Empty</t>
                    </td>
                </tr>
            </then>
        </n.if.not.page_node.has_children>
    </table>
    <div style="clear:both"></div>
</override_macro>
Overrides default macro
... in view_standard.naml
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
<macro name="standard_table" dot_parameter="columns">
    <div style="clear:both"></div>
    <table class="main medium-border-color">
        <n.table_header.>
            <tr class="header-row shaded-bg-color">
                <n.columns/>
            </tr>
        </n.table_header.>
        <n.page_node.children_list.
            start="[n.app_index_record/]"
            length="[n.app_rows_per_page/]"
            filter="[n.app_topic_filter/]"
            sort="[n.if.app_is_by_priority][then]priority[/then][else]pinned-and-last-node-date[/else][/n.if.app_is_by_priority]"
        >
            <n.loop.>
                <tr class="[n.even_row_background/] main-row">
                    <n.columns/>
                </tr>
                <n.if.next_node>
                    <then>
                        <tr class="[n.odd_row_background/] main-row">
                            <n.columns/>
                        </tr>
                    </then>
                </n.if.next_node>
            </n.loop.>
        </n.page_node.children_list.>
        <n.if.not.page_node.has_children>
            <then>
                <tr>
                    <td></td>
                    <td colspan="10" style="padding:.8em 0">
                        <t>Empty</t>
                    </td>
                </tr>
            </then>
        </n.if.not.page_node.has_children>
    </table>
    <div style="clear:both"></div>
</macro>