前端项目实战81-ant design日期新增数据进行处理
res.beginDate = countFormat(res.beginDate)
res.endDate = countFormat(res.endDate)
const countFormat = (item:any) => {
return item?moment(item).format('YYYY-MM-DD'):undefined
}
res.beginDate = countFormat(res.beginDate)
res.endDate = countFormat(res.endDate)
const countFormat = (item:any) => {
return item?moment(item).format('YYYY-MM-DD'):undefined
}