fixbug: 修改bug: 🐛 发送请求时主体颜色改变
This commit is contained in:
parent
4adf21a794
commit
1da1c78649
|
@ -5,5 +5,5 @@
|
|||
// Generated by unplugin-auto-import
|
||||
export {}
|
||||
declare global {
|
||||
|
||||
const ElMessage: typeof import('element-plus/es')['ElMessage'];
|
||||
}
|
||||
|
|
|
@ -6,22 +6,28 @@
|
|||
export {}
|
||||
|
||||
declare module 'vue' {
|
||||
export interface GlobalComponents {
|
||||
ElAside: typeof import('element-plus/es')['ElAside']
|
||||
ElButton: typeof import('element-plus/es')['ElButton']
|
||||
ElContainer: typeof import('element-plus/es')['ElContainer']
|
||||
ElHeader: typeof import('element-plus/es')['ElHeader']
|
||||
ElIcon: typeof import('element-plus/es')['ElIcon']
|
||||
ElMain: typeof import('element-plus/es')['ElMain']
|
||||
ElMenu: typeof import('element-plus/es')['ElMenu']
|
||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem']
|
||||
ElMenuItemGroup: typeof import('element-plus/es')['ElMenuItemGroup']
|
||||
ElRadioButton: typeof import('element-plus/es')['ElRadioButton']
|
||||
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
||||
ElRow: typeof import('element-plus/es')['ElRow']
|
||||
ElSubMenu: typeof import('element-plus/es')['ElSubMenu']
|
||||
ElText: typeof import('element-plus/es')['ElText']
|
||||
RouterLink: typeof import('vue-router')['RouterLink']
|
||||
RouterView: typeof import('vue-router')['RouterView']
|
||||
}
|
||||
export interface GlobalComponents {
|
||||
ElAside: typeof import('element-plus/es')['ElAside'];
|
||||
ElButton: typeof import('element-plus/es')['ElButton'];
|
||||
ElContainer: typeof import('element-plus/es')['ElContainer'];
|
||||
ElDialog: typeof import('element-plus/es')['ElDialog'];
|
||||
ElDropdown: typeof import('element-plus/es')['ElDropdown'];
|
||||
ElDropdownItem: typeof import('element-plus/es')['ElDropdownItem'];
|
||||
ElDropdownMenu: typeof import('element-plus/es')['ElDropdownMenu'];
|
||||
ElForm: typeof import('element-plus/es')['ElForm'];
|
||||
ElFormItem: typeof import('element-plus/es')['ElFormItem'];
|
||||
ElHeader: typeof import('element-plus/es')['ElHeader'];
|
||||
ElIcon: typeof import('element-plus/es')['ElIcon'];
|
||||
ElInput: typeof import('element-plus/es')['ElInput'];
|
||||
ElMain: typeof import('element-plus/es')['ElMain'];
|
||||
ElMenu: typeof import('element-plus/es')['ElMenu'];
|
||||
ElMenuItem: typeof import('element-plus/es')['ElMenuItem'];
|
||||
ElRadio: typeof import('element-plus/es')['ElRadio'];
|
||||
ElRadioButton: typeof import('element-plus/es')['ElRadioButton'];
|
||||
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup'];
|
||||
ElTable: typeof import('element-plus/es')['ElTable'];
|
||||
ElTableColumn: typeof import('element-plus/es')['ElTableColumn'];
|
||||
RouterLink: typeof import('vue-router')['RouterLink'];
|
||||
RouterView: typeof import('vue-router')['RouterView'];
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,26 +0,0 @@
|
|||
const path = require('path');
|
||||
|
||||
module.exports = {
|
||||
webpack: {
|
||||
alias: {
|
||||
'@': path.join(__dirname, 'src'),
|
||||
},
|
||||
},
|
||||
style: {
|
||||
postcss: {
|
||||
mode: 'extends',
|
||||
loaderOptions: {
|
||||
postcssOptions: {
|
||||
ident: 'postcss',
|
||||
plugins: [
|
||||
// require('postcss-mobile-forever', {
|
||||
// viewportWidth: 2560,
|
||||
// appSelector: '#root',
|
||||
// maxDisplayWidth: 1920,
|
||||
// }),
|
||||
],
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
};
|
|
@ -10,10 +10,10 @@ export const reqLogin = (data: any) => {
|
|||
|
||||
/**
|
||||
* 员工分页查询
|
||||
* @param data
|
||||
* @param params
|
||||
*/
|
||||
export const reqGetEmployeePage = (data: any) => {
|
||||
return Request({ url: '/admin/employee/page', method: 'GET', params: data });
|
||||
export const reqGetEmployeePage = (params: any) => {
|
||||
return Request({ url: '/admin/employee/page', method: 'GET', params });
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -41,7 +41,7 @@ const store = headerStore();
|
|||
max-width: 200px;
|
||||
min-width: 63px;
|
||||
height: 100%;
|
||||
background: #343744;
|
||||
background: #343744 !important;
|
||||
|
||||
.el-menu-item {
|
||||
color: #bfcbd9;
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
<!-- tablePlus:二次封装table -->
|
||||
<template>
|
||||
<el-table :data="tableData" v-bind="$attrs">
|
||||
<el-table-column v-for="item in column" :key="item.prop" v-bind="item">
|
||||
|
@ -28,5 +27,3 @@ defineProps<{
|
|||
column: Column[];
|
||||
}>();
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
|
|
|
@ -5,7 +5,6 @@ import { createPinia } from 'pinia';
|
|||
import ElementPlus from 'element-plus';
|
||||
import zhCn from 'element-plus/dist/locale/zh-cn.mjs';
|
||||
import './assets/css/reset.css';
|
||||
import './assets/css/index.scss';
|
||||
import * as ElementPlusIconsVue from '@element-plus/icons-vue';
|
||||
import '@/config/globalProperties';
|
||||
|
||||
|
|
|
@ -15,14 +15,18 @@ export const employeeStore = defineStore('employeeStore', {
|
|||
* @param data
|
||||
*/
|
||||
async login(data: any) {
|
||||
const response: any = await reqLogin(data);
|
||||
if (response.code === 1) {
|
||||
Cookies.set('token', response.data.token);
|
||||
Cookies.set('user_info', JSON.stringify(response.data));
|
||||
Cookies.set('username', response.data.name);
|
||||
router.push('/').catch();
|
||||
} else {
|
||||
ElMessage.error(response.msg);
|
||||
try {
|
||||
const response: any = await reqLogin(data);
|
||||
if (response.code === 1) {
|
||||
Cookies.set('token', response.data.token);
|
||||
Cookies.set('user_info', JSON.stringify(response.data));
|
||||
Cookies.set('username', response.data.name);
|
||||
router.push('/').catch();
|
||||
} else {
|
||||
ElMessage.error(response.msg);
|
||||
}
|
||||
} catch (e: any) {
|
||||
ElMessage.error(e.message);
|
||||
}
|
||||
},
|
||||
/**
|
||||
|
@ -30,8 +34,12 @@ export const employeeStore = defineStore('employeeStore', {
|
|||
* @param data
|
||||
*/
|
||||
async getEmployeePage(data: any) {
|
||||
const response: any = await reqGetEmployeePage(data);
|
||||
this.employeeList = response.data.records;
|
||||
try {
|
||||
const response: any = await reqGetEmployeePage(data);
|
||||
this.employeeList = response.data.records;
|
||||
} catch (e: any) {
|
||||
ElMessage.error(e.message);
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
|
@ -8,9 +8,9 @@
|
|||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import TablePlus from '@/commpent/table/table-plus.vue';
|
||||
import { employeeStore } from '@/store/employee';
|
||||
import { onMounted, reactive, toRaw } from 'vue';
|
||||
import TablePlus from '@/commpent/table/table-plus.vue';
|
||||
|
||||
const store = employeeStore();
|
||||
const requestData = reactive({
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
const {defineConfig} = require('@vue/cli-service');
|
||||
const { defineConfig } = require('@vue/cli-service');
|
||||
const AutoImport = require('unplugin-auto-import/webpack');
|
||||
const Components = require('unplugin-vue-components/webpack');
|
||||
const {ElementPlusResolver} = require('unplugin-vue-components/resolvers');
|
||||
const ElementPlus = require('unplugin-element-plus/webpack')
|
||||
const { ElementPlusResolver } = require('unplugin-vue-components/resolvers');
|
||||
const ElementPlus = require('unplugin-element-plus/webpack');
|
||||
|
||||
module.exports = defineConfig({
|
||||
transpileDependencies: true,
|
||||
|
@ -11,28 +11,28 @@ module.exports = defineConfig({
|
|||
'/api': {
|
||||
target: 'http://localhost:8080',
|
||||
changeOrigin: true,
|
||||
pathRewrite: {'^/api': ''},
|
||||
pathRewrite: { '^/api': '' },
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
chainWebpack: (config) => {
|
||||
config.plugin('define').tap((definitions) => {
|
||||
chainWebpack: config => {
|
||||
config.plugin('define').tap(definitions => {
|
||||
Object.assign(definitions[0], {
|
||||
__VUE_OPTIONS_API__: 'true',
|
||||
__VUE_PROD_DEVTOOLS__: 'false',
|
||||
__VUE_PROD_HYDRATION_MISMATCH_DETAILS__: 'false'
|
||||
})
|
||||
return definitions
|
||||
})
|
||||
__VUE_PROD_HYDRATION_MISMATCH_DETAILS__: 'false',
|
||||
});
|
||||
return definitions;
|
||||
});
|
||||
},
|
||||
css: {
|
||||
loaderOptions: {
|
||||
scss: {
|
||||
additionalData: `@use "~@/assets/css/index.scss" as *;`,
|
||||
},
|
||||
},
|
||||
},
|
||||
// css: {
|
||||
// loaderOptions: {
|
||||
// scss: {
|
||||
// additionalData: `@use "~@/styles/index.scss" as *;`,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
configureWebpack: {
|
||||
plugins: [
|
||||
AutoImport({
|
||||
|
|
Loading…
Reference in New Issue