refactor: standardized files name (#1884)

style-guide: https://panjiachen.github.io/vue-element-admin-site/guide/advanced/style-guide.html#style-guide
This commit is contained in:
花裤衩 2019-04-12 17:13:27 +08:00 committed by GitHub
parent a6be6af46d
commit fdea6c684a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
66 changed files with 74 additions and 75 deletions

View File

@ -4,7 +4,7 @@ import { param2Obj } from '../src/utils'
import user from './user'
import role from './role'
import article from './article'
import search from './remoteSearch'
import search from './remote-search'
const mocks = [
...user,

View File

@ -19,17 +19,17 @@ export const constantRoutes = [
},
{
path: '/auth-redirect',
component: 'views/login/authRedirect',
component: 'views/login/auth-redirect',
hidden: true
},
{
path: '/404',
component: 'views/errorPage/404',
component: 'views/error-page/404',
hidden: true
},
{
path: '/401',
component: 'views/errorPage/401',
component: 'views/error-page/401',
hidden: true
},
{
@ -150,19 +150,19 @@ export const asyncRoutes = [
},
{
path: 'json-editor',
component: 'views/components-demo/jsonEditor',
component: 'views/components-demo/json-editor',
name: 'JsonEditorDemo',
meta: { title: 'jsonEditor' }
},
{
path: 'splitpane',
component: 'views/components-demo/splitpane',
path: 'split-pane',
component: 'views/components-demo/split-pane',
name: 'SplitpaneDemo',
meta: { title: 'splitPane' }
},
{
path: 'avatar-upload',
component: 'views/components-demo/avatarUpload',
component: 'views/components-demo/avatar-upload',
name: 'AvatarUploadDemo',
meta: { title: 'avatarUpload' }
},
@ -180,7 +180,7 @@ export const asyncRoutes = [
},
{
path: 'count-to',
component: 'views/components-demo/countTo',
component: 'views/components-demo/count-to',
name: 'CountToDemo',
meta: { title: 'countTo' }
},
@ -192,31 +192,31 @@ export const asyncRoutes = [
},
{
path: 'back-to-top',
component: 'views/components-demo/backToTop',
component: 'views/components-demo/back-to-top',
name: 'BackToTopDemo',
meta: { title: 'backToTop' }
},
{
path: 'drag-dialog',
component: 'views/components-demo/dragDialog',
component: 'views/components-demo/drag-dialog',
name: 'DragDialogDemo',
meta: { title: 'dragDialog' }
},
{
path: 'drag-select',
component: 'views/components-demo/dragSelect',
component: 'views/components-demo/drag-select',
name: 'DragSelectDemo',
meta: { title: 'dragSelect' }
},
{
path: 'dnd-list',
component: 'views/components-demo/dndList',
component: 'views/components-demo/dnd-list',
name: 'DndListDemo',
meta: { title: 'dndList' }
},
{
path: 'drag-kanban',
component: 'views/components-demo/dragKanban',
component: 'views/components-demo/drag-kanban',
name: 'DragKanbanDemo',
meta: { title: 'dragKanban' }
}
@ -370,13 +370,13 @@ export const asyncRoutes = [
children: [
{
path: '401',
component: 'views/errorPage/401',
component: 'views/error-page/401',
name: 'Page401',
meta: { title: 'page401', noCache: true }
},
{
path: '404',
component: 'views/errorPage/404',
component: 'views/error-page/404',
name: 'Page404',
meta: { title: 'page404', noCache: true }
}
@ -390,7 +390,7 @@ export const asyncRoutes = [
children: [
{
path: 'log',
component: 'views/errorLog/index',
component: 'views/error-log/index',
name: 'ErrorLog',
meta: { title: 'errorLog', icon: 'bug' }
}
@ -409,25 +409,25 @@ export const asyncRoutes = [
children: [
{
path: 'export-excel',
component: 'views/excel/exportExcel',
component: 'views/excel/export-excel',
name: 'ExportExcel',
meta: { title: 'exportExcel' }
},
{
path: 'export-selected-excel',
component: 'views/excel/selectExcel',
component: 'views/excel/select-excel',
name: 'SelectExcel',
meta: { title: 'selectExcel' }
},
{
path: 'export-merge-header',
component: 'views/excel/mergeHeader',
component: 'views/excel/merge-header',
name: 'MergeHeader',
meta: { title: 'mergeHeader' }
},
{
path: 'upload-excel',
component: 'views/excel/uploadExcel',
component: 'views/excel/upload-excel',
name: 'UploadExcel',
meta: { title: 'uploadExcel' }
}

View File

@ -9,7 +9,7 @@ import 'tui-editor/dist/tui-editor.css' // editor ui
import 'tui-editor/dist/tui-editor-contents.css' // editor content
import Editor from 'tui-editor'
import defaultOptions from './defaultOptions'
import defaultOptions from './default-options'
export default {
name: 'MarddownEditor',

View File

@ -15,7 +15,7 @@
</template>
<script>
import { scrollTo } from '@/utils/scrollTo'
import { scrollTo } from '@/utils/scroll-to'
export default {
name: 'Pagination',

View File

@ -8,7 +8,7 @@
</template>
<script>
import editorImage from './components/editorImage'
import editorImage from './components/EditorImage'
import plugins from './plugins'
import toolbar from './toolbar'

View File

@ -16,7 +16,7 @@ import router from './router'
import i18n from './lang' // Internationalization
import './icons' // icon
import './permission' // permission control
import './utils/errorLog' // error log
import './utils/error-log' // error log
import * as filters from './filters' // global filters

View File

@ -57,17 +57,17 @@ export const constantRoutes = [
},
{
path: '/auth-redirect',
component: () => import('@/views/login/authRedirect'),
component: () => import('@/views/login/auth-redirect'),
hidden: true
},
{
path: '/404',
component: () => import('@/views/errorPage/404'),
component: () => import('@/views/error-page/404'),
hidden: true
},
{
path: '/401',
component: () => import('@/views/errorPage/401'),
component: () => import('@/views/error-page/401'),
hidden: true
},
{
@ -232,13 +232,13 @@ export const asyncRoutes = [
children: [
{
path: '401',
component: () => import('@/views/errorPage/401'),
component: () => import('@/views/error-page/401'),
name: 'Page401',
meta: { title: 'page401', noCache: true }
},
{
path: '404',
component: () => import('@/views/errorPage/404'),
component: () => import('@/views/error-page/404'),
name: 'Page404',
meta: { title: 'page404', noCache: true }
}
@ -252,7 +252,7 @@ export const asyncRoutes = [
children: [
{
path: 'log',
component: () => import('@/views/errorLog/index'),
component: () => import('@/views/error-log/index'),
name: 'ErrorLog',
meta: { title: 'errorLog', icon: 'bug' }
}
@ -271,25 +271,25 @@ export const asyncRoutes = [
children: [
{
path: 'export-excel',
component: () => import('@/views/excel/exportExcel'),
component: () => import('@/views/excel/export-excel'),
name: 'ExportExcel',
meta: { title: 'exportExcel' }
},
{
path: 'export-selected-excel',
component: () => import('@/views/excel/selectExcel'),
component: () => import('@/views/excel/select-excel'),
name: 'SelectExcel',
meta: { title: 'selectExcel' }
},
{
path: 'export-merge-header',
component: () => import('@/views/excel/mergeHeader'),
component: () => import('@/views/excel/merge-header'),
name: 'MergeHeader',
meta: { title: 'mergeHeader' }
},
{
path: 'upload-excel',
component: () => import('@/views/excel/uploadExcel'),
component: () => import('@/views/excel/upload-excel'),
name: 'UploadExcel',
meta: { title: 'uploadExcel' }
}

View File

@ -25,8 +25,8 @@ const chartsRouter = {
meta: { title: 'lineChart', noCache: true }
},
{
path: 'mixchart',
component: () => import('@/views/charts/mixChart'),
path: 'mix-chart',
component: () => import('@/views/charts/mix-chart'),
name: 'MixChart',
meta: { title: 'mixChart', noCache: true }
}

View File

@ -26,19 +26,19 @@ const componentsRouter = {
},
{
path: 'json-editor',
component: () => import('@/views/components-demo/jsonEditor'),
component: () => import('@/views/components-demo/json-editor'),
name: 'JsonEditorDemo',
meta: { title: 'jsonEditor' }
},
{
path: 'splitpane',
component: () => import('@/views/components-demo/splitpane'),
path: 'split-pane',
component: () => import('@/views/components-demo/split-pane'),
name: 'SplitpaneDemo',
meta: { title: 'splitPane' }
},
{
path: 'avatar-upload',
component: () => import('@/views/components-demo/avatarUpload'),
component: () => import('@/views/components-demo/avatar-upload'),
name: 'AvatarUploadDemo',
meta: { title: 'avatarUpload' }
},
@ -56,7 +56,7 @@ const componentsRouter = {
},
{
path: 'count-to',
component: () => import('@/views/components-demo/countTo'),
component: () => import('@/views/components-demo/count-to'),
name: 'CountToDemo',
meta: { title: 'countTo' }
},
@ -68,31 +68,31 @@ const componentsRouter = {
},
{
path: 'back-to-top',
component: () => import('@/views/components-demo/backToTop'),
component: () => import('@/views/components-demo/back-to-top'),
name: 'BackToTopDemo',
meta: { title: 'backToTop' }
},
{
path: 'drag-dialog',
component: () => import('@/views/components-demo/dragDialog'),
component: () => import('@/views/components-demo/drag-dialog'),
name: 'DragDialogDemo',
meta: { title: 'dragDialog' }
},
{
path: 'drag-select',
component: () => import('@/views/components-demo/dragSelect'),
component: () => import('@/views/components-demo/drag-select'),
name: 'DragSelectDemo',
meta: { title: 'dragSelect' }
},
{
path: 'dnd-list',
component: () => import('@/views/components-demo/dndList'),
component: () => import('@/views/components-demo/dnd-list'),
name: 'DndListDemo',
meta: { title: 'dndList' }
},
{
path: 'drag-kanban',
component: () => import('@/views/components-demo/dragKanban'),
component: () => import('@/views/components-demo/drag-kanban'),
name: 'DragKanbanDemo',
meta: { title: 'dragKanban' }
}

View File

@ -14,25 +14,25 @@ const tableRouter = {
children: [
{
path: 'dynamic-table',
component: () => import('@/views/table/dynamicTable/index'),
component: () => import('@/views/table/dynamic-table/index'),
name: 'DynamicTable',
meta: { title: 'dynamicTable' }
},
{
path: 'drag-table',
component: () => import('@/views/table/dragTable'),
component: () => import('@/views/table/drag-table'),
name: 'DragTable',
meta: { title: 'dragTable' }
},
{
path: 'inline-edit-table',
component: () => import('@/views/table/inlineEditTable'),
component: () => import('@/views/table/inline-edit-table'),
name: 'InlineEditTable',
meta: { title: 'inlineEditTable' }
},
{
path: 'complex-table',
component: () => import('@/views/table/complexTable'),
component: () => import('@/views/table/complex-table'),
name: 'ComplexTable',
meta: { title: 'complexTable' }
}

View File

@ -5,7 +5,7 @@
</template>
<script>
import Chart from '@/components/Charts/keyboard'
import Chart from '@/components/Charts/Keyboard'
export default {
name: 'KeyboardChart',

View File

@ -5,7 +5,7 @@
</template>
<script>
import Chart from '@/components/Charts/lineMarker'
import Chart from '@/components/Charts/LineMarker'
export default {
name: 'LineChart',

View File

@ -5,7 +5,7 @@
</template>
<script>
import Chart from '@/components/Charts/mixChart'
import Chart from '@/components/Charts/MixChart'
export default {
name: 'MixChart',

View File

@ -17,7 +17,7 @@
</template>
<script>
import elDragDialog from '@/directive/el-dragDialog' // base on element-ui
import elDragDialog from '@/directive/el-drag-dialog' // base on element-ui
export default {
name: 'DragDialogDemo',

View File

@ -115,7 +115,7 @@
import PanThumb from '@/components/PanThumb'
import MdInput from '@/components/MDinput'
import Mallki from '@/components/TextHoverEffect/Mallki'
import DropdownMenu from '@/components/Share/dropdownMenu'
import DropdownMenu from '@/components/Share/DropdownMenu'
import waves from '@/directive/waves/index.js' //
export default {

View File

@ -21,7 +21,7 @@
</template>
<script>
import { transactionList } from '@/api/remoteSearch'
import { transactionList } from '@/api/remote-search'
export default {
filters: {

View File

@ -7,7 +7,7 @@
</div>
</template>
<script>
import DropdownMenu from '@/components/Share/dropdownMenu'
import DropdownMenu from '@/components/Share/DropdownMenu'
export default {
name: 'Documentation',

View File

@ -1,7 +1,7 @@
<template>
<div class="errPage-container">
<errorA />
<errorB />
<ErrorA />
<ErrorB />
<!-- $t is vue-i18n global function to translate lang -->
<h3>{{ $t('errorLog.tips') }}</h3>
<code>
@ -17,12 +17,12 @@
</template>
<script>
import errorA from './errorTestA'
import errorB from './errorTestB'
import ErrorA from './components/ErrorTestA'
import ErrorB from './components/ErrorTestB'
export default {
name: 'ErrorLog',
components: { errorA, errorB }
components: { ErrorA, ErrorB }
}
</script>

View File

@ -76,12 +76,12 @@
<script>
import Tinymce from '@/components/Tinymce'
import Upload from '@/components/Upload/singleImage3'
import Upload from '@/components/Upload/SingleImage3'
import MDinput from '@/components/MDinput'
import Sticky from '@/components/Sticky' // header
import { validURL } from '@/utils/validate'
import { fetchArticle } from '@/api/article'
import { searchUser } from '@/api/remoteSearch'
import { searchUser } from '@/api/remote-search'
import Warning from './Warning'
import { CommentDropdown, PlatformDropdown, SourceUrlDropdown } from './Dropdown'

View File

@ -2,8 +2,7 @@
<div class="app-container">
<p class="warn-content">
{{ $t('guide.description') }}
<a href="https://github.com/kamranahmedse/driver.js" target="_blank">driver.js.
</a>
<a href="https://github.com/kamranahmedse/driver.js" target="_blank">driver.js.</a>
</p>
<el-button icon="el-icon-question" type="primary" @click.prevent.stop="guide">
{{ $t('guide.button') }}
@ -14,7 +13,7 @@
<script>
import Driver from 'driver.js' // import driver.js
import 'driver.js/dist/driver.min.css' // import driver.js css
import steps from './defineSteps'
import steps from './steps'
export default {
name: 'Guide',

View File

@ -10,7 +10,7 @@
</template>
<script>
// import openWindow from '@/utils/openWindow'
// import openWindow from '@/utils/open-window'
export default {
name: 'SocialSignin',

View File

@ -81,7 +81,7 @@
<script>
import { validUsername } from '@/utils/validate'
import LangSelect from '@/components/LangSelect'
import SocialSign from './socialSignin'
import SocialSign from './components/SocialSignin'
export default {
name: 'Login',

View File

@ -37,7 +37,7 @@
<script>
import clipboard from '@/utils/clipboard'
import icons from './requireIcons'
import icons from './require-icons'
import elementIcons from './element-icon.json'
export default {

View File

@ -13,7 +13,7 @@
</template>
<script>
import tabPane from './components/tabPane'
import tabPane from './components/TabPane'
export default {
name: 'Tab',

View File

@ -13,12 +13,12 @@
</template>
<script>
import fixedThead from './fixedThead'
import unfixedThead from './unfixedThead'
import FixedThead from './components/FixedThead'
import UnfixedThead from './components/UnfixedThead'
export default {
name: 'DynamicTable',
components: { fixedThead, unfixedThead }
components: { FixedThead, UnfixedThead }
}
</script>