diff --git a/src/assets/images/content/bg.jpg b/src/assets/images/content/bg.jpg new file mode 100644 index 0000000..19fae16 Binary files /dev/null and b/src/assets/images/content/bg.jpg differ diff --git a/src/components/CustomModal/index.vue b/src/components/CustomModal/index.vue new file mode 100644 index 0000000..14d176f --- /dev/null +++ b/src/components/CustomModal/index.vue @@ -0,0 +1,67 @@ + + + diff --git a/src/components/CustomSelect/index.vue b/src/components/CustomSelect/index.vue index d6edb30..b73a36c 100644 --- a/src/components/CustomSelect/index.vue +++ b/src/components/CustomSelect/index.vue @@ -1,5 +1,5 @@ @@ -7,13 +7,13 @@ export default { props: { value: { - type: [String, Number], + type: [String, Number, Array], } }, data() { return { - innerValue: null + innerValue: this.value } }, watch: { diff --git a/src/components/CustomTable/index.vue b/src/components/CustomTable/index.vue new file mode 100644 index 0000000..79915c7 --- /dev/null +++ b/src/components/CustomTable/index.vue @@ -0,0 +1,87 @@ + + + diff --git a/src/components/SearchForm/index.vue b/src/components/SearchForm/index.vue index 8cc4ed7..a46055b 100644 --- a/src/components/SearchForm/index.vue +++ b/src/components/SearchForm/index.vue @@ -1,21 +1,19 @@ @@ -60,8 +58,8 @@ export default { .search-form { height: 50px; padding: 10px; - border-top: 1px solid rgba(12, 235, 201, .3); - border-bottom: 1px solid rgba(12, 235, 201, .3); + border-top: 1px solid rgba(12, 235, 201, 0.3); + border-bottom: 1px solid rgba(12, 235, 201, 0.3); margin-bottom: 18px; } ::v-deep .ant-form-item { @@ -80,10 +78,10 @@ export default { } .search-btn { - img { - width: 16px; - height: 17px; - margin-right: 9px; - } + img { + width: 16px; + height: 17px; + margin-right: 9px; + } } diff --git a/src/components/layouts/TabLayout.vue b/src/components/layouts/TabLayout.vue index 9743031..5652b17 100644 --- a/src/components/layouts/TabLayout.vue +++ b/src/components/layouts/TabLayout.vue @@ -25,7 +25,7 @@ import { CACHE_INCLUDED_ROUTES } from '@/store/mutation-types' import registerApps from "@/qiankun"; - const indexKey = '/dashboard/analysis' + const indexKey = '/station-operation' export default { name: 'TabLayout', diff --git a/src/components/page/GlobalLayout.vue b/src/components/page/GlobalLayout.vue index 96631bd..b109c2d 100644 --- a/src/components/page/GlobalLayout.vue +++ b/src/components/page/GlobalLayout.vue @@ -769,11 +769,4 @@ margin-left: 10px; } } - - - \ No newline at end of file diff --git a/src/components/tools/Breadcrumb.vue b/src/components/tools/Breadcrumb.vue index 3bd067f..95188e1 100644 --- a/src/components/tools/Breadcrumb.vue +++ b/src/components/tools/Breadcrumb.vue @@ -26,7 +26,7 @@ export default { console.log('this.$route.matched', this.$route.matched) this.breadList = [] - this.breadList.push({ name: 'dashboard-analysis', path: '/dashboard/analysis', meta: { title: '首页' } }) + this.breadList.push({ name: 'dashboard-analysis', path: '/station-operation', meta: { title: '首页' } }) this.name = this.$route.name this.$route.matched.forEach((item) => { diff --git a/src/components/tools/Logo.vue b/src/components/tools/Logo.vue index f275de5..6b12b18 100644 --- a/src/components/tools/Logo.vue +++ b/src/components/tools/Logo.vue @@ -1,11 +1,7 @@ diff --git a/src/config/router.config.js b/src/config/router.config.js index 13890e1..a096361 100644 --- a/src/config/router.config.js +++ b/src/config/router.config.js @@ -11,7 +11,7 @@ export const asyncRouterMap = [ name: 'dashboard', component: TabLayout, meta: { title: '首页' }, - redirect: '/dashboard/analysis', + redirect: '/station-operation', children: [ // // dashboard diff --git a/src/main.js b/src/main.js index 2f4af11..acb7379 100644 --- a/src/main.js +++ b/src/main.js @@ -52,6 +52,7 @@ import './style.less' import { rules } from '@/utils/rules' import CustomSelect from '@/components/CustomSelect' +import CustomTable from '@/components/CustomTable' Vue.prototype.rules = rules Vue.config.productionTip = false @@ -67,6 +68,7 @@ Vue.use(vueBus); Vue.use(JeecgComponents); Vue.use(VueAreaLinkage); Vue.component('custom-select', CustomSelect) +Vue.component('custom-table', CustomTable) SSO.init(() => { main() diff --git a/src/mixins/FormMixin.js b/src/mixins/FormMixin.js new file mode 100644 index 0000000..e32bb17 --- /dev/null +++ b/src/mixins/FormMixin.js @@ -0,0 +1,9 @@ +export default { + watch: { + visible(val) { + if(val && this.$refs.form) { + this.$refs.form.resetFields() + } + } + } +} \ No newline at end of file diff --git a/src/mixins/JeecgListMixin.js b/src/mixins/JeecgListMixin.js index b5ecb1a..4b45972 100644 --- a/src/mixins/JeecgListMixin.js +++ b/src/mixins/JeecgListMixin.js @@ -23,7 +23,7 @@ export const JeecgListMixin = { pageSizeOptions: ['10', '20', '30'], showTotal: (total, range) => { const { current, pageSize } = this.ipagination - return `共 ${total} 条记录 第${current} / ${Math.ceil(total / pageSize)} 页` + return `共 ${total} 条记录 第 ${current} / ${Math.ceil(total / pageSize)} 页` }, showQuickJumper: true, showSizeChanger: true, @@ -81,6 +81,8 @@ export const JeecgListMixin = { if (arg === 1) { this.ipagination.current = 1; } + this.onClearSelected() + var params = this.getQueryParams();//查询条件 this.loading = true; getAction(this.url.list, params).then((res) => { diff --git a/src/store/mutation-types.js b/src/store/mutation-types.js index fee0f7f..59c4460 100644 --- a/src/store/mutation-types.js +++ b/src/store/mutation-types.js @@ -16,7 +16,7 @@ export const SYS_BUTTON_AUTH = 'SYS_BUTTON_AUTH' export const ENCRYPTED_STRING = 'ENCRYPTED_STRING' export const ENHANCE_PRE = 'enhance_' export const UI_CACHE_DB_DICT_DATA = 'UI_CACHE_DB_DICT_DATA' -export const INDEX_MAIN_PAGE_PATH = '/dashboard/analysis' +export const INDEX_MAIN_PAGE_PATH = '/station-operation' export const OAUTH2_LOGIN_PAGE_PATH = '/oauth2-app/login' export const TENANT_ID = 'TENANT_ID' export const ONL_AUTH_FIELDS = 'ONL_AUTH_FIELDS' diff --git a/src/style.less b/src/style.less index c0fec19..695ecfc 100644 --- a/src/style.less +++ b/src/style.less @@ -10,9 +10,21 @@ src: url(~@/assets/fonts/BOOKOS.ttf); } +body { + color: #fff; +} + +.ant-layout { + background: url(~@/assets/images/content/bg.jpg) center center no-repeat; + background-size: cover; + height: 100vh; +} + +@modalBg: #022024; + // 卡片样式 .ant-card { - background-color: #061214; + background-color: transparent; .ant-card-body { padding: 0; } @@ -46,10 +58,15 @@ background-color: transparent !important; } } + &.ant-table-row-selected { + td { + background-color: #0d4e5c !important; + } + } } } &-placeholder { - background-color: #061214; + background-color: transparent; border-top: none; border-bottom: none; } @@ -57,13 +74,16 @@ background-color: 0d4e5c; } } + +// 表格下的分页器 .ant-table-pagination { float: none !important; text-align: center; } // 表单样式 -.ant-form { +@antFormSelector: .ant-form; +@{antFormSelector} { &-item { &-label { > label { @@ -71,6 +91,13 @@ } } } + &-horizontal { + @{antFormSelector} { + &-item { + display: flex; + } + } + } } @formInputBgColor: #03353f; @@ -84,6 +111,16 @@ &::placeholder { color: #fff; } + &:focus { + box-shadow: none; + } +} + +// 单选样式 +.ant-radio { + &-wrapper { + color: #fff; + } } // 下拉框样式 @@ -93,21 +130,129 @@ background-color: @formInputBgColor !important; border-color: @formInputBorderColor !important; border-radius: 0; + box-shadow: none !important; &__placeholder { color: #fff !important; } + + &--multiple { + .ant-select-selection__choice { + background: transparent; + color: #fff; + border: 1px solid #0b8c82; + &__remove { + color: #fff !important; + } + } + } } &-dropdown { - background: #03353f; + background-color: transparent; + padding-top: 7px; + + @borderColor: #0da397; + &-content { + border: 1px solid @borderColor; + overflow: visible !important; + &::before { + position: absolute; + top: -6px; + left: 20px; + content: ''; + width: 12px; + height: 12px; + border: 1px solid #0da397; + background: #03353f; + transform: rotate(45deg) skew(14deg, 14deg); + } + } &-menu { + background: #03353f; + padding: 0; + position: relative; &-item { color: #fff; - background-color: #02282b; - &:not(&-disabled):hover, - &-selected, - &-active { - background-color: #08363c; + font-family: Arial; + border: 0; + background-color: transparent !important; + padding: 4px 14px; + &:hover { + background-color: #055565 !important; + } + &-selected { + color: #0cebc9; + font-weight: normal; + } + &-disabled { + color: #476d74 !important; + &:hover { + background-color: transparent !important; + } + } + } + } + + &--multiple { + // 多选 + color: #000; + .ant-select-dropdown { + &-menu-item { + padding-left: 35px; + .anticon-check { + width: 16px; + height: 16px; + line-height: 18px; + left: 13px; + border: 1px solid #0a544e !important; + color: transparent !important; + background-color: #03353f; + } + &-selected { + .anticon-check { + background: #00e9fe; + border-color: #00e9fe; + color: #000 !important; + } + } + } + } + } + } + + // 下拉框打开时的样式 + &-open { + .ant-select { + &-selection { + background-color: #055565 !important; + } + } + } +} + +// 下拉菜单 +.ant-dropdown { + &-menu { + background: #03353f; + padding: 0; + position: relative; + &-item { + color: #fff; + font-family: Arial; + border: 0; + background-color: transparent !important; + padding: 4px 14px; + &:hover { + background-color: #055565 !important; + } + &-selected { + color: #0cebc9; + font-weight: normal; + } + &-disabled { + color: #476d74 !important; + &:hover { + background-color: transparent !important; } } } @@ -122,6 +267,10 @@ } } +// 树形结构 +.ant-tree { +} + // 按钮 .ant-btn { border-radius: 0; @@ -130,6 +279,26 @@ text-shadow: 0px 1px 0px #000; font-size: 16px; } + + &-success { + // 自定义warn样式 + background-color: #08a7cf !important; + color: #fff !important; + border-color: #08a7cf !important; + &:hover { + background-color: #08a7cf !important; + } + } + + &-warn { + // 自定义warn样式 + background-color: #b98326 !important; + color: #fff !important; + border-color: #b98326 !important; + &:hover { + background-color: #b98326 !important; + } + } } // 空状态 @@ -138,6 +307,7 @@ color: #fff; } +// 分页器样式 .ant-pagination { &, &-item a { @@ -162,7 +332,7 @@ } &-disabled { .ant-pagination-item-link { - color: #9ca2a6; + color: #9ca2a6 !important; } } @@ -213,6 +383,81 @@ } } +// 弹窗样式 +.ant-modal { + &-content { + border-radius: 0; + border: 1px solid #0c6a66; + background-color: @modalBg; + } + &-header { + background-color: #0c817b; + padding: 0 20px; + border-radius: 0; + border-bottom: none; + } + &-title { + font-family: MicrogrammaD-MediExte; + font-weight: bold; + color: #fff; + height: 40px; + line-height: 40px; + } + &-close { + color: #fff !important; + &-x { + width: 40px; + height: 40px; + line-height: 40px; + } + } + &-body { + padding-bottom: 0; + } + &-footer { + border-top: none; + text-align: center; + padding-bottom: 22px; + } +} + +// 确认弹窗样式 +.ant-modal-confirm { + &-title, + &-content { + color: #fff !important; + } +} + +// 通知样式 +.ant-message { + &-notice { + &-content { + background-color: @modalBg; + } + } +} + +// 抽屉 +.ant-drawer { + &-content { + background-color: @modalBg; + } + &-body { + > div { + background-color: transparent !important; + border: none !important; + } + } +} + +// 警告提示 +.ant-alert { + &-info { + background-color: @modalBg; + } +} + // 滚动条 ::-webkit-scrollbar { width: 6px; diff --git a/src/utils/util.js b/src/utils/util.js index bf4f48f..d0143b6 100644 --- a/src/utils/util.js +++ b/src/utils/util.js @@ -89,7 +89,7 @@ export function generateIndexRouter(data) { //component: () => import('@/components/layouts/BasicLayout'), component: resolve => require(['@/components/layouts/TabLayout'], resolve), meta: { title: '首页' }, - redirect: '/dashboard/analysis', + redirect: '/station-operation', children: [ ...generateChildRouters(data) ] diff --git a/src/views/system/UserList.vue b/src/views/system/UserList.vue index 6315174..d02e79b 100644 --- a/src/views/system/UserList.vue +++ b/src/views/system/UserList.vue @@ -1,130 +1,97 @@