Browse Source

fix: 后端返回的日期是年月日, 前端代码只判断了月日

tags/PMS_Frontend_v1.0.6-develop
chenglb 1 year ago
parent
commit
f57662e3c9
  1. 4
      src/pages/SystemMgm/BusinessConfig/VacationConf/loadable.jsx

4
src/pages/SystemMgm/BusinessConfig/VacationConf/loadable.jsx

@ -130,7 +130,7 @@ function VacationConf() {
}; };
const onPanelChange = (e,a)=>{ const onPanelChange = (e,a)=>{
console.log(e,a , 'aaaa',e.years(), e.months())
// console.log(e,a , 'aaaa',e.years(), e.months())
let tempdate = { let tempdate = {
year: e.years() + '', year: e.years() + '',
month: e.months() + 1 + '' month: e.months() + 1 + ''
@ -140,7 +140,7 @@ function VacationConf() {
} }
const dateFullCellRender = (date)=>{ const dateFullCellRender = (date)=>{
let temp = date.format('MM-DD'),highlight = false,temp_vc_name = '';
let temp = date.format('YYYY-MM-DD'),highlight = false,temp_vc_name = '';
if(vacationData.length){ if(vacationData.length){
let one = vacationData.find(item=> item.day == temp) let one = vacationData.find(item=> item.day == temp)
if(one){ if(one){

Loading…
Cancel
Save