From 1c714de914757eeaa51d1f4a22388d06ba0c5c9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sat, 14 Mar 2020 23:42:48 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Signinstatistics/Signinstatistics.js | 21 ++++++++++++------- .../courses/signin/css/Signinstatistics.css | 8 +++++-- 2 files changed, 19 insertions(+), 10 deletions(-) diff --git a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js index ca7ecace4..ca3e0286a 100644 --- a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js +++ b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js @@ -38,19 +38,23 @@ class Signinstatistics extends Component { if(response.data.history_attendances.length>0){ response.data.history_attendances.map((item,key)=>{ newlists.push({ - month: item.index, + // month: item.index, + // month: item.name+" "+item.attendance_date+" "+item.start_time+"-"+item.end_time, + month:item.name, city:"到课率", - temperature: (item.normal_rate).toFixed(0) + temperature: (item.normal_rate*100).toFixed(0) }) newlists.push({ - month: item.index, + //month: item.index, + month:item.name, city: "旷课率", - temperature: (item.absence_rate).toFixed(0) + temperature: (item.absence_rate*100).toFixed(0) }) newlists.push({ - month: item.index, + //month: item.index, + month:item.name, city: "请假率", - temperature: (item.leave_rate).toFixed(0) + temperature: (item.leave_rate*100).toFixed(0) }) }) } @@ -101,8 +105,9 @@ class Signinstatistics extends Component { let {datas,newlist,course_groups,spal}=this.state; const cols = { - month: { - range: [0, 1] + temperature: { + type: 'log', + base: 10 } }; diff --git a/public/react/src/modules/courses/signin/css/Signinstatistics.css b/public/react/src/modules/courses/signin/css/Signinstatistics.css index 388f0ad28..f179e80af 100644 --- a/public/react/src/modules/courses/signin/css/Signinstatistics.css +++ b/public/react/src/modules/courses/signin/css/Signinstatistics.css @@ -102,8 +102,12 @@ color: rgba(153,153,153,1); text-align: right; margin-right: 20px; - line-height: 32px; - height: 32px; + line-height: 32px !important; + height: 32px !important; +} +.ant-select-selection--single .ant-select-selection__rendered{ + line-height: 32px !important; + height: 32px !important; } #form_in_modal_group_ids .ant-select-selection{ From e64cdf148d7f4c209e8bbbc4bfb8bd27b2196ac8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sat, 14 Mar 2020 23:59:28 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/courses/signin/Signinstatistics/Signinstatistics.js | 2 +- .../react/src/modules/courses/signin/css/Signinstatistics.css | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js index ca3e0286a..9eedb8e3e 100644 --- a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js +++ b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js @@ -195,7 +195,7 @@ class Signinstatistics extends Component { 显示最近十次签到 - this.handleChange(e)} style={{width:"130px"}} className={"Signinstatisticsfontselect"}> {course_groups&&course_groups.map((item,key)=>{ return( diff --git a/public/react/src/modules/courses/signin/css/Signinstatistics.css b/public/react/src/modules/courses/signin/css/Signinstatistics.css index f179e80af..298ef9403 100644 --- a/public/react/src/modules/courses/signin/css/Signinstatistics.css +++ b/public/react/src/modules/courses/signin/css/Signinstatistics.css @@ -105,7 +105,7 @@ line-height: 32px !important; height: 32px !important; } -.ant-select-selection--single .ant-select-selection__rendered{ +.Signinstatisticsfontselect .ant-select-selection--single .ant-select-selection__rendered{ line-height: 32px !important; height: 32px !important; } From 70807c84191a47ac814f9c10d1aff6fac1f106b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sun, 15 Mar 2020 00:24:22 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Signinstatistics/Signinstatistics.js | 35 +++++++++++++++---- 1 file changed, 28 insertions(+), 7 deletions(-) diff --git a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js index 9eedb8e3e..a19eb05c8 100644 --- a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js +++ b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js @@ -38,21 +38,23 @@ class Signinstatistics extends Component { if(response.data.history_attendances.length>0){ response.data.history_attendances.map((item,key)=>{ newlists.push({ - // month: item.index, - // month: item.name+" "+item.attendance_date+" "+item.start_time+"-"+item.end_time, - month:item.name, + month: item.index, + name: item.name+" "+item.attendance_date+" "+item.start_time+"-"+item.end_time, + // month:item.name, city:"到课率", temperature: (item.normal_rate*100).toFixed(0) }) newlists.push({ - //month: item.index, - month:item.name, + month: item.index, + name: item.name+" "+item.attendance_date+" "+item.start_time+"-"+item.end_time, + // month:item.name, city: "旷课率", temperature: (item.absence_rate*100).toFixed(0) }) newlists.push({ - //month: item.index, - month:item.name, + month: item.index, + name: item.name+" "+item.attendance_date+" "+item.start_time+"-"+item.end_time, + // month:item.name, city: "请假率", temperature: (item.leave_rate*100).toFixed(0) }) @@ -105,6 +107,9 @@ class Signinstatistics extends Component { let {datas,newlist,course_groups,spal}=this.state; const cols = { + month:{ + range: [0, 1] + }, temperature: { type: 'log', base: 10 @@ -229,6 +234,14 @@ class Signinstatistics extends Component { // color={"city"} shape={"smooth"} color={["city", ["#26C7C9", "#FF835C","#EDBA6F"]]} + tooltip={['name*temperature*city', (name, temperature,city) => { + return { + //自定义 tooltip 上显示的 title 显示内容等。 + name: city, + title: name, + value: temperature+"%" + }; + }]} /> { + // return { + // //自定义 tooltip 上显示的 title 显示内容等。 + // name: 'sold1', + // title: 'dddd' + month, + // value: temperature + // }; + // }]} /> From 9451a751f722f34c90c63ae7d7e8d757753c5ffd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sun, 15 Mar 2020 00:31:14 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../courses/signin/Signinstatistics/Signinstatistics.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js index a19eb05c8..d01bccbf1 100644 --- a/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js +++ b/public/react/src/modules/courses/signin/Signinstatistics/Signinstatistics.js @@ -107,9 +107,6 @@ class Signinstatistics extends Component { let {datas,newlist,course_groups,spal}=this.state; const cols = { - month:{ - range: [0, 1] - }, temperature: { type: 'log', base: 10