From 694fd1c39452b29924ecd9d9b4444a143e068b10 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 20 Jan 2022 13:09:34 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E4=B8=93=E5=AE=B6=E8=BA=AB=E4=BB=BD?= =?UTF-8?q?=E8=BF=9B=E5=85=A5=E4=B8=93=E5=AE=B6=E4=BF=A1=E6=81=AF=E5=A1=AB?= =?UTF-8?q?=E5=86=99=E9=A1=B5=20=E6=8F=90=E4=BA=A4=E6=8C=89=E9=92=AE?= =?UTF-8?q?=E6=94=B9=E4=B8=BA=E4=BF=AE=E6=94=B9=E6=8C=89=E9=92=AE=EF=BC=8C?= =?UTF-8?q?=E4=BF=A1=E6=81=AF=E5=A1=AB=E5=86=99=E9=A1=B5=E4=B8=89=E4=B8=AA?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E6=A0=B7=E5=BC=8F=EF=BC=8C=E7=BA=A0=E6=AD=A3?= =?UTF-8?q?=E9=94=99=E5=88=AB=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/military/expert/expertUser/register/index.jsx | 6 +++--- src/military/expert/expertUser/register/index.scss | 6 ------ src/military/expert/expertUser/taskDetail/index.jsx | 2 +- 3 files changed, 4 insertions(+), 10 deletions(-) diff --git a/src/military/expert/expertUser/register/index.jsx b/src/military/expert/expertUser/register/index.jsx index a14030ca5..b4f822c77 100644 --- a/src/military/expert/expertUser/register/index.jsx +++ b/src/military/expert/expertUser/register/index.jsx @@ -252,7 +252,6 @@ export default Form.create()(({ match, history, showNotification, form, current_ } } - return (
{ @@ -561,9 +560,10 @@ export default Form.create()(({ match, history, showNotification, form, current_
提示:个人简介、职称证明、学术成果、荣誉称号都只能上传一个文件,建议上传zip或rar格式的压缩文件
- + {/* 专家: 修改,非专家: 提交 */} + {(!lastRegister || lastRegister.status !== 1) && } - + - +

任务信息

From 009c51159297d6687584e13d0248df451002e97a Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 20 Jan 2022 13:53:26 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=B8=93=E5=AE=B6?= =?UTF-8?q?=E5=BA=93=E9=A1=B5=E9=9D=A2=20=E5=88=A0=E9=99=A4=E4=B8=93?= =?UTF-8?q?=E5=AE=B6=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/military/expert/api.js | 8 +++++++ src/military/expert/expertList/index.jsx | 28 ++++++++++++++++++++--- src/military/expert/expertList/index.scss | 2 +- 3 files changed, 34 insertions(+), 4 deletions(-) diff --git a/src/military/expert/api.js b/src/military/expert/api.js index 1e6986141..048da61a6 100644 --- a/src/military/expert/api.js +++ b/src/military/expert/api.js @@ -18,6 +18,14 @@ export async function expertList(params) { } } +//删除专家 +export function deleteExpert(expertId) { + return fetch({ + url: `/api/experts/${expertId}?isDelete=1`, + method: 'delete' + }); +} + // 获取用户信息 export function getUserInfo() { return fetch({ diff --git a/src/military/expert/expertList/index.jsx b/src/military/expert/expertList/index.jsx index 0157151ea..604afd3a3 100644 --- a/src/military/expert/expertList/index.jsx +++ b/src/military/expert/expertList/index.jsx @@ -1,10 +1,10 @@ import React, { useState, useMemo, useEffect } from "react"; -import { Input, Select, Button, Form, Table, Upload, Modal } from 'antd'; +import { Input, Select, Button, Form, Table, Upload, Modal, Popconfirm, message } from 'antd'; import cookie from 'react-cookies'; import { exportExcel } from '../components/exportExcel.js'; import Paginationtable from "../../components/paginationTable"; import { Info } from '../../components/ModalFun'; -import { expertList } from "../api"; +import { expertList, deleteExpert } from "../api"; import { professionalType, reviewArea } from "../static"; import { httpUrl } from '../fetch'; @@ -186,6 +186,15 @@ function RegisterList({ showNotification }) { }) } }, + { + title: '操作', + dataIndex: 'id', + key: 'action', + fixed: 'right', + render: (text, record)=>{ + return { delExpert(text);}} okText="是" cancelText="否"> + } + } ]; }, []); @@ -233,6 +242,20 @@ function RegisterList({ showNotification }) { }); }, [download]); + // 删除专家 + const delExpert=(expertId)=>{ + setLoading(true); + deleteExpert(expertId).then(response=>{ + if(response && response.message === "删除专家成功"){ + message.success("删除成功"); + setReload(Math.random()); + }else{ + message.error("删除失败"); + } + }).finally(()=>{ + setLoading(false); + }) + } function beforeUpload(file) { const isExcel = file.type.indexOf('xlsx') || file.type.indexOf('xls') || file.type.indexOf('sheet'); @@ -350,7 +373,6 @@ function RegisterList({ showNotification }) { rowKey={(row) => row.id} /> - Date: Thu, 20 Jan 2022 15:22:23 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E4=B8=93=E5=AE=B6=E5=BA=93=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=B7=BB=E5=8A=A0=E4=B8=93=E5=AE=B6=E8=AF=84=E4=BC=B0?= =?UTF-8?q?=E5=88=86=E6=95=B0=E4=BB=A5=E5=8F=8A=E4=BF=AE=E7=BC=AE=E5=85=B6?= =?UTF-8?q?=E4=BB=96=E5=B0=8Fbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/military/expert/expertList/index.jsx | 20 ++++++++++++------- .../expert/expertUser/taskDetail/index.jsx | 2 +- src/military/expert/selectExpert/index.jsx | 2 +- src/military/task/taskAdmin/index.jsx | 2 +- 4 files changed, 16 insertions(+), 10 deletions(-) diff --git a/src/military/expert/expertList/index.jsx b/src/military/expert/expertList/index.jsx index 604afd3a3..21666b5f3 100644 --- a/src/military/expert/expertList/index.jsx +++ b/src/military/expert/expertList/index.jsx @@ -38,12 +38,14 @@ function RegisterList({ showNotification }) { return [{ title: '姓名', dataIndex: 'expertName', - width: 75, + width: 85, key: 'expertName', fixed: 'left', - // render: (text, record) => { - // return record.user ? record.user.nickname || record.user.login : '' - // } + }, + { + title: '手机号码', + dataIndex: 'phone', + key: 'phone', }, { title: '最高学历', @@ -52,9 +54,13 @@ function RegisterList({ showNotification }) { width: 80, }, { - title: '手机号码', - dataIndex: 'phone', - key: 'phone', + title: '专家评估', + dataIndex: 'expertScore', + key: 'expertScore', + width: 80, + render: (text, record) => { + return text || '--' + } }, { title: '工作单位', diff --git a/src/military/expert/expertUser/taskDetail/index.jsx b/src/military/expert/expertUser/taskDetail/index.jsx index 994aa5d9e..cbfe59bb5 100644 --- a/src/military/expert/expertUser/taskDetail/index.jsx +++ b/src/military/expert/expertUser/taskDetail/index.jsx @@ -382,7 +382,7 @@ function ReviewTasks({ showNotification, match, history, current_user }) {

- +
diff --git a/src/military/expert/selectExpert/index.jsx b/src/military/expert/selectExpert/index.jsx index 02854d8a7..68d8fb299 100644 --- a/src/military/expert/selectExpert/index.jsx +++ b/src/military/expert/selectExpert/index.jsx @@ -85,7 +85,7 @@ function SelectExpert(props) { align: 'center', }, { - title: '专家评分', + title: '专家评估', dataIndex: 'expertScore', align: 'center', render:(text,record)=>{ diff --git a/src/military/task/taskAdmin/index.jsx b/src/military/task/taskAdmin/index.jsx index f2ad6e641..80d8586a3 100644 --- a/src/military/task/taskAdmin/index.jsx +++ b/src/military/task/taskAdmin/index.jsx @@ -324,7 +324,7 @@ export default Form.create()(({ form, showNotification, match, history, state }) width: 260, }, { - title: '专家评分', + title: '专家评估', dataIndex: 'expertScore', align: 'center', render:(text,record)=>{