搭建完整的前后端分离架构,实现数据概览、预测分析、聚类分析等核心功能模块 详细版: feat: 初始化员工缺勤分析系统项目 - 后端:基于 Flask 搭建 RESTful API,包含数据概览、特征分析、预测模型、聚类分析四大模块 - 前端:基于 Vue.js 构建单页应用,实现 Dashboard、预测、聚类、因子分析等页面 - 模型:集成随机森林、XGBoost、LightGBM、Stacking 等多种机器学习模型 - 文档:完成需求规格说明、系统架构设计、接口设计、数据设计、UI原型设计等文档
75 lines
1.5 KiB
Vue
75 lines
1.5 KiB
Vue
<template>
|
|
<el-container class="app-container">
|
|
<el-header class="app-header">
|
|
<div class="logo">员工缺勤分析与预测系统</div>
|
|
<el-menu
|
|
:default-active="activeMenu"
|
|
mode="horizontal"
|
|
router
|
|
class="nav-menu"
|
|
>
|
|
<el-menu-item index="/dashboard">数据概览</el-menu-item>
|
|
<el-menu-item index="/analysis">影响因素</el-menu-item>
|
|
<el-menu-item index="/prediction">缺勤预测</el-menu-item>
|
|
<el-menu-item index="/clustering">员工画像</el-menu-item>
|
|
</el-menu>
|
|
</el-header>
|
|
<el-main class="app-main">
|
|
<router-view />
|
|
</el-main>
|
|
</el-container>
|
|
</template>
|
|
|
|
<script setup>
|
|
import { computed } from 'vue'
|
|
import { useRoute } from 'vue-router'
|
|
|
|
const route = useRoute()
|
|
const activeMenu = computed(() => route.path)
|
|
</script>
|
|
|
|
<style>
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif;
|
|
background-color: #f5f7fa;
|
|
}
|
|
|
|
.app-container {
|
|
min-height: 100vh;
|
|
}
|
|
|
|
.app-header {
|
|
background-color: #fff;
|
|
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
|
display: flex;
|
|
align-items: center;
|
|
padding: 0 20px;
|
|
height: 60px !important;
|
|
}
|
|
|
|
.logo {
|
|
font-size: 18px;
|
|
font-weight: bold;
|
|
color: #409EFF;
|
|
margin-right: 40px;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.nav-menu {
|
|
border-bottom: none;
|
|
flex: 1;
|
|
}
|
|
|
|
.app-main {
|
|
padding: 20px;
|
|
background-color: #f5f7fa;
|
|
min-height: calc(100vh - 60px);
|
|
}
|
|
</style>
|