File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
admin/src/views/api_excel Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,8 @@ export default {
157
157
},
158
158
created () {
159
159
this .listQuery = this .$route .query
160
- this .currentpage = parseInt (this .listQuery .page )
160
+ const page = parseInt (this .listQuery .page )
161
+ this .currentpage = isNaN (page) ? 1 : page
161
162
const perPage = parseInt (this .$route .query .perPage )
162
163
this .perpage = isNaN (perPage) ? this .perpage : perPage
163
164
// this.fetchData()
@@ -222,7 +223,7 @@ export default {
222
223
},
223
224
initWebSocket () { // 初始化 weosocket
224
225
if (' WebSocket' in window ) {
225
- const url = process .env .WEBSOCKET + ' ?action=api_excel&token=' + getToken ()
226
+ const url = process .env .WEBSOCKET + ' ?action=api_excel&token=' + getToken () + ' &page= ' + this . currentpage + ' &perPage= ' + this . perpage
226
227
this .websock = new WebSocket (url)
227
228
this .websock .onmessage = this .onmessage
228
229
this .websock .onopen = this .onopen
You can’t perform that action at this time.
0 commit comments