diff options
| -rw-r--r-- | bitbake/lib/toaster/toastergui/static/js/table.js | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/bitbake/lib/toaster/toastergui/static/js/table.js b/bitbake/lib/toaster/toastergui/static/js/table.js index f18034df52..bc81e67a6a 100644 --- a/bitbake/lib/toaster/toastergui/static/js/table.js +++ b/bitbake/lib/toaster/toastergui/static/js/table.js | |||
| @@ -33,14 +33,6 @@ function tableInit(ctx){ | |||
| 33 | 33 | ||
| 34 | loadData(tableParams); | 34 | loadData(tableParams); |
| 35 | 35 | ||
| 36 | window.onpopstate = function(event){ | ||
| 37 | if (event.state){ | ||
| 38 | tableParams = event.state.tableParams; | ||
| 39 | /* We skip loadData and just update the table */ | ||
| 40 | updateTable(event.state.tableData); | ||
| 41 | } | ||
| 42 | }; | ||
| 43 | |||
| 44 | function loadData(tableParams){ | 36 | function loadData(tableParams){ |
| 45 | $.ajax({ | 37 | $.ajax({ |
| 46 | type: "GET", | 38 | type: "GET", |
| @@ -49,10 +41,8 @@ function tableInit(ctx){ | |||
| 49 | headers: { 'X-CSRFToken' : $.cookie('csrftoken')}, | 41 | headers: { 'X-CSRFToken' : $.cookie('csrftoken')}, |
| 50 | success: function(tableData) { | 42 | success: function(tableData) { |
| 51 | updateTable(tableData); | 43 | updateTable(tableData); |
| 52 | window.history.pushState({ | 44 | window.history.replaceState(null, null, |
| 53 | tableData: tableData, | 45 | libtoaster.dumpsUrlParams(tableParams)); |
| 54 | tableParams: tableParams | ||
| 55 | }, null, libtoaster.dumpsUrlParams(tableParams)); | ||
| 56 | } | 46 | } |
| 57 | }); | 47 | }); |
| 58 | } | 48 | } |
