|
|
|
|
@ -108,6 +108,9 @@
|
|
|
|
|
import {
|
|
|
|
|
getToken
|
|
|
|
|
} from '@/utils/auth'
|
|
|
|
|
import {
|
|
|
|
|
deepCopy
|
|
|
|
|
} from '@/utils/index'
|
|
|
|
|
import imports from "./components/imports.vue"
|
|
|
|
|
export default {
|
|
|
|
|
components: {
|
|
|
|
|
@ -249,7 +252,23 @@
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
importTable(row) {
|
|
|
|
|
this.$refs.imports.headers = this.table_item
|
|
|
|
|
let arr = deepCopy(this.table_item)
|
|
|
|
|
let maps = ['Separation Mode', 'Bead Type', 'Particle Size (µm)', 'Pore Size (Å)', 'ID (mm)', 'Length (mm)']
|
|
|
|
|
arr.unshift({
|
|
|
|
|
prop: 'Product Phase',
|
|
|
|
|
label: 'Product Phase',
|
|
|
|
|
export:true
|
|
|
|
|
})
|
|
|
|
|
maps.map(item=>{
|
|
|
|
|
arr.push({
|
|
|
|
|
prop: item,
|
|
|
|
|
label: item,
|
|
|
|
|
export:true
|
|
|
|
|
})
|
|
|
|
|
})
|
|
|
|
|
console.log("arr",arr)
|
|
|
|
|
this.$refs.imports.headers = arr
|
|
|
|
|
|
|
|
|
|
this.$refs.imports.show()
|
|
|
|
|
},
|
|
|
|
|
editProduct(type, id) {
|
|
|
|
|
@ -325,7 +344,13 @@
|
|
|
|
|
_export[item.prop] = item.label
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
_export['product_details'] = 'Product Details'
|
|
|
|
|
// 'Separation Mode', 'Bead Type', 'Particle Size (µm)', 'Pore Size (Å)', 'ID (mm)', 'Length (mm)'
|
|
|
|
|
_export['Separation Mode'] = 'Separation Mode'
|
|
|
|
|
_export['Bead Type'] = 'Bead Type'
|
|
|
|
|
_export['Particle Size (µm)'] = 'Particle Size (µm)'
|
|
|
|
|
_export['Pore Size (Å)'] = 'Pore Size (Å)'
|
|
|
|
|
_export['ID (mm)'] = 'ID (mm)'
|
|
|
|
|
_export['Length (mm)'] = 'Length (mm)'
|
|
|
|
|
download(
|
|
|
|
|
'/api/admin/product/index',
|
|
|
|
|
'get', {
|
|
|
|
|
|