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.
1 line
18 KiB
1 line
18 KiB
"use strict";(self.webpackChunk=self.webpackChunk||[]).push([[3585],{32501:function(e,t,n){n.r(t),n.d(t,{default:function(){return Z}});var r=n(10574),o=n.n(r),l=n(39343),a=n.n(l),i=n(26801),s=n.n(i),c=n(11006),d=n.n(c),u=n(59301),m=n(9498),p=n.n(m),x=n(22211),f=n(59981),h=n(66104),v=n(99313),g=n(72315),j=n(15830),y="bg___oFrjP",_="title___Lhfh_",b="img___x1Ip0",k="right___l5YAN",I="top___ku6kq",w="font___OYhDA",O="bottom___MllAb",S="li___d6sjF",C="num___YfZHN",E="ling___ijtU2",N="content___FWvET",D=n(67871),F=n(37712),P=[{text:"未开启",color:"#272A3A"},{text:"未通关",color:"#E30000"},{text:"按时通关",color:"#038D00"},{text:"迟交通关",color:"#0152D9"}],A=function(e,t){var n={shixun_homework:[{text:"未开启",color:"#272A3A"},{text:"未通关",color:"#E30000"},{text:"按时通关",color:"#038D00"},{text:"迟交通关",color:"#0152D9"}],program_homework:[{text:"未开启",color:"#272A3A"},{text:"未通关",color:"#E30000"},{text:"按时通关",color:"#038D00"},{text:"迟交通关",color:"#0152D9"},{text:"截止通关",color:"#E30000"}],common_homework:[{text:"未提交",color:"#272A3A"},{text:"按时提交",color:"#038D00"},{text:"延时提交",color:"#0152D9"}],group_homework:[{text:"未提交",color:"#272A3A"},{text:"按时提交",color:"#038D00"},{text:"延时提交",color:"#0152D9"}],exercise:[{text:"未开始",color:"#272A3A"},{text:"考试中",color:"#0152D9"},{text:"已交卷",color:"#038D00"},{text:"已交卷/未答",color:"#038D00"}],video:[{text:"未完成",color:"#272A3A"},{text:"已完成",color:"#038D00"}]}[e]||P;return{shixun_homework:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"实验名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,n){return(0,F.jsx)("a",{href:"/classrooms/".concat(null==t?void 0:t.coursesId,"/shixun_homework/").concat(null==n?void 0:n.id,"/").concat(null==n?void 0:n.student_work_id,"/comment"),target:"_blank",style:{marginLeft:12},children:e})}},{title:"作业状态",dataIndex:"work_status",render:function(e){var t,r;return-1===e?(0,F.jsx)("span",{style:{color:"#FF9D18"},children:"重做中"}):(0,F.jsx)("span",{style:{color:null===(t=n[e])||void 0===t?void 0:t.color},children:null===(r=n[e])||void 0===r?void 0:r.text})}},{title:"完成时间",dataIndex:"update_time"},{title:"通关情况",dataIndex:"current_complete_count",align:"center",render:function(e,t){return(0,F.jsx)("span",{children:e+"/"+(null==t?void 0:t.complete_count)})}},{title:"最终成绩",dataIndex:"work_score",align:"center",key:"address",render:function(e){return(0,F.jsx)("span",{style:{color:100===parseInt(e)?"#FF6800":"#E30000"},children:e})}},{title:"作业达成情况",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],common_homework:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"作业名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,n){return(0,F.jsx)("a",{href:"/classrooms/".concat(null==t?void 0:t.coursesId,"/common_homework/").concat(null==n?void 0:n.id,"/review/").concat(null==n?void 0:n.student_work_id),target:"_blank",style:{marginLeft:12},children:e})}},{title:"作业状态",dataIndex:"work_status",render:function(e){var t,r;return-1===e?(0,F.jsx)("span",{style:{color:"#FF9D18"},children:"重做中"}):(0,F.jsx)("span",{style:{color:null===(t=n[e])||void 0===t?void 0:t.color},children:null===(r=n[e])||void 0===r?void 0:r.text})}},{title:"完成时间",dataIndex:"update_time",render:function(e){return"2022-06-02 12:34:12"}},{title:"最终成绩",dataIndex:"work_score",align:"center",key:"address",render:function(e){return(0,F.jsx)("span",{style:{color:100===parseInt(e)?"#FF6800":"#E30000"},children:e})}},{title:"作业达成情况",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],group_homework:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"作业名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,n){return(0,F.jsx)("a",{href:"/classrooms/".concat(null==t?void 0:t.coursesId,"/group_homework/").concat(null==n?void 0:n.id,"/review/").concat(null==n?void 0:n.student_work_id),target:"_blank",style:{marginLeft:12},children:e})}},{title:"作业状态",dataIndex:"work_status",render:function(e){var t,r;return-1===e?(0,F.jsx)("span",{style:{color:"#FF9D18"},children:"重做中"}):(0,F.jsx)("span",{style:{color:null===(t=n[e])||void 0===t?void 0:t.color},children:null===(r=n[e])||void 0===r?void 0:r.text})}},{title:"完成时间",dataIndex:"update_time",render:function(e){return"2022-06-02 12:34:12"}},{title:"最终成绩",dataIndex:"work_score",align:"center",key:"address",render:function(e){return(0,F.jsx)("span",{style:{color:100===parseInt(e)?"#FF6800":"#E30000"},children:e})}},{title:"作业达成情况",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],program_homework:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"作业名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,t){return(0,F.jsx)("span",{style:{marginLeft:12},children:e})}},{title:"作业状态",dataIndex:"work_status",render:function(e){var t,r;return-1===e?(0,F.jsx)("span",{style:{color:"#FF9D18"},children:"重做中"}):(0,F.jsx)("span",{style:{color:null===(t=n[e])||void 0===t?void 0:t.color},children:null===(r=n[e])||void 0===r?void 0:r.text})}},{title:"完成时间",dataIndex:"update_time",render:function(e){return"2022-06-02 12:34:12"}},{title:"通关情况",dataIndex:"current_complete_count",align:"center",render:function(e,t){return(0,F.jsx)("span",{children:e+"/"+(null==t?void 0:t.complete_count)})}},{title:"最终成绩",dataIndex:"work_score",align:"center",key:"address",render:function(e){return(0,F.jsx)("span",{style:{color:100===parseInt(e)?"#FF6800":"#E30000"},children:e})}},{title:"作业达成情况",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],exercise:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"考试名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,n){return(0,F.jsx)("a",{href:"/classrooms/".concat(null==t?void 0:t.coursesId,"/exercise/").concat(null==n?void 0:n.id,"/review/").concat(t.login),target:"_blank",style:{marginLeft:12},children:e})}},{title:"考试状态",dataIndex:"work_status",render:function(e){var t,r;return-1===e?(0,F.jsx)("span",{style:{color:"#FF9D18"},children:"重做中"}):(0,F.jsx)("span",{style:{color:null===(t=n[e])||void 0===t?void 0:t.color},children:null===(r=n[e])||void 0===r?void 0:r.text})}},{title:"交卷时间",dataIndex:"update_time",render:function(e){return"2022-06-02 12:34:12"}},{title:"最终成绩",dataIndex:"score",align:"center",key:"address",render:function(e){return(0,F.jsx)("span",{style:{color:100===parseInt(e)?"#FF6800":"#E30000"},children:e})}},{title:"考试达成情况",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],video:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"视频名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,t){return(0,F.jsx)("span",{style:{marginLeft:12},children:e})}},{title:"是否观看完成",dataIndex:"work_status",render:function(e){var t,r;return(0,F.jsx)("span",{style:{color:null===(t=n[e?1:0])||void 0===t?void 0:t.color},children:null===(r=n[e?1:0])||void 0===r?void 0:r.text})}},{title:"观看时长",dataIndex:"watch_duration"},{title:"观看达成状态",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}],attendance:[{title:(0,F.jsx)("div",{style:{marginLeft:12},children:"签到名称"}),dataIndex:"name",ellipsis:!0,width:"30%",render:function(e,t){return(0,F.jsx)("span",{style:{marginLeft:12},children:e})}},{title:"签到状态",dataIndex:"work_status"},{title:"签到达成状态",dataIndex:"rate",align:"center",render:function(e){return"".concat(e,"%")}}]}[e]};p().locale("zh-cn");var Z=function(){var e,t,n,r=(0,x.useParams)(),l=(0,u.useState)(s()(s()({},r),{},{page:1,limit:10})),i=d()(l,2),c=i[0],m=i[1],p=(0,u.useState)({}),P=d()(p,2),Z=P[0],$=P[1],L=(0,u.useState)([]),T=d()(L,2),R=T[0],z=T[1],X=(0,u.useState)(0),M=d()(X,2),H=M[0],B=M[1],U=(0,u.useState)("0"),W=d()(U,2),Y=W[0],Q=W[1],q=(0,u.useState)(!0),G=d()(q,2),J=G[0],K=G[1],V=(0,u.useState)(!0),ee=d()(V,2),te=ee[0],ne=ee[1];(0,u.useEffect)((function(){re(r,!0)}),[]);var re=function(){var e=a()(o()().mark((function e(t){var n,l,a,i,s=arguments;return o()().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return(n=s.length>1&&void 0!==s[1]&&s[1])?ne(!0):K(!0),e.next=4,(0,j.ZP)("/api/courses/".concat(null==r?void 0:r.coursesId,"/course_members/").concat(r.login,"/student_detail"),{method:"get",params:t});case 4:(l=e.sent)&&(n&&($(l),Q(String((null==l?void 0:l.homework_type)||0))),z((null==l||null===(a=l.table_data)||void 0===a?void 0:a.list)||[]),B((null==l||null===(i=l.table_data)||void 0===i?void 0:i.total_count)||0)),ne(!1),K(!1);case 8:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),oe=null==Z||null===(e=Z.course_modules)||void 0===e||null===(e=e.find((function(e){return String(e.type)===Y})))||void 0===e?void 0:e.module_type;return(0,F.jsx)("section",{className:y,children:(0,F.jsxs)(f.Z,{loading:te,active:!0,paragraph:{rows:5},children:[(0,F.jsxs)(h.Z,{separator:">",style:{marginTop:20},children:[(0,F.jsx)(h.Z.Item,{children:"教学课堂"}),(0,F.jsx)(h.Z.Item,{href:"/classrooms/".concat(null==r?void 0:r.coursesId),children:null==Z?void 0:Z.course_name}),(0,F.jsx)(h.Z.Item,{href:"/classrooms/".concat(null==r?void 0:r.coursesId,"/statistics/").concat(null==r?void 0:r.categoryId),children:"学生分析"}),(0,F.jsx)(h.Z.Item,{children:"学生学习详情"})]}),(0,F.jsxs)("div",{className:_,children:[(0,F.jsx)("div",{className:b,children:(0,F.jsx)("img",{src:D.Z.IMG_SERVER+"/images/"+(null==Z?void 0:Z.image_url)})}),(0,F.jsxs)("div",{className:k,children:[(0,F.jsx)("div",{className:I,children:(0,F.jsxs)("div",{children:[(0,F.jsxs)("span",{className:w,children:["姓名:",(0,F.jsx)("span",{children:null==Z?void 0:Z.username})]}),(0,F.jsxs)("span",{className:w,children:["学号:",(0,F.jsx)("span",{children:(null==Z?void 0:Z.student_id)||"- -"})]}),(0,F.jsxs)("span",{className:w,children:["分班:",(0,F.jsx)("span",{children:(null==Z?void 0:Z.course_group)||"- -"})]})]})}),(0,F.jsxs)("div",{className:O,children:[(0,F.jsxs)("div",{className:S,style:{marginLeft:0},children:[(0,F.jsxs)("div",{className:C,style:{color:"#0152D9"},children:[null==Z?void 0:Z.total_rate,"%"]}),(0,F.jsx)("div",{children:"整体达成度"})]}),(0,F.jsx)("div",{className:E}),null==Z||null===(t=Z.course_target_users)||void 0===t?void 0:t.map((function(e,t){return(0,F.jsxs)(u.Fragment,{children:[(0,F.jsxs)("div",{className:S,children:[(0,F.jsxs)("div",{className:C,children:[e.rate,"%"]}),(0,F.jsx)("div",{children:e.target_name})]}),(0,F.jsx)("div",{className:E})]},t)}))]})]})]}),(0,F.jsxs)("div",{className:N,children:[(0,F.jsx)(v.Z,{activeKey:Y,onChange:function(e){Q(e),c.page=1,c.type=e,m(s()({},c)),re(c)},tabBarStyle:{paddingLeft:20,height:55},children:null==Z||null===(n=Z.course_modules)||void 0===n?void 0:n.map((function(e){return(0,F.jsx)(v.Z.TabPane,{style:{marginRight:68},tab:e.module_name},String(e.type))}))}),(0,F.jsx)(g.Z,{style:{padding:"12px 20px 0 20px"},dataSource:R,columns:A(oe,c),onChange:function(e){c.page=null==e?void 0:e.current,c.limit=null==e?void 0:e.pageSize,m(s()({},c)),re(c)},loading:J,pagination:{pageSize:c.limit,total:H,current:c.page,showQuickJumper:!0,showSizeChanger:!1,hideOnSinglePage:!0,position:["bottomCenter"],showTotal:function(e){return(0,F.jsxs)("span",{className:"mr10",children:["共",(0,F.jsx)("span",{className:"c-orange",children:e}),"条数据"]})}}})]})]})})}},66104:function(e,t,n){n.d(t,{Z:function(){return N}});var r=n(73287),o=n.n(r),l=n(45659),a=n(3286),i=n(59301),s=n(92343),c=n(36355),d=n(42884),u=n(91857);const m=e=>{let{children:t}=e;const{getPrefixCls:n}=i.useContext(c.E_),r=n("breadcrumb");return i.createElement("li",{className:`${r}-separator`,"aria-hidden":"true"},""===t?t:t||"/")};m.__ANT_BREADCRUMB_SEPARATOR=!0;var p=m,x=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};function f(e,t,n,r){if(null==n)return null;const{className:l,onClick:s}=t,c=x(t,["className","onClick"]),d=Object.assign(Object.assign({},(0,a.Z)(c,{data:!0,aria:!0})),{onClick:s});return void 0!==r?i.createElement("a",Object.assign({},d,{className:o()(`${e}-link`,l),href:r}),n):i.createElement("span",Object.assign({},d,{className:o()(`${e}-link`,l)}),n)}function h(e,t){return(n,r,o,l,a)=>{if(t)return t(n,r,o,l);const i=function(e,t){if(void 0===e.title||null===e.title)return null;const n=Object.keys(t).join("|");return"object"==typeof e.title?e.title:String(e.title).replace(new RegExp(`:(${n})`,"g"),((e,n)=>t[n]||e))}(n,r);return f(e,n,i,a)}}var v=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};const g=e=>{const{prefixCls:t,separator:n="/",children:r,menu:o,overlay:l,dropdownProps:a,href:s}=e;const c=(e=>{if(o||l){const n=Object.assign({},a);if(o){const e=o||{},{items:t}=e,r=v(e,["items"]);n.menu=Object.assign(Object.assign({},r),{items:null==t?void 0:t.map(((e,t)=>{var{key:n,title:r,label:o,path:l}=e,a=v(e,["key","title","label","path"]);let c=null!=o?o:r;return l&&(c=i.createElement("a",{href:`${s}${l}`},c)),Object.assign(Object.assign({},a),{key:null!=n?n:t,label:c})}))})}else l&&(n.overlay=l);return i.createElement(u.Z,Object.assign({placement:"bottom"},n),i.createElement("span",{className:`${t}-overlay-link`},e,i.createElement(d.Z,null)))}return e})(r);return null!=c?i.createElement(i.Fragment,null,i.createElement("li",null,c),n&&i.createElement(p,null,n)):null},j=e=>{const{prefixCls:t,children:n,href:r}=e,o=v(e,["prefixCls","children","href"]),{getPrefixCls:l}=i.useContext(c.E_),a=l("breadcrumb",t);return i.createElement(g,Object.assign({},o,{prefixCls:a}),f(a,o,n,r))};j.__ANT_BREADCRUMB_ITEM=!0;var y=j,_=n(17313),b=n(83116),k=n(37613);const I=e=>{const{componentCls:t,iconCls:n}=e;return{[t]:Object.assign(Object.assign({},(0,_.Wf)(e)),{color:e.itemColor,fontSize:e.fontSize,[n]:{fontSize:e.iconFontSize},ol:{display:"flex",flexWrap:"wrap",margin:0,padding:0,listStyle:"none"},a:Object.assign({color:e.linkColor,transition:`color ${e.motionDurationMid}`,padding:`0 ${e.paddingXXS}px`,borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",marginInline:-e.marginXXS,"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover}},(0,_.Qy)(e)),"li:last-child":{color:e.lastItemColor},[`${t}-separator`]:{marginInline:e.separatorMargin,color:e.separatorColor},[`${t}-link`]:{[`\n > ${n} + span,\n > ${n} + a\n `]:{marginInlineStart:e.marginXXS}},[`${t}-overlay-link`]:{borderRadius:e.borderRadiusSM,height:e.lineHeight*e.fontSize,display:"inline-block",padding:`0 ${e.paddingXXS}px`,marginInline:-e.marginXXS,[`> ${n}`]:{marginInlineStart:e.marginXXS,fontSize:e.fontSizeIcon},"&:hover":{color:e.linkHoverColor,backgroundColor:e.colorBgTextHover,a:{color:e.linkHoverColor}},a:{"&:hover":{backgroundColor:"transparent"}}},[`&${e.componentCls}-rtl`]:{direction:"rtl"}})}};var w=(0,b.Z)("Breadcrumb",(e=>{const t=(0,k.TS)(e,{});return[I(t)]}),(e=>({itemColor:e.colorTextDescription,lastItemColor:e.colorText,iconFontSize:e.fontSize,linkColor:e.colorTextDescription,linkHoverColor:e.colorText,separatorColor:e.colorTextDescription,separatorMargin:e.marginXS}))),O=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};function S(e){const{breadcrumbName:t,children:n}=e,r=O(e,["breadcrumbName","children"]),o=Object.assign({title:t},r);return n&&(o.menu={items:n.map((e=>{var{breadcrumbName:t}=e,n=O(e,["breadcrumbName"]);return Object.assign(Object.assign({},n),{title:t})}))}),o}var C=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n};const E=e=>{const{prefixCls:t,separator:n="/",style:r,className:d,rootClassName:u,routes:m,items:x,children:f,itemRender:v,params:j={}}=e,y=C(e,["prefixCls","separator","style","className","rootClassName","routes","items","children","itemRender","params"]),{getPrefixCls:_,direction:b,breadcrumb:k}=i.useContext(c.E_);let I;const O=_("breadcrumb",t),[E,N]=w(O),D=function(e,t){return(0,i.useMemo)((()=>e||(t?t.map(S):null)),[e,t])}(x,m);const F=h(O,v);if(D&&D.length>0){const e=[],t=x||m;I=D.map(((r,o)=>{const{path:l,key:s,type:c,menu:d,overlay:u,onClick:m,className:x,separator:f,dropdownProps:h}=r,v=((e,t)=>{if(void 0===t)return t;let n=(t||"").replace(/^\//,"");return Object.keys(e).forEach((t=>{n=n.replace(`:${t}`,e[t])})),n})(j,l);void 0!==v&&e.push(v);const y=null!=s?s:o;if("separator"===c)return i.createElement(p,{key:y},f);const _={},b=o===D.length-1;d?_.menu=d:u&&(_.overlay=u);let{href:k}=r;return e.length&&void 0!==v&&(k=`#/${e.join("/")}`),i.createElement(g,Object.assign({key:y},_,(0,a.Z)(r,{data:!0,aria:!0}),{className:x,dropdownProps:h,href:k,separator:b?"":n,onClick:m,prefixCls:O}),F(r,j,t,e,k))}))}else if(f){const e=(0,l.Z)(f).length;I=(0,l.Z)(f).map(((t,r)=>{if(!t)return t;const o=r===e-1;return(0,s.Tm)(t,{separator:o?"":n,key:r})}))}const P=o()(O,null==k?void 0:k.className,{[`${O}-rtl`]:"rtl"===b},d,u,N),A=Object.assign(Object.assign({},null==k?void 0:k.style),r);return E(i.createElement("nav",Object.assign({className:P,style:A},y),i.createElement("ol",null,I)))};E.Item=y,E.Separator=p;var N=E}}]); |