// 获取是否打卡class function getClass(json) { if (json) { if (json.startPunchClock && json.endPunchClock) { return 'all'; } else if (json.startPunchClock || json.endPunchClock) { return 'shortage'; } } return '' } module.exports = { getClass: getClass };