Merge branch 'feature/ticket0807' into develop_bm
This commit is contained in:
@@ -20,14 +20,16 @@ class ConversationService
|
||||
$result = (new ConversationLogic())->list($params);
|
||||
|
||||
$status_fanyi = array_map(fn($v) => "{{{$v}}}", array_flip(Constants::TICKET_STATUS));
|
||||
$result = $result??$result->toArray();
|
||||
$ossservice = new OssService();
|
||||
foreach ($result as $key => $value) {
|
||||
$result[$key]['content'] = str_replace($status_fanyi,$ticket_status,$value['content']);
|
||||
$result[$key]['attachment'] = empty($value['attachment'])?[]:unserialize($value['attachment']);
|
||||
foreach ($result[$key]['attachment'] as $k => $attachment) {
|
||||
$result[$key]['attachment']['storage_path_full'][$k] = (!empty($attachment))?$ossservice->generatePrivateUrl($attachment['storage_path']):'';
|
||||
$value=$value->toArray();
|
||||
$value['content'] = str_replace($status_fanyi,$ticket_status,$value['content']);
|
||||
$value['attachment'] = empty($value['attachment'])?[]:unserialize($value['attachment']);
|
||||
foreach ($value['attachment'] as $k => $attachment) {
|
||||
$value['attachment'][$k]['storage_path_full'] = (!empty($attachment))?$ossservice->generatePrivateUrl($attachment['storage_path']):'';
|
||||
}
|
||||
|
||||
$result[$key] = $value;
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user