Skip to content

Commit 46e069b

Browse files
author
Kevin Ngai
committed
Set station pagination limit to 10000
- set version to "dev"
1 parent 114b32e commit 46e069b

3 files changed

Lines changed: 18 additions & 18 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "climate-data-extraction-tool",
3-
"version": "1.18.5",
3+
"version": "1.19.0-dev",
44
"private": true,
55
"description": "Climate data extraction tool for CCCS",
66
"author": "Kevin Ngai <kevin.ngai@canada.ca>",

src/components/mixins/oapi-features.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export const oapif = {
2121
oapif_selected_station_ids: [],
2222
oapif_station_limit: 10000,
2323
// oapif_limit: 150000,
24-
oapif_limit: 500,
24+
oapif_limit: 10000,
2525
oapif_max_limit: 1000000,
2626
oapif_min_limit: 1,
2727
date_start: null,

src/store/modules/stations.js

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ Vuex module for the climate stations and related selections
44

55
import axios from 'axios'
66

7-
// temporary hard limit
8-
const OAPIFEATURES_LIMIT = 500
7+
// Limit for pagination
8+
const OAPI_FEATURES_LIMIT = 10000
99

1010
// initial state
1111
const state = {
@@ -314,8 +314,8 @@ const actions = {
314314

315315
// Paginate requests based on totalStations
316316
const requests = []
317-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
318-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
317+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
318+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
319319
cancelToken: state.cancelSourceStation.token
320320
})
321321
requests.push(request)
@@ -366,8 +366,8 @@ const actions = {
366366

367367
// Paginate requests based on totalStations
368368
const requests = []
369-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
370-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
369+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
370+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
371371
cancelToken: state.cancelSourceStation.token
372372
})
373373
requests.push(request)
@@ -406,8 +406,8 @@ const actions = {
406406

407407
// Paginate requests based on totalStations
408408
const requests = []
409-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
410-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
409+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
410+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
411411
cancelToken: state.cancelSourceStation.token
412412
})
413413
requests.push(request)
@@ -446,8 +446,8 @@ const actions = {
446446

447447
// Paginate requests based on totalStations
448448
const requests = []
449-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
450-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
449+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
450+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
451451
cancelToken: state.cancelSourceStation.token
452452
})
453453
requests.push(request)
@@ -486,8 +486,8 @@ const actions = {
486486

487487
// Paginate requests based on totalStations
488488
const requests = []
489-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
490-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
489+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
490+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
491491
cancelToken: state.cancelSourceStation.token
492492
})
493493
requests.push(request)
@@ -526,8 +526,8 @@ const actions = {
526526

527527
// Paginate requests based on totalStations
528528
const requests = []
529-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
530-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
529+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
530+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
531531
cancelToken: state.cancelSourceStation.token
532532
})
533533
requests.push(request)
@@ -566,8 +566,8 @@ const actions = {
566566

567567
// Paginate requests based on totalStations
568568
const requests = []
569-
for (let offset = 0; offset < totalStations; offset += OAPIFEATURES_LIMIT) {
570-
const request = axios.get(`${url}&offset=${offset}&limit=${OAPIFEATURES_LIMIT}`, {
569+
for (let offset = 0; offset < totalStations; offset += OAPI_FEATURES_LIMIT) {
570+
const request = axios.get(`${url}&offset=${offset}&limit=${OAPI_FEATURES_LIMIT}`, {
571571
cancelToken: state.cancelSourceStation.token
572572
})
573573
requests.push(request)

0 commit comments

Comments
 (0)