diff --git a/.env.test b/.env.test
index 707e773..8591b7e 100644
--- a/.env.test
+++ b/.env.test
@@ -1,5 +1,6 @@
-VITE_BASE_URL = '/pms-front-test'
-VITE_BASE_NAME = "pms-front-test"
+VITE_BASE_URL = "./"
+VITE_BASE_NAME = "dev"
VITE_APP_PROXYURL = 'http://192.168.124.202:8080'
-VITE_APP_REQUESTURL = '/pms-front-test'
-VITE_APP_ROUTERURL = '/pms-front-test/'
\ No newline at end of file
+VITE_APP_REQUESTURL = '/prod-api'
+VITE_APP_ROUTERURL = '/dev/'
+
diff --git a/.gitignore b/.gitignore
index bb71358..4ea2db4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -9,7 +9,7 @@ lerna-debug.log*
node_modules
pms-front
-pms-front-test
+dev
dist
dist-ssr
*.local
diff --git a/src/assets/imgs/warning.png b/src/assets/imgs/warning.png
new file mode 100644
index 0000000..259cd33
Binary files /dev/null and b/src/assets/imgs/warning.png differ
diff --git a/src/components/table.vue b/src/components/CustomTable.vue
similarity index 89%
rename from src/components/table.vue
rename to src/components/CustomTable.vue
index 32f8316..15309f3 100644
--- a/src/components/table.vue
+++ b/src/components/CustomTable.vue
@@ -7,6 +7,7 @@
v-bind="$attrs"
@selection-change="handleSelectionChange"
:border="border"
+ :highlight-current-row="highligt"
>
@@ -28,8 +29,7 @@
-
-
+
{{ scope.row[column.prop] }}
@@ -90,8 +90,8 @@ const props = defineProps({
default: () => [10, 20, 30, 50],
},
maxHeight: {
- type: Number,
- default: null,
+ type: String,
+ default: '100%',
},
offsetHeight: {
type: Number,
@@ -101,6 +101,14 @@ const props = defineProps({
type: Boolean,
default: false,
},
+ multiSelect: {
+ type: Boolean,
+ default: true,
+ },
+ highligt: {
+ type: Boolean,
+ default: true,
+ },
})
const emit = defineEmits(['selection-change', 'size-change', 'current-change', 'button-click'])
@@ -128,7 +136,7 @@ const handleCurrentChange = val => {
const updateTableHeight = () => {
nextTick(() => {
- if (tableContainer.value && paginationContainer.value) {
+ if (tableContainer.value) {
const parentElement = tableContainer.value.parentElement
const parentHeight = parentElement.clientHeight
const tableTop = tableContainer.value.getBoundingClientRect().top - parentElement.getBoundingClientRect().top
@@ -161,36 +169,38 @@ onUnmounted(() => {
width: 100%;
display: flex;
flex-direction: column;
+ flex: 1;
}
.pagination-container {
margin-top: 10px;
display: flex;
justify-content: flex-end;
}
-:deep(.el-scrollbar__wrap--hidden-default){
+:deep(.el-scrollbar__wrap--hidden-default) {
min-height: 100px;
}
- :deep(.el-table) {
+:deep(.el-table) {
--el-table-text-align: center;
}
- :deep(.el-table th) {
+:deep(.el-table th) {
text-align: center;
}
- :deep(.el-table .cell) {
+:deep(.el-table .cell) {
text-align: center;
}
/* 如果操作列需要特殊处理,可以添加以下样式 */
- :deep(.operation-column .cell) {
+:deep(.operation-column .cell) {
text-align: center;
display: flex;
justify-content: center;
}
-:deep(.el-table__inner-wrapper::before){
-
- display: none;
-
+:deep(.el-table__inner-wrapper::before) {
+ display: none;
+}
+:deep(.el-table-column--selection) {
+ text-align: center;
}
diff --git a/src/components/selectUser.vue b/src/components/selectUser.vue
index a937732..2ebb533 100644
--- a/src/components/selectUser.vue
+++ b/src/components/selectUser.vue
@@ -13,6 +13,7 @@
:show-selection="true"
:show-index="true"
:table-height="tableHeight"
+ :multiSelect="multiSelect"
@selection-change="handleSelectionChange"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
@@ -38,7 +39,8 @@
\ No newline at end of file
+
diff --git a/src/utils/api.js b/src/utils/api.js
index 791e77e..40b5d99 100644
--- a/src/utils/api.js
+++ b/src/utils/api.js
@@ -4,9 +4,9 @@ export const loginApi = {
// 登录
login: data => request('/login', 'json', data),
// 退出登录
- loginOut: () => request('/aiops-api/logout', 'get'),
+ loginOut: () => request('/logout', 'get'),
//修改密码
- editPassword: data => request('/aiops-api/auth/user/updatePwd', 'post', data),
+ editPassword: data => request('/auth/user/updatePwd', 'post', data),
// 获取验证码
getCode: () => request('/captchaImage', 'captchaImage', {}, {
SHOW_LOADING: false, headers: {
@@ -30,7 +30,13 @@ export const projectApi = {
updateProjectUser: data => request('/business/project/team', 'json', data),
deleteProjectUser: id => request(`/business/project/team/${id}`, 'delete'),
}
-
+// 工作日志
+export const workLogApi = {
+ userProject: id => request(`/business/work/hour/project/${id}`, 'get'),
+ getLogData: data => request('/business/work/hour/calendar', 'json', data, { SHOW_LOADING: false }),
+ getLogDataDetail: data => request('/business/work/hour/getInfo', 'json', data, { SHOW_LOADING: false }),
+ addLog: data => request('/business/work/hour/add', 'json', data),
+}
// 用户板块
export const useUserApi = () => {
@@ -38,8 +44,9 @@ export const useUserApi = () => {
}
// 系统板块
export const systemApi = {
- getUserList: data => request('/aiops-api/auth/user/list', 'post', data),
+ getUserList: data => request('/system/user/list', 'get', data),
getDictData: dictCode => request('/system/dict/data/type/' + dictCode, 'get'),
+ getDeptTree: () => request('/system/user/deptTree', 'get'),
}
// 系统定时任务
export const systemJobApi = {
diff --git a/src/views/project/detail.vue b/src/views/project/detail.vue
index d31fd75..9645378 100644
--- a/src/views/project/detail.vue
+++ b/src/views/project/detail.vue
@@ -14,7 +14,7 @@
-
+
@@ -158,7 +158,7 @@
-

+
确定要删除该成员吗?此操作不可逆。
@@ -174,8 +174,8 @@
@@ -295,6 +340,7 @@ onMounted(() => {
transition: all 0.3s;
overflow: hidden;
position: relative;
+ height: 100%;
}
.project-list.collapsed {
@@ -311,6 +357,7 @@ onMounted(() => {
border-bottom: 1px solid #dcdfe6;
position: relative;
height: 40px;
+ flex: 1;
}
.collapse-button-wrapper {
@@ -347,30 +394,6 @@ onMounted(() => {
color: #606266;
}
-.project-list :deep(.el-table__body-wrapper) {
- overflow-y: auto;
-}
-
-.project-list :deep(.el-table__footer-wrapper) {
- position: sticky;
- bottom: 0;
- z-index: 1;
-}
-
-.project-list :deep(.el-table__footer) {
- background-color: white;
-}
-
-.project-list :deep(.el-table__footer td) {
- background-color: white !important;
- font-weight: bold;
-}
-
-.project-list :deep(.el-table__body td),
-.project-list :deep(.el-table__footer td) {
- height: 60px; /* 增加单格度 */
-}
-
.project-info-calendar {
flex: 1;
padding: 20px;
@@ -402,11 +425,11 @@ onMounted(() => {
background-color: #ecf5ff;
}
.calendar-view :deep(.out-range) {
- background-color: rgba(0, 0, 0, 0.05);
+ background-color: rgba(0, 0, 0, 0.05) !important;
}
.calendar-view :deep(.disabled) {
- background-color: #fff;
+ background-color: #fff !important;
color: #c0c4cc;
cursor: not-allowed;
}
@@ -469,6 +492,10 @@ onMounted(() => {
.log-form :deep(.el-input__wrapper) {
height: 50px;
+ width: 100% !important;
+}
+:deep(.el-date-editor--date) {
+ width: 100% !important;
}
.log-form :deep(.el-input__inner) {
@@ -486,7 +513,7 @@ onMounted(() => {
/* 增加 el-form-item__label 的高度和行高 */
:deep(.el-form-item__label) {
- height: 42px; /* 默认通常是 32px,所以增加 10px 后变为 42px */
+ height: 42px; /* 默认通常是 32px,所以增加 10px ��变为 42px */
line-height: 42px; /* 行高与高度相同,确保文字垂直居中 */
}
@@ -573,4 +600,24 @@ onMounted(() => {
.date-cell.disabled {
cursor: not-allowed;
}
+:deep(.el-table__footer-wrapper) {
+ background-color: #f5f7fa;
+}
+
+:deep(.el-table__footer td) {
+ background-color: #f5f7fa !important;
+ font-weight: bold;
+ color: #606266;
+}
+:deep(.el-table__row) {
+ cursor: pointer;
+}
+:deep(tr.el-table__row:hover .el-table__cell) {
+ background: #409eff !important;
+ color: #fff;
+}
+:deep(tr.el-table__row.current-row .el-table__cell) {
+ background-color: #409eff !important;
+ color: #fff;
+}
diff --git a/vite.config.js b/vite.config.js
index 376fca1..62a396e 100644
--- a/vite.config.js
+++ b/vite.config.js
@@ -6,8 +6,6 @@ import AutoImport from 'unplugin-auto-import/vite'
import Components from 'unplugin-vue-components/vite'
import vue from '@vitejs/plugin-vue'
import myPlugin from './public/js/zip'
-// console.log(env.VITE_BASE_URL, 'env.VITE_BASE_URL')
-// https://vitejs.dev/config/
export default ({ mode }) => {
const env = loadEnv(mode, process.cwd())