hrms-user/src/utils/functions.ts

11 lines
318 B
TypeScript
Raw Normal View History

2025-10-02 13:21:41 +07:00
/**
*
*
* @param date
* @returns
*/
export function calculateFiscalYear(date: Date) {
const month = date.getMonth() + 1;
return month >= 10 ? date.getFullYear() + 1 : date.getFullYear();
}