diff --git a/core/components/tickets/processors/web/comment/create.class.php b/core/components/tickets/processors/web/comment/create.class.php index b7872a1..2ff22f9 100644 --- a/core/components/tickets/processors/web/comment/create.class.php +++ b/core/components/tickets/processors/web/comment/create.class.php @@ -87,12 +87,17 @@ public function beforeSet() unset($properties['requiredFields']); // Comment values + if($this->getProperty("date")){ + $date = $this->getProperty("date"); + } else { + $date = date('Y-m-d H:i:s'); + } $ip = $this->modx->request->getClientIp(); $this->setProperties(array( 'text' => $text, 'thread' => $this->thread->id, 'ip' => $ip['ip'], - 'createdon' => date('Y-m-d H:i:s'), + 'createdon' => $date, 'createdby' => $this->modx->user->isAuthenticated($this->modx->context->key) ? $this->modx->user->id : 0,