From 0f09cb50e9b91cf0b335d10654c1986491f9abaf Mon Sep 17 00:00:00 2001 From: Joffrey JAFFEUX Date: Fri, 28 Dec 2018 19:07:29 +0100 Subject: [PATCH] FIX: less fancy pages computation for browser compatibility (#6823) --- .../javascripts/admin/components/admin-report-table.js.es6 | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/admin/components/admin-report-table.js.es6 b/app/assets/javascripts/admin/components/admin-report-table.js.es6 index bf1ea4efaeb..7f75af90273 100644 --- a/app/assets/javascripts/admin/components/admin-report-table.js.es6 +++ b/app/assets/javascripts/admin/components/admin-report-table.js.es6 @@ -106,7 +106,12 @@ export default Ember.Component.extend({ pages(data, perPage, page) { if (!data || data.length <= perPage) return []; - let pages = [...Array(Math.ceil(data.length / perPage)).keys()].map(v => { + const pagesIndexes = []; + for (let i = 0; i < Math.ceil(data.length / perPage); i++) { + pagesIndexes.push(i); + } + + let pages = pagesIndexes.map(v => { return { page: v + 1, index: v,