factory_web/src/App.vue

134 lines
2.3 KiB
Vue

<template>
<el-config-provider :locale="locale" :size="config.size" :zIndex="config.zIndex" :button="config.button">
<router-view></router-view>
</el-config-provider>
</template>
<script>
import colorTool from '@/utils/color';
export default {
name: 'App',
data() {
return {
config: {
size: "default",
zIndex: 2000,
button: {
autoInsertSpace: false
}
}
}
},
computed: {
locale() {
return this.$i18n.messages[this.$i18n.locale].el
},
},
created() {
//设置主题颜色
const app_color = this.$CONFIG.COLOR || this.$TOOL.data.get('APP_COLOR')
if (app_color) {
document.documentElement.style.setProperty('--el-color-primary', app_color);
for (let i = 1; i <= 9; i++) {
document.documentElement.style.setProperty(`--el-color-primary-light-${i}`, colorTool.lighten(app_color, i / 10));
}
for (let i = 1; i <= 9; i++) {
document.documentElement.style.setProperty(`--el-color-primary-dark-${i}`, colorTool.darken(app_color, i / 10));
}
}
}
}
</script>
<style lang="scss">
@import '@/style/style.scss';
.headerSearch {
width: 120px !important;
margin-right: 5px;
}
.printWrap {
width: 100%;
overflow-x: scroll;
}
.printContainer {
width: 1075px;
}
.myTable {
table-layout: fixed;
border: 1px solid #cccccc;
}
.myTableHead {
background: #008080;
color: #ffffff;
}
.myTable th {
height: 40px;
font-weight: 500;
}
.myTable td {
height: 32px;
padding-left: 5px;
border: 1px solid #cccccc;
}
.numCell {
height: 35px;
text-align: center;
}
.numCell {
width: 100px;
}
.chartWrap {
width: 1035px;
margin-top: 20px;
border: 1px solid #eeeeee;
}
.chartTitle {
text-align: center;
font-size: 20px;
font-weight: bold;
margin-top: 20px;
}
.redColor {
font-weight: bold;
color: #ff0000;
}
.greenColor {
font-weight: bold;
color: #008000;
}
#table1.el-table,
#table1.el-table tr,
#table1.el-table .el-table__body-wrapper,
#table1.el-table .el-table__header-wrapper .el-table__row,
#table1.el-table .el-table__body-wrapper .el-table__row,
#table1.el-table td.el-table__cell,
#table1.el-table th.el-table__cell.is-leaf {
background: rgba(0, 0, 0, 0);
}
.el-calendar-table .el-calendar-day {
height: 43px !important;
}
.el-calendar {
border-radius: 15px;
}
.el-calendar>.el-calendar__body {
padding: 0 20px 20px;
}</style>