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__Engineering__Evaluate__L...

1 line
14 KiB

(self.webpackChunk=self.webpackChunk||[]).push([[4973],{61441:function(e,t,n){"use strict";n.d(t,{Z:function(){return s}});var a=n(5891),i=n(59301),r={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"},o=n(88853),l=function(e,t){return i.createElement(o.Z,(0,a.Z)({},e,{ref:t,icon:r}))};var s=i.forwardRef(l)},30631:function(e,t,n){"use strict";n.d(t,{Z:function(){return s}});var a=n(5891),i=n(59301),r={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},o=n(88853),l=function(e,t){return i.createElement(o.Z,(0,a.Z)({},e,{ref:t,icon:r}))};var s=i.forwardRef(l)},46197:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return _}});var a=n(82242),i=n.n(a),r=n(79800),o=n.n(r),l=n(59301),s=n(87381),c="evaluateContainer___ywXNF",u="header___pX29F",d="select___QJc1x",p="button___Z7ioB",f=n(3720),v=n(57809),g=n(71418),m=n(3113),y={evaluateContainer:"evaluateContainer___UtSup",red:"red___4997a",green:"green___sNh2a"},h=n(6848),x=n(81327),C=n(51700),b=n(2595),j=n(21627),w=n(37712),E=(0,s.connect)((function(e){var t=e.engineeringEvaluteList,n=e.loading;return i()({loading:n},t)}))((function(e){var t=e.headerData,n=e.tabListData,a=e.loading,i=e.dispatch,r=[{title:"序号",dataIndex:"key",width:67,align:"center",render:function(e){return(0,w.jsx)("div",{children:e||"--"})}},{title:"课程名称",dataIndex:"name",ellipsis:{showTitle:!1},render:function(e){return(0,w.jsx)(h.Z,{placement:"topLeft",title:e,children:e})}},{title:"授课教师",dataIndex:"course_teachers",ellipsis:{showTitle:!1},width:100,render:function(e){return(0,w.jsx)(h.Z,{placement:"topLeft",title:e,children:e||"--"})}},{title:"认证工作教师",dataIndex:"work_teachers",align:"left",width:120,render:function(e){return(0,w.jsx)(h.Z,{placement:"topLeft",title:e,children:e||"--"})}},{title:"课程目标达成度",dataIndex:"course_target",align:"center",width:120,render:function(e){var t=e.split("/")||[],n="";return t.length>1&&(n=t[0]===t[1]?"green":"red"),(0,w.jsx)("div",{className:y[n],children:e})}},{title:"评价结果",dataIndex:"result",align:"center",width:75,render:function(e){return(0,w.jsx)("div",{className:["已达成","达成"].includes(e)?y.green:y.red,children:e})}},{title:"状态",dataIndex:"status",width:60},{title:"计算时间",dataIndex:"evaluation_time",width:170,render:function(e){return(0,w.jsx)("div",{children:e||"--"})}},{title:"操作",width:68,render:function(e){return(0,w.jsxs)(x.Z,{children:[(0,w.jsx)(C.Z.Link,{onClick:function(){return o(e.id)},children:(0,w.jsx)("i",{className:"iconfont icon-jisuan",style:{color:"#0152D9"}})}),(0,w.jsx)(C.Z.Link,{onClick:function(){return s.history.push("/engineering/evaluate/course/".concat(t.active[j.k[1]],"/").concat(e.id))},children:(0,w.jsx)("i",{className:"iconfont icon-chakansvg",style:{color:"#0152D9"}})})]})}}],o=function(e){i({type:"engineeringEvaluteList/compute",payload:{all:!1,ec_course_id:e}})};return(0,w.jsx)("div",{className:y.evaluateContainer,children:(0,w.jsx)(b.Z,{loading:a.effects["engineeringEvaluteList/getCourseResults"]||a.effects["engineeringEvaluteList/compute"],rowKey:"id",columns:r,bordered:!1,dataSource:n.dataSource,pagination:{onChange:function(e,t){i({type:"engineeringEvaluteList/getCourseResults",payload:{page:e,per_page:t}})},position:["bottomCenter"],total:n.total,current:n.pageNo,pageSize:n.pageSize,showQuickJumper:!0,showSizeChanger:!0,size:"default",pageSizeOptions:["10","20","50","100"]}})})})),k=v.default.Option,_=(0,s.connect)((function(e){var t=e.user,n=e.engineeringEvaluteList,a=e.loading;return i()({loading:a,user:t},n)}))((function(e){var t,n=e.user,a=e.headerData,i=e.tabListData,r=e.dispatch,s=e.loading,y=(0,l.useRef)(!0);(0,l.useEffect)((function(){var e;return null!==(e=n.userInfo)&&void 0!==e&&e.login&&r({type:"engineeringEvaluteList/getMajorList"}),function(){r({type:"engineeringEvaluteList/save",payload:{actionTabs:{key:"",params:{}}}}),r({type:"engineeringEvaluteList/setMajorOrYearActive",payload:{key:j.k[0],value:""}}),r({type:"engineeringEvaluteList/setMajorOrYearActive",payload:{key:j.k[1],value:""}})}}),[null===(t=n.userInfo)||void 0===t?void 0:t.login]),(0,l.useEffect)((function(){a.active[j.k[0]]&&(r({type:"engineeringEvaluteList/getYearList",payload:{id:a.active[j.k[0]],firstEnter:y.current}}),y.current=!1),r({type:"engineeringEvaluteList/setMajorOrYearDataSource",payload:{key:j.k[1],value:[]}}),r({type:"engineeringEvaluteList/setMajorOrYearActive",payload:{key:j.k[1],value:""}})}),[a.active[j.k[0]]]),(0,l.useEffect)((function(){r({type:"engineeringEvaluteList/getCourseResults"})}),[a.active[j.k[1]]]);return(0,w.jsx)(g.Z,{spinning:s.effects["engineeringEvaluteList/compute"]||!1,children:(0,w.jsxs)("div",{className:c,children:[(0,w.jsx)(f.p,{title:"课程评价"}),(0,w.jsxs)("div",{className:u,children:[(0,w.jsx)("div",{className:d,children:Object.entries(a.dataSource).map((function(e){var t=o()(e,2),n=t[0],i=t[1];return(0,w.jsx)(f.v,{title:n,children:(0,w.jsx)(v.default,{style:{width:i.width},value:a.active[n]||void 0,bordered:!1,placeholder:i.placeholder,loading:s.effects[i.loading],onChange:function(e){return function(e,t){r({type:"engineeringEvaluteList/setMajorOrYearActive",payload:{key:e,value:t}})}(n,e)},children:i.dataList.map((function(e){return(0,w.jsx)(k,{value:e.value,children:e.label},e.value)}))})},n)}))}),(0,w.jsxs)("div",{className:p,children:[(0,w.jsx)(m.ZP,{type:"primary",icon:(0,w.jsx)("i",{className:"iconfont icon-jisuan"}),disabled:!a.active[j.k[1]]||!i.dataSource.length,onClick:function(){i.dataSource.length&&a.active[j.k[1]]&&r({type:"engineeringEvaluteList/compute",payload:{all:!0,ec_year_id:a.active[j.k[1]]}})},children:"全部计算"}),(0,w.jsx)(m.ZP,{disabled:!a.active[j.k[1]]||!i.dataSource.length,onClick:function(){r({type:"engineeringEvaluteList/exportCourse"})},type:"default",icon:(0,w.jsx)("i",{className:"iconfont icon-daochubeifen "}),children:"导出"})]})]}),(0,w.jsx)(E,{})]})})}))},3720:function(e,t,n){"use strict";n.d(t,{p:function(){return r},v:function(){return l}});n(59301);var a="panelTitleContainer___Ypuh_",i=n(37712),r=function(e){var t=e.title,n=e.style,r=void 0===n?{}:n;return(0,i.jsx)("div",{className:a,style:r,children:(0,i.jsx)("div",{children:t})})},o="selectWrapContainer___qocIH",l=function(e){var t=e.title,n=e.children;return(0,i.jsxs)("div",{className:o,children:[(0,i.jsx)("span",{children:t}),n]})}},92832:function(e,t,n){"use strict";n.d(t,{Z:function(){return N}});var a=n(92310),i=n.n(a),r=n(59301),o=n(36355),l=n(32441),s=n(9937);var c=e=>{const{getPrefixCls:t,direction:n}=(0,r.useContext)(o.E_),{prefixCls:a,className:c}=e,u=t("input-group",a),d=t("input"),[p,f]=(0,s.ZP)(d),v=i()(u,{[`${u}-lg`]:"large"===e.size,[`${u}-sm`]:"small"===e.size,[`${u}-compact`]:e.compact,[`${u}-rtl`]:"rtl"===n},f,c),g=(0,r.useContext)(l.aM),m=(0,r.useMemo)((()=>Object.assign(Object.assign({},g),{isFormItemInput:!1})),[g]);return p(r.createElement("span",{className:v,style:e.style,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,onFocus:e.onFocus,onBlur:e.onBlur},r.createElement(l.aM.Provider,{value:m},e.children)))},u=n(9432),d=n(61441),p=n(30631),f=n(45115),v=n(35648),g=n(59412),m=function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(a=Object.getOwnPropertySymbols(e);i<a.length;i++)t.indexOf(a[i])<0&&Object.prototype.propertyIsEnumerable.call(e,a[i])&&(n[a[i]]=e[a[i]])}return n};const y=e=>e?r.createElement(p.Z,null):r.createElement(d.Z,null),h={click:"onClick",hover:"onMouseOver"};var x=r.forwardRef(((e,t)=>{const{visibilityToggle:n=!0}=e,a="object"==typeof n&&void 0!==n.visible,[l,s]=(0,r.useState)((()=>!!a&&n.visible)),c=(0,r.useRef)(null);r.useEffect((()=>{a&&s(n.visible)}),[a,n]);const d=(0,g.Z)(c),p=()=>{const{disabled:t}=e;t||(l&&d(),s((e=>{var t;const a=!e;return"object"==typeof n&&(null===(t=n.onVisibleChange)||void 0===t||t.call(n,a)),a})))},{className:x,prefixCls:C,inputPrefixCls:b,size:j}=e,w=m(e,["className","prefixCls","inputPrefixCls","size"]),{getPrefixCls:E}=r.useContext(o.E_),k=E("input",b),_=E("input-password",C),L=n&&(t=>{const{action:n="click",iconRender:a=y}=e,i=h[n]||"",o=a(l),s={[i]:p,className:`${t}-icon`,key:"passwordIcon",onMouseDown:e=>{e.preventDefault()},onMouseUp:e=>{e.preventDefault()}};return r.cloneElement(r.isValidElement(o)?o:r.createElement("span",null,o),s)})(_),O=i()(_,x,{[`${_}-${j}`]:!!j}),N=Object.assign(Object.assign({},(0,f.Z)(w,["suffix","iconRender","visibilityToggle"])),{type:l?"text":"password",className:O,prefixCls:k,suffix:L});return j&&(N.size=j),r.createElement(u.Z,Object.assign({ref:(0,v.sQ)(t,c)},N))})),C=n(21970),b=n(92343),j=n(3113),w=n(19716),E=n(33234),k=function(e,t){var n={};for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&t.indexOf(a)<0&&(n[a]=e[a]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(a=Object.getOwnPropertySymbols(e);i<a.length;i++)t.indexOf(a[i])<0&&Object.prototype.propertyIsEnumerable.call(e,a[i])&&(n[a[i]]=e[a[i]])}return n};var _=r.forwardRef(((e,t)=>{const{prefixCls:n,inputPrefixCls:a,className:l,size:s,suffix:c,enterButton:d=!1,addonAfter:p,loading:f,disabled:g,onSearch:m,onChange:y,onCompositionStart:h,onCompositionEnd:x}=e,_=k(e,["prefixCls","inputPrefixCls","className","size","suffix","enterButton","addonAfter","loading","disabled","onSearch","onChange","onCompositionStart","onCompositionEnd"]),{getPrefixCls:L,direction:O}=r.useContext(o.E_),N=r.useRef(!1),S=L("input-search",n),D=L("input",a),{compactSize:Z}=(0,E.ri)(S,O),z=(0,w.Z)((e=>{var t;return null!==(t=null!=s?s:Z)&&void 0!==t?t:e})),M=r.useRef(null),R=e=>{var t;document.activeElement===(null===(t=M.current)||void 0===t?void 0:t.input)&&e.preventDefault()},P=e=>{var t,n;m&&m(null===(n=null===(t=M.current)||void 0===t?void 0:t.input)||void 0===n?void 0:n.value,e,{source:"input"})},I="boolean"==typeof d?r.createElement(C.Z,null):null,A=`${S}-button`;let T;const $=d||{},B=$.type&&!0===$.type.__ANT_BUTTON;T=B||"button"===$.type?(0,b.Tm)($,Object.assign({onMouseDown:R,onClick:e=>{var t,n;null===(n=null===(t=null==$?void 0:$.props)||void 0===t?void 0:t.onClick)||void 0===n||n.call(t,e),P(e)},key:"enterButton"},B?{className:A,size:z}:{})):r.createElement(j.ZP,{className:A,type:d?"primary":void 0,size:z,disabled:g,key:"enterButton",onMouseDown:R,onClick:P,loading:f,icon:I},d),p&&(T=[T,(0,b.Tm)(p,{key:"addonAfter"})]);const U=i()(S,{[`${S}-rtl`]:"rtl"===O,[`${S}-${z}`]:!!z,[`${S}-with-button`]:!!d},l);return r.createElement(u.Z,Object.assign({ref:(0,v.sQ)(M,t),onPressEnter:e=>{N.current||f||P(e)}},_,{size:z,onCompositionStart:e=>{N.current=!0,null==h||h(e)},onCompositionEnd:e=>{N.current=!1,null==x||x(e)},prefixCls:D,addonAfter:T,suffix:c,onChange:e=>{e&&e.target&&"click"===e.type&&m&&m(e.target.value,e,{source:"clear"}),y&&y(e)},className:U,disabled:g}))})),L=n(1643);const O=u.Z;O.Group=c,O.Search=_,O.TextArea=L.Z,O.Password=x;var N=O},25769:function(e,t,n){"use strict";var a=n(98040),i={"text/plain":"Text","text/html":"Url",default:"Text"};e.exports=function(e,t){var n,r,o,l,s,c,u=!1;t||(t={}),n=t.debug||!1;try{if(o=a(),l=document.createRange(),s=document.getSelection(),(c=document.createElement("span")).textContent=e,c.ariaHidden="true",c.style.all="unset",c.style.position="fixed",c.style.top=0,c.style.clip="rect(0, 0, 0, 0)",c.style.whiteSpace="pre",c.style.webkitUserSelect="text",c.style.MozUserSelect="text",c.style.msUserSelect="text",c.style.userSelect="text",c.addEventListener("copy",(function(a){if(a.stopPropagation(),t.format)if(a.preventDefault(),void 0===a.clipboardData){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var r=i[t.format]||i.default;window.clipboardData.setData(r,e)}else a.clipboardData.clearData(),a.clipboardData.setData(t.format,e);t.onCopy&&(a.preventDefault(),t.onCopy(a.clipboardData))})),document.body.appendChild(c),l.selectNodeContents(c),s.addRange(l),!document.execCommand("copy"))throw new Error("copy command was unsuccessful");u=!0}catch(a){n&&console.error("unable to copy using execCommand: ",a),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),u=!0}catch(a){n&&console.error("unable to copy using clipboardData: ",a),n&&console.error("falling back to prompt"),r=function(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}("message"in t?t.message:"Copy to clipboard: #{key}, Enter"),window.prompt(r,e)}}finally{s&&("function"==typeof s.removeRange?s.removeRange(l):s.removeAllRanges()),c&&document.body.removeChild(c),o()}return u}},98040:function(e){e.exports=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],a=0;a<e.rangeCount;a++)n.push(e.getRangeAt(a));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null}return e.removeAllRanges(),function(){"Caret"===e.type&&e.removeAllRanges(),e.rangeCount||n.forEach((function(t){e.addRange(t)})),t&&t.focus()}}}}]);