* Finish task #5821.

This commit is contained in:
Yagami
2019-06-24 09:17:17 +08:00
parent 38608263d3
commit a54180c49f
3 changed files with 11 additions and 3 deletions
+9 -1
View File
@@ -86,7 +86,15 @@ class webhookModel extends model
$object->$field = '';
}
$text = substr($data->text, 0, strpos($data->text, '(http')) ? substr($data->text, 0, strpos($data->text, '(http')) : zget($users, $data->user, $this->app->user->realname) . $this->lang->action->label->{$action->action} . $this->lang->action->objectTypes[$action->objectType] . "[#{$action->objectID}::{$object->$field}]";
$text = '';
if(isset($data->markdown) and is_object($data->markdown))
{
$text = substr($data->markdown->text, 0, strpos($data->markdown->text, '(http'));
}
else
{
$text = substr($data->text, 0, strpos($data->text, '(http')) ? substr($data->text, 0, strpos($data->text, '(http')) : zget($users, $data->user, $this->app->user->realname) . $this->lang->action->label->{$action->action} . $this->lang->action->objectTypes[$action->objectType] . "[#{$action->objectID}::{$object->$field}]";
}
$log->action = $text;
$log->actionURL = $this->getViewLink($action->objectType, $action->objectID);