mirror of
https://github.com/nocodb/nocodb.git
synced 2026-04-29 14:46:39 +00:00
@@ -0,0 +1,20 @@
|
||||
import ExcelTemplateAdapter from '~/components/import/templateParsers/ExcelTemplateAdapter'
|
||||
|
||||
export default class ExcelUrlTemplateAdapter extends ExcelTemplateAdapter {
|
||||
constructor(url, $store) {
|
||||
const name = url.split('/').pop()
|
||||
super(name, null)
|
||||
this.url = url
|
||||
this.$store = $store
|
||||
}
|
||||
|
||||
async init() {
|
||||
const res = await this.$store.dispatch('sqlMgr/ActSqlOp', [null, 'handleAxiosCall',
|
||||
[{
|
||||
url: this.url,
|
||||
responseType: 'arraybuffer'
|
||||
}]])
|
||||
this.excelData = res.data
|
||||
await super.init()
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user