|
@@ -78,8 +78,8 @@
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
<el-table-column label="ID" align="center" prop="id" />
|
|
|
<el-table-column label="标题" align="center" prop="title" />
|
|
|
- <el-table-column label="分配者" align="center" prop="assignerName" />
|
|
|
- <el-table-column label="执行人" align="center" prop="executorName" />
|
|
|
+ <el-table-column label="分配者" align="center" prop="creatorName" />
|
|
|
+ <el-table-column label="执行人" align="center" prop="assigneeName" />
|
|
|
<el-table-column label="描述" align="center" prop="description" show-overflow-tooltip />
|
|
|
<el-table-column label="状态" align="center" prop="status">
|
|
|
<template slot-scope="scope">
|
|
@@ -114,13 +114,13 @@
|
|
|
@click="handleUpdate(scope.row)"
|
|
|
v-hasPermi="['todo:todoItems:edit']"
|
|
|
>修改</el-button>
|
|
|
- <el-button
|
|
|
- size="mini"
|
|
|
- type="text"
|
|
|
- icon="el-icon-check"
|
|
|
- @click="handleUpdateStatus(scope.row)"
|
|
|
- v-hasPermi="['todo:todoItems:edit']"
|
|
|
- >更新状态</el-button>
|
|
|
+<!-- <el-button-->
|
|
|
+<!-- size="mini"-->
|
|
|
+<!-- type="text"-->
|
|
|
+<!-- icon="el-icon-check"-->
|
|
|
+<!-- @click="handleUpdateStatus(scope.row)"-->
|
|
|
+<!-- v-hasPermi="['todo:todoItems:edit']"-->
|
|
|
+<!-- >更新状态</el-button>-->
|
|
|
<el-button
|
|
|
size="mini"
|
|
|
type="text"
|
|
@@ -151,7 +151,7 @@
|
|
|
</div>
|
|
|
|
|
|
<!-- 添加或修改待办事项对话框 -->
|
|
|
- <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
|
|
+ <el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
|
|
<el-form-item label="标题" prop="title">
|
|
|
<el-input v-model="form.title" placeholder="请输入待办事项标题" />
|
|
@@ -345,7 +345,7 @@ export default {
|
|
|
/** 获取执行者列表 */
|
|
|
getExecutorList() {
|
|
|
const params = {
|
|
|
- companyName: this.queryParams.companyName,
|
|
|
+ companyName: this.queryParams.companyName || '',
|
|
|
companyId: null,
|
|
|
pageNum: 1,
|
|
|
pageSize: 10 // 获取足够多的执行者供选择
|
|
@@ -386,16 +386,7 @@ export default {
|
|
|
};
|
|
|
return priorityMap[String(priority)] || 'info';
|
|
|
},
|
|
|
- /** 表格行样式类 */
|
|
|
- tableRowClassName({ row, rowIndex }) {
|
|
|
- // 根据优先级设置行样式
|
|
|
- if (row.priority === '3' || row.priority === 3) {
|
|
|
- return 'priority-urgent-row';
|
|
|
- } else if (row.priority === '2' || row.priority === 2) {
|
|
|
- return 'priority-high-row';
|
|
|
- }
|
|
|
- return '';
|
|
|
- },
|
|
|
+
|
|
|
// 取消按钮
|
|
|
cancel() {
|
|
|
this.open = false;
|
|
@@ -448,7 +439,9 @@ export default {
|
|
|
handleUpdate(row) {
|
|
|
this.reset();
|
|
|
const id = row.id || this.ids
|
|
|
- getTodoItems(id).then(response => {
|
|
|
+ // 确保id是单个值,如果是数组则取第一个
|
|
|
+ const todoId = Array.isArray(id) ? id[0] : id;
|
|
|
+ getTodoItems(todoId).then(response => {
|
|
|
this.form = response.data;
|
|
|
// 确保数据类型匹配
|
|
|
if (this.form.status !== null && this.form.status !== undefined) {
|
|
@@ -552,36 +545,9 @@ export default {
|
|
|
width: 100px;
|
|
|
}
|
|
|
|
|
|
-/* 搜索表单样式 */
|
|
|
-.search-form {
|
|
|
- background: #f8f9fa;
|
|
|
- padding: 20px;
|
|
|
- border-radius: 8px;
|
|
|
- margin-bottom: 20px;
|
|
|
- box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
|
|
-}
|
|
|
|
|
|
-/* 操作按钮行样式 */
|
|
|
-.operation-row {
|
|
|
- background: #fff;
|
|
|
- padding: 15px;
|
|
|
- border-radius: 8px;
|
|
|
- box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
|
|
- margin-bottom: 20px;
|
|
|
-}
|
|
|
|
|
|
-/* 操作按钮样式 */
|
|
|
-.action-btn {
|
|
|
- margin-right: 8px;
|
|
|
- border-radius: 6px;
|
|
|
- font-weight: 500;
|
|
|
- transition: all 0.3s ease;
|
|
|
-}
|
|
|
|
|
|
-.action-btn:hover {
|
|
|
- transform: translateY(-2px);
|
|
|
- box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
|
|
|
-}
|
|
|
|
|
|
.assign-executor-btn {
|
|
|
margin-left: 5px;
|
|
@@ -598,22 +564,7 @@ export default {
|
|
|
}
|
|
|
|
|
|
|
|
|
-/* 优先级行样式 */
|
|
|
-.priority-urgent-row {
|
|
|
- background: linear-gradient(135deg, #fff5f5 0%, #ffe8e8 100%);
|
|
|
-}
|
|
|
-
|
|
|
-.priority-urgent-row:hover {
|
|
|
- background: linear-gradient(135deg, #ffe8e8 0%, #ffd6d6 100%);
|
|
|
-}
|
|
|
|
|
|
-.priority-high-row {
|
|
|
- background: linear-gradient(135deg, #fffbf0 0%, #fff2d9 100%);
|
|
|
-}
|
|
|
-
|
|
|
-.priority-high-row:hover {
|
|
|
- background: linear-gradient(135deg, #fff2d9 0%, #ffe7ba 100%);
|
|
|
-}
|
|
|
|
|
|
/* 标签样式优化 */
|
|
|
.el-tag {
|