From 97da162690c790cab03617820ddbc3662f77743e Mon Sep 17 00:00:00 2001 From: xingyongchun Date: Thu, 1 Dec 2022 16:29:50 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=A8=E9=83=A8=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/client/assets/人员信息.xlsx | Bin 0 -> 10096 bytes web/client/assets/项目信息.xlsx | Bin 0 -> 10269 bytes .../src/sections/article/actions/article.js | 23 +++ .../article/components/import_model.js | 22 +-- .../src/sections/article/components/modeal.js | 9 +- .../src/sections/article/containers/index.js | 112 +++++++++---- .../src/sections/homePage/actions/profile.js | 6 +- .../src/sections/homePage/containers/index.js | 156 +++++++++++------- .../src/sections/personnel/actions/article.js | 12 ++ .../personnel/components/import_model.js | 81 +++++---- .../sections/personnel/components/modeal.js | 105 ++++++------ .../sections/personnel/containers/index.js | 100 +++++++++-- .../src/sections/wait/actions/article.js | 56 ++----- .../sections/wait/components/import_model.js | 2 +- .../src/sections/wait/components/modeal.js | 47 +++--- .../src/sections/wait/containers/index.js | 139 +++++++++------- web/client/src/utils/webapi.js | 12 +- 17 files changed, 527 insertions(+), 355 deletions(-) create mode 100644 web/client/assets/人员信息.xlsx create mode 100644 web/client/assets/项目信息.xlsx diff --git a/web/client/assets/人员信息.xlsx b/web/client/assets/人员信息.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..ca46634ce1a43834af458de5bf7deda64973748b GIT binary patch literal 10096 zcmeHtWl)^k(k|{U3GM_5?ykYzA$V|icMq;1xJz(%clV%!1(%>9!QmT{b9Qz(`=0vl z&s%lZk9ntNTGsn?uU=iHmmQZNqFOl4qz0f$D-(d%$J9 zTI-i=D4rpF*w8o`v`*MK)uC|4JSv?fE5d$!JmR&ShTCm&SWJej^~v@pW0&R_CIzf#5)?vOfE z-%-jqTrk230*oiCy*C+jpb5hWWk9W z)T!|kA%)SmFUN0o?+^?D-0@3pUASp%S(98F->ppf3b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iT%klPwe>YmCOds0LcTs&KL(c> zHNA0~iATc}gEHUoE@a(ibxtH%%Z-=V7dFutmfv69G11JH-E=MK(M23IPB~D=f*E)R zf539Fao15#Kk{neWu}kw-c?vo!4eeBD(9d(SvQ;VAe8Zu_@RN9s?LCvEjJd`!CdN^jip zXGpMdgCubPh6H?|i$3*-HHB@g9gVCVb(P(0jU2R}!a`lbh;{c9Rv&JVV;e9T<%^1` z!NU0xX%+XO8-E18=|y%!2NTNQ-w){i&#+s75@QT`qPqLe;CR#_%0>6X%o0+E>1?>GBqpU)Evm87qX&Tl3Z|C728Ce?uBiSIiVkTchm-&5$&N`~elDg<3Zq zNutQ60vN?lnyOh`QDj{qXx==8MpB2_oSvx)+AB#M1A0ylJ32i~!)dU(s(A2U1lyqH zD9|)#rrc2A;C-`79K}35l#%*$ZedE`=&XstGKip?l{+^Z=DB<+9l)-P?!V3~X;>_H zFD1Aai+jeJ_t~?x0+r6npIUyPF+2^0{3uK1#(|_>( zp7(gZ{paoa-%^O7|Jwe)cJTA@vw8o&mx2oPLm>Endyk(|ezt_=r67L>4s_r(5f9w+ J0Lhc~{{fx7WHkT) literal 0 HcmV?d00001 diff --git a/web/client/assets/项目信息.xlsx b/web/client/assets/项目信息.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..e95a5dd2623f7b18de3557909beda01b22112886 GIT binary patch literal 10269 zcmeHtRZyMH(k`&j;I2V}yAxcqaJN8kcXtmi!7aEuL4v!xyIX+Z9-II_Bzu3t{{CI( zT%M{k7rYd-%sk!G-8J2^5&-a5AkQmMdY%9I`|kzw^ozcgo~*5vwH>|e6B*jmAE1Ac z#h3HkaDjq=n1X?TApMn0$J(0C*}^c&#NaJ zh|^=_`x1+Di^mL3;E3)*a;FC0^Q3X8`3k|O`9W_eGzfml4|S>b5x>RvY za?EI8e#9N-$nEw|IQ>Pgm<5-1+!VHqG0yc13uE5A%@3}|s0s_B`MK?pOQqeJlLm+5 z!B^Y8wX==ZFh=bWMyUs7m({#TF_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4L=mwrBH;rP{!u5f6N;?|bU&=ep(8mUk4Eb(-s=Pvh>4o@8!q z@O@4#Fa<8RR|#RR%0*M0FswcgTE0L{IfFBtq&*PDlbgUmVn36^Jy}j;If1=b+re&2 zvy*8c1x8C55B8ftGn5QDirVD33(_mtj~T`GB5rPq2;G`@(8aIlED1x>2%#Dj+cs)v zIX_a^fn6KiA51Q&n$3AG#JUy%O-9ywX$2QNicD57N~0QDDVD}W9y`2$PWK*q-L0M4 z5O_W{#zDc*er2!U<1{a=^kgUyP!PhWpJPP-XtUn}{`mqu2czHXc`}EJ;Lp(Xccm|b z(=*R+rP6=!{JKp4P1*Bp{k@)*J+Hq^4E@SBp{$vL{1(QG7{}}Q3Z-;)KUiiJ953L6NuUUrY*YPXW!Zf9d@zZ2xW3&*LY**RzG)e_QyO`Hx|g z7ry;s9Oaq!x77;%gZIzjl$YCoIR@~j6i28(w*Rjk{QCSF3iv;lV)$f>C-DDrj$cxK YwVGumAbtf7)TcBN^R#Ds;%Dvu0~MCG>i_@% literal 0 HcmV?d00001 diff --git a/web/client/src/sections/article/actions/article.js b/web/client/src/sections/article/actions/article.js index 4ee0707..23b4ae9 100644 --- a/web/client/src/sections/article/actions/article.js +++ b/web/client/src/sections/article/actions/article.js @@ -85,4 +85,27 @@ export function postInProject(articleObj) { msg: { error: "上传项目信息失败" }, // reducer: { name: "articleInsertInfo" }, }); +} +export function delCancel(query) { + return (dispatch) => + basicAction({ + type: "post", + dispatch: dispatch, + data: query, + actionType: "DEL_CANCEL", + url: `${ApiTable.delCancel}`, + msg: { error: "删除项目信息失败" }, + // reducer: { name: "articleInsertInfo" }, + }); +} +export function getDownProject() { + return (dispatch) => + basicAction({ + type: "get", + dispatch: dispatch, + actionType: "DEL_CANCEL", + url: `${ApiTable.getDownProject}`, + msg: { error: "下载项目信息失败" }, + // reducer: { name: "articleInsertInfo" }, + }); } \ No newline at end of file diff --git a/web/client/src/sections/article/components/import_model.js b/web/client/src/sections/article/components/import_model.js index af133de..95af0de 100644 --- a/web/client/src/sections/article/components/import_model.js +++ b/web/client/src/sections/article/components/import_model.js @@ -12,7 +12,7 @@ import { Button, Input, Card, Modal, Upload, message } from "antd"; import { Request } from "@peace/utils"; import request from "superagent"; import XLSX from "xlsx"; -import { postInProject } from "../actions/article"; +import { postInProject,getDownProject } from "../actions/article"; //TODO 下载模板和上传文件读取 const ImportUser = (props) => { @@ -22,13 +22,16 @@ const ImportUser = (props) => { const [postData, setPostData] = useState([]); const confirm = () => { + handleCancel if (postData.length) { + console.log(postData) setLoading(true); dispatch(postInProject(postData)).then((res) => { console.log(res) + if (res.success) { - handleCancel(); message.success("上传成功"); + handleCancel() } setLoading(false); }); @@ -55,18 +58,9 @@ const ImportUser = (props) => { }) }}>下载模板 */} - - - + + +
下载模板后填写完整后上传
i.name_people), - build_time: dayjs(editData?.build_time), - publish_time: dayjs(editData.publish_time), + build_time: moment(editData?.build_time).format('YYYY-MM-DD'), + publish_time: moment(editData?.publish_time).format('YYYY-MM-DD'), progress:editData.progress }) } @@ -49,14 +50,14 @@ function modeal(props) { name="build_time" rules={[{ required: true, message: '请选择时间' }]} > - + - + { const { dispatch } = props; @@ -19,9 +19,7 @@ export const Default = (props) => { const [visible, setVisible] = useState(false); //弹窗 const [editData, setEditData] = useState(); //数据 const [importVisible, setImportVisible] = useState(false); //弹窗 - const tableActionRef = useRef(); - const dataSore = [{ name_project: '企服v1.0.1', part_people: '投入研发3、测试1', build_time: new Date( ), publish_time: new Date( ), progress: '研发中' }] const columns = [ { title: "项目计划", @@ -38,7 +36,20 @@ export const Default = (props) => { dataIndex: "part_people", hideInSearch: true, render: (dom, record) => { - return
{record.part_people.map((i, index) => record.part_people.length == 1 ? {i.name_people} : {i.name_people}{index < record.part_people.length-1 ? '、':'' }) }
+ return ( +
+ {record.part_people.map((i, index) => + record.part_people.length == 1 ? ( + {i.name_people} + ) : ( + + {i.name_people} + {index < record.part_people.length - 1 ? "、" : ""} + + ) + )} +
+ ); }, }, { @@ -47,7 +58,7 @@ export const Default = (props) => { dataIndex: "build_time", hideInSearch: true, render: (dom, record) => { - return moment(record.build_time).format('YYYY-MM-DD') + return moment(record.build_time).format("YYYY-MM-DD"); }, }, { @@ -56,7 +67,7 @@ export const Default = (props) => { dataIndex: "publish_time", hideInSearch: true, render: (dom, record) => { - return moment(record.publish_time).format('YYYY-MM-DD') + return moment(record.publish_time).format("YYYY-MM-DD"); }, }, { @@ -65,7 +76,7 @@ export const Default = (props) => { hideInSearch: true, order: 3, render: (dom, record) => { - return record.progress + return record.progress; }, }, { @@ -87,14 +98,13 @@ export const Default = (props) => { { - delDataList(record.id); + delDataList(record); }} >
- ) - + ); }, }, { @@ -108,7 +118,7 @@ export const Default = (props) => { type="primary" style={{ width: "200px" }} onClick={() => { - setImportVisible(true) + setImportVisible(true); }} > 项目信息导入 @@ -118,27 +128,50 @@ export const Default = (props) => { }, ]; const handleCancel = () => { - setVisible(false) - } - const handOk = () => { - - } + tableActionRef.current.reload(); + setVisible(false); + }; + const handOk = (values) => { + const query = [{ + build_time: values.build_time, + name_project: values.name_project, + part_people: values.part_people.map((i) => { + return {name_people:i} + }), + progress: values.progress, + publish_time: values.publish_time, + o_name_project:editData?.name_project, + }]; + dispatch(postInProject(query)).then((res) => { + if (res.success) { + handleCancel(); + // tableActionRef.current.reload(); + } + }); + }; const importHandleCancel = () => { - setImportVisible(false) - } + tableActionRef.current.reload(); + setImportVisible(false); + }; //删除资讯 - const delDataList = (ids, type) => { - dispatch(Action.delDataList(ids)).then((res) => { + const delDataList = (record) => { + const query = { + delete: record.name_project, + delete_state: record.progress, + table_name: "test_project", + }; + dispatch(delCancel(query)).then((res) => { if (res.success) { // 刷新 - tableActionRef.current.reload(); + // tableActionRef.current.reload(); + handleCancel() } }); }; //编辑 const editor = (record) => { - setVisible(true) - setEditData(record) + setVisible(true); + setEditData(record); }; return (
@@ -147,14 +180,13 @@ export const Default = (props) => { actionRef={tableActionRef} columns={columns} options={false} - dataSource={counts||[]} + dataSource={counts || []} search={{ optionRender: false, collapsed: false, }} request={async (params) => { const res = await dispatch(postProject()); - console.log(res) setCounts(res.payload.data.projects); return { ...res, @@ -167,8 +199,17 @@ export const Default = (props) => { }} /> - - + +
); }; @@ -181,11 +222,10 @@ const mapStateToProps = (state) => ({}); export default connect(mapStateToProps)(Default); - const data = [ - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: '大王', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: '大王', age: '18', 任务1: 'v1', 计划1: 'time1' } -] \ No newline at end of file + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "大王", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "大王", age: "18", 任务1: "v1", 计划1: "time1" }, +]; diff --git a/web/client/src/sections/homePage/actions/profile.js b/web/client/src/sections/homePage/actions/profile.js index 5334716..5bd8588 100644 --- a/web/client/src/sections/homePage/actions/profile.js +++ b/web/client/src/sections/homePage/actions/profile.js @@ -99,7 +99,7 @@ export function getProject() { type: "post", dispatch: dispatch, actionType: "PROJECT", - url: ApiTable.getProjectUrl, + url: ApiTable.projectUrl, msg: { option: "获取本周在研项目" }, reducer: { name: "project", @@ -113,7 +113,7 @@ export function getPeople() { type: "post", dispatch: dispatch, actionType: "PEOPLE", - url: ApiTable.getPeopleUrl, + url: ApiTable.peopleUrl, msg: { option: "获取人员情况" }, reducer: { name: "people", @@ -127,7 +127,7 @@ export function getWait() { type: "post", dispatch: dispatch, actionType: "WAIT", - url: ApiTable.getWaitUrl, + url: ApiTable.waitUrl, msg: { option: "获取待研发项目" }, reducer: { name: "wait", diff --git a/web/client/src/sections/homePage/containers/index.js b/web/client/src/sections/homePage/containers/index.js index 5d300c7..134b489 100644 --- a/web/client/src/sections/homePage/containers/index.js +++ b/web/client/src/sections/homePage/containers/index.js @@ -13,7 +13,7 @@ const topImg = "/assets/images/top.png"; const pointImg = "/assets/images/point.png"; function Management(props) { - const { dispatch, user } = props; + const { dispatch, user } = props const [dataSource, setDataSource] = useState([]) @@ -21,6 +21,17 @@ function Management(props) { const [peopleData, setPeopleData] = useState([]) const [waitData, setWaitData] = useState([]) + useEffect(() => { + dispatch(getProject()).then((res) => { + setProjectData(res.payload.data.projects) + }) + dispatch(getPeople()).then((res) => { + setPeopleData(res.payload.data.projects) + }) + dispatch(getWait()).then((res) => { + setWaitData(res.payload.data.projects) + }) + },[]) const projectCol = [ { title: '项目名称', @@ -32,19 +43,28 @@ function Management(props) { title: '投入人力', dataIndex: 'part_people', key: 'part_people', - align: 'center' + align: 'center', + render: (dom, record) => { + return
{record.part_people.map((i, index) => record.part_people.length == 1 ? {i.name_people} : {i.name_people}{index < record.part_people.length-1 ? '、':'' }) }
+ }, }, { title: '构建时间', dataIndex: 'build_time', key: 'build_time', - align: 'center' + align: 'center', + render: (dom, record) => { + return moment(record.build_time).format('YYYY-MM-DD') + }, }, { title: '发布时间', dataIndex: 'publish_time', key: 'publish_time', - align: 'center' + align: 'center', + render: (dom, record) => { + return moment(record.publish_time).format('YYYY-MM-DD') + }, }, { title: '进度', @@ -56,53 +76,80 @@ function Management(props) { const peopleCol = [ { - title: '姓名', - dataIndex: 'name', - key: 'name', - align: 'center' - }, - { - title: '部门', - dataIndex: 'dept', - key: 'dept', - align: 'center' - }, - { - title: '11.28', - dataIndex: 'monday', - key: 'monday', - align: 'center', - onCell: (record, index) => { - // console.log("record, index: ", record, index); - return { - className: "cell-class", - colSpan: 2 - }; - } - }, - { - title: '11.29', - dataIndex: 'tuesday', - key: 'tuesday', - align: 'center' - }, - { - title: '11.30', - dataIndex: 'wednesday', - key: 'wednesday', - align: 'center' - }, - { - title: '12.1', - dataIndex: 'thursday', - key: 'thursday', - align: 'center' - }, - { - title: '12.2', - dataIndex: 'friday', - key: 'friday', - align: 'center' + title: "人员姓名", + dataIndex: "name_people", + key: "name_people", + hideInSearch: true, + render: (dom, record) => { + return record.name_people; + }, + }, + { + title: "岗位", + key: "post_people", + dataIndex: "post_people", + hideInSearch: true, + render: (dom, record) => { + return record.post_people + }, + }, + { + title: "周一", + key: "md", + dataIndex: "md", + hideInSearch: true, + render: (dom, record) => { + return record.md + }, + }, + { + title: "周二", + key: "td", + dataIndex: "td", + hideInSearch: true, + render: (dom, record) => { + return record.td + }, + },{ + title: "周三", + key: "wd", + dataIndex: "wd", + hideInSearch: true, + render: (dom, record) => { + return record.wd + }, + },{ + title: "周四", + key: "thd ", + dataIndex: "thd ", + hideInSearch: true, + render: (dom, record) => { + return record.thd + }, + },{ + title: "周五", + key: "fd", + dataIndex: "fd", + hideInSearch: true, + render: (dom, record) => { + return record.fd + }, + },{ + title: "周六", + key: "sd", + dataIndex: "sd", + hideInSearch: true, + render: (dom, record) => { + return record.sd + }, + },{ + title: "周日", + key: "ssd", + dataIndex: "ssd", + hideInSearch: true, + render: (dom, record) => { + return record.ssd + }, }, ]; @@ -132,11 +179,6 @@ function Management(props) { align: 'center' }, ]; - - // useEffect(() => { - // dispatch(getPartyMember()).then((res) => {}); - // }, []); - return ( <>
@@ -154,7 +196,7 @@ function Management(props) {
人员情况
/Information on Personnel
- +
diff --git a/web/client/src/sections/personnel/actions/article.js b/web/client/src/sections/personnel/actions/article.js index 3e311cd..225eaad 100644 --- a/web/client/src/sections/personnel/actions/article.js +++ b/web/client/src/sections/personnel/actions/article.js @@ -86,3 +86,15 @@ export function postInPeople(articleObj) { // reducer: { name: "articleInsertInfo" }, }); } +export function delCancel(query) { + return (dispatch) => + basicAction({ + type: "post", + dispatch: dispatch, + data: query, + actionType: "DEL_CANCEL", + url: `${ApiTable.delCancel}`, + msg: { error: "删除项目信息失败" }, + // reducer: { name: "articleInsertInfo" }, + }); +} diff --git a/web/client/src/sections/personnel/components/import_model.js b/web/client/src/sections/personnel/components/import_model.js index f144154..362e984 100644 --- a/web/client/src/sections/personnel/components/import_model.js +++ b/web/client/src/sections/personnel/components/import_model.js @@ -54,18 +54,9 @@ const ImportUser = (props) => { }) }}>下载模板 */} - - - + + +
下载模板后填写完整后上传
{ for (let i = 0; i < res.length; i++) { let d = res[i]; let name_people = String(d["人员姓名"]).trim(); - let post_people = String(d["岗位"]).trim(); - let time = String(d["本周计划"]).trim(); - let project = String(d["本周任务"]).trim(); - if (!name_people || !post_people || !time || !project) { + + let md = String(d["周一"]).trim(); + let td = String(d["周二"]).trim(); + let wd = String(d["周三"]).trim(); + let thd = String(d["周四"]).trim(); + let fd = String(d["周五"]).trim(); + let sd = String(d["周六"]).trim(); + let ssd = String(d["周日"]).trim(); + if (!name_people || !post_people || !md || !td||!wd||!thd||!fd||!sd||!ssd) { error(`第${i + 1} 行有空值,请填写后重新上传`); return; } postData.push({ name_people, - post_people, - time, - project, + post_people,md,td,wd,thd,fd,sd,ssd + }); } if (postData.length) { - let newArray = postData.reduce((total, cur, index) => { - let hasValue = total.findIndex((current) => { - return current.name_people === cur.name_people; - }); - let obj = { - name_people: cur.name_people, - post_people: cur.post_people, - work: [ - { - time: cur.time, - project: cur.project, - }, - ], - }; - let obj1 = { - time: cur.time, - project: cur.project, - }; - hasValue === -1 && total.push(obj); - hasValue !== -1 && total[hasValue].work.push(obj1); - return total; - }, []); - console.log(newArray); - setPostData(newArray); + // let newArray = postData.reduce((total, cur, index) => { + // let hasValue = total.findIndex((current) => { + // return current.name_people === cur.name_people; + // }); + // let obj = { + // name_people: cur.name_people, + // post_people: cur.post_people, + // work: [ + // { + // time: cur.time, + // project: cur.project, + // }, + // ], + // }; + // let obj1 = { + // time: cur.time, + // project: cur.project, + // }; + // hasValue === -1 && total.push(obj); + // hasValue !== -1 && total[hasValue].work.push(obj1); + // return total; + // }, []); + // console.log(newArray); + setPostData(postData); } let msg = "文件解析完成,点击确定按钮上传保存!"; setMsg(msg); diff --git a/web/client/src/sections/personnel/components/modeal.js b/web/client/src/sections/personnel/components/modeal.js index 8db4470..911de20 100644 --- a/web/client/src/sections/personnel/components/modeal.js +++ b/web/client/src/sections/personnel/components/modeal.js @@ -12,8 +12,14 @@ function modeal(props) { name_people: editData.name_people, post_people: editData.post_people, progress: editData.progress, - time:editData.work.map((i)=>i.time), - project:editData.work.map((i)=>i.project) + md: editData.md, + td: editData.td, + wd: editData.wd, + thd: editData.thd, + fd: editData.fd, + sd: editData.sd, + ssd: editData.ssd, + }) } @@ -46,67 +52,58 @@ function modeal(props) { > - {/* {editData?.work.map(() => { - return <> - - })} */} - - {(fields, { add, remove }) => ( - <> - {editData?.work.map(({ key, name, ...restField }) => ( - - - - - - - + + + + + + + + + + + + + - - ))} - - - - - )} - + + + + +
{ const [importVisible, setImportVisible] = useState(false); //弹窗 const tableActionRef = useRef(); - const dataSore = [{ name_project: '企服v1.0.1', part_people: '投入研发3、测试1', build_time: new Date( ), publish_time: new Date( ), progress: '研发中' }] const columns = [ { title: "人员姓名", @@ -42,14 +41,61 @@ export const Default = (props) => { }, }, { - title: "本周工作计划", - key: "work", - dataIndex: "work", + title: "周一", + key: "md", + dataIndex: "md", hideInSearch: true, render: (dom, record) => { - return
{record?.work?.map((item) => { - return
{item.time}{item.project }
- })}
+ return record.md + }, + }, + { + title: "周二", + key: "td", + dataIndex: "td", + hideInSearch: true, + render: (dom, record) => { + return record.td + }, + },{ + title: "周三", + key: "wd", + dataIndex: "wd", + hideInSearch: true, + render: (dom, record) => { + return record.wd + }, + },{ + title: "周四", + key: "thd ", + dataIndex: "thd ", + hideInSearch: true, + render: (dom, record) => { + return record.thd + }, + },{ + title: "周五", + key: "fd", + dataIndex: "fd", + hideInSearch: true, + render: (dom, record) => { + return record.fd + }, + },{ + title: "周六", + key: "sd", + dataIndex: "sd", + hideInSearch: true, + render: (dom, record) => { + return record.sd + }, + },{ + title: "周日", + key: "ssd", + dataIndex: "ssd", + hideInSearch: true, + render: (dom, record) => { + return record.ssd }, }, { @@ -71,7 +117,7 @@ export const Default = (props) => { { - delDataList(record.id); + delDataList(record); }} > @@ -103,19 +149,44 @@ export const Default = (props) => { ]; const handleCancel = () => { setVisible(false) + tableActionRef.current.reload(); } - const handOk = () => { - + const handOk = (values) => { + const query = [{ + name_people: values.name_people, + post_people: values.post_people, + md: values.md, + td: values.td, + wd: values.wd, + thd: values.thd, + fd: values.fd, + sd: values.sd, + ssd: values.ssd, + o_name_people:editData?.name_people, + }]; + dispatch(postInPeople(query)).then((res) => { + if (res.success) { + handleCancel(); + // tableActionRef.current.reload(); + } + }); } const importHandleCancel = () => { setImportVisible(false) + tableActionRef.current.reload(); } //删除资讯 - const delDataList = (ids, type) => { - dispatch(Action.delDataList(ids)).then((res) => { + const delDataList = (record) => { + const query = { + delete: record?.name_people, + delete_state: record?.post_people, + table_name: "test_people", + }; + dispatch(delCancel(query)).then((res) => { if (res.success) { // 刷新 - tableActionRef.current.reload(); + // tableActionRef.current.reload(); + handleCancel() } }); }; @@ -137,7 +208,6 @@ export const Default = (props) => { collapsed: false, }} request={async(params) => { - console.log(params) const res = await dispatch(postOutPeople()); setCounts(res.payload.data.projects); diff --git a/web/client/src/sections/wait/actions/article.js b/web/client/src/sections/wait/actions/article.js index cdada0d..ffe43b9 100644 --- a/web/client/src/sections/wait/actions/article.js +++ b/web/client/src/sections/wait/actions/article.js @@ -3,62 +3,38 @@ import { ApiTable } from "$utils"; import { Request } from "@peace/utils"; import { basicAction } from "@peace/utils"; -export function addArticle(articleObj) { +export function postWaitUrl(articleObj) { return (dispatch) => basicAction({ type: "post", dispatch: dispatch, data: articleObj, - actionType: "ADD_ARTICLE", - url: `${ApiTable.addArticle}`, - msg: { error: "新增文章失败" }, - reducer: { name: "articleInsertInfo" }, + actionType: "POST_WAITURL", + url: `${ApiTable.waitUrl}`, + msg: { error: "获取项目失败" }, }); } - -export function editArticle(articleObj) { +export function postInWait(articleObj) { return (dispatch) => basicAction({ - type: "put", + type: "post", dispatch: dispatch, data: articleObj, - actionType: "EDIT_ARTICLE", - url: `${ApiTable.addArticle}`, - msg: { error: "编辑文章失败" }, - reducer: { name: "articleInsertInfo" }, + actionType: "POST_INWAIT", + url: `${ApiTable.postInWait}`, + msg: { error: "添加项目失败" }, }); } -export function getDataList(query) { +export function delCancel(query) { return (dispatch) => basicAction({ - type: "get", + type: "post", dispatch: dispatch, - actionType: "GET_DATALIST", - url: ApiTable.getDataList, - query: query, - msg: { error: "获取文章信息失败" }, - reducer: { - name: "articlesfrom", - }, + data: query, + actionType: "DEL_CANCEL", + url: `${ApiTable.delCancel}`, + msg: { error: "删除项目信息失败" }, + // reducer: { name: "articleInsertInfo" }, }); } -export function delDataList(id) { - return (dispatch) => - basicAction({ - type: "del", - dispatch: dispatch, - actionType: "DEL_DATALIST11", - url: ApiTable.delDataList + `?id=${id}`, - query: { id: id }, - msg: { error: "删除文章信息失败" }, - }); -} -export const MODIFYARTICAL = { - REQUEST_SUCCESS: "MODIFY_ARTICAL_SUCCESS", -}; -export function setModifyData(data) { - return (dispatch) => { - dispatch({ type: MODIFYARTICAL.REQUEST_SUCCESS, payload: { data } }); - }; -} diff --git a/web/client/src/sections/wait/components/import_model.js b/web/client/src/sections/wait/components/import_model.js index 41098a5..51b1368 100644 --- a/web/client/src/sections/wait/components/import_model.js +++ b/web/client/src/sections/wait/components/import_model.js @@ -53,7 +53,7 @@ const ImportUser = props => { }) }}>下载模板 */} - +
下载模板后填写完整后上传
diff --git a/web/client/src/sections/wait/components/modeal.js b/web/client/src/sections/wait/components/modeal.js index 53e5c41..3782a04 100644 --- a/web/client/src/sections/wait/components/modeal.js +++ b/web/client/src/sections/wait/components/modeal.js @@ -3,19 +3,21 @@ import { Modal, Form, Input, Button,DatePicker,Select } from 'antd' import dayjs from 'dayjs'; function modeal(props) { const [form] = Form.useForm(); - const { visible, handleOk, handleCancel, editData } = props + const { visible, handleOk, handleCancel, editData ,setEditData,setState} = props console.log(editData) useEffect(() => { if (editData && visible) { form.setFieldsValue({ name_project: editData.name_project, - part_people: editData.part_people, - build_time: dayjs(editData?.build_time), - publish_time: dayjs(editData.publish_time), + from_project: editData.from_project, + contacts: editData.contacts, progress:editData.progress }) + setState(true) } }, [editData, visible]) + + return ( - - + - - - - +
diff --git a/web/client/src/sections/wait/containers/index.js b/web/client/src/sections/wait/containers/index.js index 647d8dc..d625bfa 100644 --- a/web/client/src/sections/wait/containers/index.js +++ b/web/client/src/sections/wait/containers/index.js @@ -3,25 +3,21 @@ import React, { useEffect, useState, useRef } from "react"; import { connect } from "react-redux"; import { Button, Popconfirm } from "antd"; import ProTable from "@ant-design/pro-table"; -import Action from "../actions/index"; +import { postWaitUrl, postInWait,delCancel } from "../actions/article"; import moment from "moment"; import { push } from "react-router-redux"; import { Scroller } from "$components"; -import ProjectModeal from '../components/modeal' -import ImportModeal from '../components/import_model' +import ProjectModeal from "../components/modeal"; +import ImportModeal from "../components/import_model"; export const Default = (props) => { const { dispatch } = props; - const [heading, setHeading] = useState(); //标题 - const [state, setState] = useState(); //状态 - const [day, setDay] = useState(); //发布时间 + const [state, setState] = useState(false); //状态 const [counts, setCounts] = useState(); //数据 const [visible, setVisible] = useState(false); //弹窗 const [editData, setEditData] = useState(); //数据 - const [importVisible, setImportVisible] = useState(false); //弹窗 - const tableActionRef = useRef(); - const dataSore = [{ name_project: '企服v1.0.1', part_people: '投入研发3、测试1', build_time: new Date(), publish_time: new Date(), progress: '研发中' }] + const columns = [ { title: "项目", @@ -38,7 +34,7 @@ export const Default = (props) => { dataIndex: "from_project", hideInSearch: true, render: (dom, record) => { - return record.part_people + return record.from_project; }, }, { @@ -47,14 +43,15 @@ export const Default = (props) => { dataIndex: "contacts", hideInSearch: true, render: (dom, record) => { - return moment(record.build_time).format('YYYY-MM-DD') + return record.contacts; }, }, { - title: '处理进度', - dataIndex: 'progress', - key: 'progress', - align: 'center' + title: "处理进度", + dataIndex: "progress", + key: "progress", + align: "center", + hideInSearch: true, }, { title: "操作", @@ -75,14 +72,13 @@ export const Default = (props) => { { - delDataList(record.id); + delDataList(record); }} >
- ) - + ); }, }, { @@ -96,37 +92,72 @@ export const Default = (props) => { type="primary" style={{ width: "200px" }} onClick={() => { - setImportVisible(true) + editor(); }} > - 项目信息导入 + 添加 ); }, }, ]; const handleCancel = () => { - setVisible(false) - } - const handOk = () => { + tableActionRef.current.reload(); + setVisible(false); + }; + const handOk = (values) => { + let query = null; + if (state) { + query = [ + { + name_project: values.name_project, + from_project: values.from_project, + contacts: values.contacts, + progress: values.progress, + o_name_project: editData?.name_project, + }, + ]; + } else { + query = [ + { + name_project: values.name_project, + from_project: values.from_project, + contacts: values.contacts, + progress: values.progress, + }, + ]; + } + + dispatch(postInWait(query)).then((res) => { + if (res.success) { + handleCancel(); + setEditData([]); + tableActionRef.current.reload(); + } + }); + }; - } - const importHandleCancel = () => { - setImportVisible(false) - } //删除资讯 - const delDataList = (ids, type) => { - dispatch(Action.delDataList(ids)).then((res) => { + const delDataList = (record) => { + const query = { + delete: record.name_project, + delete_state: record.progress, + table_name: "test_waiting", + }; + dispatch(delCancel(query)).then((res) => { if (res.success) { // 刷新 - tableActionRef.current.reload(); + // tableActionRef.current.reload(); + handleCancel() } }); }; //编辑 const editor = (record) => { - setVisible(true) - setEditData(record) + if (record) { + setEditData(record); + } + setVisible(true); }; return (
@@ -135,28 +166,14 @@ export const Default = (props) => { actionRef={tableActionRef} columns={columns} options={false} - dataSource={dataSore} + dataSource={counts || []} search={{ optionRender: false, collapsed: false, }} request={async (params) => { - let query = { - type: -1, - searchValue: heading, - status: state, - page: params.current, - limit: params.pageSize, - publishTime: - day && day.length && day[0].trim() != "" - ? JSON.stringify([ - moment(day[0]).startOf("day"), - moment(day[1]).endOf("day"), - ]) - : null, - }; - const res = await dispatch(Action.getDataList(query)); - setCounts(res.payload.data); + const res = await dispatch(postWaitUrl()); + setCounts(res.payload.data.projects); return { ...res, total: res.payload.data ? res.payload.data.total : 0, @@ -168,8 +185,15 @@ export const Default = (props) => { }} /> - - +
); }; @@ -182,11 +206,10 @@ const mapStateToProps = (state) => ({}); export default connect(mapStateToProps)(Default); - const data = [ - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: 'yongchu', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: '大王', age: '18', 任务1: 'v1', 计划1: 'time1' }, - { name: '大王', age: '18', 任务1: 'v1', 计划1: 'time1' } -] \ No newline at end of file + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "yongchu", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "大王", age: "18", 任务1: "v1", 计划1: "time1" }, + { name: "大王", age: "18", 任务1: "v1", 计划1: "time1" }, +]; diff --git a/web/client/src/utils/webapi.js b/web/client/src/utils/webapi.js index 0521bde..957e728 100644 --- a/web/client/src/utils/webapi.js +++ b/web/client/src/utils/webapi.js @@ -7,12 +7,12 @@ export const ApiTable = { peopleUrl: "outPeople", // 人员情况 waitUrl: "outWait", // 待研项目 postInProject:'inProject', // 增加项目 - postInPeople:'inPeople',//增加人员任务 - //支委会人员信息 - getCommittee: "partyOrganizations", //获取支委会人员 - postCommittee: "partyOrganization", //新增 - putCommittee: "partyOrganization/:id", //修改 - apiRoot: 'query/api/root', + postInPeople: 'inPeople',//增加人员任务 + postInWait: 'inWait',//增加人员任务 + + delCancel: 'deleteDB', //删除信息 + //下载项目模板 + getDownProject:'downProject' }; export const RouteTable = {