(length)
| 3672 | |
| 3673 | // `generatePdfName` is used to generate file name |
| 3674 | export function generatePdfName(length) { |
| 3675 | const characters = |
| 3676 | "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; |
| 3677 | let result = ""; |
| 3678 | const charactersLength = characters.length; |
| 3679 | |
| 3680 | for (let i = 0; i < length; i++) { |
| 3681 | result += characters.charAt(Math.floor(Math.random() * charactersLength)); |
| 3682 | } |
| 3683 | return result; |
| 3684 | } |
| 3685 | |
| 3686 | // Format date and time for the selected timezone |
| 3687 | export const formatTimeInTimezone = (date, timezone) => { |
no outgoing calls
no test coverage detected