You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
NewEduCoderBuild/p__Graduations__Lists__Pers...

1 line
26 KiB

"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[66063],{14516:function(e,t,n){n.r(t),n.d(t,{default:function(){return T}});var r=n(82242),s=n.n(r),a=n(37205),c=n.n(a),i=n(7557),l=n.n(i),o=n(41498),u=n.n(o),d=n(79800),p=n.n(d),h=n(59301),f={flex_box_center:"flex_box_center___SU33_",flex_space_between:"flex_space_between___NnGYW",flex_box_vertical_center:"flex_box_vertical_center___lX31d",flex_box_center_end:"flex_box_center_end___KWld3",flex_box_column:"flex_box_column___QHzze",ActvieE3:"ActvieE3___Hv5W0",Actvie00:"Actvie00___xMrRz",body:"body___gECjr",AddBut:"AddBut___iCNdk",selectInfo:"selectInfo___2doF7"},m=n(75936),x=n(78241),g=n(6848),v=n(43418),j=n(81327),w=n(3113),_=n(95237),Z=n(43604),y=n(8591),b=n(66999),S=n(51945),k=n(86859),C=n(24650),N=n(89257),O=n(89392),I=n(67604),E=n(50883),F=n(40660),$=n(89260),z=n(37712),T=(0,m.connect)((function(e){return{graduations:e.graduations,loading:e.loading}}))((function(e){var t,n,r,a,i,o,d,T,L,P,H,D,A=e.graduations,M=e.loading,R=e.dispatch,B=(0,m.useParams)(),G=(0,m.useSearchParams)(),V=p()(G,1)[0],Y=(0,h.useState)("teachers"),U=p()(Y,2),q=U[0],W=U[1],K=(0,h.useState)("processing"),X=p()(K,2),Q=X[0],J=X[1],ee=(0,h.useRef)(""),te=(0,h.useState)(!1),ne=p()(te,2),re=ne[0],se=ne[1],ae=x.Z.useForm(),ce=p()(ae,1)[0],ie=(0,h.useState)(!1),le=p()(ie,2),oe=le[0],ue=le[1],de=(0,h.useState)({id:B.id,keyword:ee.current,page:1,per_page:20}),pe=p()(de,2),he=pe[0],fe=pe[1],me=(0,h.useState)([]),xe=p()(me,2),ge=xe[0],ve=xe[1],je=[{title:"教师姓名",width:112,dataIndex:"name",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"所属学校",dataIndex:"school",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"所属学院",ellipsis:!0,dataIndex:"department",render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"工号",width:120,dataIndex:"staff_id",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"职称",dataIndex:"technical_title",width:80,ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"操作",align:"right",width:100,dataIndex:"name",render:function(e,t){return(0,z.jsx)(z.Fragment,{children:(0,$.tu)()&&(0,z.jsxs)(z.Fragment,{children:["processing"===Q&&(0,z.jsx)("a",{className:f.ActvieE3,onClick:function(){v.Z.confirm({centered:!0,icon:null,title:"删除",content:(0,z.jsx)("div",{className:"",children:'确认要将"'.concat(t.name,'"从该毕业设计中移除吗?移除后该用 户在毕设中提交的文件将被清空')}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.zT)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"删除"}),"processing"!==Q&&(0,z.jsx)(z.Fragment,{children:(0,z.jsxs)(j.Z,{children:[(0,z.jsx)("a",{onClick:function(){v.Z.confirm({centered:!0,content:(0,z.jsx)("div",{className:"",children:'是否确认同意"'.concat(t.name,'"的加入?')}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.V1)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"通过"}),(0,z.jsx)("a",{onClick:function(){v.Z.confirm({icon:null,centered:!0,title:'是否确认拒绝"'.concat(t.name,'"的加入?'),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.Ib)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"驳回"})]})})]})})}}],we=[{title:"学生姓名",width:112,dataIndex:"name",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e})})}},{title:"学号",dataIndex:"student_id",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"手机号",width:200,ellipsis:!0,dataIndex:"phone",render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"专业",width:200,dataIndex:"major",ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"所属课题",dataIndex:"graduation_tasks",width:136,ellipsis:!0,render:function(e){return(0,z.jsx)(g.Z,{placement:"topLeft",title:e,children:(0,z.jsx)("span",{children:e||"- -"})})}},{title:"操作",align:"right",width:120,dataIndex:"name",render:function(e,t){return(0,z.jsx)(z.Fragment,{children:(0,$.tu)()&&(0,z.jsxs)(z.Fragment,{children:["processing"===Q&&(0,z.jsxs)(z.Fragment,{children:[(0,z.jsx)("a",{className:f.Active00,onClick:function(){ce.setFieldsValue(t),ue(!0)},children:"编辑"}),(0,z.jsx)("a",{className:"ml20 ".concat(f.ActvieE3),onClick:function(){v.Z.confirm({centered:!0,icon:null,title:"删除",content:'确认要将"'.concat(t.name,'"从该毕业设计中移除吗?移除后该用 户在毕设中提交的文件将被清空'),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.rU)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"删除"})]}),"processing"!==Q&&(0,z.jsx)(z.Fragment,{children:(0,z.jsxs)(j.Z,{children:[(0,z.jsx)("a",{className:f.Active00,onClick:function(){v.Z.confirm({centered:!0,content:(0,z.jsx)("div",{className:"",children:'是否确认同意"'.concat(t.name,'"的加入?')}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.Fi)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"通过"}),(0,z.jsx)("a",{className:"ml20 ".concat(f.ActvieE3),onClick:function(){v.Z.confirm({icon:null,centered:!0,title:'是否确认拒绝"'.concat(t.name,'"的加入?'),onOk:(0,O.throttle)(u()(l()().mark((function e(){var n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.Zd)(B.id,{ids:[t.id]});case 2:0===(null==(n=e.sent)?void 0:n.status)&&ye();case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:"驳回"})]})})]})})}}],_e=[{id:"processing",name:"已审核 ".concat(("teachers"==q?null==A||null===(t=A.teachers)||void 0===t?void 0:t.pass_count:null==A||null===(n=A.students)||void 0===n?void 0:n.pass_count)||0)},{id:"end",name:"未审核 ".concat(("teachers"==q?null==A||null===(r=A.teachers)||void 0===r?void 0:r.not_pass_count:null==A||null===(a=A.students)||void 0===a?void 0:a.not_pass_count)||0)}],Ze={selectedRowKeys:ge,onChange:function(e){console.log("selectedRowKeys changed: ",e),ve(e)}},ye=function(){var e=u()(l()().mark((function e(){var t;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t="graduations/getGraduationsStudents",he.keyword=ee.current,""===Q?delete he.not_pass:he.not_pass="processing"!==Q,"teachers"===q&&(t="graduations/getGraduationsTeachers"),R({type:t,payload:he});case 5:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return(0,h.useEffect)((function(){V.get("state")&&0==Number(V.get("state"))?J("end"):J("processing"),location.pathname.includes("teachers")?W("teachers"):W("students")}),[]),(0,h.useEffect)((function(){ye()}),[q,Q,null==A?void 0:A.updateIndex]),(0,z.jsxs)("section",{className:f.body,children:[(0,z.jsx)(N.YG,{value:q,tabBarExtraContent:(0,z.jsx)(z.Fragment,{children:(0,z.jsx)(j.Z,{children:(0,$.tu)()&&(0,z.jsxs)(z.Fragment,{children:["teachers"!=q&&(0,z.jsx)(w.ZP,{className:f.AddBut,onClick:function(){return se(!0)},children:"添加学生"}),"teachers"==q&&(0,z.jsx)(w.ZP,{className:f.AddBut,onClick:function(){return se(!0)},children:"添加教师"})]})})}),dataSource:[{id:"teachers",name:"教师"},{id:"students",name:"学生"}],onChange:function(e){ee.current="",J("processing"),m.history.push("/graduations/".concat(B.id,"/").concat(e)),ve([])}}),(0,z.jsxs)(_.Z,{wrap:!1,align:"middle",justify:"space-between",children:[(0,z.jsx)(Z.Z,{children:(0,z.jsx)(N.qp,{title:"状态",className:"mt20",dataSource:_e,titleWidth:28,value:Q,onChange:function(e){he.page=1,fe(he),J(e),ve([])}})}),(0,z.jsx)(Z.Z,{children:(0,z.jsx)(N.t7,{style:{width:210,height:"38px"},placeholder:"".concat("teachers"===q?"教师姓名/工号":"学生姓名/学号"),value:ee.current,onChange:function(e){he.page=1,fe(he),ee.current=e,ye()}})})]}),(null==ge?void 0:ge.length)>0&&(0,$.tu)()&&(0,z.jsxs)("div",{className:f.selectInfo,children:[(0,z.jsxs)("div",{children:["已选择 ",(0,z.jsx)("span",{className:"c-blue",children:null==ge?void 0:ge.length})," 项"]}),(0,z.jsxs)("div",{children:["processing"===Q&&(0,z.jsxs)("a",{className:"c-red",onClick:function(){v.Z.confirm({centered:!0,content:(0,z.jsx)("div",{className:"",children:"请确认是否要批量移除吗?"}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var t;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,("teachers"===q?I.zT:I.rU)(B.id,{ids:c()(ge)});case 2:0===(null==(t=e.sent)?void 0:t.status)&&(y.ZP.warning("批量删除操作成功"),he.page=1,fe(he),ve([]),ye());case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:[(0,z.jsx)("span",{className:"iconfont icon-shanchu12 mr8"}),"批量删除"]}),"processing"!==Q&&(0,z.jsxs)(j.Z,{children:[(0,z.jsxs)("a",{className:"c-green-29b ml20",onClick:function(){v.Z.confirm({centered:!0,content:(0,z.jsx)("div",{className:"",children:"请确认是否要批量通过吗?"}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var t;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,("teachers"===q?I.V1:I.Fi)(B.id,{ids:c()(ge)});case 2:0===(null==(t=e.sent)?void 0:t.status)&&(ve([]),y.ZP.warning("批量通过操作成功"),ye());case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:[(0,z.jsx)("span",{className:"iconfont icon-tongguobeifen mr8 c-green-29b"}),"批量通过"]}),(0,z.jsxs)("a",{className:"c-red ml20",onClick:function(){v.Z.confirm({icon:null,centered:!0,content:(0,z.jsx)("div",{className:"",children:"请确认是否要批量驳回吗?"}),onOk:(0,O.throttle)(u()(l()().mark((function e(){var t;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,("teachers"===q?I.Ib:I.Zd)(B.id,{ids:c()(ge)});case 2:0===(null==(t=e.sent)?void 0:t.status)&&(ve([]),y.ZP.warning("批量驳回操作成功"),ye());case 4:case"end":return e.stop()}}),e)}))),2e3)})},children:[(0,z.jsx)("span",{className:"iconfont icon-bohuibeifen mr8"}),"批量驳回"]})]})]})]}),"teachers"===q&&(0,z.jsxs)(b.Z,{loading:M.effects["graduations/getGraduationsTeachers"],avatar:!0,active:!0,children:[(0,z.jsx)(S.Z,{rowSelection:Ze,style:{minHeight:500},locale:{emptyText:(0,z.jsx)(E.Z,{customText:"暂时还没有相关数据哦!"})},columns:je,dataSource:(null==A||null===(i=A.teachers)||void 0===i?void 0:i.data)||[],pagination:!1}),0!=(null==A||null===(o=A.teachers)||void 0===o?void 0:o.count)&&(0,z.jsxs)(_.Z,{className:"mt20 mb20",wrap:!1,align:"middle",justify:"space-between",children:[(0,z.jsxs)(Z.Z,{children:["共 ",(0,z.jsx)("span",{className:"c-blue",children:null==A||null===(d=A.teachers)||void 0===d?void 0:d.count})," 条数据"]}),(0,z.jsx)(Z.Z,{children:(0,z.jsx)(k.Z,{showQuickJumper:!0,showSizeChanger:!0,onShowSizeChange:function(e,t){he.per_page=t,fe(s()({},he)),ye()},current:he.page,pageSize:he.per_page,onChange:function(e){he.page=e,fe(s()({},he)),ye()},total:null==A||null===(T=A.teachers)||void 0===T?void 0:T.count})})]})]}),"teachers"!==q&&(0,z.jsxs)(b.Z,{loading:M.effects["graduations/getGraduationsStudents"],avatar:!0,active:!0,children:[(0,z.jsx)(S.Z,{rowSelection:Ze,style:{minHeight:500},locale:{emptyText:(0,z.jsx)(E.Z,{customText:"暂时还没有相关数据哦!"})},columns:we,dataSource:(null==A||null===(L=A.students)||void 0===L?void 0:L.data)||[],pagination:!1}),0!=(null==A||null===(P=A.students)||void 0===P?void 0:P.count)&&(0,z.jsxs)(_.Z,{className:"mt20 mb20",wrap:!1,align:"middle",justify:"space-between",children:[(0,z.jsxs)(Z.Z,{children:["共 ",(0,z.jsx)("span",{className:"c-blue",children:null==A||null===(H=A.students)||void 0===H?void 0:H.count})," 条数据"]}),(0,z.jsx)(Z.Z,{children:(0,z.jsx)(k.Z,{showQuickJumper:!0,showSizeChanger:!0,current:he.page,pageSize:he.per_page,onShowSizeChange:function(e,t){he.per_page=t,he.page=1,fe(s()({},he)),ye()},onChange:function(e){he.page=e,fe(s()({},he)),ye()},total:null==A||null===(D=A.students)||void 0===D?void 0:D.count})})]})]}),(0,z.jsx)(v.Z,{centered:!0,open:oe,destroyOnClose:!0,title:"编辑学生",onCancel:function(){return ue(!1)},onOk:function(){return ce.submit()},children:(0,z.jsxs)(x.Z,{className:"mt10",layout:"vertical",colon:!1,form:ce,initialValues:{},size:"large",onFinish:function(){var e=u()(l()().mark((function e(t){return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,I.Ot)(s()({identifier:B.id},t));case 2:0==e.sent.status&&(y.ZP.success("修改成功"),ue(!1),ye());case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),children:[(0,z.jsx)(x.Z.Item,{htmlFor:null,label:(0,z.jsx)("span",{style:{color:"#5F6368"},children:"专业"}),name:"major",rules:[{required:!0,message:"请输入专业"},{type:"string",max:60,message:"输入超限,请缩减字符数"},{type:"string",whitespace:!0,message:"内容不能全为空格"}],children:(0,z.jsx)(C.Z,{showCount:!0,maxLength:60,size:"large"})}),(0,z.jsx)(x.Z.Item,{hidden:!0,name:"id",children:(0,z.jsx)(C.Z,{})})]})}),(0,z.jsx)(F.Z,{open:re,onCancel:function(){return se(!1)},title:"teachers"===q?"添加老师":"添加学生",OnOk:function(){var e=u()(l()().mark((function e(t){return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,("teachers"==q?I.HF:I.NX)({id:B.id,user_ids:t});case 2:0==e.sent.status&&(y.ZP.success("添加成功"),se(!1),R({type:"graduations/getGraduationsDetails",payload:{id:null==B?void 0:B.id}}),ye());case 4:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()})]})}))},40660:function(e,t,n){var r=n(37205),s=n.n(r),a=n(82242),c=n.n(a),i=n(7557),l=n.n(i),o=n(41498),u=n.n(o),d=n(79800),p=n.n(d),h=n(59301),f=n(75936),m=n(78241),x=n(6848),g=n(8591),v=n(43418),j=n(57809),w=n(24650),_=n(88522),Z=n(51945),y=n(61186),b=n.n(y),S=n(50883),k=n(67604),C=n(89257),N=n(37712);t.Z=(0,f.connect)((function(e){return{graduations:e.graduations}}))((function(e){e.graduations.StageSetting;var t=e.onCancel,n=e.OnOk,r=e.open,a=void 0!==r&&r,i=e.title,o=(e.dispatch,(0,f.useParams)()),d=(0,h.useState)([]),y=p()(d,2),O=y[0],I=y[1],E=m.Z.useForm(),F=p()(E,1)[0],$=(0,h.useState)({school:"",search:"",search_type:"name"}),z=p()($,2),T=z[0],L=z[1],P=(0,h.useState)(!0),H=p()(P,2),D=H[0],A=H[1],M=(0,h.useState)(!1),R=p()(M,2),B=R[0],G=R[1],V=(0,h.useState)(!1),Y=p()(V,2),U=Y[0],q=Y[1],W=(0,h.useState)([]),K=p()(W,2),X=K[0],Q=K[1],J=(0,h.useState)(0),ee=p()(J,2),te=ee[0],ne=ee[1],re=(0,h.useState)(0),se=p()(re,2),ae=se[0],ce=se[1],ie=(0,h.useState)(1),le=p()(ie,2),oe=le[0],ue=le[1],de=(0,h.useState)([]),pe=p()(de,2),he=pe[0],fe=pe[1],me=(0,h.useState)(!1),xe=p()(me,2),ge=xe[0],ve=xe[1],je=(0,h.useRef)(null);(0,h.useEffect)((function(){switch(i){case"添加学生":ce(0);break;case"添加老师":ce(1);break;default:ce(null)}}),[a]),(0,h.useEffect)((function(){u()(l()().mark((function e(){var t,n;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,k.xF)({keyword:"",per_page:9999});case 2:n=e.sent,I(null==n||null===(t=n.schools)||void 0===t?void 0:t.map((function(e){return{label:e.name,value:e.id}})));case 4:case"end":return e.stop()}}),e)})))()}),[]);var we=[{title:"姓名",width:100,ellipsis:!0,dataIndex:"name",render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{style:{color:"#000"},children:e||"--"})})}},{title:"学校/单位",dataIndex:"school",ellipsis:!0,render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{style:{color:"#000"},children:e||"--"})})}},{title:"院系/部门",dataIndex:"department",width:130,ellipsis:!0,render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{style:{color:"#000"},children:e||"--"})})}},{title:"学号/工号",width:100,dataIndex:"student_number",ellipsis:!0,render:function(e,t){return(0,N.jsx)(x.Z,{placement:"topLeft",title:t.staff_id||t.student_id,children:(0,N.jsx)("span",{className:"c-grey-666",children:t.staff_id||t.student_id||"--"})})}},{title:"手机",width:110,dataIndex:"phone",ellipsis:!0,render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{className:"c-grey-666",children:e||"--"})})}},{title:"邮箱",dataIndex:"mail",width:120,ellipsis:!0,render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{className:"c-grey-666",children:e||"--"})})}},{title:"实名认证",dataIndex:"authentication",width:80,render:function(e){return e?(0,N.jsx)("span",{style:{color:"#000"},children:"是"}):"否"}},{title:"最后登录时间",dataIndex:"last_login_on",width:140,ellipsis:!0,render:function(e){return(0,N.jsx)(x.Z,{placement:"topLeft",title:e,children:(0,N.jsx)("span",{className:"c-grey-666",children:b()(e).format("YYYY-MM-DD HH:mm")})})}},{title:"状态",dataIndex:"checked",width:80,render:function(e){return e?(0,N.jsx)("span",{className:"c-green",children:"已添加"}):(0,N.jsx)("span",{className:"c-grey-333",children:"未添加"})}}],_e=function(){var e=u()(l()().mark((function e(t){var n,r,s;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(je.current&&(null===(n=je.current)||void 0===n||null===(n=n.querySelector(".ant-table-body"))||void 0===n||n.scrollTo(0,0)),ve(!0),fe([]),t.search||t.school){e.next=6;break}return g.ZP.warning("请输入搜索内容"),e.abrupt("return");case 6:if(G(!0),L(t),ue(1),s=c()({id:o.id},t),0!=ae){e.next=14;break}return e.next=13,(0,k.l5)(s);case 13:r=e.sent;case 14:if(1!=ae){e.next=18;break}return e.next=17,(0,k.bS)(s);case 17:r=e.sent;case 18:0==r.status&&(Q(r.data),ne(r.count)),G(!1);case 20:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Ze=function(){var e=u()(l()().mark((function e(){var t,n,r,a,i,u,d,p,h,f=arguments;return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(f.length>0&&void 0!==f[0]&&f[0],a=null===(t=je.current)||void 0===t?void 0:t.querySelector(".ant-table-body").scrollHeight,i=null===(n=je.current)||void 0===n?void 0:n.querySelector(".ant-table-body").scrollTop,u=null===(r=je.current)||void 0===r?void 0:r.querySelector(".ant-table-body").clientHeight,a!=i+u||!D||B){e.next=18;break}if(G(!0),ue(oe+1),p=c()({page:oe+1,id:o.id},T),0!=ae){e.next=12;break}return e.next=11,(0,k.l5)(p);case 11:d=e.sent;case 12:if(1!=ae){e.next=16;break}return e.next=15,(0,k.bS)(p);case 15:d=e.sent;case 16:0==d.status&&((null===(h=d)||void 0===h||null===(h=h.data)||void 0===h?void 0:h.length)+X.length==d.count&&A(!1),Q([].concat(s()(X),s()(d.data))),ne(d.count)),G(!1);case 18:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ye={selectedRowKeys:he,onChange:function(e,t){fe(e)},getCheckboxProps:function(e){return{disabled:e.checked,name:e.checked}}};return(0,N.jsxs)(v.Z,{destroyOnClose:!0,width:1200,style:{height:"613px"},open:a,confirmLoading:U,title:i,bodyStyle:{padding:"0px 25px"},onOk:u()(l()().mark((function e(){return l()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(he.length>0)){e.next=11;break}return q(!0),e.next=4,n(he);case 4:q(!1),F.resetFields(),Q([]),ve(!1),fe([]),e.next=12;break;case 11:g.ZP.warning("请选择添加人员");case 12:case"end":return e.stop()}}),e)}))),onCancel:function(){t(),F.resetFields(),ve(!1),Q([]),fe([])},children:[(0,N.jsxs)(m.Z,{layout:"inline",className:"mt10",colon:!1,form:F,initialValues:{school:"",search:"",search_type:"name"},onValuesChange:function(e,t){return L(t)},size:"large",onFinish:_e,children:[(0,N.jsx)(m.Z.Item,{name:"search_type",label:"搜索类型",children:(0,N.jsxs)(j.default,{style:{width:160},children:[(0,N.jsx)(j.default.Option,{value:"name",children:"姓名"}),(0,N.jsx)(j.default.Option,{value:"phone",children:"手机号"}),(0,N.jsx)(j.default.Option,{value:"mail",children:"邮箱"})]})}),(0,N.jsx)(m.Z.Item,{name:"search",label:"搜索内容",children:(0,N.jsx)(w.Z,{allowClear:!0,style:{width:320},placeholder:"请输入搜索内容",defaultValue:""})}),(0,N.jsx)(m.Z.Item,{name:"school",label:"单位",children:(0,N.jsx)(_.Z,{options:O,style:{width:380},placeholder:"请输入单位名称",onSelect:function(e,t){console.log(e,t),F.setFieldsValue({school:t.label})},filterOption:function(e,t){return-1!==t.label.toUpperCase().indexOf(e.toUpperCase())}})}),(0,N.jsx)(m.Z.Item,{noStyle:!0,children:(0,N.jsx)(C.op,{onClick:function(){return F.submit()},size:"large",shape:"default",children:"搜索"})})]}),(0,N.jsx)("div",{onScrollCapture:function(){return Ze()},children:ge?(0,N.jsx)(Z.Z,{className:"mt20",loading:B,showHeader:X.length>0,scroll:te>10?{y:450}:{},rowKey:"user_id",rowSelection:ye,locale:{emptyText:(0,N.jsx)(S.Z,{customText:"未找到符合条件的数据,请重新调整您的筛选条件。"})},pagination:!1,dataSource:X,ref:je,columns:we}):(0,N.jsx)(S.Z,{customText:"请搜索要添加的人员"})})]})}))},88522:function(e,t,n){var r=n(92310),s=n.n(r),a=n(75440),c=n(55405),i=n(59301),l=n(53487),o=n(92343),u=n(36355),d=n(57809);const{Option:p}=d.default;function h(e){return e&&e.type&&(e.type.isSelectOption||e.type.isSelectOptGroup)}const f=(e,t)=>{const{prefixCls:n,className:r,popupClassName:l,dropdownClassName:f,children:m,dataSource:x}=e,g=(0,a.Z)(m);let v;1===g.length&&(0,o.l$)(g[0])&&!h(g[0])&&([v]=g);const j=v?()=>v:void 0;let w;w=g.length&&h(g[0])?m:x?x.map((e=>{if((0,o.l$)(e))return e;switch(typeof e){case"string":return i.createElement(p,{key:e,value:e},e);case"object":{const{value:t}=e;return i.createElement(p,{key:t,value:t},e.text)}default:return}})):[];const{getPrefixCls:_}=i.useContext(u.E_),Z=_("select",n);return i.createElement(d.default,Object.assign({ref:t,suffixIcon:null},(0,c.Z)(e,["dataSource","dropdownClassName"]),{prefixCls:Z,popupClassName:l||f,className:s()(`${Z}-auto-complete`,r),mode:d.default.SECRET_COMBOBOX_MODE_DO_NOT_USE},{getInputElement:j}),w)},m=i.forwardRef(f),x=(0,l.Z)(m);m.Option=p,m._InternalPanelDoNotUseOrYouWillBeFired=x,t.Z=m},31797:function(e,t,n){n.d(t,{Z:function(){return _}});var r=n(59301),s=n(56762),a=n(92343),c=n(92310),i=n.n(c),l=n(36355),o=n(66999);var u=e=>{const{value:t,formatter:n,precision:s,decimalSeparator:a,groupSeparator:c="",prefixCls:i}=e;let l;if("function"==typeof n)l=n(t);else{const e=String(t),n=e.match(/^(-?)(\d*)(\.(\d+))?$/);if(n&&"-"!==e){const e=n[1];let t=n[2]||"0",o=n[4]||"";t=t.replace(/\B(?=(\d{3})+(?!\d))/g,c),"number"==typeof s&&(o=o.padEnd(s,"0").slice(0,s>0?s:0)),o&&(o=`${a}${o}`),l=[r.createElement("span",{key:"int",className:`${i}-content-value-int`},e,t),o&&r.createElement("span",{key:"decimal",className:`${i}-content-value-decimal`},o)]}else l=e}return r.createElement("span",{className:`${i}-content-value`},l)},d=n(17313),p=n(83116),h=n(37613);const f=e=>{const{componentCls:t,marginXXS:n,padding:r,colorTextDescription:s,titleFontSize:a,colorTextHeading:c,contentFontSize:i,fontFamily:l}=e;return{[`${t}`]:Object.assign(Object.assign({},(0,d.Wf)(e)),{[`${t}-title`]:{marginBottom:n,color:s,fontSize:a},[`${t}-skeleton`]:{paddingTop:r},[`${t}-content`]:{color:c,fontSize:i,fontFamily:l,[`${t}-content-value`]:{display:"inline-block",direction:"ltr"},[`${t}-content-prefix, ${t}-content-suffix`]:{display:"inline-block"},[`${t}-content-prefix`]:{marginInlineEnd:n},[`${t}-content-suffix`]:{marginInlineStart:n}}})}};var m=(0,p.Z)("Statistic",(e=>{const t=(0,h.TS)(e,{});return[f(t)]}),(e=>{const{fontSizeHeading3:t,fontSize:n}=e;return{titleFontSize:n,contentFontSize:t}}));var x=e=>{const{prefixCls:t,className:n,rootClassName:s,style:a,valueStyle:c,value:d=0,title:p,valueRender:h,prefix:f,suffix:x,loading:g=!1,onMouseEnter:v,onMouseLeave:j,decimalSeparator:w=".",groupSeparator:_=","}=e,{getPrefixCls:Z,direction:y,statistic:b}=r.useContext(l.E_),S=Z("statistic",t),[k,C]=m(S),N=r.createElement(u,Object.assign({decimalSeparator:w,groupSeparator:_,prefixCls:S},e,{value:d})),O=i()(S,{[`${S}-rtl`]:"rtl"===y},null==b?void 0:b.className,n,s,C);return k(r.createElement("div",{className:O,style:Object.assign(Object.assign({},null==b?void 0:b.style),a),onMouseEnter:v,onMouseLeave:j},p&&r.createElement("div",{className:`${S}-title`},p),r.createElement(o.Z,{paragraph:!1,loading:g,className:`${S}-skeleton`},r.createElement("div",{style:c,className:`${S}-content`},f&&r.createElement("span",{className:`${S}-content-prefix`},f),h?h(N):N,x&&r.createElement("span",{className:`${S}-content-suffix`},x)))))};const g=[["Y",31536e6],["M",2592e6],["D",864e5],["H",36e5],["m",6e4],["s",1e3],["S",1]];function v(e,t){const{format:n=""}=t,r=new Date(e).getTime(),s=Date.now();return function(e,t){let n=e;const r=/\[[^\]]*]/g,s=(t.match(r)||[]).map((e=>e.slice(1,-1))),a=t.replace(r,"[]"),c=g.reduce(((e,t)=>{let[r,s]=t;if(e.includes(r)){const t=Math.floor(n/s);return n-=t*s,e.replace(new RegExp(`${r}+`,"g"),(e=>{const n=e.length;return t.toString().padStart(n,"0")}))}return e}),a);let i=0;return c.replace(r,(()=>{const e=s[i];return i+=1,e}))}(Math.max(r-s,0),n)}const j=e=>{const{value:t,format:n="HH:mm:ss",onChange:c,onFinish:i}=e,l=(0,s.Z)(),o=r.useRef(null),u=()=>{const e=function(e){return new Date(e).getTime()}(t);e>=Date.now()&&(o.current=setInterval((()=>{l(),null==c||c(e-Date.now()),e<Date.now()&&(null==i||i(),o.current&&(clearInterval(o.current),o.current=null))}),33.333333333333336))};r.useEffect((()=>(u(),()=>{o.current&&(clearInterval(o.current),o.current=null)})),[t]);return r.createElement(x,Object.assign({},e,{valueRender:e=>(0,a.Tm)(e,{title:void 0}),formatter:(e,t)=>v(e,Object.assign(Object.assign({},t),{format:n}))}))};var w=r.memo(j);x.Countdown=w;var _=x}}]);