diff --git a/src/military/expert/expertUser/taskDetail/index.jsx b/src/military/expert/expertUser/taskDetail/index.jsx
index 36ca5d2d..c03c0dcf 100644
--- a/src/military/expert/expertUser/taskDetail/index.jsx
+++ b/src/military/expert/expertUser/taskDetail/index.jsx
@@ -80,7 +80,10 @@ function ReviewTasks({ showNotification, match, history, current_user }) {
key: 'comments',
width: 80,
render: (text, record, index) => {
- return { writeComments(text, index, 'comments') }}>{record.status === 2 ? text ? '编辑' : '填写' : '查看'}意见
+ return
+ { writeComments(text, index, 'comments') }}>{record.status === 2 ? text ? '编辑' : '填写' : '查看'}意见
+
+
}
},
];
@@ -192,7 +195,7 @@ function ReviewTasks({ showNotification, match, history, current_user }) {
}
setDataList(dataArr);
disabled && setLoading(false);
- !disabled && dataArr.length && initScoringDetails(dataArr).then(res => {
+ !disabled && dataArr.length && rules && initScoringDetails(dataArr).then(res => {
if (res) {
setReload(Math.random());
setLoading(false);
@@ -326,34 +329,26 @@ function ReviewTasks({ showNotification, match, history, current_user }) {
typeof item.gradesFour === 'number' && gradesArr.push(item.gradesFour);
typeof item.gradesFive === 'number' && gradesArr.push(item.gradesFive);
if (gradesArr.length < gradesNum && gradesArr.length) {
- errorArr.push(index);
+ errorArr.push(index+1);
} else if (!item.comments && gradesArr.length) {
- commentsError.push(index);
+ commentsError.push(index+1);
} else if (gradesArr.length) {
scoringArr.push(index);
}
}
if (errorArr.length) {
- let content = '';
- for (const item of errorArr) {
- content += `第${item + 1}行数据请填写完整 `;
- }
Info({
title: '提醒',
- content: content,
+ content: `第${errorArr.join(',')}行数据请填写完整`,
});
return;
}
if (commentsError.length) {
- let content = '';
- for (const item of commentsError) {
- content += `第${item + 1}行数据请填写意见 `;
- }
Info({
title: '提醒',
- content: content,
+ content: `第${commentsError.join(',')}行数据请填写意见`,
});
return;
}