[Blockers] Blockers POST, PUT

This commit is contained in:
Matej Glasnák committed 2023-03-13 21:16:37 +01:00
1 parent 6a376ce405
commit 0d5bfa3b9b
1 file changed
+8
@@ -78,6 +78,10 @@ export default {
computed: { computed: {
...mapGetters('tm', [ ...mapGetters('tm', [
'enrichedEmployees' 'enrichedEmployees'
]),
...mapGetters('auth', [
'user'
]) ])
}, },
@@ -141,6 +145,10 @@ export default {
if (!value || !value[1]) if (!value || !value[1])
return return
this.startEndDate[0] = this.startEndDate[0].setHours(this.user.work_start, 0, 0, 0)
this.startEndDate[1] = this.startEndDate[1].setHours(this.user.work_end, 0, 0, 0)
this.blocker = { this.blocker = {
...this.blocker, ...this.blocker,
start: tmUtils.formatDateTimeForBackend(this.startEndDate[0]), start: tmUtils.formatDateTimeForBackend(this.startEndDate[0]),