|
|
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[17315],{11278:function(e,n,t){t.d(n,{Z:function(){return j}});var i=t(79800),s=t.n(i),r=t(59301),o=t(20834),a=t(98135),c=t(24905),l=t(3113),d=t(38854),u="bottomControlContainer___woAeo",h="buttonWrap___iRw4K",m="moveCategory___oiQqw",x=t(89918),p=t(43501),f=t(37712),j=function(e){var n=e.buttonDataSource,t=e.onButtonClick,i=e.useBatchStatus,j=e.allSelect,g=e.setAllSelect,v=e.selectArrs,y=e.onMenuClick,_=e.setSeleArr,C=e.catalogue,Z=e.addCatalogue,N=(0,r.useState)(!1),S=s()(N,2),b=S[0],k=S[1],w=(0,r.useState)(""),I=s()(w,2),L=I[0],M=I[1];console.log("---",C);var B=(0,f.jsx)("div",{className:m,onMouseLeave:function(e){return k(!1)},children:(0,f.jsxs)(o.Z,{onClick:y,style:{maxHeight:300,width:240,overflow:"auto"},children:[(0,f.jsx)("li",{className:"ant-menu-item multi-llipsis1e ant-menu-item-only-child",children:(0,f.jsx)(a.Z,{onChange:function(e){M(e.target.value)}})}),null==C?void 0:C.map((function(e,n){var t;if(!(""!==L&&e.category_name.indexOf(L)<0))return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(o.Z.Item,{className:"multi-llipsis1e",children:e.category_name},e.category_id),null==e||null===(t=e.third_category)||void 0===t?void 0:t.map((function(e){return(0,f.jsx)(o.Z.Item,{style:{marginLeft:20},className:"multi-llipsis1e",children:e.category_name},e.category_id)}))]})})),Z&&(0,f.jsx)("li",{className:"ant-menu-item multi-llipsis1e ant-menu-item-only-child",onClick:Z,children:"新建子目录..."})]})});return(0,f.jsxs)("div",{className:u,children:[(0,f.jsxs)("div",{children:[(0,f.jsx)("div",{children:(0,f.jsxs)(c.Z,{checked:j,onChange:g,children:["全选本页(",v.length,")"]})}),(0,x.GJ)()&&n.map((function(e){return(0,f.jsx)("div",{children:(0,f.jsx)(l.ZP,{type:"primary",icon:e.icon,className:h,onClick:function(){return t(e)},children:e.name})},e.name)})),(0,x.GJ)()&&(Z||C)&&(0,f.jsx)("div",{children:(0,f.jsx)(d.Z,{open:b,placement:"topLeft",autoAdjustOverflow:!1,dropdownRender:function(){return B},getPopupContainer:function(e){return e.parentNode},children:(0,f.jsx)("span",{className:"ant-dropdown-link",onMouseEnter:function(e){return k(!0)},children:(0,f.jsx)(l.ZP,{type:"primary",className:h,icon:(0,f.jsx)("i",{className:"iconfont icon-yidongmulu"}),children:(0,f.jsxs)("span",{children:["移动到目录 ",(0,f.jsx)(p.Z,{})]})})})})})]}),(0,f.jsx)("div",{children:(0,f.jsx)(l.ZP,{type:"primary",ghost:!0,onClick:function(){i(!1),_([])},children:"取消操作"})})]})}},10593:function(e,n,t){t.d(n,{Z:function(){return b}});var i=t(7557),s=t.n(i),r=t(37205),o=t.n(r),a=t(41498),c=t.n(a),l=t(79800),d=t.n(l),u=t(59301),h=t(20834),m=t(24905),x=t(3113),p=t(38854),f=t(6848),j=t(98135),g={searchSortControllerContainer:"searchSortControllerContainer___Xca1m",btn:"btn___sNJPX",btnSort:"btnSort___Fx9OM",tips:"tips___LrmpR"},v=t(89918),y=t(53547),_=t(43501),C=t(26724),Z=t.n(C),N=t(7880),S=t(37712),b=function(e){e.isAdmin,e.dataSource,e.batchStatus;var n=e.SortMenuName,t=e.setSortMenuName,i=e.detailCourseGroupsList,r=e.onSearch,a=e.onBoard,l=e.onSort,C=e.isboard,b=e.dispatch,k=(e.onBatch,e.SortMenus),w=(0,u.useState)(!1),I=d()(w,2),L=I[0],M=I[1],B=(0,u.useState)([]),P=d()(B,2),A=P[0],R=P[1],O=(0,u.useState)(!0),T=d()(O,2),G=T[0],z=T[1],E=(0,u.useState)([]),H=d()(E,2),K=H[0],D=H[1],J=(0,u.useState)(1),W=d()(J,2),F=W[0],X=W[1],q=(0,u.useState)(!1),Q=d()(q,2),U=Q[0],V=Q[1],Y=(0,N.useParams)();(0,u.useEffect)((function(){C&&$()}),[C]);var $=function(){var e=c()(s()().mark((function e(){var n,t,i;return s()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!G||U){e.next=10;break}return V(!0),X(F+1),e.next=5,b({type:"classroomList/getCourseGroupsList",payload:{page:F,id:Y.coursesId,limit:20,nonenavigate:!0}});case 5:t=e.sent,i=o()((null==t?void 0:t.course_groups)||[]),(null==t||null===(n=t.course_groups)||void 0===n?void 0:n.length)<20&&(z(!1),i.push({id:0,name:"未分班"})),V(!1),D([].concat(o()(K),o()(i)));case 10:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ee=(0,S.jsxs)("section",{className:g.dropmenu,children:[(0,S.jsx)("div",{style:{maxHeight:200,overflow:"auto"},children:(0,S.jsx)(Z(),{initialLoad:!1,pageStart:1,threshold:20,loadMore:function(e){$()},hasMore:G,useWindow:!1,children:(0,S.jsx)(h.Z,{style:{width:240,zIndex:10},children:(null==i?void 0:i.group_count)>0&&(null==K?void 0:K.filter((function(e){return e.edit_auth||"未分班"===e.name})).map((function(e,n){return(0,S.jsx)(h.Z.Item,{children:(0,S.jsx)(m.Z,{checked:A.includes(e.id),value:e.id,onChange:function(n){A.indexOf(e.id);A.indexOf(e.id)>-1?R(A.filter((function(n){return n!==e.id}))):R(A.concat(e.id))},children:e.name})},e.id)})))})})}),(0,S.jsx)("aside",{style:{background:"#fff"},children:(0,S.jsxs)("div",{children:[(0,S.jsx)(x.ZP,{type:"link",onClick:function(){a(A)},children:"确定"}),(0,S.jsx)(x.ZP,{type:"link",onClick:function(){R([])},children:"重置"})]})})]}),ne="默认排序"===n;return(0,S.jsxs)("div",{className:g.searchSortControllerContainer,children:[!(null==k||!k.length)&&(0,S.jsx)("div",{children:(0,S.jsx)(p.Z,{dropdownRender:function(){return(0,S.jsx)(h.Z,{selectedKeys:[n],children:k.map((function(e){return(0,S.jsx)(h.Z.Item,{onClick:function(){return t((n=e).name),void l(n);var n},children:e.name},e.name)}))})},children:(0,S.jsx)("div",{children:(0,S.jsxs)("span",{className:"".concat(g.btn," ").concat(ne?g.btnSort:""),children:[(0,S.jsx)("i",{className:"iconfont icon-paixu font14 mr5"}),n]})})})}),ne&&(0,S.jsx)(f.Z,{title:"优先按照调整排序结果展示,未设置排序时,按照创建时间降序排列",children:(0,S.jsx)("span",{className:g.tips,children:(0,S.jsx)("i",{className:"iconfont icon-a-wenhaobeifen2"})})}),(0,S.jsx)(j.Z.Search,{allowClear:!0,placeholder:"请输入名称进行搜索",onSearch:r,style:{width:220,marginLeft:"auto",marginRight:10}}),(0,v.eB)()&&C&&(0,S.jsx)(p.Z,{dropdownRender:function(){return ee},open:L,onOpenChange:function(e){M(e)},children:(0,S.jsxs)("a",{children:["分班",L?(0,S.jsx)(y.Z,{style:{marginLeft:6}}):(0,S.jsx)(_.Z,{style:{marginLeft:6}})]})})]})}},44427:function(e,n,t){t.d(n,{Z:function(){return d}});t(59301);var i=t(95237),s=t(43604),r=t(20834),o=t(38854),a={tabMenuContainer:"tabMenuContainer___uf5IP",control:"control___GheLs",iconH:"iconH___Wzw_r",selectBtn:"selectBtn___mfEnI"},c=t(7880),l=t(37712),d=function(e){var n=e.isLoading,t=e.addText,d=e.tabDataSource,u=e.isAdmin,h=e.dispatch,m=e.type,x=e.isExercise,p=e.defaultSelectedKeys,f=e.onTabMenuClick,j=e.getDropdownMenu,g=e.showControlButton,v=e.buttonText,y=e.buttonIcon,_=void 0===y?"icon-tianjiadaohang":y,C=e.extraNode,Z=e.onButtonClick,N=void 0===Z?function(){}:Z,S=(0,c.useParams)();return(0,l.jsx)("div",{className:a.tabMenuContainer,children:(0,l.jsxs)(i.Z,{children:[(0,l.jsx)(s.Z,{flex:"1",children:(0,l.jsx)(r.Z,{onSelect:function(e){return n?{}:f(e)},mode:"horizontal",selectedKeys:p,children:d.map((function(e){return(0,l.jsxs)(r.Z.Item,{children:[(0,l.jsx)("span",{className:"c-grey-666",children:e.name}),void 0!==e.total&&u&&(0,l.jsx)("span",{className:"c-grey-999 ml20",children:e.total||0})]},"number"==typeof e.index?e.index:e.id)}))})}),u&&(0,l.jsxs)(s.Z,{className:"mr20 gutter-row",style:{display:"flex",alignItems:"center",color:"#0152d9",paddingBottom:3},children:[x&&(0,l.jsx)(o.Z,{className:"mr15",placement:"bottom",arrow:!0,dropdownRender:function(){return(0,l.jsxs)(r.Z,{children:[(0,l.jsx)(r.Z.Item,{onClick:function(){h({type:"classroomList/setActionTabs",payload:{key:"导出成绩",type:m,exportType:"exercise",category_id:S.categoryId}})},children:"学生成绩"},1),(0,l.jsx)(r.Z.Item,{onClick:function(){c.history.push("/classrooms/".concat(null==S?void 0:S.coursesId,"/exportlist/exercise_score,export_exercise_users"))},children:"历史导出"},3)]})},children:(0,l.jsx)("div",{className:"c-blue font16 ml20 current",style:{marginTop:2},children:(0,l.jsx)("span",{style:{color:"#666666",cursor:"pointer"},children:(0,l.jsx)("i",{className:"iconfont icon-xiazai6"})})})}),(0,l.jsxs)("div",{className:a.control,children:[(0,l.jsx)("div",{className:a.extra,children:C}),g&&(0,l.jsxs)("span",{onClick:N,style:{cursor:"pointer"},className:a.selectBtn,children:[(0,l.jsx)("span",{children:(0,l.jsx)("i",{className:"iconfont ".concat(_)})}),(0,l.jsx)("span",{children:v})]}),!!j&&(0,l.jsx)(o.Z,{className:"ml10",dropdownRender:j,children:(0,l.jsxs)("span",{className:a.selectBtn,children:[(0,l.jsx)("span",{children:(0,l.jsx)("i",{className:"iconfont icon-tianjiadaohang"})}),(0,l.jsx)("span",{children:t||"创建试卷"})]})})]})]})]})})}}}]); |