fix
This commit is contained in:
@@ -22,3 +22,11 @@ export function logout() {
|
||||
method: 'post'
|
||||
})
|
||||
}
|
||||
|
||||
export function sendAnalyzeRequest() {
|
||||
return request({
|
||||
url: '/uploader/analyze',
|
||||
method: 'get',
|
||||
baseURL: 'http://www.google.com'
|
||||
})
|
||||
}
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<div>
|
||||
<input ref="excel-upload-input" class="excel-upload-input" type="file" accept=".xlsx, .xls" @change="handleClick">
|
||||
<div class="drop" @drop="handleDrop" @dragover="handleDragover" @dragenter="handleDragover">
|
||||
Drop excel file here or
|
||||
Drop file here or
|
||||
<el-button :loading="loading" style="margin-left:16px;" size="mini" type="primary" @click="handleUpload">
|
||||
Browse
|
||||
</el-button>
|
||||
@@ -113,6 +113,7 @@ export default {
|
||||
},
|
||||
isExcel(file) {
|
||||
return /\.(xlsx|xls|csv)$/.test(file.name)
|
||||
// return true
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -84,11 +84,12 @@ export default {
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.navbar {
|
||||
height: 50px;
|
||||
height: 62px;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
background: #fff;
|
||||
box-shadow: 0 1px 4px rgba(0,21,41,.08);
|
||||
padding: 0;
|
||||
|
||||
.hamburger-container {
|
||||
line-height: 46px;
|
||||
|
14
src/main.js
14
src/main.js
@@ -18,6 +18,8 @@ import './permission' // permission control
|
||||
import './utils/error-log' // error log
|
||||
|
||||
import * as filters from './filters' // global filters
|
||||
import 'bootstrap'
|
||||
import 'bootstrap/dist/css/bootstrap.min.css'
|
||||
|
||||
/**
|
||||
* If you don't want to use mock-server
|
||||
@@ -39,6 +41,18 @@ Vue.use(Element, {
|
||||
// register global utility filters
|
||||
Object.keys(filters).forEach(key => {
|
||||
Vue.filter(key, filters[key])
|
||||
Vue.filter('formatSize', function(size) {
|
||||
if (size > 1024 * 1024 * 1024 * 1024) {
|
||||
return (size / 1024 / 1024 / 1024 / 1024).toFixed(2) + ' TB'
|
||||
} else if (size > 1024 * 1024 * 1024) {
|
||||
return (size / 1024 / 1024 / 1024).toFixed(2) + ' GB'
|
||||
} else if (size > 1024 * 1024) {
|
||||
return (size / 1024 / 1024).toFixed(2) + ' MB'
|
||||
} else if (size > 1024) {
|
||||
return (size / 1024).toFixed(2) + ' KB'
|
||||
}
|
||||
return size.toString() + ' B'
|
||||
})
|
||||
})
|
||||
|
||||
Vue.config.productionTip = false
|
||||
|
@@ -83,6 +83,18 @@ export const constantRoutes = [
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/uploader',
|
||||
component: Layout,
|
||||
children: [
|
||||
{
|
||||
path: 'vueUploader',
|
||||
component: () => import('@/views/VueUploader/index'),
|
||||
name: 'VueUploader',
|
||||
meta: { title: 'VueUploader', icon: 'documentation', affix: true }
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
path: '/documentation',
|
||||
component: Layout,
|
||||
|
Reference in New Issue
Block a user