Total Complexity | 1 |
Complexity/F | 1 |
Lines of Code | 13 |
Function Count | 1 |
Duplicated Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | import { RouteNameResolver } from "src/Infrastructure/Common/ExtendedRouting/RouteNameResolver"; |
||
2 | |||
3 | export function makeMonthUrl(resolver: RouteNameResolver, date: Date): string { |
||
4 | const url = resolver.resolve('faircalendar_index'); |
||
5 | |||
6 | const params = new URLSearchParams({ |
||
7 | month: (date.getMonth() + 1).toString(), |
||
8 | year: (date.getFullYear()).toString(), |
||
9 | }); |
||
10 | |||
11 | return url + '?' + params.toString(); |
||
12 | } |
||
13 |