#39 - generate timesheet #56

Merged
Baakoma merged 9 commits from #39-generate-timesheet into main 2022-02-21 16:09:45 +01:00
Baakoma commented 2022-02-21 15:01:50 +01:00 (Migrated from github.com)

It should close #39
image

It should close #39 ![image](https://user-images.githubusercontent.com/16743001/154969666-0f0838a4-2bbd-4f32-b8a2-2ed968cb3552.png)
krzysztofrewak (Migrated from github.com) requested changes 2022-02-21 15:35:16 +01:00
@@ -0,0 +37,4 @@
self::September => CarbonInterface::SEPTEMBER,
self::October => CarbonInterface::OCTOBER,
self::November => CarbonInterface::NOVEMBER,
self::December => CarbonInterface::DECEMBER,
krzysztofrewak (Migrated from github.com) commented 2022-02-21 15:32:49 +01:00
            static::January => CarbonInterface::JANUARY,
            static::February => CarbonInterface::FEBRUARY,
            static::March => CarbonInterface::MARCH,
            static::April => CarbonInterface::APRIL,
            static::May => CarbonInterface::MAY,
            static::June => CarbonInterface::JUNE,
            static::July => CarbonInterface::JULY,
            static::August => CarbonInterface::AUGUST,
            static::September => CarbonInterface::SEPTEMBER,
            static::October => CarbonInterface::OCTOBER,
            static::November => CarbonInterface::NOVEMBER,
            static::December => CarbonInterface::DECEMBER,
```suggestion static::January => CarbonInterface::JANUARY, static::February => CarbonInterface::FEBRUARY, static::March => CarbonInterface::MARCH, static::April => CarbonInterface::APRIL, static::May => CarbonInterface::MAY, static::June => CarbonInterface::JUNE, static::July => CarbonInterface::JULY, static::August => CarbonInterface::AUGUST, static::September => CarbonInterface::SEPTEMBER, static::October => CarbonInterface::OCTOBER, static::November => CarbonInterface::NOVEMBER, static::December => CarbonInterface::DECEMBER, ```
krzysztofrewak (Migrated from github.com) commented 2022-02-21 15:33:17 +01:00

Plus maybe some exception could be thrown on unknow value/default?

Plus maybe some exception could be thrown on unknow value/default?
krzysztofrewak (Migrated from github.com) commented 2022-02-21 15:33:37 +01:00

Why not to use map()?

Why not to use `map()`?
krzysztofrewak (Migrated from github.com) commented 2022-02-21 15:34:57 +01:00

I would import that too.

I would import that too.
mtracz (Migrated from github.com) requested changes 2022-02-21 15:41:55 +01:00
mtracz (Migrated from github.com) commented 2022-02-21 15:39:05 +01:00

I think we can simplify it:

        return Month::tryFrom($name) ?? Month::current();     
I think we can simplify it: ```suggestion return Month::tryFrom($name) ?? Month::current(); ```
mtracz (Migrated from github.com) commented 2022-02-21 15:40:19 +01:00

Maybe move these hours to consts as start hour and end hour?

Maybe move these hours to consts as start hour and end hour?
Baakoma (Migrated from github.com) reviewed 2022-02-21 15:48:14 +01:00
@@ -0,0 +37,4 @@
self::September => CarbonInterface::SEPTEMBER,
self::October => CarbonInterface::OCTOBER,
self::November => CarbonInterface::NOVEMBER,
self::December => CarbonInterface::DECEMBER,
Baakoma (Migrated from github.com) commented 2022-02-21 15:48:14 +01:00

image

![image](https://user-images.githubusercontent.com/16743001/154977581-bb213207-098b-4e9d-8feb-7d1b5c69e4e5.png)
mtracz (Migrated from github.com) approved these changes 2022-02-21 16:00:44 +01:00
krzysztofrewak (Migrated from github.com) approved these changes 2022-02-21 16:06:28 +01:00
Sign in to join this conversation.