mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-29 01:13:59 +00:00
Merge branch 'dillon/41-voucherify-phase-2b' into development
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
namespace App\Classes\Modules\Vouchers\DataTransferObjects;
|
||||
|
||||
use App\Classes\General\Interfaces\DataTransferObject;
|
||||
use Carbon\Carbon;
|
||||
use DateTime;
|
||||
use Illuminate\Support\Facades\Log;
|
||||
|
||||
@@ -86,7 +87,8 @@ class VoucherObject implements DataTransferObject
|
||||
{
|
||||
try {
|
||||
if(!$this->startDate) return null;
|
||||
$dateTime = new DateTime($this->startDate);
|
||||
// $dateTime = new DateTime($this->startDate);
|
||||
$dateTime = Carbon::parse($this->startDate)->tz('Asia/Kuala_Lumpur');
|
||||
return $dateTime;
|
||||
} catch (\Exception $e) {
|
||||
Log::error($e);
|
||||
@@ -101,7 +103,7 @@ class VoucherObject implements DataTransferObject
|
||||
{
|
||||
try {
|
||||
if(!$this->endDate) return null;
|
||||
$dateTime = new DateTime($this->endDate);
|
||||
$dateTime = Carbon::parse($this->endDate)->tz('Asia/Kuala_Lumpur');
|
||||
return $dateTime;
|
||||
} catch (\Exception $e) {
|
||||
Log::error($e);
|
||||
|
||||
Reference in New Issue
Block a user