docs.js 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653
  1. $(function () {
  2. 'use strict';
  3. function initTables() {
  4. var cardView = false;
  5. if ($(window).width() < 640) {
  6. cardView = true;
  7. }
  8. $('#table, #column, #event, #method, #localization').bootstrapTable('destroy');
  9. $('#table').bootstrapTable({
  10. cardView: cardView,
  11. columns: [
  12. {field: 'name', title: 'Name', sortable: true},
  13. {field: 'name', title: '名称', sortable: true, visible: false},
  14. {field: 'attribute', title: 'Attribute'},
  15. {field: 'attribute', title: '属性', visible: false},
  16. {field: 'type', title: 'Type'},
  17. {field: 'type', title: '类型', visible: false},
  18. {field: 'description', title: 'Description', align: 'left'},
  19. {field: 'description_zh', title: '描述', align: 'left', visible: false},
  20. {field: 'default', title: 'Default', align: 'left'},
  21. {field: 'default', title: '默认', align: 'left', visible: false},
  22. {field: 'example', title: '', valign: 'middle', formatter: function (value) {
  23. if (!value) {
  24. return '-';
  25. }
  26. return [
  27. '<a title="Example" href="examples.html#' + value + '">',
  28. '<i class="glyphicon glyphicon-eye-open"></i>',
  29. '</a>'].join('');
  30. }}
  31. ],
  32. data: [
  33. {
  34. name: '-',
  35. attribute: 'data-toggle',
  36. type: 'String',
  37. description: 'Activate bootstrap table without writing JavaScript.',
  38. description_zh: '不通过JavaScript的方式启动Bootstrap Table。',
  39. 'default': 'table',
  40. example: 'basic-table'
  41. },
  42. {
  43. name: 'classes',
  44. attribute: 'data-classes',
  45. type: 'String',
  46. description: 'The class name of table.',
  47. description_zh: '表格的类名。',
  48. 'default': 'table table-hover',
  49. example: 'classes-table'
  50. },
  51. {
  52. name: 'height',
  53. attribute: 'data-height',
  54. type: 'Number',
  55. description: 'The height of table.',
  56. description_zh: '表格的高度。',
  57. 'default': 'undefined',
  58. example: 'basic-table'
  59. },
  60. {
  61. name: 'undefinedText',
  62. attribute: 'data-undefined-text',
  63. type: 'String',
  64. description: 'Defines the default undefined text.',
  65. description_zh: '定义默认的undefined显示文字。',
  66. 'default': '-',
  67. example: ''
  68. },
  69. {
  70. name: 'striped',
  71. attribute: 'data-striped',
  72. type: 'Boolean',
  73. description: 'True to stripe the rows.',
  74. description_zh: '使表格带有条纹。',
  75. 'default': 'false',
  76. example: 'classes-table'
  77. },
  78. {
  79. name: 'sortName',
  80. attribute: 'data-sort-name',
  81. type: 'String',
  82. description: 'Defines which column can be sorted.',
  83. description_zh: '定义哪一列可被排序。',
  84. 'default': 'undefined',
  85. example: 'sort-table'
  86. },
  87. {
  88. name: 'sortOrder',
  89. attribute: 'data-sort-order',
  90. type: 'String',
  91. description: 'Defines the column sort order, can only be "asc" or "desc".',
  92. description_zh: '定义列排序的顺序,只能为“asc”和“desc”',
  93. 'default': 'asc',
  94. example: 'sort-table'
  95. },
  96. {
  97. name: 'columns',
  98. attribute: '-',
  99. type: 'Array',
  100. description: 'The table columns config object, see column properties for more details.',
  101. description_zh: '表格列的配置,详细见列属性。',
  102. 'default': '[]',
  103. example: 'via-javascript-table'
  104. },
  105. {
  106. name: 'data',
  107. attribute: '-',
  108. type: 'Array',
  109. description: 'The data to be loaded.',
  110. description_zh: '需要加载的数据。',
  111. 'default': '[]',
  112. example: 'table-methods'
  113. },
  114. {
  115. name: 'method',
  116. attribute: 'data-method',
  117. type: 'String',
  118. description: 'The method type to request remote data.',
  119. description_zh: '远程数据请求的方法。',
  120. 'default': 'get',
  121. example: 'basic-table'
  122. },
  123. {
  124. name: 'url',
  125. attribute: 'data-url',
  126. type: 'String',
  127. description: 'A URL to request data from remote site.',
  128. description_zh: '远程数据请求的URL地址。',
  129. 'default': 'undefined',
  130. example: 'basic-table'
  131. },
  132. {
  133. name: 'contentType',
  134. attribute: 'data-content-type',
  135. type: 'String',
  136. description: 'The contentType of request remote data.',
  137. description_zh: '远程数据请求的“contentType”类型。',
  138. 'default': 'application/json',
  139. example: ''
  140. },
  141. {
  142. name: 'queryParams',
  143. attribute: 'data-query-params',
  144. type: 'Function',
  145. description: 'When request remote data, sending additional parameters by format the queryParams, the parameters object contains: <br>pageSize, pageNumber, searchText, sortName, sortOrder.',
  146. description_zh: '远程数据请求时,可以通过queryParams来格式化所需要的数据信息,参数(对象)包含了:<br>pageSize, pageNumber, searchText, sortName, sortOrder。',
  147. 'default': 'function(params) {<br>return {};<br>}',
  148. example: 'server-side-pagination-table'
  149. },
  150. {
  151. name: 'queryParamsType',
  152. attribute: 'data-query-params-type',
  153. type: 'String',
  154. description: 'Set "limit" to send query params width RESTFul type.',
  155. description_zh: '设置为“limit”可以发送标准的RESTFul类型的参数请求。',
  156. 'default': 'undefined',
  157. example: '-'
  158. },
  159. {
  160. name: 'responseHandler',
  161. attribute: 'data-response-handler',
  162. type: 'Function',
  163. description: 'Before load remote data, handler the response data format, the parameters object contains: <br>res: the response data.',
  164. description_zh: '在加载数据前,可以对返回的数据进行处理,参数包含:<br>res: 返回的数据。',
  165. 'default': 'function(res) {<br>return res;<br>}',
  166. example: 'card-view'
  167. },
  168. {
  169. name: 'pagination',
  170. attribute: 'data-pagination',
  171. type: 'Boolean',
  172. description: 'True to show a pagination toolbar on table bottom.',
  173. description_zh: '设置True在表格底部显示分页工具栏。',
  174. 'default': 'false',
  175. example: 'pagination-table'
  176. },
  177. {
  178. name: 'sidePagination',
  179. attribute: 'data-side-pagination',
  180. type: 'String',
  181. description: 'Defines the side pagination of table, can only be "client" or "server".',
  182. description_zh: '定义表格分页的位置,只能是“client”(客户端)和“server”(服务器端)。',
  183. 'default': 'client',
  184. example: 'pagination-table'
  185. },
  186. {
  187. name: 'totalRows',
  188. attribute: 'data-total-rows',
  189. type: 'Number',
  190. description: 'Defines the total rows of table, you need to set this option when the sidePagination option is set to "server".',
  191. description_zh: '定义表格记录的总条数,在server端分页的时候需要设置该参数。',
  192. 'default': 0,
  193. example: ''
  194. },
  195. {
  196. name: 'pageNumber',
  197. attribute: 'data-page-number',
  198. type: 'Number',
  199. description: 'When set pagination property, initialize the page number.',
  200. description_zh: '分页的时候设置当前的页码。',
  201. 'default': 1,
  202. example: 'via-javascript-table'
  203. },
  204. {
  205. name: 'pageSize',
  206. attribute: 'data-page-size',
  207. type: 'Number',
  208. description: 'When set pagination property, initialize the page size.',
  209. description_zh: '分页的时候设置每页的条数。',
  210. 'default': 10,
  211. example: 'via-javascript-table'
  212. },
  213. {
  214. name: 'pageList',
  215. attribute: 'data-page-list',
  216. type: 'Array',
  217. description: 'When set pagination property, initialize the page size selecting list.',
  218. description_zh: '分页的时候设置分页数的列表。',
  219. 'default': '[10, 25, 50, 100]',
  220. example: 'via-javascript-table'
  221. },
  222. {
  223. name: 'search',
  224. attribute: 'data-search',
  225. type: 'Boolean',
  226. description: 'Enable the search input.',
  227. description_zh: '启用搜索输入框。',
  228. 'default': 'false',
  229. example: 'pagination-table'
  230. },
  231. {
  232. name: 'selectItemName',
  233. attribute: 'data-select-item-name',
  234. type: 'String',
  235. description: 'The name of radio or checkbox input.',
  236. description_zh: '单选框或者复选框的name,用于多个表格使用radio的情况。',
  237. 'default': 'btSelectItem',
  238. example: 'radio-table'
  239. },
  240. {
  241. name: 'showHeader',
  242. attribute: 'data-show-header',
  243. type: 'Boolean',
  244. description: 'False to hide the table header.',
  245. description_zh: '设置为False可隐藏表头。',
  246. 'default': 'true',
  247. example: 'hide-header-table'
  248. },
  249. {
  250. name: 'showColumns',
  251. attribute: 'data-show-columns',
  252. type: 'Boolean',
  253. description: 'True to show the columns drop down list.',
  254. description_zh: '设置为True可显示表格显示/隐藏列表。',
  255. 'default': 'false',
  256. example: 'show-columns-table'
  257. },
  258. {
  259. name: 'showRefresh',
  260. attribute: 'data-show-refresh',
  261. type: 'Boolean',
  262. description: 'True to show the refresh button.',
  263. description_zh: '设置为True可显示刷新按钮。',
  264. 'default': 'false',
  265. example: 'basic-toolbar-table'
  266. },
  267. {
  268. name: 'showToggle',
  269. attribute: 'data-show-toggle',
  270. type: 'Boolean',
  271. description: 'True to show the toggle button to toggle table / card view.',
  272. description_zh: '设置为True可显示切换普通表格和名片(card)布局。',
  273. 'default': 'false',
  274. example: 'basic-toolbar-table'
  275. },
  276. {
  277. name: 'minimunCountColumns',
  278. attribute: 'data-minimun-count-columns',
  279. type: 'Number',
  280. description: 'The minimun count columns to hide of the columns drop down list.',
  281. description_zh: '表格显示/隐藏列表时可设置最小隐藏的列数。',
  282. 'default': '1',
  283. example: 'via-javascript-table'
  284. },
  285. {
  286. name: 'idField',
  287. attribute: 'data-id-field',
  288. type: 'String',
  289. description: 'Indicate which field is an identity field.',
  290. description_zh: '标识哪个字段为id主键。',
  291. 'default': 'undefined',
  292. example: ''
  293. },
  294. {
  295. name: 'cardView',
  296. attribute: 'data-card-view',
  297. type: 'Boolean',
  298. description: 'True to show card view table, for example mobile view.',
  299. description_zh: '设置为True时显示名片(card)布局,例如用手机浏览的时候。',
  300. 'default': 'false',
  301. example: 'card-view'
  302. },
  303. {
  304. name: 'clickToSelect',
  305. attribute: 'data-click-to-select',
  306. type: 'Boolean',
  307. description: 'True to select checkbox or radiobox when click rows.',
  308. description_zh: '设置为True时点击行即可选中单选/复选框。',
  309. 'default': 'false',
  310. example: 'table-select'
  311. },
  312. {
  313. name: 'singleSelect',
  314. attribute: 'data-single-select',
  315. type: 'Boolean',
  316. description: 'True to allow checkbox selecting only one row.',
  317. description_zh: '设置为True时复选框只能选择一条记录。',
  318. 'default': 'false',
  319. example: 'single-checkbox-table'
  320. },
  321. {
  322. name: 'toolbar',
  323. attribute: 'data-toolbar',
  324. type: 'String',
  325. description: 'A jQuery selector that indicate the toolbar, for example: <br>#toolbar, .toolbar.',
  326. description_zh: '设置jQuery元素为工具栏,例如:<br>#toolbar, .toolbar。',
  327. 'default': 'undefined',
  328. example: 'custom-toolbar-table'
  329. },
  330. {
  331. name: 'checkboxHeader',
  332. attribute: 'data-checkbox-header',
  333. type: 'Boolean',
  334. description: 'False to hide check-all checkbox in header row.',
  335. description_zh: '设置为False时隐藏表头中的全选复选框。',
  336. 'default': 'true',
  337. example: '-'
  338. },
  339. {
  340. name: 'rowStyle',
  341. attribute: 'data-row-style',
  342. type: 'Function',
  343. description: 'The row style formatter function, take two parameters: <br>row: the row record data.<br>index: the row index.<br>Support classes or css.',
  344. description_zh: '行样式格式化方法,有两个参数:<br>row: 行记录的数据。<br>index: 行数据的 index。<br>支持 classes 或者 css.',
  345. 'default': '{}',
  346. example: 'classes-table'
  347. }
  348. ]
  349. });
  350. $('#column').bootstrapTable({
  351. cardView: cardView,
  352. columns: [
  353. {field: 'name', title: 'Name', width: 60, sortable: true},
  354. {field: 'attribute', title: 'Attribute'},
  355. {field: 'type', title: 'Type', width: 60},
  356. {field: 'description', title: 'Description', align: 'left', width: 400},
  357. {field: 'default', title: 'Default', align: 'left', width: 180},
  358. {field: 'example', title: '', formatter: function (value) {
  359. if (!value) {
  360. return '-';
  361. }
  362. return [
  363. '<a title="Example" href="examples.html#' + value + '">',
  364. '<i class="glyphicon glyphicon-eye-open"></i>',
  365. '</a>'].join('');
  366. }}
  367. ],
  368. data: [
  369. {
  370. name: 'radio',
  371. attribute: 'data-radio',
  372. type: 'Boolean',
  373. description: 'True to show a radio. The radio column has fixed width.',
  374. 'default': 'false',
  375. example: 'radio-table'
  376. },
  377. {
  378. name: 'checkbox',
  379. attribute: 'data-checkbox',
  380. type: 'Boolean',
  381. description: 'True to show a checkbox. The checkbox column has fixed width.',
  382. 'default': 'false',
  383. example: 'checkbox-table'
  384. },
  385. {
  386. name: 'field',
  387. attribute: 'data-field',
  388. type: 'String',
  389. description: 'The column field name.',
  390. 'default': 'undefined',
  391. example: 'via-javascript-table'
  392. },
  393. {
  394. name: 'title',
  395. attribute: 'data-title',
  396. type: 'String',
  397. description: 'The column title text.',
  398. 'default': 'undefined',
  399. example: 'via-javascript-table'
  400. },
  401. {
  402. name: 'class',
  403. attribute: 'class / data-class',
  404. type: 'String',
  405. description: 'The column class name.',
  406. 'default': 'undefined',
  407. example: 'classes-table'
  408. },
  409. {
  410. name: 'align',
  411. attribute: 'data-align',
  412. type: 'String',
  413. description: 'Indicate how to align the column data. "left", "right", "center" can be used.',
  414. 'default': 'undefined',
  415. example: 'via-javascript-table'
  416. },
  417. {
  418. name: 'valign',
  419. attribute: 'data-valign',
  420. type: 'String',
  421. description: 'Indicate how to align the cell data. "top", "middle", "bottom" can be used.',
  422. 'default': 'undefined',
  423. example: 'via-javascript-table'
  424. },
  425. {
  426. name: 'width',
  427. attribute: 'data-width',
  428. type: 'Number',
  429. description: 'The width of column. If not defined, the width will auto expand to fit its contents.',
  430. 'default': 'undefined',
  431. example: ''
  432. },
  433. {
  434. name: 'sortable',
  435. attribute: 'data-sortable',
  436. type: 'Boolean',
  437. description: 'True to allow the column can be sorted.',
  438. 'default': 'false',
  439. example: 'sort-table'
  440. },
  441. {
  442. name: 'order',
  443. attribute: 'data-order',
  444. type: 'String',
  445. description: 'The default sort order, can only be "asc" or "desc".',
  446. 'default': 'asc',
  447. example: 'sort-table'
  448. },
  449. {
  450. name: 'visible',
  451. attribute: 'data-visible',
  452. type: 'Boolean',
  453. description: 'True to visible the columns item.',
  454. 'default': 'true',
  455. example: 'show-columns-table'
  456. },
  457. {
  458. name: 'switchable',
  459. attribute: 'data-switchable',
  460. type: 'Boolean',
  461. description: 'False to disable the switchable of columns item.',
  462. 'default': 'true',
  463. example: 'show-columns-table'
  464. },
  465. {
  466. name: 'formatter',
  467. attribute: 'data-formatter',
  468. type: 'Function',
  469. description: 'The cell formatter function, take three parameters: <br />value: the field value. <br />row: the row record data.<br />index: the row index.',
  470. 'default': 'undefined',
  471. example: 'format-table'
  472. },
  473. {
  474. name: 'events',
  475. attribute: 'data-events',
  476. type: 'Object',
  477. description: 'The cell events listener when you use formatter function, take three parameters: <br />event: the jQuery event. <br />value: the field value. <br />row: the row record data.<br />index: the row index.',
  478. 'default': 'undefined',
  479. example: 'column-events-table'
  480. },
  481. {
  482. name: 'sorter',
  483. attribute: 'data-sorter',
  484. type: 'Function',
  485. description: 'The custom field sort function that used to do local sorting, take two parameters: <br />a: the first field value.<br /> b: the second field value.',
  486. 'default': 'undefined',
  487. example: 'custom-sort-table'
  488. }
  489. ]
  490. });
  491. $('#event').bootstrapTable({
  492. cardView: cardView,
  493. columns: [
  494. {field: 'name', title: 'Option Event', width: 100, sortable: true},
  495. {field: 'event', title: 'jQuery Event', width: 100, sortable: true},
  496. {field: 'parameter', title: 'Parameter', width: 100, sortable: true},
  497. {field: 'description', title: 'Description', align: 'left', width: 400, sortable: true}
  498. ],
  499. data: [
  500. {
  501. name: 'onAll',
  502. event: 'all.bs.table',
  503. parameter: 'name, args',
  504. description: 'Fires when all events trigger, the parameters contains: <br />name: the event name, <br>args: the event data.'
  505. },
  506. {
  507. name: 'onClickRow',
  508. event: 'click-row.bs.table',
  509. parameter: 'row, $element',
  510. description: 'Fires when user click a row, the parameters contains: <br />row: the record corresponding to the clicked row, <br>$element: the tr element.'
  511. },
  512. {
  513. name: 'onDblClickRow',
  514. event: 'dbl-click-row.bs.table',
  515. parameter: 'row, $element',
  516. description: 'Fires when user click a row, the parameters contains: <br />row: the record corresponding to the clicked row, <br>$element: the tr element.'
  517. },
  518. {
  519. name: 'onSort',
  520. event: 'sort.bs.table',
  521. parameter: 'name, order',
  522. description: 'Fires when user sort a column, the parameters contains: <br />name: the sort column field name<br />order: the sort column order.'
  523. },
  524. {
  525. name: 'onCheck',
  526. event: 'check.bs.table',
  527. parameter: 'row',
  528. description: 'Fires when user check a row, the parameters contains: <br />row: the record corresponding to the clicked row.'
  529. },
  530. {
  531. name: 'onUncheck',
  532. event: 'uncheck.bs.table',
  533. parameter: 'row',
  534. description: 'Fires when user uncheck a row, the parameters contains: <br />row: the record corresponding to the clicked row.'
  535. },
  536. {
  537. name: 'onCheckAll',
  538. event: 'check-all.bs.table',
  539. parameter: 'none',
  540. description: 'Fires when user check all rows.'
  541. },
  542. {
  543. name: 'onUncheckAll',
  544. event: 'uncheck-all.bs.table',
  545. parameter: 'none',
  546. description: 'Fires when user uncheck all rows.'
  547. },
  548. {
  549. name: 'onLoadSuccess',
  550. event: 'load-success.bs.table',
  551. parameter: 'data',
  552. description: 'Fires when remote data is loaded successfully.'
  553. },
  554. {
  555. name: 'onLoadError',
  556. event: 'load-error.bs.table',
  557. parameter: 'status',
  558. description: 'Fires when some errors occur to load remote data.'
  559. }
  560. ],
  561. onClickRow: function (row) {
  562. console.log('onClickRow', row);
  563. },
  564. onSort: function (name, order) {
  565. console.log('onSort', name, order);
  566. },
  567. onCheck: function(row) {
  568. console.log('onCheck', row);
  569. },
  570. onUncheck: function(row) {
  571. console.log('onUncheck', row);
  572. },
  573. onCheckAll: function() {
  574. console.log('onCheckAll');
  575. },
  576. onUncheckAll: function() {
  577. console.log('onUncheckAll');
  578. }
  579. });
  580. $('#method').bootstrapTable({
  581. cardView: cardView,
  582. columns: [
  583. {field: 'name', title: 'Name', width: 100},
  584. {field: 'parameter', title: 'Parameter', width: 100},
  585. {field: 'description', title: 'Description', align: 'left', width: 400}
  586. ]
  587. }).bootstrapTable('load', [
  588. {name: 'getSelections', parameter: 'none', description: 'Return all selected rows, when no record selected, am empty array will return.'},
  589. {name: 'load', parameter: 'data', description: 'Load the data to table.'}
  590. ]).bootstrapTable('append', [
  591. {name: 'append', parameter: 'data', description: 'Append the data to table.'},
  592. {name: 'mergeCells', parameter: 'options', description: 'Merge some cells to one cell, the options contains following properties:'},
  593. {name: 'mergeCells', parameter: 'options', description: 'index: the row index.'},
  594. {name: 'mergeCells', parameter: 'options', description: 'field: the field name.'},
  595. {name: 'mergeCells', parameter: 'options', description: 'rowspan: the rowspan count to be merged.'},
  596. {name: 'mergeCells', parameter: 'options', description: 'colspan: the colspan count to be merged.'},
  597. {name: 'refresh', parameter: 'none', description: 'Refresh the remote server data.'},
  598. {name: 'showLoading', parameter: 'none', description: 'Show loading status.'},
  599. {name: 'hideLoading', parameter: 'none', description: 'Hide loading status.'},
  600. {name: 'checkAll', parameter: 'none', description: 'Check all current page rows.'},
  601. {name: 'uncheckAll', parameter: 'none', description: 'Uncheck all current page rows.'},
  602. {name: 'resetView', parameter: 'params', description: 'Reset the bootstrap table view, for example reset the table height.'},
  603. {name: 'destroy', parameter: 'none', description: 'Destroy the bootstrap table.'}
  604. ]).bootstrapTable('mergeCells', {
  605. index: 3,
  606. field: 'name',
  607. rowspan: 5
  608. }).bootstrapTable('mergeCells', {
  609. index: 3,
  610. field: 'parameter',
  611. rowspan: 5
  612. });
  613. $('#localization').bootstrapTable({
  614. cardView: cardView,
  615. columns: [
  616. {field: 'name', title: 'Name', width: 100},
  617. {field: 'parameter', title: 'Parameter', width: 100},
  618. {field: 'default', title: 'Default', width: 200}
  619. ],
  620. data: [{
  621. name: 'formatLoadingMessage',
  622. parameter: '-',
  623. 'default': 'Loading, please wait…'
  624. }, {
  625. name: 'formatRecordsPerPage',
  626. parameter: 'pageNumber',
  627. 'default': '%s records per page'
  628. }, {
  629. name: 'formatShowingRows',
  630. parameter: 'pageFrom, pageTo, totalRows',
  631. 'default': 'Showing %s to %s of %s rows'
  632. }, {
  633. name: 'formatSearch',
  634. parameter: '-',
  635. 'default': 'Search'
  636. }, {
  637. name: 'formatNoMatches',
  638. parameter: '-',
  639. 'default': 'No matching records found'
  640. }]
  641. });
  642. $('[title]').tooltip();
  643. }
  644. $(window).on('resize', initTables);
  645. initTables();
  646. });