feat: acs国际化

This commit is contained in:
2023-11-27 15:17:01 +08:00
parent ce4f06a789
commit c46e41f3e8
46 changed files with 959 additions and 332 deletions

View File

@@ -69,7 +69,7 @@ public class SysMenuServiceImpl extends ServiceImpl<SysMenuMapper, SysMenu> impl
if (StringUtils.isNotEmpty(query.getBlurry())){ if (StringUtils.isNotEmpty(query.getBlurry())){
query.setPid(null); query.setPid(null);
} }
Page<SysMenu> menuPage = this.page(page.build(), query.build()); Page<SysMenu> menuPage = this.page(page.build(SysMenu.class), query.build());
List<MenuDto> collect = menuPage.getRecords().stream().map(menu -> this.doToDto(menu)).collect(Collectors.toList()); List<MenuDto> collect = menuPage.getRecords().stream().map(menu -> this.doToDto(menu)).collect(Collectors.toList());
return collect; return collect;
} }
@@ -360,6 +360,9 @@ public class SysMenuServiceImpl extends ServiceImpl<SysMenuMapper, SysMenu> impl
menuDto.setType(entity.getType()); menuDto.setType(entity.getType());
menuDto.setPermission(entity.getPermission()); menuDto.setPermission(entity.getPermission());
menuDto.setTitle(entity.getTitle()); menuDto.setTitle(entity.getTitle());
menuDto.setIn_title(entity.getIn_title());
menuDto.setEn_title(entity.getEn_title());
menuDto.setZh_title(entity.getZh_title());
menuDto.setMenu_sort(entity.getMenu_sort()); menuDto.setMenu_sort(entity.getMenu_sort());
menuDto.setPath(entity.getPath()); menuDto.setPath(entity.getPath());
menuDto.setComponent(entity.getComponent()); menuDto.setComponent(entity.getComponent());

View File

@@ -62,6 +62,7 @@
"path-to-regexp": "2.4.0", "path-to-regexp": "2.4.0",
"qrcodejs2": "0.0.2", "qrcodejs2": "0.0.2",
"qs": "^6.9.1", "qs": "^6.9.1",
"save": "^2.9.0",
"screenfull": "4.2.0", "screenfull": "4.2.0",
"sortablejs": "1.8.4", "sortablejs": "1.8.4",
"throttle-debounce": "^5.0.0", "throttle-debounce": "^5.0.0",
@@ -73,6 +74,7 @@
"vue-easy-print": "0.0.8", "vue-easy-print": "0.0.8",
"vue-echarts": "^5.0.0-beta.0", "vue-echarts": "^5.0.0-beta.0",
"vue-highlightjs": "^1.3.3", "vue-highlightjs": "^1.3.3",
"vue-i18n": "^8.27.0",
"vue-image-crop-upload": "^2.5.0", "vue-image-crop-upload": "^2.5.0",
"vue-print-nb": "^1.7.5", "vue-print-nb": "^1.7.5",
"vue-router": "3.0.2", "vue-router": "3.0.2",

View File

