Minor fixes for timezone

This commit is contained in:
David Bomba 2023-06-15 16:29:40 +10:00
parent 98706698d2
commit e54525658b
2 changed files with 1 additions and 2 deletions

View File

@ -88,7 +88,7 @@ class StorePaymentRequest extends Request
// $input['is_manual'] = true; // $input['is_manual'] = true;
if (! isset($input['date'])) { if (! isset($input['date'])) {
$input['date'] = now()->addSeconds(auth()->user()->company->timezone()->utc_offset)->format('Y-m-d'); $input['date'] = now()->addSeconds(auth()->user()->company()->timezone()->utc_offset)->format('Y-m-d');
} }
$this->replace($input); $this->replace($input);

View File

@ -71,7 +71,6 @@ class MarkPaid extends AbstractService
$payment->is_manual = true; $payment->is_manual = true;
if ($this->invoice->company->timezone()) { if ($this->invoice->company->timezone()) {
nlog($this->invoice->company->timezone()->utc_offset);
$payment->date = now()->addSeconds($this->invoice->company->timezone()->utc_offset)->format('Y-m-d'); $payment->date = now()->addSeconds($this->invoice->company->timezone()->utc_offset)->format('Y-m-d');
} }