| | |
| | | return { |
| | | ...item, |
| | | coursePeriodNum: item.coursePeriod ? (item.coursePeriod /60).toFixed(2).replace(/\.00$/, '') + '分钟':'', |
| | | finishRate: item.finishCount ? item.finishCount ===0 && item.studentCount ===0 ? '0%': (item.finishCount / item.studentCount).toFixed(2) *100 + '%' : '' |
| | | finishRate: item.finishCount ? item.finishCount ===0 && item.studentCount ===0 ? '0%': ((item.finishCount / item.studentCount)*100).toFixed(2).replace(/\.00$/, '') + '%' : '' |
| | | } |
| | | }) |
| | | data.total = res.data.total |
| | |
| | | state.dataList = res.data.list.map(item => { |
| | | return { |
| | | ...item, |
| | | passRate: item.passStudentCount && item.paperStudentCount ? (item.passStudentCount / item.paperStudentCount).toFixed(2) *100 + '%': item.passStudentCount == 0 && item.paperStudentCount == 0? '0%': '' |
| | | passRate: item.passStudentCount && item.paperStudentCount ? ((item.passStudentCount / item.paperStudentCount)*100).toFixed(2).replace(/\.00$/, '') + '%': item.passStudentCount == 0 && item.paperStudentCount == 0? '0%': '' |
| | | |
| | | } |
| | | }) |
| | |
| | | data.dataList = res.data.list.map(item => { |
| | | return { |
| | | ...item, |
| | | passRate: item.paperStudentInfoVO.passStudentCount ===0 && item.paperStudentInfoVO.studentCount ===0 ? '0%': (item.paperStudentInfoVO.passStudentCount / item.paperStudentInfoVO.studentCount).toFixed(2) *100 + '%', |
| | | passRate: item.paperStudentInfoVO.passStudentCount ===0 && item.paperStudentInfoVO.studentCount ===0 ? '0%': ((item.paperStudentInfoVO.passStudentCount / item.paperStudentInfoVO.studentCount)*100).toFixed(2).replace(/\.00$/, '') + '%', |
| | | deadlineNum: item.deadline ? item.deadline.slice(0,10) : '' |
| | | } |
| | | }) |