@@ -2,8 +2,8 @@
<el-breadcrumb class="app-breadcrumb" separator="/"> <el-breadcrumb class="app-breadcrumb" separator="/">
<transition-group name="breadcrumb"> <transition-group name="breadcrumb">
<el-breadcrumb-item v-for="(item,index) in levelList" :key="item.path"> <el-breadcrumb-item v-for="(item,index) in levelList" :key="item.path">
<span v-if="item.redirect==='noredirect'||index==levelList.length-1" class="no-redirect">{{ item.meta.title }}</span> <span v-if="item.redirect==='noredirect'||index==levelList.length-1" class="no-redirect">{{ $t(item.meta.title) }}</span>
<a v-else @click.prevent="handleLink(item)">{{ item.meta.title }}</a> <a v-else @click.prevent="handleLink(item)">{{ $t(item.meta.title) }}</a>
</el-breadcrumb-item> </el-breadcrumb-item>
</transition-group> </transition-group>
</el-breadcrumb> </el-breadcrumb>
@@ -37,7 +37,7 @@ export default {
const first = matched[0] const first = matched[0]
if (!this.isDashboard(first)) { if (!this.isDashboard(first)) {
matched = [{ path: '/dashboard', meta: { title: '首页' }}].concat(matched) matched = [{ path: '/dashboard', meta: { title: this.$t('common.home') }}].concat(matched)
} }
this.levelList = matched.filter(item => item.meta && item.meta.title && item.meta.breadcrumb !== false) this.levelList = matched.filter(item => item.meta && item.meta.title && item.meta.breadcrumb !== false)

View File

@@ -12,7 +12,7 @@
icon="el-icon-plus" icon="el-icon-plus"
@click="crud.toAdd" @click="crud.toAdd"
> >
新增 {{ $t('common.Create') }}
</el-button> </el-button>
<el-button <el-button
v-if="crud.optShow.edit" v-if="crud.optShow.edit"
@@ -24,7 +24,7 @@
:disabled="crud.selections.length !== 1" :disabled="crud.selections.length !== 1"
@click="crud.toEdit(crud.selections[0])" @click="crud.toEdit(crud.selections[0])"
> >
修改 {{ $t('common.Update') }}
</el-button> </el-button>
<el-button <el-button
v-if="crud.optShow.del" v-if="crud.optShow.del"
@@ -38,7 +38,7 @@
:disabled="crud.selections.length === 0" :disabled="crud.selections.length === 0"
@click="toDelete(crud.selections)" @click="toDelete(crud.selections)"
> >
删除 {{ $t('common.Delete') }}
</el-button> </el-button>
<el-button <el-button
v-if="crud.optShow.download" v-if="crud.optShow.download"
@@ -49,7 +49,7 @@
type="warning" type="warning"
icon="el-icon-download" icon="el-icon-download"
@click="crud.doExport" @click="crud.doExport"
>导出</el-button> >{{ $t('common.Export') }}</el-button>
<!--右侧--> <!--右侧-->
<slot name="right" /> <slot name="right" />
</span> </span>
@@ -86,7 +86,7 @@
:indeterminate="allColumnsSelectedIndeterminate" :indeterminate="allColumnsSelectedIndeterminate"
@change="handleCheckAllChange" @change="handleCheckAllChange"
> >
全选 {{ $t('common.SelectAll') }}
</el-checkbox> </el-checkbox>
<el-checkbox <el-checkbox
v-for="item in tableColumns" v-for="item in tableColumns"
@@ -190,9 +190,9 @@ export default {
this.tableColumns = columns this.tableColumns = columns
}, },
toDelete(datas) { toDelete(datas) {
this.$confirm(`确认删除选中的${datas.length}条数据?`, '提示', { this.$confirm(this.$t('common.Tip1') + ` ${datas.length} ` + this.$t('common.Tip2'), this.$t('common.Tips'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.Confirm'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.Cancel'),
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.crud.delAllLoading = true this.crud.delAllLoading = true

View File

@@ -5,9 +5,9 @@
<el-button v-if="crud.optShow.reset" class="filter-item" size="mini" type="warning" icon="el-icon-refresh-left" @click="crud.resetQuery()">重置</el-button> <el-button v-if="crud.optShow.reset" class="filter-item" size="mini" type="warning" icon="el-icon-refresh-left" @click="crud.resetQuery()">重置</el-button>
--> -->
<el-dropdown split-button type="primary" class="filter-item" @click="crud.toQuery"> <el-dropdown split-button type="primary" class="filter-item" @click="crud.toQuery">
<i class="el-icon-search el-icon--left" />查询 <i class="el-icon-search el-icon--left" />{{ $t('common.Query') }}
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<el-dropdown-item icon="el-icon-zoom-out" @click.native="crud.resetQuery()">重置</el-dropdown-item> <el-dropdown-item icon="el-icon-zoom-out" @click.native="crud.resetQuery()">{{ $t('common.Reset') }}</el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>

View File

@@ -1,13 +1,13 @@
<template> <template>
<div> <div>
<el-button v-if="isVisiableEdit" v-permission="permission.edit" type="text" :loading="crud.status.cu === 2" :disabled="disabledEdit" size="mini" icon="el-icon-edit" @click="crud.toEdit(data)">修改</el-button> <el-button v-if="isVisiableEdit" v-permission="permission.edit" type="text" :loading="crud.status.cu === 2" :disabled="disabledEdit" size="mini" icon="el-icon-edit" @click="crud.toEdit(data)">{{ $t('common.Update') }}</el-button>
<el-popover v-model="pop" v-permission="permission.del" placement="top" width="180" trigger="manual" @show="onPopoverShow" @hide="onPopoverHide"> <el-popover v-model="pop" v-permission="permission.del" placement="top" width="180" trigger="manual" @show="onPopoverShow" @hide="onPopoverHide">
<p>{{ msg }}</p> <p>{{ msg }}</p>
<div style="text-align: right; margin: 0"> <div style="text-align: right; margin: 0">
<el-button size="mini" type="text" @click="doCancel">取消</el-button> <el-button size="mini" type="text" @click="doCancel">{{ $t('common.Cancel') }}</el-button>
<el-button :loading="crud.dataStatus[crud.getDataId(data)].delete === 2" type="primary" size="mini" @click="crud.doDelete(data)">确定</el-button> <el-button :loading="crud.dataStatus[crud.getDataId(data)].delete === 2" type="primary" size="mini" @click="crud.doDelete(data)">{{ $t('common.Confirm') }}</el-button>
</div> </div>
<el-button v-if="isVisiableDel" slot="reference" type="text" :disabled="disabledDle" icon="el-icon-delete" size="mini" @click="toDelete">删除</el-button> <el-button v-if="isVisiableDel" slot="reference" type="text" :disabled="disabledDle" icon="el-icon-delete" size="mini" @click="toDelete">{{ $t('common.Delete') }}</el-button>
</el-popover> </el-popover>
</div> </div>

View File

@@ -1,6 +1,7 @@
import { download, initData } from '@/api/data' import { download, initData } from '@/api/data'
import { downloadFile, parseTime } from '@/utils/index' import { downloadFile, parseTime } from '@/utils/index'
import Vue from 'vue' import Vue from 'vue'
import i18n from '@/i18n'
/** /**
* CRUD配置 * CRUD配置
@@ -84,7 +85,7 @@ function CRUD(options) {
}, },
// 标题 // 标题
get title() { get title() {
return this.add > CRUD.STATUS.NORMAL ? `新增${crud.title}` : this.edit > CRUD.STATUS.NORMAL ? `编辑${crud.title}` : crud.title return this.add > CRUD.STATUS.NORMAL ? i18n.t('common.Create') + ' ' + i18n.t(`${crud.title}`) : this.edit > CRUD.STATUS.NORMAL ? i18n.t('common.Editors') + ' ' + i18n.t(`${crud.title}`) : crud.title
} }
}, },
msg: { msg: {

View File

@@ -17,7 +17,7 @@
<!-- 顶部菜单超出数量折叠 --> <!-- 顶部菜单超出数量折叠 -->
<el-submenu v-if="topMenus.length > visibleNumber" :style="{'--theme': theme}" index="more"> <el-submenu v-if="topMenus.length > visibleNumber" :style="{'--theme': theme}" index="more">
<template slot="title">更多菜单</template> <template slot="title">{{ $t('common.moreMenu') }}</template>
<template v-for="(item, index) in topMenus"> <template v-for="(item, index) in topMenus">
<el-menu-item <el-menu-item
v-if="index >= visibleNumber" v-if="index >= visibleNumber"

View File

@@ -2,9 +2,9 @@
<div> <div>
<input ref="excel-upload-input" class="excel-upload-input" type="file" accept=".xlsx, .xls" @change="handleClick"> <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"> <div class="drop" @drop="handleDrop" @dragover="handleDragover" @dragenter="handleDragover">
拖拽excel文件到此处 或者 {{ $t('common.Tip7') }}
<el-button :loading="loading" style="margin-left:16px;" size="mini" type="primary" @click="handleUpload"> <el-button :loading="loading" style="margin-left:16px;" size="mini" type="primary" @click="handleUpload">
浏览 {{ $t('common.browses') }}
</el-button> </el-button>
</div> </div>
</div> </div>

View File

@@ -0,0 +1,27 @@
import Vue from 'vue'
import VueI18n from 'vue-i18n'
import locale from 'element-ui/lib/locale'
import zh from './langs/chinese'
import en from './langs/english'
import indonesian from './langs/indonesian'
Vue.use(VueI18n)
const messages = {
en: {
...en
},
zh: {
...zh
},
in: {
...indonesian
}
}
const i18n = new VueI18n({
locale: localStorage.lang || 'zh',
messages,
silentTranslationWarn: true, // 解决vue-i18n黄色警告"value of key 'xxx' is not a string"和"cannot translate the value of keypath 'xxx'.use the value of keypath as default",可忽略
globalInjection: true, // 全局注入
fallbackLocale: 'zh'
})
locale.i18n((key, value) => i18n.t(key, value))
export default i18n

View File

@@ -0,0 +1,11 @@
import zhLocale from 'element-ui/lib/locale/lang/zh-CN'
import zh from './zh-CN'
import menu from './menu/zh'
import param from './param/zh'
export default {
...zhLocale,
...zh,
...menu,
...param
}

View File

@@ -0,0 +1,99 @@
export default {
'lang': 'English',
'common': {
'home': 'Dashboard',
'Layout_setting': 'Layout Setting',
'Personal_center': 'Personal Center',
'Log_out': 'Log Out',
'Personal_information': 'Personal Information',
'username': 'UserName',
'name': 'Name',
'phone': 'Phone Number',
'phone2': 'Phone',
'sex': 'Sex',
'sex_male': 'Male',
'sex_female': 'Female',
'email': 'E-mail',
'Security_settings': 'Security Settings',
'Save_settings': 'Save Settings',
'Reset_settings': 'Reset Settings',
'Change_password': 'Change Password',
'New_password': 'New Password',
'Old_password': 'Old Password',
'Verify_password': 'Verify Password',
'User_information': 'User Information',
'Operation_log': 'Operation Log',
'action': 'Action',
'IP_source': 'IP Source',
'Browser': 'Browser',
'Request_time': 'Request Time',
'Creation_date': 'Creation Date',
'account': 'Account',
'password': 'Password',
'verification_code': 'Code',
'login_rm': 'Remember Me',
'login': 'Login',
'login_ing': 'Logging in...',
'Create': 'Create',
'Update': 'Update',
'Delete': 'Delete',
'Export': 'Export',
'Editors': 'Editor',
'SelectAll': 'SelectAll',
'Query': 'Query',
'Reset': 'Reset',
'Confirm': 'Confirm',
'Cancel': 'Cancel',
'Operate': 'Operate',
'Refresh': 'Refresh',
'Closes': 'Close',
'Closes_l': 'Close Left',
'Closes_r': 'Close Right',
'Closes_o': 'Close Other',
'Closes_a': 'Close All',
'Theme_style_setting': 'Theme Style Setting',
'Theme_color': 'Theme Color',
'System_layout_configuration': 'System Layout Configuration',
'Open': 'Open',
'Fixation': 'Fixation',
'Display': 'Display',
'Dynamic_titles': 'Dynamic Titles',
'crudTip': 'Are you sure to delete this data?',
'startDate': 'StartDate',
'endDate': 'EndDate',
'moreMenu': 'MoreMenu',
'browses': 'browse',
'fz': 'Full screen zoom',
'Tips': 'Tips',
'Tip1': 'Confirm deletion of selected',
'Tip2': 'Data?',
'Tip3': 'User name not used as login',
'Tip4': 'Mobile phone number cannot be duplicate',
'Tip5': 'Please enter a phone number',
'Tip6': 'Please enter the correct 11 digit phone number',
'Tip7': 'Drag and drop the excel file here or',
'Tip8': 'The two passwords are different',
'Tip9': 'Please enter your password again',
'Tip10': 'Please enter your old password',
'Tip11': 'Please enter your new password',
'Tip12': '6 to 20 characters in length',
'Tip13': 'Are you sure to log out and exit the system?',
'Tip14': 'WebSocket connection error',
'loading': 'loading...'
},
'monitor': {
'sys': 'System',
'day': 'Running Day',
'status': 'Status',
'core': 'Core',
'cpu': 'CPU Utilization',
'memory': 'Memory Utilization',
'tality': 'Tality',
'used': 'Used',
'leisure': 'Leisure',
'exchange': 'Exchange Utilization',
'disk': 'Disk Utilization',
'cpu_monitoring': 'Cpu Utilization Monitoring',
'memory_monitoring': 'Memory Utilization Monitoring'
}
}

View File

@@ -0,0 +1,11 @@
import enLocale from 'element-ui/lib/locale/lang/en'
import en from './en'
import menu from './menu/en'
import param from './param/en'
export default {
...enLocale,
...en,
...menu,
...param
}

View File

@@ -0,0 +1,99 @@
export default {
'lang': 'in',
'common': {
'home': 'rumah', // 首页
'Layout_setting': 'Pengaturan Bentangan',
'Personal_center': 'Pusat Pribadi',
'Log_out': 'Log Out',
'Personal_information': 'Informasi Pribadi',
'username': 'Nama Pengguna',
'name': 'Nama',
'phone': 'Nomor Ponsel',
'phone2': 'Ponsel',
'sex': 'Gender',
'sex_male': 'laki-laki',
'sex_female': 'wanita',
'email': 'E-mail',
'Security_settings': 'Pengaturan Keamanan',
'Save_settings': 'Simpan Pengaturan',
'Reset_settings': 'Reset pengaturan',
'Change_password': 'Ubah kata sandi',
'New_password': 'Kata sandi baru',
'Old_password': 'Kata sandi lama',
'Verify_password': 'Konfirmasi Sandi',
'User_information': 'Informasi Pengguna',
'Operation_log': 'Log Operasi',
'action': 'Perilaku',
'Browser': 'Pelayar',
'IP_source': 'IP Sumber',
'Request_time': 'Meminta Konsumsi Waktu',
'Creation_date': 'Dicipta Pada',
'account': 'Akaun',
'password': 'Sandi',
'verification_code': 'Kode',
'login_rm': 'Ingat aku',
'login': 'Login',
'login_ing': 'Daftar masuk',
'Create': 'Buat',
'Update': 'Kemaskini',
'Delete': 'Hapus',
'Export': 'Ekspor',
'Editors': 'Editor',
'SelectAll': 'Pilih Semua',
'Query': 'Pertanyaan',
'Reset': 'Reset',
'Confirm': 'konfirmasi',
'Cancel': 'Batalkan',
'Operate': 'operasi',
'Refresh': 'Segar',
'Closes': 'Tutup',
'Closes_l': 'Tutup Sisi Kiri',
'Closes_r': 'Tutup Sisi Kanan',
'Closes_o': 'Tutup Lain',
'Closes_a': 'Tutup Semua',
'Theme_style_setting': 'Pengaturan Gaya Tema',
'Theme_color': 'Warna Tema',
'System_layout_configuration': 'Konfigurasi layout sistem',
'Open': 'Buka',
'Fixation': 'Tetap',
'Display': 'Tampilan',
'Dynamic_titles': 'Tajuk Dinamik',
'crudTip': 'Apakah Anda yakin untuk menghapus data ini?',
'startDate': 'TarikhAwal',
'endDate': 'TarikhAkhir',
'moreMenu': 'LebihBanyakMenu',
'browses': 'melayar',
'fz': 'Zum layar penuh',
'Tips': 'Prompt',
'Tip1': 'Konfirmasi Penghapusan Yang Dipilih',
'Tip2': 'Data?',
'Tip3': 'Nama pengguna tidak digunakan sebagai daftar masuk',
'Tip4': 'Nomor telepon ponsel tidak dapat duplikasi',
'Tip5': 'Silakan masukkan nomor telepon',
'Tip6': 'Silakan masukkan nomor telepon 11 digit yang benar',
'Tip7': 'Seret dan jatuhkan berkas Excel di sini atau',
'Tip8': 'Kata sandi yang dimasukkan dua kali tidak cocok',
'Tip9': 'Silakan masukkan sandi lagi',
'Tip10': 'Silakan masukkan kata sandi lama Anda',
'Tip11': 'Silakan masukkan sandi baru',
'Tip12': 'Antara 6 dan 20 karakter dalam panjang',
'Tip13': 'Apakah Anda yakin untuk log keluar dan keluar dari sistem?',
'Tip14': 'Koneksi WebSocket error',
'loading': 'Memuatkan Data...'
},
'monitor': {
'sys': 'Sistem',
'day': 'Proyek ini telah berjalan terus menerus',
'status': 'Keadaan',
'core': 'Inti',
'cpu': 'Kadar penggunaan CPU',
'memory': 'Kadar penggunaan ingatan',
'tality': 'Total',
'used': 'Digunakan',
'leisure': 'Bebas',
'exchange': 'Kadar penggunaan area pertukaran',
'disk': 'Kadar penggunaan disk',
'cpu_monitoring': 'Monitor penggunaan CPU',
'memory_monitoring': 'Monitor penggunaan memori'
}
}

View File

@@ -0,0 +1,11 @@
import idLocale from 'element-ui/lib/locale/lang/id'
import id from './in'
import menu from './menu/in'
import param from './param/in'
export default {
...idLocale,
...id,
...menu,
...param
}

View File

@@ -0,0 +1,23 @@
export default {
'menu': {
'placeholder': {
'fuzzy_search': 'fuzzy search',
'owning_system': 'system'
},
'table_title': {
'menu_title': 'title',
'system': 'system',
'icon': 'icon',
'sort': 'sort',
'permission_ident': 'permission mark',
'path': 'path',
'outside_chain': 'out chain',
'cache': 'cache',
'visible': 'visible',
'create_time': 'create time'
},
'msg': {
'delete_msg': 'Are you sure to delete it? If there are subordinate nodes, they will be deleted together. This operation cannot be undone!'
}
}
}

View File

@@ -0,0 +1,23 @@
export default {
'menu': {
'placeholder': {
'fuzzy_search': 'pencarian kabur',
'owning_system': 'sistem terkait'
},
'table_title': {
'menu_title': 'title',
'system': 'sistem',
'icon': 'ikon',
'sort': 'sort',
'permission_ident': 'otoritas',
'path': 'assembly',
'outside_chain': 'rantai luar',
'cache': 'cache',
'visible': 'terlihat',
'create_time': 'tarikh penciptaan'
},
'msg': {
'delete_msg': 'Apakah Anda yakin untuk menghapusnya? Jika ada nod subordinat, mereka akan dihapus bersama. Operasi ini tidak dapat dibatalkan!'
}
}
}

View File

@@ -0,0 +1,23 @@
export default {
'menu': {
'placeholder': {
'fuzzy_search': '模糊搜索',
'owning_system': '所属系统'
},
'table_title': {
'menu_title': '菜单标题',
'system': '所属系统',
'icon': '图标',
'sort': '排序',
'permission_ident': '权限标识',
'path': '组件路径',
'outside_chain': '外链',
'cache': '缓存',
'visible': '可见',
'create_time': '创建日期'
},
'msg': {
'delete_msg': '确定删除吗,如果存在下级节点则一并删除,此操作不能撤销!'
}
}
}

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': 'code',
'name': 'name',
'values': 'value',
'description': 'remark'
},
'rules': {
'NotNull': 'Cannot be empty'
}
}
}

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': 'kode',
'name': 'nama',
'values': 'nilai',
'description': 'Catatan'
},
'rules': {
'NotNull': 'Tidak dapat kosong'
}
}
}

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': '编码',
'name': '名称',
'values': '值',
'description': '备注'
},
'rules': {
'NotNull': '不能为空'
}
}
}

View File

@@ -0,0 +1,99 @@
export default {
'lang': 'zh',
'common': {
'home': '首页',
'Layout_setting': '布局设置',
'Personal_center': '个人中心',
'Log_out': '退出登录',
'Personal_information': '个人信息',
'username': '用户姓名',
'name': '姓名',
'phone': '手机号码',
'phone2': '手机号',
'sex': '性别',
'sex_male': '男',
'sex_female': '女',
'email': '用户邮箱',
'Security_settings': '安全设置',
'Save_settings': '保存配置',
'Reset_settings': '重置配置',
'Change_password': '修改密码',
'New_password': '新密码',
'Old_password': '旧密码',
'Verify_password': '确认密码',
'User_information': '用户资料',
'Operation_log': '操作日志',
'action': '行为',
'IP_source': 'IP来源',
'Browser': '浏览器',
'Request_time': '请求耗时',
'Creation_date': '创建日期',
'account': '账号',
'password': '密码',
'verification_code': '验证码',
'login_rm': '记住我',
'login': '登 录',
'login_ing': '登 录 中...',
'Create': '新增',
'Update': '修改',
'Delete': '删除',
'Export': '导出',
'Editors': '编辑',
'SelectAll': '全选',
'Query': '查询',
'Reset': '重置',
'Confirm': '确认',
'Cancel': '取消',
'Operate': '操作',
'Refresh': '刷新',
'Closes': '关闭',
'Closes_l': '关闭左侧',
'Closes_r': '关闭右侧',
'Closes_o': '关闭其他',
'Closes_a': '关闭全部',
'Theme_style_setting': '主题风格设置',
'Theme_color': '主题颜色',
'System_layout_configuration': '系统布局配置',
'Open': '开启',
'Fixation': '固定',
'Display': '显示',
'Dynamic_titles': '动态标题',
'crudTip': '确定删除本条数据吗?',
'startDate': '开始日期',
'endDate': '结束日期',
'moreMenu': '更多菜单',
'browses': '浏览',
'fz': '全屏缩放',
'Tips': '提示',
'Tip1': '确认删除选中的',
'Tip2': '条数据?',
'Tip3': '用户姓名不作为登录使用',
'Tip4': '手机号码不能重复',
'Tip5': '请输入电话号码',
'Tip6': '请输入正确的11位手机号码',
'Tip7': '拖拽excel文件到此处 或者',
'Tip8': '两次输入的密码不一致',
'Tip9': '请再次输入密码',
'Tip10': '请输入旧密码',
'Tip11': '请输入新密码',
'Tip12': '长度在 6 到 20 个字符',
'Tip13': '确定注销并退出系统吗?',
'Tip14': 'WebSocket连接发生错误',
'loading': '数据加载中...'
},
'monitor': {
'sys': '系统',
'day': '项目已不间断运行',
'status': '状态',
'cpu': 'CPU使用率',
'core': '核心',
'memory': '内存使用率',
'tality': '总量',
'used': '已使用',
'leisure': '空闲',
'exchange': '交换区使用率',
'disk': '磁盘使用率',
'cpu_monitoring': 'CPU使用率监控',
'memory_monitoring': '内存使用率监控'
}
}

View File

@@ -9,18 +9,18 @@
<search id="header-search" class="right-menu-item" /> <search id="header-search" class="right-menu-item" />
<!-- <el-tooltip content="项目文档" effect="dark" placement="bottom"> <!-- <el-tooltip content="项目文档" effect="dark" placement="bottom">
<Doc class="right-menu-item hover-effect" /> <Doc class="right-menu-item hover-effect" />
</el-tooltip>--> </el-tooltip>-->
<el-tooltip content="全屏缩放" effect="dark" placement="bottom"> <el-tooltip :content="$t('common.fz')" effect="dark" placement="bottom">
<screenfull id="screenfull" class="right-menu-item hover-effect" /> <screenfull id="screenfull" class="right-menu-item hover-effect" />
</el-tooltip> </el-tooltip>
<notice-icon class="right-menu-item" /> <notice-icon class="right-menu-item" />
<notice-icon-reader ref="noticeIconReader" /> <notice-icon-reader ref="noticeIconReader" />
<!-- <el-tooltip content="布局设置" effect="dark" placement="bottom"> <!-- <el-tooltip content="布局设置" effect="dark" placement="bottom">
<size-select id="size-select" class="right-menu-item hover-effect" /> <size-select id="size-select" class="right-menu-item hover-effect" />
</el-tooltip>--> </el-tooltip>-->
</template> </template>
<img :src="Avatar" class="user-avatar"> <img :src="Avatar" class="user-avatar">
@@ -31,21 +31,31 @@
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<span style="display:block;" @click="show = true"> <span style="display:block;" @click="show = true">
<el-dropdown-item> <el-dropdown-item>
布局设置 {{ $t('common.Layout_setting') }}
</el-dropdown-item> </el-dropdown-item>
</span> </span>
<router-link to="/user/center"> <router-link to="/user/center">
<el-dropdown-item> <el-dropdown-item>
个人中心 {{ $t('common.Personal_center') }}
</el-dropdown-item> </el-dropdown-item>
</router-link> </router-link>
<span style="display:block;" @click="open"> <span style="display:block;" @click="open">
<el-dropdown-item divided> <el-dropdown-item divided>
退出登录 {{ $t('common.Log_out') }}
</el-dropdown-item> </el-dropdown-item>
</span> </span>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
<el-dropdown class="right-menu-item" style="font-size: 14px" trigger="click" @command="langChange">
<span class="el-dropdown-link">
{{ language }} <i class="el-icon-caret-bottom" />
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item divided command="zh">简体中文</el-dropdown-item>
<el-dropdown-item divided command="en">English</el-dropdown-item>
<el-dropdown-item divided command="in">Indonesian</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div> </div>
</div> </div>
</template> </template>
@@ -79,10 +89,12 @@ export default {
data() { data() {
return { return {
Avatar: Avatar, Avatar: Avatar,
dialogVisible: false dialogVisible: false,
language: '简体中文'
} }
}, },
created() { created() {
this.setLang(localStorage.getItem('lang'))
this.initWebSocket() this.initWebSocket()
}, },
computed: { computed: {
@@ -110,13 +122,29 @@ export default {
} }
}, },
methods: { methods: {
// 中英文切换
langChange(command) {
this.$i18n.locale = command
localStorage.setItem('lang', command)
this.setLang(command)
location.reload()
},
setLang(command) {
if (command === 'en') {
this.language = 'English'
} else if (command === 'zh') {
this.language = '简体中文'
} else if (command === 'in') {
this.language = 'Indonesian'
}
},
toggleSideBar() { toggleSideBar() {
this.$store.dispatch('app/toggleSideBar') this.$store.dispatch('app/toggleSideBar')
}, },
open() { open() {
this.$confirm('确定注销并退出系统吗?', '提示', { this.$confirm(this.$t('common.Tip13'), this.$t('common.Tips'), {
confirmButtonText: '确定', confirmButtonText: this.$t('common.Confirm'),
cancelButtonText: '取消', cancelButtonText: this.$t('common.Cancel'),
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.logout() this.logout()
@@ -128,6 +156,7 @@ export default {
}) })
}, },
initWebSocket() { initWebSocket() {
// const wsUri = (process.env.VUE_APP_WS_API === '/' ? '/' : (process.env.VUE_APP_WS_API + '/')) + 'messageInfo'
const wsUri = window.g.prod.VUE_APP_BASE_API.replace('http', 'ws') + '/webSocket/' + 'messageInfo' const wsUri = window.g.prod.VUE_APP_BASE_API.replace('http', 'ws') + '/webSocket/' + 'messageInfo'
this.websock = new WebSocket(wsUri) this.websock = new WebSocket(wsUri)
this.websock.onerror = this.webSocketOnError this.websock.onerror = this.webSocketOnError
@@ -135,7 +164,7 @@ export default {
}, },
webSocketOnError(e) { webSocketOnError(e) {
this.$notify({ this.$notify({
title: 'WebSocket连接发生错误', title: this.$t('common.Tip14'),
type: 'error', type: 'error',
duration: 0 duration: 0
}) })

View File

@@ -3,7 +3,7 @@
<div> <div>
<div class="setting-drawer-content"> <div class="setting-drawer-content">
<div class="setting-drawer-title"> <div class="setting-drawer-title">
<h3 class="drawer-title">主题风格设置</h3> <h3 class="drawer-title">{{ $t('common.Theme_style_setting') }}</h3>
</div> </div>
<div class="setting-drawer-block-checbox"> <div class="setting-drawer-block-checbox">
<div class="setting-drawer-block-checbox-item" @click="handleTheme('theme-dark')"> <div class="setting-drawer-block-checbox-item" @click="handleTheme('theme-dark')">
@@ -51,44 +51,44 @@
</div> </div>
<div class="drawer-item"> <div class="drawer-item">
<span>主题颜色</span> <span>{{ $t('common.Theme_color') }}</span>
<theme-picker style="float: right;height: 26px;margin: -3px 8px 0 0;" @change="themeChange" /> <theme-picker style="float: right;height: 26px;margin: -3px 8px 0 0;" @change="themeChange" />
</div> </div>
</div> </div>
<el-divider /> <el-divider />
<h3 class="drawer-title">系统布局配置</h3> <h3 class="drawer-title">{{ $t('common.System_layout_configuration') }}</h3>
<div class="drawer-item"> <div class="drawer-item">
<span>开启 TopNav</span> <span>{{ $t('common.Open') }} TopNav</span>
<el-switch v-model="topNav" class="drawer-switch" /> <el-switch v-model="topNav" class="drawer-switch" />
</div> </div>
<div class="drawer-item"> <div class="drawer-item">
<span>开启 Tags-Views</span> <span>{{ $t('common.Open') }} Tags-Views</span>
<el-switch v-model="tagsView" class="drawer-switch" /> <el-switch v-model="tagsView" class="drawer-switch" />
</div> </div>
<div class="drawer-item"> <div class="drawer-item">
<span>固定 Header</span> <span>{{ $t('common.Fixation') }} Header</span>
<el-switch v-model="fixedHeader" class="drawer-switch" /> <el-switch v-model="fixedHeader" class="drawer-switch" />
</div> </div>
<div class="drawer-item"> <div class="drawer-item">
<span>显示 Logo</span> <span>{{ $t('common.Display') }} Logo</span>
<el-switch v-model="sidebarLogo" class="drawer-switch" /> <el-switch v-model="sidebarLogo" class="drawer-switch" />
</div> </div>
<div class="drawer-item"> <div class="drawer-item">
<span>动态标题</span> <span>{{ $t('common.Dynamic_titles') }}</span>
<el-switch v-model="dynamicTitle" class="drawer-switch" /> <el-switch v-model="dynamicTitle" class="drawer-switch" />
</div> </div>
<el-divider /> <el-divider />
<el-button size="mini" type="primary" plain icon="el-icon-document-add" @click="saveSetting">保存配置</el-button> <el-button size="mini" type="primary" plain icon="el-icon-document-add" @click="saveSetting">{{ $t('common.Save_settings') }}</el-button>
<el-button size="mini" plain icon="el-icon-refresh" @click="resetSetting">重置配置</el-button> <el-button size="mini" plain icon="el-icon-refresh" @click="resetSetting">{{ $t('common.Reset_settings') }}</el-button>
</div> </div>
</div> </div>
</template> </template>

View File

@@ -3,14 +3,14 @@
<template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren)&&!item.alwaysShow"> <template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren)&&!item.alwaysShow">
<app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path)"> <app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path)">
<el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}"> <el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}">
<item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="onlyOneChild.meta.title" /> <item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="$t(onlyOneChild.meta.title)" />
</el-menu-item> </el-menu-item>
</app-link> </app-link>
</template> </template>
<el-submenu v-else ref="subMenu" :index="resolvePath(item.path)" popper-append-to-body> <el-submenu v-else ref="subMenu" :index="resolvePath(item.path)" popper-append-to-body>
<template slot="title"> <template slot="title">
<item v-if="item.meta" :icon="item.meta && item.meta.icon" :title="item.meta.title" /> <item v-if="item.meta" :icon="item.meta && item.meta.icon" :title="$t(item.meta.title)" />
</template> </template>
<sidebar-item <sidebar-item
v-for="child in item.children" v-for="child in item.children"

View File

@@ -12,17 +12,17 @@
@click.middle.native="closeSelectedTag(tag)" @click.middle.native="closeSelectedTag(tag)"
@contextmenu.prevent.native="openMenu(tag,$event)" @contextmenu.prevent.native="openMenu(tag,$event)"
> >
{{ tag.title }} {{ $t(tag.title) }}
<span v-if="!tag.meta.affix" class="el-icon-close" @click.prevent.stop="closeSelectedTag(tag)" /> <span v-if="!tag.meta.affix" class="el-icon-close" @click.prevent.stop="closeSelectedTag(tag)" />
</router-link> </router-link>
</scroll-pane> </scroll-pane>
<ul v-show="visible" :style="{left:left+'px',top:top+'px'}" class="contextmenu"> <ul v-show="visible" :style="{left:left+'px',top:top+'px'}" class="contextmenu">
<li @click="refreshSelectedTag(selectedTag)">刷新</li> <li @click="refreshSelectedTag(selectedTag)">{{ $t('common.Refresh') }}</li>
<li v-if="!(selectedTag.meta&&selectedTag.meta.affix)" @click="closeSelectedTag(selectedTag)">关闭</li> <li v-if="!(selectedTag.meta&&selectedTag.meta.affix)" @click="closeSelectedTag(selectedTag)">{{ $t('common.Closes') }}</li>
<li v-if="!isFirstView()" @click="closeLeftTags()">关闭左侧</li> <li v-if="!isFirstView()" @click="closeLeftTags()">{{ $t('common.Closes_l') }}</li>
<li v-if="!isLastView()" @click="closeRightTags">关闭右侧</li> <li v-if="!isLastView()" @click="closeRightTags">{{ $t('common.Closes_r') }}</li>
<li @click="closeOthersTags">关闭其他</li> <li @click="closeOthersTags">{{ $t('common.Closes_o') }}</li>
<li @click="closeAllTags(selectedTag)">关闭全部</li> <li @click="closeAllTags(selectedTag)">{{ $t('common.Closes_a') }}</li>
</ul> </ul>
</div> </div>
</template> </template>

View File

@@ -47,6 +47,8 @@ import { addDateRange, handleTree, parseTime, resetForm, selectDictLabel, select
import { getValueByCode } from '@/views/system/param/param' import { getValueByCode } from '@/views/system/param/param'
import VueBus from 'vue-bus' import VueBus from 'vue-bus'
// 引入i18
import i18n from './i18n'
LogicFlow.use(Menu) LogicFlow.use(Menu)
@@ -77,11 +79,18 @@ Vue.use(Element, {
size: 'mini' // set element-ui default size size: 'mini' // set element-ui default size
}) })
Vue.prototype.$langPre = {
computedProp(suffix) {
return localStorage.getItem('lang') + '_' + suffix
}
}
Vue.config.productionTip = false Vue.config.productionTip = false
new Vue({ new Vue({
el: '#app', el: '#app',
router, router,
store, store,
i18n,
render: h => h(App) render: h => h(App)
}) })

View File

@@ -5,6 +5,7 @@ import 'nprogress/nprogress.css' // progress bar style
import { getToken } from '@/utils/auth' // getToken from cookie import { getToken } from '@/utils/auth' // getToken from cookie
import { buildMenus } from '@/api/system/menu' import { buildMenus } from '@/api/system/menu'
import { filterAsyncRouter } from '@/store/modules/permission' import { filterAsyncRouter } from '@/store/modules/permission'
import i18n from '@/i18n'
NProgress.configure({ showSpinner: false })// NProgress Configuration NProgress.configure({ showSpinner: false })// NProgress Configuration
@@ -13,7 +14,7 @@ const whiteList = ['/login', '/expand']// no redirect whitelist
router.beforeEach((to, from, next) => { router.beforeEach((to, from, next) => {
if (to.meta.title) { if (to.meta.title) {
// document.title = to.meta.title + ' - ' + Config.title // document.title = to.meta.title + ' - ' + Config.title
document.title = to.meta.title document.title = i18n.t(to.meta.title)
} }
NProgress.start() NProgress.start()
if (getToken()) { if (getToken()) {

View File

@@ -1,6 +1,7 @@
import Vue from 'vue' import Vue from 'vue'
import Router from 'vue-router' import Router from 'vue-router'
import Layout from '../layout/index' import Layout from '../layout/index'
import i18n from '@/i18n'
Vue.use(Router) Vue.use(Router)
@@ -46,7 +47,7 @@ export const constantRouterMap = [
path: 'dashboard', path: 'dashboard',
component: (resolve) => require(['@/views/monitor/server/index'], resolve), component: (resolve) => require(['@/views/monitor/server/index'], resolve),
name: 'Dashboard', name: 'Dashboard',
meta: { title: '首页', icon: 'index', affix: true, noCache: true } meta: { title: i18n.t('common.home'), icon: 'index', affix: true, noCache: true }
} }
] ]
}, },
@@ -65,8 +66,8 @@ export const constantRouterMap = [
{ {
path: 'center', path: 'center',
component: (resolve) => require(['@/views/system/user/center'], resolve), component: (resolve) => require(['@/views/system/user/center'], resolve),
name: '个人中心', name: i18n.t('common.Personal_center'),
meta: { title: '个人中心' } meta: { title: i18n.t('common.Personal_center') }
} }
] ]
} }

View File

@@ -18,10 +18,12 @@ const service = axios.create({
// request拦截器 // request拦截器
service.interceptors.request.use( service.interceptors.request.use(
config => { config => {
const lang = localStorage.getItem('lang')
if (getToken()) { if (getToken()) {
config.headers['Authorization'] = getToken() ? 'Bearer ' + getToken() : undefined // 让每个请求携带自定义token 请根据实际情况自行修改 config.headers['Authorization'] = getToken() ? 'Bearer ' + getToken() : undefined // 让每个请求携带自定义token 请根据实际情况自行修改
} }
config.headers['Content-Type'] = 'application/json' config.headers['Content-Type'] = 'application/json'
config.headers['Accept-Language'] = lang
return config return config
}, },
error => { error => {

View File

@@ -4,30 +4,46 @@
<h3 class="title"> <h3 class="title">
{{ title }}</h3> {{ title }}</h3>
<el-form-item prop="username"> <el-form-item prop="username">
<el-input v-model="loginForm.username" type="text" auto-complete="off" placeholder="账号"> <el-input v-model="loginForm.username" type="text" auto-complete="off" :placeholder="$t('common.account')">
<svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" /> <svg-icon slot="prefix" icon-class="user" class="el-input__icon input-icon" />
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item prop="password"> <el-form-item prop="password">
<el-input v-model="loginForm.password" type="password" auto-complete="off" placeholder="密码" @keyup.enter.native="handleLogin"> <el-input v-model="loginForm.password" type="password" auto-complete="off" :placeholder="$t('common.password')" @keyup.enter.native="handleLogin">
<svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" /> <svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" />
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-form-item prop="code"> <el-form-item prop="code">
<el-input v-model="loginForm.code" auto-complete="off" placeholder="验证码" style="width: 63%" @keyup.enter.native="handleLogin"> <el-input v-model="loginForm.code" auto-complete="off" :placeholder="$t('common.verification_code')" style="width: 63%" @keyup.enter.native="handleLogin">
<svg-icon slot="prefix" icon-class="validCode" class="el-input__icon input-icon" /> <svg-icon slot="prefix" icon-class="validCode" class="el-input__icon input-icon" />
</el-input> </el-input>
<div class="login-code"> <div class="login-code">
<img :src="codeUrl" @click="getCode"> <img :src="codeUrl" @click="getCode">
</div> </div>
</el-form-item> </el-form-item>
<el-checkbox v-model="loginForm.rememberMe" style="margin:0 0 25px 0;"> <el-row :gutter="20">
记住我 <el-col :span="12">
</el-checkbox> <el-checkbox v-model="loginForm.rememberMe" style="margin:0 0 25px 0;">
{{ $t('common.login_rm') }}
</el-checkbox>
</el-col>
<el-col :span="12">
<el-dropdown style="display: flex; justify-content: right; color: #409EFF;" trigger="click" @command="langChange">
<span class="el-dropdown-link">
{{ language }}
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item divided command="zh">简体中文</el-dropdown-item>
<el-dropdown-item divided command="en">English</el-dropdown-item>
<el-dropdown-item divided command="in">Indonesian</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</el-col>
</el-row>
<el-form-item style="width:100%;"> <el-form-item style="width:100%;">
<el-button :loading="loading" size="medium" type="primary" style="width:100%;" @click.native.prevent="handleLogin"> <el-button :loading="loading" size="medium" type="primary" style="width:100%;" @click.native.prevent="handleLogin">
<span v-if="!loading"> </span> <span v-if="!loading">{{ $t('common.login') }}</span>
<span v-else> 中...</span> <span v-else>{{ $t('common.login_ing') }}</span>
</el-button> </el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@@ -50,6 +66,7 @@ export default {
name: 'Login', name: 'Login',
data() { data() {
return { return {
language: '简体中文',
title: '诺力开发平台', title: '诺力开发平台',
title_param: 'platform', title_param: 'platform',
Background: Background, Background: Background,
@@ -80,6 +97,7 @@ export default {
} }
}, },
created() { created() {
this.setLang(localStorage.getItem('lang'))
this.getValueByCode(this.title_param).then(res => { this.getValueByCode(this.title_param).then(res => {
this.title = res.value this.title = res.value
}) })
@@ -91,6 +109,22 @@ export default {
this.point() this.point()
}, },
methods: { methods: {
// 中英文切换
langChange(command) {
this.$i18n.locale = command
localStorage.setItem('lang', command)
this.setLang(command)
location.reload()
},
setLang(command) {
if (command === 'en') {
this.language = 'English'
} else if (command === 'zh') {
this.language = '简体中文'
} else if (command === 'in') {
this.language = 'Indonesian'
}
},
getCode() { getCode() {
getCodeImg().then(res => { getCodeImg().then(res => {
this.codeUrl = res.img this.codeUrl = res.img
@@ -135,7 +169,7 @@ export default {
this.$store.dispatch('Login', user).then(() => { this.$store.dispatch('Login', user).then(() => {
this.loading = false this.loading = false
window.location.href = this.redirect window.location.href = this.redirect
// if (this.redirect === 'http://localhost:8014/dashboard'){ // if (this.redirect === 'http://localhost:8013/dashboard'){
// window.location.href = this.redirect // window.location.href = this.redirect
// } // }
// this.$router.push({ path: this.redirect || '/' }) // this.$router.push({ path: this.redirect || '/' })
@@ -167,47 +201,47 @@ export default {
</script> </script>
<style rel="stylesheet/scss" lang="scss"> <style rel="stylesheet/scss" lang="scss">
.login { .login {
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
height: 100%; height: 100%;
background-size: cover; background-size: cover;
} }
.title { .title {
margin: 0 auto 30px auto; margin: 0 auto 30px auto;
text-align: center; text-align: center;
color: #707070; color: #707070;
} }
.login-form { .login-form {
border-radius: 6px; border-radius: 6px;
background: #ffffff; background: #ffffff;
width: 385px; width: 385px;
padding: 25px 25px 5px 25px; padding: 25px 25px 5px 25px;
.el-input { .el-input {
height: 38px;
input {
height: 38px;
}
}
.input-icon{
height: 39px;width: 14px;margin-left: 2px;
}
}
.login-tip {
font-size: 13px;
text-align: center;
color: #bfbfbf;
}
.login-code {
width: 33%;
display: inline-block;
height: 38px; height: 38px;
float: right; input {
img{ height: 38px;
cursor: pointer;
vertical-align:middle
} }
} }
.input-icon{
height: 39px;width: 14px;margin-left: 2px;
}
}
.login-tip {
font-size: 13px;
text-align: center;
color: #bfbfbf;
}
.login-code {
width: 33%;
display: inline-block;
height: 38px;
float: right;
img{
cursor: pointer;
vertical-align:middle
}
}
</style> </style>

View File

@@ -1,28 +1,28 @@
<template> <template>
<div v-loading="!show" element-loading-text="数据加载中..." :style="!show ? 'height: 500px' : 'height: 100%'" class="app-container"> <div v-loading="!show" :element-loading-text="$t('common.loading')" :style="!show ? 'height: 500px' : 'height: 100%'" class="app-container">
<div v-if="show"> <div v-if="show">
<el-card class="box-card"> <el-card class="box-card">
<div style="color: #666;font-size: 13px;"> <div style="color: #666;font-size: 13px;">
<svg-icon icon-class="system" style="margin-right: 5px" /> <svg-icon icon-class="system" style="margin-right: 5px" />
<span> <span>
系统{{ data.sys.os }} {{ $t('monitor.sys') }}{{ data.sys.os }}
</span> </span>
<span> <span>
IP{{ data.sys.ip }} IP{{ data.sys.ip }}
</span> </span>
<span> <span>
项目已不间断运行{{ data.sys.day }} {{ $t('monitor.day') }}{{ data.sys.day }}
</span> </span>
<i class="el-icon-refresh" style="margin-left: 40px" @click="init" /> <i class="el-icon-refresh" style="margin-left: 40px" @click="init" />
</div> </div>
</el-card> </el-card>
<el-card class="box-card"> <el-card class="box-card">
<div slot="header" class="clearfix"> <div slot="header" class="clearfix">
<span style="font-weight: bold;color: #666;font-size: 15px">状态</span> <span style="font-weight: bold;color: #666;font-size: 15px">{{ $t('monitor.status') }}</span>
</div> </div>
<div> <div>
<el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px">
<div class="title">CPU使用率</div> <div class="title">{{ $t('monitor.cpu') }}</div>
<el-tooltip placement="top-end"> <el-tooltip placement="top-end">
<div slot="content" style="font-size: 12px;"> <div slot="content" style="font-size: 12px;">
<div style="padding: 3px;"> <div style="padding: 3px;">
@@ -42,20 +42,20 @@
<el-progress type="dashboard" :percentage="parseFloat(data.cpu.used)" /> <el-progress type="dashboard" :percentage="parseFloat(data.cpu.used)" />
</div> </div>
</el-tooltip> </el-tooltip>
<div class="footer">{{ data.cpu.coreNumber }} 核心</div> <div class="footer">{{ data.cpu.coreNumber }} {{ $t('monitor.core') }}</div>
</el-col> </el-col>
<el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px">
<div class="title">内存使用率</div> <div class="title">{{ $t('monitor.memory') }}</div>
<el-tooltip placement="top-end"> <el-tooltip placement="top-end">
<div slot="content" style="font-size: 12px;"> <div slot="content" style="font-size: 12px;">
<div style="padding: 3px;"> <div style="padding: 3px;">
总量{{ data.memory.total }} {{ $t('monitor.tality') }}{{ data.memory.total }}
</div> </div>
<div style="padding: 3px"> <div style="padding: 3px">
已使用{{ data.memory.used }} {{ $t('monitor.used') }}{{ data.memory.used }}
</div> </div>
<div style="padding: 3px"> <div style="padding: 3px">
空闲{{ data.memory.available }} {{ $t('monitor.leisure') }}{{ data.memory.available }}
</div> </div>
</div> </div>
<div class="content"> <div class="content">
@@ -65,17 +65,17 @@
<div class="footer">{{ data.memory.used }} / {{ data.memory.total }}</div> <div class="footer">{{ data.memory.used }} / {{ data.memory.total }}</div>
</el-col> </el-col>
<el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px">
<div class="title">交换区使用率</div> <div class="title">{{ $t('monitor.exchange') }}</div>
<el-tooltip placement="top-end"> <el-tooltip placement="top-end">
<div slot="content" style="font-size: 12px;"> <div slot="content" style="font-size: 12px;">
<div style="padding: 3px;"> <div style="padding: 3px;">
总量{{ data.swap.total }} {{ $t('monitor.tality') }}{{ data.swap.total }}
</div> </div>
<div style="padding: 3px"> <div style="padding: 3px">
已使用{{ data.swap.used }} {{ $t('monitor.used') }}{{ data.swap.used }}
</div> </div>
<div style="padding: 3px"> <div style="padding: 3px">
空闲{{ data.swap.available }} {{ $t('monitor.leisure') }}{{ data.swap.available }}
</div> </div>
</div> </div>
<div class="content"> <div class="content">
@@ -85,15 +85,15 @@
<div class="footer">{{ data.swap.used }} / {{ data.swap.total }}</div> <div class="footer">{{ data.swap.used }} / {{ data.swap.total }}</div>
</el-col> </el-col>
<el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="6" :lg="6" :xl="6" style="margin-bottom: 10px">
<div class="title">磁盘使用率</div> <div class="title">{{ $t('monitor.disk') }}</div>
<div class="content"> <div class="content">
<el-tooltip placement="top-end"> <el-tooltip placement="top-end">
<div slot="content" style="font-size: 12px;"> <div slot="content" style="font-size: 12px;">
<div style="padding: 3px"> <div style="padding: 3px">
总量{{ data.disk.total }} {{ $t('monitor.tality') }}{{ data.disk.total }}
</div> </div>
<div style="padding: 3px"> <div style="padding: 3px">
空闲{{ data.disk.available }} {{ $t('monitor.leisure') }}{{ data.disk.available }}
</div> </div>
</div> </div>
<div class="content"> <div class="content">
@@ -111,7 +111,7 @@
<el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12" style="margin-bottom: 10px">
<el-card class="box-card"> <el-card class="box-card">
<div slot="header" class="clearfix"> <div slot="header" class="clearfix">
<span style="font-weight: bold;color: #666;font-size: 15px">CPU使用率监控</span> <span style="font-weight: bold;color: #666;font-size: 15px">{{ $t('monitor.cpu_monitoring') }}</span>
</div> </div>
<div> <div>
<v-chart :options="cpuInfo" /> <v-chart :options="cpuInfo" />
@@ -121,7 +121,7 @@
<el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12" style="margin-bottom: 10px">
<el-card class="box-card"> <el-card class="box-card">
<div slot="header" class="clearfix"> <div slot="header" class="clearfix">
<span style="font-weight: bold;color: #666;font-size: 15px">内存使用率监控</span> <span style="font-weight: bold;color: #666;font-size: 15px">{{ $t('monitor.memory_monitoring') }}</span>
</div> </div>
<div> <div>
<v-chart :options="memoryInfo" /> <v-chart :options="memoryInfo" />
@@ -251,41 +251,41 @@ export default {
</script> </script>
<style rel="stylesheet/scss" lang="scss" scoped> <style rel="stylesheet/scss" lang="scss" scoped>
::v-deep .box-card { ::v-deep .box-card {
margin-bottom: 5px; margin-bottom: 5px;
span { span {
margin-right: 28px; margin-right: 28px;
}
.el-icon-refresh {
margin-right: 10px;
float: right;
cursor:pointer;
}
} }
.cpu, .memory, .swap, .disk { .el-icon-refresh {
width: 20%; margin-right: 10px;
float: left; float: right;
padding-bottom: 20px; cursor:pointer;
margin-right: 5%;
}
.title {
text-align: center;
font-size: 15px;
font-weight: 500;
color: #999;
margin-bottom: 16px;
}
.footer {
text-align: center;
font-size: 15px;
font-weight: 500;
color: #999;
margin-top: -5px;
margin-bottom: 10px;
}
.content {
text-align: center;
margin-top: 5px;
margin-bottom: 5px;
} }
}
.cpu, .memory, .swap, .disk {
width: 20%;
float: left;
padding-bottom: 20px;
margin-right: 5%;
}
.title {
text-align: center;
font-size: 15px;
font-weight: 500;
color: #999;
margin-bottom: 16px;
}
.footer {
text-align: center;
font-size: 15px;
font-weight: 500;
color: #999;
margin-top: -5px;
margin-bottom: 10px;
}
.content {
text-align: center;
margin-top: 5px;
margin-bottom: 5px;
}
</style> </style>

View File

@@ -8,7 +8,7 @@
v-model="query.blurry" v-model="query.blurry"
clearable clearable
size="mini" size="mini"
placeholder="模糊搜索" :placeholder="$t('menu.placeholder.fuzzy_search')"
style="width: 200px;margin-bottom: 10px" style="width: 200px;margin-bottom: 10px"
class="filter-item" class="filter-item"
@keyup.enter.native="queryBlurry" @keyup.enter.native="queryBlurry"
@@ -16,7 +16,7 @@
<el-select <el-select
v-model="query.system_type" v-model="query.system_type"
style="width: 100px; height: 35px;top: -5px;" style="width: 100px; height: 35px;top: -5px;"
placeholder="所属系统" :placeholder="$t('menu.placeholder.owning_system')"
@change="changetype" @change="changetype"
> >
<el-option <el-option
@@ -81,15 +81,36 @@
</el-form-item> </el-form-item>
<el-form-item v-show="form.type.toString() !== '2' && form.type.toString() !== '1' " label="菜单可见" prop="hidden"> <el-form-item v-show="form.type.toString() !== '2' && form.type.toString() !== '1' " label="菜单可见" prop="hidden">
<el-radio-group v-model="form.hidden" size="mini"> <el-radio-group v-model="form.hidden" size="mini">
<el-radio-button label="true">是</el-radio-button> <el-radio-button label="false">是</el-radio-button>
<el-radio-button label="false">否</el-radio-button> <el-radio-button label="true">否</el-radio-button>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item v-if="form.type.toString() !== '2'" label="菜单标题" prop="title"> <el-form-item v-if="form.type.toString() !== '2'" label="默认标题" prop="title">
<el-input <el-input
v-model="form.title" v-model="form.title"
:style=" form.type.toString() === '0' ? 'width: 450px' : 'width: 190px'" :style=" form.type.toString() === '0' ? 'width: 450px' : 'width: 190px'"
placeholder="菜单标题" placeholder="默认标题"
/>
</el-form-item>
<el-form-item v-if="form.type.toString() !== '2'" label="中文标题" prop="zh_title">
<el-input
v-model="form.zh_title"
:style=" form.type.toString() === '0' ? 'width: 450px' : 'width: 190px'"
placeholder="中文标题"
/>
</el-form-item>
<el-form-item v-if="form.type.toString() !== '2'" label="英文标题" prop="en_title">
<el-input
v-model="form.en_title"
:style=" form.type.toString() === '0' ? 'width: 450px' : 'width: 190px'"
placeholder="英文标题"
/>
</el-form-item>
<el-form-item v-if="form.type.toString() !== '2'" label="印尼标题" prop="in_title">
<el-input
v-model="form.in_title"
:style=" form.type.toString() === '0' ? 'width: 450px' : 'width: 190px'"
placeholder="印尼标题"
/> />
</el-form-item> </el-form-item>
<el-form-item v-if="form.type.toString() === '2'" label="按钮名称" prop="title"> <el-form-item v-if="form.type.toString() === '2'" label="按钮名称" prop="title">
@@ -149,46 +170,46 @@
@selection-change="crud.selectionChangeHandler" @selection-change="crud.selectionChangeHandler"
> >
<el-table-column type="selection" width="55" /> <el-table-column type="selection" width="55" />
<el-table-column label="菜单标题" prop="title" :min-width="100" /> <el-table-column :label="$t('menu.table_title.menu_title')" :prop="$langPre.computedProp('title')" :min-width="flexWidth($langPre.computedProp('title'),crud.data,$t('menu.table_title.menu_title'))" />
<el-table-column label="所属系统" prop="system_type" :min-width="flexWidth('system_type',crud.data,'所属系统')"> <el-table-column :label="$t('menu.table_title.system')" prop="system_type" :min-width="flexWidth('system_type',crud.data,$t('menu.table_title.system'))">
<template slot-scope="scope"> <template slot-scope="scope">
{{ dict.label.system_type[scope.row.system_type] }} : {{ scope.row.system_type }} {{ dict.label.system_type[scope.row.system_type] }} : {{scope.row.system_type}}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="icon" label="图标" align="center" :min-width="flexWidth('icon',crud.data,'图标')"> <el-table-column prop="icon" :label="$t('menu.table_title.icon')" align="center" :min-width="flexWidth('icon',crud.data, $t('menu.table_title.system'))">
<template slot-scope="scope"> <template slot-scope="scope">
<svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" /> <svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="menu_sort" align="center" label="排序" :min-width="flexWidth('menu_sort',crud.data,'排序')"> <el-table-column prop="menu_sort" align="center" :label="$t('menu.table_title.sort')" :min-width="flexWidth('menu_sort',crud.data,$t('menu.table_title.sort'))">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.menu_sort }} {{ scope.row.menu_sort }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="permission" label="权限标识" :min-width="flexWidth('permission',crud.data,'权限标识')" /> <el-table-column prop="permission" :label="$t('menu.table_title.permission_ident')" :min-width="flexWidth('permission',crud.data,$t('menu.table_title.permission_ident'))" />
<el-table-column prop="component" label="组件路径" min-width="120" /> <el-table-column prop="component" :label="$t('menu.table_title.path')" min-width="120" />
<el-table-column prop="iframe" label="外链" :formatter="crud.formatIsOrNot" :min-width="flexWidth('iframe',crud.data,'外链')"> <el-table-column prop="iframe" :label="$t('menu.table_title.outside_chain')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('iframe',crud.data,$t('menu.table_title.outside_chain'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.iframe">是</span> <span v-if="scope.row.iframe">是</span>
<span v-else>否</span> <span v-else>否</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="cache" label="缓存" :formatter="crud.formatIsOrNot" :min-width="flexWidth('cache',crud.data,'缓存')"> <el-table-column prop="cache" :label="$t('menu.table_title.cache')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('cache',crud.data,$t('menu.table_title.cache'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.cache">是</span> <span v-if="scope.row.cache">是</span>
<span v-else>否</span> <span v-else>否</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="hidden" label="可见" :formatter="crud.formatIsOrNot" :min-width="flexWidth('hidden',crud.data,'可见')"> <el-table-column prop="hidden" :label="$t('menu.table_title.visible')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('hidden',crud.data,$t('menu.table_title.visible'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.hidden">否</span> <span v-if="scope.row.hidden">否</span>
<span v-else>是</span> <span v-else>是</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="create_time" label="创建日期" :min-width="flexWidth('create_time',crud.data,'创建日期')" /> <el-table-column prop="create_time" :label="$t('menu.table_title.create_time')" :min-width="flexWidth('create_time',crud.data,$t('menu.table_title.create_time'))" />
<el-table-column <el-table-column
v-permission="['admin','menu:edit','menu:del']" v-permission="['admin','menu:edit','menu:del']"
label="操作" :label="$t('common.Operate')"
width="130px" width="130px"
align="center" align="center"
fixed="right" fixed="right"
@@ -197,7 +218,7 @@
<udOperation <udOperation
:data="scope.row" :data="scope.row"
:permission="permission" :permission="permission"
msg="确定删除吗,如果存在下级节点则一并删除此操作不能撤销" :msg="$t('menu.msg.delete_msg')"
/> />
</template> </template>
</el-table-column> </el-table-column>
@@ -222,6 +243,9 @@ import Dict from '../../../components/Dict/Dict'
const defaultForm = { const defaultForm = {
menu_id: null, menu_id: null,
title: null, title: null,
en_title: null,
in_title: null,
zh_title: null,
menu_sort: 999, menu_sort: 999,
path: null, path: null,
system_type: null, system_type: null,
@@ -233,15 +257,15 @@ const defaultForm = {
pid: 0, pid: 0,
icon: null, icon: null,
cache: false, cache: false,
hidden: true, hidden: false,
type: 0, type: 2,
permission: null permission: null
} }
export default { export default {
name: 'Menu', name: 'Menu',
components: { Treeselect, IconSelect, crudOperation, rrOperation, udOperation, DateRangePicker }, components: { Treeselect, IconSelect, crudOperation, rrOperation, udOperation, DateRangePicker },
cruds() { cruds() {
return CRUD({ title: '菜单', idField: 'menu_id', url: 'api/sysMenu', crudMethod: { ...crudMenu }, sort: 'menu_sort,asc'}) return CRUD({ title: '菜单', idField: 'menu_id', url: 'api/sysMenu', crudMethod: { ...crudMenu }})
}, },
mixins: [presenter(), header(), form(defaultForm), crud()], mixins: [presenter(), header(), form(defaultForm), crud()],
dicts: ['system_type'], dicts: ['system_type'],
@@ -259,6 +283,15 @@ export default {
title: [ title: [
{ required: true, message: '请输入标题', trigger: 'blur' } { required: true, message: '请输入标题', trigger: 'blur' }
], ],
zh_title: [
{ required: true, message: '请输入标题', trigger: 'blur' }
],
en_title: [
{ required: true, message: '请输入标题', trigger: 'blur' }
],
in_title: [
{ required: true, message: '请输入标题', trigger: 'blur' }
],
path: [ path: [
{ required: true, message: '请输入地址', trigger: 'blur' } { required: true, message: '请输入地址', trigger: 'blur' }
] ]

View File

@@ -13,22 +13,22 @@
width="500px" width="500px"
> >
<el-form ref="form" :model="form" :rules="rules" size="mini" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" size="mini" label-width="80px">
<el-form-item label="编码" prop="code"> <el-form-item :label="$t('SysParam.table.code')" prop="code">
<el-input v-model="form.code" style="width: 370px;" /> <el-input v-model="form.code" style="width: 370px;" />
</el-form-item> </el-form-item>
<el-form-item label="名字" prop="name"> <el-form-item :label="$t('SysParam.table.name')" prop="name">
<el-input v-model="form.name" style="width: 370px;" /> <el-input v-model="form.name" style="width: 370px;" />
</el-form-item> </el-form-item>
<el-form-item label="" prop="value"> <el-form-item :label="$t('SysParam.table.values')" prop="value">
<el-input v-model="form.value" style="width: 370px;" /> <el-input v-model="form.value" style="width: 370px;" />
</el-form-item> </el-form-item>
<el-form-item label="备注" prop="description"> <el-form-item :label="$t('SysParam.table.description')" prop="description">
<el-input v-model="form.remark" style="width: 380px;" rows="5" type="textarea" /> <el-input v-model="form.remark" style="width: 380px;" rows="5" type="textarea" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="text" @click="crud.cancelCU">取消</el-button> <el-button type="text" @click="crud.cancelCU">{{ $t('common.Cancel') }}</el-button>
<el-button :loading="crud.cu === 2" type="primary" @click="crud.submitCU">确认</el-button> <el-button :loading="crud.cu === 2" type="primary" @click="crud.submitCU">{{ $t('common.Confirm') }}</el-button>
</div> </div>
</el-dialog> </el-dialog>
<!--表格渲染--> <!--表格渲染-->
@@ -42,11 +42,11 @@
> >
<el-table-column type="selection" width="55" /> <el-table-column type="selection" width="55" />
<el-table-column v-if="false" prop="id" label="id" /> <el-table-column v-if="false" prop="id" label="id" />
<el-table-column prop="code" label="编码" min-width="130" show-overflow-tooltip /> <el-table-column prop="code" :label="$t('SysParam.table.code')" min-width="130" show-overflow-tooltip />
<el-table-column prop="name" label="名称" min-width="120" show-overflow-tooltip /> <el-table-column :prop="$langPre.computedProp('name')" :label="$t('SysParam.table.name')" min-width="120" show-overflow-tooltip />
<el-table-column prop="value" label="" min-width="270" show-overflow-tooltip /> <el-table-column prop="value" :label="$t('SysParam.table.values')" min-width="270" show-overflow-tooltip />
<el-table-column prop="remark" label="备注" /> <el-table-column prop="remark" :label="$t('SysParam.table.description')" />
<el-table-column v-permission="['admin','param:edit','param:del']" label="操作" width="150px" align="center"> <el-table-column v-permission="['admin','param:edit','param:del']" :label="$t('common.Operate')" width="150px" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<udOperation <udOperation
:data="scope.row" :data="scope.row"
@@ -82,7 +82,7 @@ export default {
components: { pagination, crudOperation, rrOperation, udOperation }, components: { pagination, crudOperation, rrOperation, udOperation },
mixins: [presenter(), header(), form(defaultForm), crud()], mixins: [presenter(), header(), form(defaultForm), crud()],
cruds() { cruds() {
return CRUD({ title: '系统参数', url: 'api/param', idField: 'id', sort: 'id,desc', crudMethod: { ...crudParam }, return CRUD({ title: 'menu.SystemParam', url: 'api/param', idField: 'id', sort: 'id,desc', crudMethod: { ...crudParam },
optShow: { optShow: {
add: true, add: true,
edit: true, edit: true,
@@ -102,23 +102,27 @@ export default {
rules: { rules: {
id: [ id: [
{ required: true, message: '不能为空', trigger: 'blur' } { required: true, message: this.$t('SysParam.rules.NotNull'), trigger: 'blur' }
], ],
code: [ code: [
{ required: true, message: '不能为空', trigger: 'blur' } { required: true, message: this.$t('SysParam.rules.NotNull'), trigger: 'blur' }
], ],
name: [ name: [
{ required: true, message: '不能为空', trigger: 'blur' } { required: true, message: this.$t('SysParam.rules.NotNull'), trigger: 'blur' }
], ],
value: [ value: [
{ required: true, message: '不能为空', trigger: 'blur' } { required: true, message: this.$t('SysParam.rules.NotNull'), trigger: 'blur' }
],
create_time: [
{ required: true, message: '不能为空', trigger: 'blur' }
] ]
} }
} }
}, },
// computed: {
// computedProp() {
// // 在计算属性中拼接属性名
// console.log(localStorage.getItem('lang'))
// return localStorage.getItem('lang') + '_name'
// }
// },
created() { created() {
// this.webSocket() // this.webSocket()
}, },

View File

@@ -4,7 +4,7 @@
<el-col :xs="24" :sm="24" :md="8" :lg="6" :xl="5" style="margin-bottom: 10px"> <el-col :xs="24" :sm="24" :md="8" :lg="6" :xl="5" style="margin-bottom: 10px">
<el-card class="box-card"> <el-card class="box-card">
<div slot="header" class="clearfix"> <div slot="header" class="clearfix">
<span>个人信息</span> <span>{{ $t('common.Personal_information') }}</span>
</div> </div>
<div> <div>
<div style="text-align: center"> <div style="text-align: center">
@@ -19,15 +19,15 @@
</div> </div>
</div> </div>
<ul class="user-info"> <ul class="user-info">
<li><div style="height: 100%"><svg-icon icon-class="login" /> 登录账号<div class="user-right">{{ user.username }}</div></div></li> <li><div style="height: 100%"><svg-icon icon-class="login" /> {{ $t('common.account') }}<div class="user-right">{{ user.username }}</div></div></li>
<li><svg-icon icon-class="user1" /> 用户姓名 <div class="user-right">{{ user.person_name }}</div></li> <li><svg-icon icon-class="user1" /> {{ $t('common.username') }} <div class="user-right">{{ user.person_name }}</div></li>
<!-- <li><svg-icon icon-class="dept" /> 所属部门 <div class="user-right"> {{ user.dept.name }}</div></li>--> <!-- <li><svg-icon icon-class="dept" /> 所属部门 <div class="user-right"> {{ user.dept.name }}</div></li>-->
<li><svg-icon icon-class="phone" /> 手机号码 <div class="user-right">{{ user.phone }}</div></li> <li><svg-icon icon-class="phone" /> {{ $t('common.phone') }} <div class="user-right">{{ user.phone }}</div></li>
<li><svg-icon icon-class="email" /> 用户邮箱 <div class="user-right">{{ user.email }}</div></li> <li><svg-icon icon-class="email" /> {{ $t('common.email') }} <div class="user-right">{{ user.email }}</div></li>
<li> <li>
<svg-icon icon-class="anq" /> 安全设置 <svg-icon icon-class="anq" /> {{ $t('common.Security_settings') }}
<div class="user-right"> <div class="user-right">
<a @click="$refs.pass.dialog = true">修改密码</a> <a @click="$refs.pass.dialog = true">{{ $t('common.Change_password') }}</a>
<!-- <a @click="$refs.email.dialog = true">修改邮箱</a>--> <!-- <a @click="$refs.email.dialog = true">修改邮箱</a>-->
</div> </div>
</li> </li>
@@ -39,35 +39,35 @@
<!-- 用户资料 --> <!-- 用户资料 -->
<el-card class="box-card"> <el-card class="box-card">
<el-tabs v-model="activeName" @tab-click="handleClick"> <el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="用户资料" name="first"> <el-tab-pane :label="$t('common.User_information')" name="first">
<el-form ref="form" :model="form" :rules="rules" style="margin-top: 10px;" size="mini" label-width="65px"> <el-form ref="form" :model="form" :rules="rules" style="margin-top: 10px;" size="mini" label-width="65px">
<el-form-item label="姓名" prop="person_name"> <el-form-item :label="$t('common.name')" prop="person_name">
<el-input v-model="form.person_name" style="width: 35%" /> <el-input v-model="form.person_name" style="width: 35%" />
<span style="color: #C0C0C0;margin-left: 10px;">用户姓名不作为登录使用</span> <span style="color: #C0C0C0;margin-left: 10px;">{{ $t('common.Tip3') }}</span>
</el-form-item> </el-form-item>
<el-form-item label="手机号" prop="phone"> <el-form-item :label="$t('common.phone2')" prop="phone">
<el-input v-model="form.phone" style="width: 35%;" /> <el-input v-model="form.phone" style="width: 35%;" />
<span style="color: #C0C0C0;margin-left: 10px;">手机号码不能重复</span> <span style="color: #C0C0C0;margin-left: 10px;">{{ $t('common.Tip4') }}</span>
</el-form-item> </el-form-item>
<el-form-item label="性别"> <el-form-item :label="$t('common.sex')">
<el-radio-group v-model="form.gender" style="width: 178px"> <el-radio-group v-model="form.gender" style="width: 178px">
<el-radio label="男"></el-radio> <el-radio :label="$t('common.sex_male')">{{ $t('common.sex_male') }}</el-radio>
<el-radio label="女"></el-radio> <el-radio :label="$t('common.sex_female')">{{ $t('common.sex_female') }}</el-radio>
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item label=""> <el-form-item label="">
<el-button :loading="saveLoading" size="mini" type="primary" @click="doSubmit">保存配置</el-button> <el-button :loading="saveLoading" size="mini" type="primary" @click="doSubmit">{{ $t('common.Save_settings') }}</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
</el-tab-pane> </el-tab-pane>
<!-- 操作日志 --> <!-- 操作日志 -->
<el-tab-pane label="操作日志" name="second"> <el-tab-pane :label="$t('common.Operation_log')" name="second">
<el-table v-loading="loading" :data="data" style="width: 100%;"> <el-table v-loading="loading" :data="data" style="width: 100%;">
<el-table-column prop="description" label="行为" min-width="130" show-overflow-tooltip /> <el-table-column prop="description" :label="$t('common.action')" min-width="130" show-overflow-tooltip />
<el-table-column prop="request_ip" label="IP" /> <el-table-column prop="request_ip" label="IP" />
<el-table-column show-overflow-tooltip prop="address" label="IP来源" /> <el-table-column show-overflow-tooltip prop="address" :label="$t('common.IP_source')" />
<el-table-column prop="browser" label="浏览器" min-width="120" show-overflow-tooltip /> <el-table-column prop="browser" :label="$t('common.Browser')" min-width="120" show-overflow-tooltip />
<el-table-column prop="time" label="请求耗时" align="center"> <el-table-column prop="time" :label="$t('common.Request_time')" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.time <= 300">{{ scope.row.time }}ms</el-tag> <el-tag v-if="scope.row.time <= 300">{{ scope.row.time }}ms</el-tag>
<el-tag v-else-if="scope.row.time <= 1000" type="warning">{{ scope.row.time }}ms</el-tag> <el-tag v-else-if="scope.row.time <= 1000" type="warning">{{ scope.row.time }}ms</el-tag>
@@ -80,7 +80,8 @@
show-overflow-tooltip show-overflow-tooltip
> >
<template slot="header"> <template slot="header">
<div style="display:inline-block;float: right;cursor: pointer" @click="init">创建日期<i class="el-icon-refresh" style="margin-left: 40px" /></div> <div style="display:inline-block;float: right;cursor: pointer" @click="init">
{{ $t('common.Creation_date') }} <i class="el-icon-refresh" style="margin-left: 40px" /></div>
</template> </template>
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ parseTime(scope.row.create_time) }}</span> <span>{{ parseTime(scope.row.create_time) }}</span>
@@ -126,9 +127,9 @@ export default {
// 自定义验证 // 自定义验证
const validPhone = (rule, value, callback) => { const validPhone = (rule, value, callback) => {
if (!value) { if (!value) {
callback(new Error('请输入电话号码')) callback(new Error(this.$t('common.Tip5')))
} else if (!isvalidPhone(value)) { } else if (!isvalidPhone(value)) {
callback(new Error('请输入正确的11位手机号码')) callback(new Error(this.$t('common.Tip6')))
} else { } else {
callback() callback()
} }
@@ -202,24 +203,24 @@ export default {
</script> </script>
<style rel="stylesheet/scss" lang="scss"> <style rel="stylesheet/scss" lang="scss">
.avatar { .avatar {
width: 120px; width: 120px;
height: 120px; height: 120px;
border-radius: 50%; border-radius: 50%;
}
.user-info {
padding-left: 0;
list-style: none;
li{
border-bottom: 1px solid #F0F3F4;
padding: 11px 0;
font-size: 13px;
} }
.user-info { .user-right {
padding-left: 0; float: right;
list-style: none; a{
li{ color: #317EF3;
border-bottom: 1px solid #F0F3F4;
padding: 11px 0;
font-size: 13px;
}
.user-right {
float: right;
a{
color: #317EF3;
}
} }
} }
}
</style> </style>

View File

@@ -1,20 +1,20 @@
<template> <template>
<div style="display: inline-block"> <div style="display: inline-block">
<el-dialog :visible.sync="dialog" :close-on-click-modal="false" :before-close="cancel" :title="title" append-to-body width="500px" @close="cancel"> <el-dialog :visible.sync="dialog" :close-on-click-modal="false" :before-close="cancel" :title="title" append-to-body width="500px" @close="cancel">
<el-form ref="form" :model="form" :rules="rules" size="mini" label-width="88px"> <el-form ref="form" :model="form" :rules="rules" size="mini" label-width="30%">
<el-form-item label="旧密码" prop="oldPass"> <el-form-item :label="$t('common.Old_password')" prop="oldPass">
<el-input v-model="form.oldPass" type="password" auto-complete="on" style="width: 370px;" /> <el-input v-model="form.oldPass" type="password" auto-complete="on" style="width: 70%;" />
</el-form-item> </el-form-item>
<el-form-item label="新密码" prop="newPass"> <el-form-item :label="$t('common.New_password')" prop="newPass">
<el-input v-model="form.newPass" type="password" auto-complete="on" style="width: 370px;" /> <el-input v-model="form.newPass" type="password" auto-complete="on" style="width: 70%;" />
</el-form-item> </el-form-item>
<el-form-item label="确认密码" prop="confirmPass"> <el-form-item :label="$t('common.Verify_password')" prop="confirmPass">
<el-input v-model="form.confirmPass" type="password" auto-complete="on" style="width: 370px;" /> <el-input v-model="form.confirmPass" type="password" auto-complete="on" style="width: 70%;" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button type="text" @click="cancel">取消</el-button> <el-button type="text" @click="cancel">{{ $t('common.Cancel') }}</el-button>
<el-button :loading="loading" type="primary" @click="doSubmit">确认</el-button> <el-button :loading="loading" type="primary" @click="doSubmit">{{ $t('common.Confirm') }}</el-button>
</div> </div>
</el-dialog> </el-dialog>
</div> </div>
@@ -23,28 +23,29 @@
<script> <script>
import store from '@/store' import store from '@/store'
import { updatePass } from '@/views/system/user/user' import { updatePass } from '@/views/system/user/user'
import i18n from '@/i18n'
export default { export default {
data() { data() {
const confirmPass = (rule, value, callback) => { const confirmPass = (rule, value, callback) => {
if (value) { if (value) {
if (this.form.newPass !== value) { if (this.form.newPass !== value) {
callback(new Error('两次输入的密码不一致')) callback(new Error(this.$t('common.Tip8')))
} else { } else {
callback() callback()
} }
} else { } else {
callback(new Error('请再次输入密码')) callback(new Error(i18n.t('common.Tip9')))
} }
} }
return { return {
loading: false, dialog: false, title: '修改密码', form: { oldPass: '', newPass: '', confirmPass: '' }, loading: false, dialog: false, title: i18n.t('common.Change_password'), form: { oldPass: '', newPass: '', confirmPass: '' },
rules: { rules: {
oldPass: [ oldPass: [
{ required: true, message: '请输入旧密码', trigger: 'blur' } { required: true, message: i18n.t('common.Tip10'), trigger: 'blur' }
], ],
newPass: [ newPass: [
{ required: true, message: '请输入新密码', trigger: 'blur' }, { required: true, message: i18n.t('common.Tip11'), trigger: 'blur' },
{ min: 6, max: 20, message: '长度在 6 到 20 个字符', trigger: 'blur' } { min: 6, max: 20, message: i18n.t('common.Tip12'), trigger: 'blur' }
], ],
confirmPass: [ confirmPass: [
{ required: true, validator: confirmPass, trigger: 'blur' } { required: true, validator: confirmPass, trigger: 'blur' }

View File

@@ -1,6 +1,7 @@
export default { export default {
'lang': 'English', 'lang': 'English',
'common': { 'common': {
'home': 'Dashboard',
'Layout_setting': 'Layout Setting', 'Layout_setting': 'Layout Setting',
'Personal_center': 'Personal Center', 'Personal_center': 'Personal Center',
'Log_out': 'Log Out', 'Log_out': 'Log Out',
@@ -80,10 +81,6 @@ export default {
'Tip14': 'WebSocket connection error', 'Tip14': 'WebSocket connection error',
'loading': 'loading...' 'loading': 'loading...'
}, },
// 菜单
'menu': {
'home': 'Dashboard'
},
'WorkOrder': { 'WorkOrder': {
'form': { 'form': {
'WorkOrderCode': 'WorkOrderCode' 'WorkOrderCode': 'WorkOrderCode'
@@ -92,17 +89,6 @@ export default {
'WorkOrderCode': 'Please enter the code' 'WorkOrderCode': 'Please enter the code'
} }
}, },
'SysParam': {
'table': {
'code': 'code',
'name': 'name',
'values': 'value',
'description': 'remark'
},
'rules': {
'NotNull': 'Cannot be empty'
}
},
'monitor': { 'monitor': {
'sys': 'System', 'sys': 'System',
'day': 'Running Day', 'day': 'Running Day',

View File

@@ -1,6 +1,7 @@
export default { export default {
'lang': 'in', 'lang': 'in',
'common': { 'common': {
'home': 'rumah', // 首页
'Layout_setting': 'Pengaturan Bentangan', 'Layout_setting': 'Pengaturan Bentangan',
'Personal_center': 'Pusat Pribadi', 'Personal_center': 'Pusat Pribadi',
'Log_out': 'Log Out', 'Log_out': 'Log Out',
@@ -80,10 +81,6 @@ export default {
'Tip14': 'Koneksi WebSocket error', 'Tip14': 'Koneksi WebSocket error',
'loading': 'Memuatkan Data...' 'loading': 'Memuatkan Data...'
}, },
// 菜单
'menu': {
'home': 'rumah' // 首页
},
'WorkOrder': { 'WorkOrder': {
'form': { 'form': {
'WorkOrderCode': 'Kode Perintah Kerja' 'WorkOrderCode': 'Kode Perintah Kerja'
@@ -92,17 +89,6 @@ export default {
'WorkOrderCode': 'Silakan masukkan kode perintah kerja' 'WorkOrderCode': 'Silakan masukkan kode perintah kerja'
} }
}, },
'SysParam': {
'table': {
'code': 'kode',
'name': 'nama',
'values': 'nilai',
'description': 'Catatan'
},
'rules': {
'NotNull': 'Tidak dapat kosong'
}
},
'monitor': { 'monitor': {
'sys': 'Sistem', 'sys': 'Sistem',
'day': 'Proyek ini telah berjalan terus menerus', 'day': 'Proyek ini telah berjalan terus menerus',

View File

@@ -1,6 +1,23 @@
export default { export default {
'placeholder': { 'menu': {
'fuzzy_search': 'fuzzy search', 'placeholder': {
'owning_system': 'system' 'fuzzy_search': 'fuzzy search',
'owning_system': 'system'
},
'table_title': {
'menu_title': 'title',
'system': 'system',
'icon': 'icon',
'sort': 'sort',
'permission_ident': 'permission mark',
'path': 'path',
'outside_chain': 'out chain',
'cache': 'cache',
'visible': 'visible',
'create_time': 'create time'
},
'msg': {
'delete_msg': 'Are you sure to delete it? If there are subordinate nodes, they will be deleted together. This operation cannot be undone!'
}
} }
} }

View File

@@ -1,6 +1,23 @@
export default { export default {
'placeholder': { 'menu': {
'fuzzy_search': 'pencarian kabur', 'placeholder': {
'owning_system': 'sistem terkait' 'fuzzy_search': 'pencarian kabur',
'owning_system': 'sistem terkait'
},
'table_title': {
'menu_title': 'title',
'system': 'sistem',
'icon': 'ikon',
'sort': 'sort',
'permission_ident': 'otoritas',
'path': 'assembly',
'outside_chain': 'rantai luar',
'cache': 'cache',
'visible': 'terlihat',
'create_time': 'tarikh penciptaan'
},
'msg': {
'delete_msg': 'Apakah Anda yakin untuk menghapusnya? Jika ada nod subordinat, mereka akan dihapus bersama. Operasi ini tidak dapat dibatalkan!'
}
} }
} }

View File

@@ -1,6 +1,23 @@
export default { export default {
'placeholder': { 'menu': {
'fuzzy_search': '模糊搜索', 'placeholder': {
'owning_system': '所属系统' 'fuzzy_search': '模糊搜索',
'owning_system': '所属系统'
},
'table_title': {
'menu_title': '菜单标题',
'system': '所属系统',
'icon': '图标',
'sort': '排序',
'permission_ident': '权限标识',
'path': '组件路径',
'outside_chain': '外链',
'cache': '缓存',
'visible': '可见',
'create_time': '创建日期'
},
'msg': {
'delete_msg': '确定删除吗,如果存在下级节点则一并删除,此操作不能撤销!'
}
} }
} }

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': 'code',
'name': 'name',
'values': 'value',
'description': 'remark'
},
'rules': {
'NotNull': 'Cannot be empty'
}
}
}

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': 'kode',
'name': 'nama',
'values': 'nilai',
'description': 'Catatan'
},
'rules': {
'NotNull': 'Tidak dapat kosong'
}
}
}

View File

@@ -0,0 +1,13 @@
export default {
'SysParam': {
'table': {
'code': '编码',
'name': '名称',
'values': '值',
'description': '备注'
},
'rules': {
'NotNull': '不能为空'
}
}
}

View File

@@ -1,6 +1,7 @@
export default { export default {
'lang': 'zh', 'lang': 'zh',
'common': { 'common': {
'home': '首页', // 首页
'Layout_setting': '布局设置', 'Layout_setting': '布局设置',
'Personal_center': '个人中心', 'Personal_center': '个人中心',
'Log_out': '退出登录', 'Log_out': '退出登录',
@@ -80,17 +81,6 @@ export default {
'Tip14': 'WebSocket连接发生错误', 'Tip14': 'WebSocket连接发生错误',
'loading': '数据加载中...' 'loading': '数据加载中...'
}, },
// 菜单
'menu': {
'home': '首页', // 首页
'SystemManagement': '系统管理',
'SystemParam': '系统参数',
'BasicData': '基础数据',
'media': '媒体', // 媒体
'data': '数据', // 数据
'docking': '对接', // 对接
'operator': '当前操作账号:' // 当前操作账号
},
'WorkOrder': { 'WorkOrder': {
'form': { 'form': {
'WorkOrderCode': '工单编码' 'WorkOrderCode': '工单编码'
@@ -99,17 +89,6 @@ export default {
'WorkOrderCode': '请输入工单编码' 'WorkOrderCode': '请输入工单编码'
} }
}, },
'SysParam': {
'table': {
'code': '编码',
'name': '名称',
'values': '值',
'description': '备注'
},
'rules': {
'NotNull': '不能为空'
}
},
'monitor': { 'monitor': {
'sys': '系统', 'sys': '系统',
'day': '项目已不间断运行', 'day': '项目已不间断运行',

View File

@@ -8,7 +8,7 @@
v-model="query.blurry" v-model="query.blurry"
clearable clearable
size="mini" size="mini"
:placeholder="$t('placeholder.fuzzy_search')" :placeholder="$t('menu.placeholder.fuzzy_search')"
style="width: 200px;margin-bottom: 10px" style="width: 200px;margin-bottom: 10px"
class="filter-item" class="filter-item"
@keyup.enter.native="queryBlurry" @keyup.enter.native="queryBlurry"
@@ -16,7 +16,7 @@
<el-select <el-select
v-model="query.system_type" v-model="query.system_type"
style="width: 100px; height: 35px;top: -5px;" style="width: 100px; height: 35px;top: -5px;"
:placeholder="$t('placeholder.owning_system')" :placeholder="$t('menu.placeholder.owning_system')"
@change="changetype" @change="changetype"
> >
<el-option <el-option
@@ -170,46 +170,46 @@
@selection-change="crud.selectionChangeHandler" @selection-change="crud.selectionChangeHandler"
> >
<el-table-column type="selection" width="55" /> <el-table-column type="selection" width="55" />
<el-table-column label="菜单标题" prop="title" :min-width="100" /> <el-table-column :label="$t('menu.table_title.menu_title')" :prop="$langPre.computedProp('title')" :min-width="flexWidth($langPre.computedProp('title'),crud.data,$t('menu.table_title.menu_title'))" />
<el-table-column label="所属系统" prop="system_type" :min-width="flexWidth('system_type',crud.data,'所属系统')"> <el-table-column :label="$t('menu.table_title.system')" prop="system_type" :min-width="flexWidth('system_type',crud.data,$t('menu.table_title.system'))">
<template slot-scope="scope"> <template slot-scope="scope">
{{ dict.label.system_type[scope.row.system_type] }} : {{scope.row.system_type}} {{ dict.label.system_type[scope.row.system_type] }} : {{scope.row.system_type}}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="icon" label="图标" align="center" :min-width="flexWidth('icon',crud.data,'图标')"> <el-table-column prop="icon" :label="$t('menu.table_title.icon')" align="center" :min-width="flexWidth('icon',crud.data, $t('menu.table_title.system'))">
<template slot-scope="scope"> <template slot-scope="scope">
<svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" /> <svg-icon :icon-class="scope.row.icon ? scope.row.icon : ''" />
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="menu_sort" align="center" label="排序" :min-width="flexWidth('menu_sort',crud.data,'排序')"> <el-table-column prop="menu_sort" align="center" :label="$t('menu.table_title.sort')" :min-width="flexWidth('menu_sort',crud.data,$t('menu.table_title.sort'))">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.row.menu_sort }} {{ scope.row.menu_sort }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="permission" label="权限标识" :min-width="flexWidth('permission',crud.data,'权限标识')" /> <el-table-column prop="permission" :label="$t('menu.table_title.permission_ident')" :min-width="flexWidth('permission',crud.data,$t('menu.table_title.permission_ident'))" />
<el-table-column prop="component" label="组件路径" min-width="120" /> <el-table-column prop="component" :label="$t('menu.table_title.path')" min-width="120" />
<el-table-column prop="iframe" label="外链" :formatter="crud.formatIsOrNot" :min-width="flexWidth('iframe',crud.data,'外链')"> <el-table-column prop="iframe" :label="$t('menu.table_title.outside_chain')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('iframe',crud.data,$t('menu.table_title.outside_chain'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.iframe">是</span> <span v-if="scope.row.iframe">是</span>
<span v-else>否</span> <span v-else>否</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="cache" label="缓存" :formatter="crud.formatIsOrNot" :min-width="flexWidth('cache',crud.data,'缓存')"> <el-table-column prop="cache" :label="$t('menu.table_title.cache')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('cache',crud.data,$t('menu.table_title.cache'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.cache">是</span> <span v-if="scope.row.cache">是</span>
<span v-else>否</span> <span v-else>否</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="hidden" label="可见" :formatter="crud.formatIsOrNot" :min-width="flexWidth('hidden',crud.data,'可见')"> <el-table-column prop="hidden" :label="$t('menu.table_title.visible')" :formatter="crud.formatIsOrNot" :min-width="flexWidth('hidden',crud.data,$t('menu.table_title.visible'))">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.hidden">否</span> <span v-if="scope.row.hidden">否</span>
<span v-else>是</span> <span v-else>是</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="create_time" label="创建日期" :min-width="flexWidth('create_time',crud.data,'创建日期')" /> <el-table-column prop="create_time" :label="$t('menu.table_title.create_time')" :min-width="flexWidth('create_time',crud.data,$t('menu.table_title.create_time'))" />
<el-table-column <el-table-column
v-permission="['admin','menu:edit','menu:del']" v-permission="['admin','menu:edit','menu:del']"
label="操作" :label="$t('common.Operate')"
width="130px" width="130px"
align="center" align="center"
fixed="right" fixed="right"
@@ -218,7 +218,7 @@
<udOperation <udOperation
:data="scope.row" :data="scope.row"
:permission="permission" :permission="permission"
msg="确定删除吗,如果存在下级节点则一并删除此操作不能撤销" :msg="$t('menu.msg.delete_msg')"
/> />
</template> </template>
</el-table-column> </el-table-column>