corrade-nucleus-nucleons – Blame information for rev 20
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
20 | office | 1 | # Localizations []({{ site.repo }}/blob/develop/docs/_i18n/{{ site.lang }}/documentation/localizations.md) |
2 | |||
3 | --- |
||
4 | |||
5 | <table class="table" |
||
6 | id="l" |
||
7 | data-search="true" |
||
8 | data-show-toggle="true" |
||
9 | data-show-columns="true" |
||
10 | data-mobile-responsive="true"> |
||
11 | <thead> |
||
12 | <tr> |
||
13 | <th>Name</th> |
||
14 | <th>Parameter</th> |
||
15 | <th>Default</th> |
||
16 | </tr> |
||
17 | </thead> |
||
18 | <tbody> |
||
19 | <tr> |
||
20 | <td>formatLoadingMessage</td> |
||
21 | <td>-</td> |
||
22 | <td>'Loading, please wait…'</td> |
||
23 | </tr> |
||
24 | <tr> |
||
25 | <td>formatRecordsPerPage</td> |
||
26 | <td>pageNumber</td> |
||
27 | <td>'%s records per page'</td> |
||
28 | </tr> |
||
29 | <tr> |
||
30 | <td>formatShowingRows</td> |
||
31 | <td>pageFrom, pageTo, totalRows</td> |
||
32 | <td>'Showing %s to %s of %s rows'</td> |
||
33 | </tr> |
||
34 | <tr> |
||
35 | <td>formatDetailPagination</td> |
||
36 | <td>totalRows</td> |
||
37 | <td>'Showing %s rows'</td> |
||
38 | </tr> |
||
39 | <tr> |
||
40 | <td>formatSearch</td> |
||
41 | <td>-</td> |
||
42 | <td>'Search'</td> |
||
43 | </tr> |
||
44 | <tr> |
||
45 | <td>formatNoMatches</td> |
||
46 | <td>-</td> |
||
47 | <td>'No matching records found'</td> |
||
48 | </tr> |
||
49 | <tr> |
||
50 | <td>formatRefresh</td> |
||
51 | <td>-</td> |
||
52 | <td>'Refresh'</td> |
||
53 | </tr> |
||
54 | <tr> |
||
55 | <td>formatToggle</td> |
||
56 | <td>-</td> |
||
57 | <td>'Toggle'</td> |
||
58 | </tr> |
||
59 | <tr> |
||
60 | <td>formatColumns</td> |
||
61 | <td>-</td> |
||
62 | <td>'Columns'</td> |
||
63 | </tr> |
||
64 | <tr> |
||
65 | <td>formatAllRows</td> |
||
66 | <td>-</td> |
||
67 | <td>'All'</td> |
||
68 | </tr> |
||
69 | </tbody> |
||
70 | </table> |
||
71 | |||
72 | --- |
||
73 | |||
74 | **PS:** |
||
75 | |||
76 | We can import [all locale files](https://github.com/wenzhixin/bootstrap-table/tree/master/src/locale) what you need: |
||
77 | |||
78 | ```html |
||
79 | <script src="bootstrap-table-en-US.js"></script> |
||
80 | <script src="bootstrap-table-zh-CN.js"></script> |
||
81 | ... |
||
82 | ``` |
||
83 | |||
84 | And then use JavaScript to switch locale: |
||
85 | |||
86 | ```js |
||
87 | $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['en-US']); |
||
88 | // $.extend($.fn.bootstrapTable.defaults, $.fn.bootstrapTable.locales['zh-CN']); |
||
89 | // ... |
||
90 | ``` |
||
91 | |||
92 | Or use data attributes to set locale for table: |
||
93 | |||
94 | ```html |
||
95 | <table data-toggle="table" data-locale="en-US"> |
||
96 | </table> |
||
97 | ``` |
||
98 | |||
99 | Or use JavaScript to set locale for table: |
||
100 | |||
101 | ```js |
||
102 | $('table').bootstrapTable({locale:'en-US'}); |
||
103 | ``` |