Merge branch 'pdf'
This commit is contained in:
@@ -215,8 +215,12 @@ class UsedCarController extends BaseController
|
||||
$toLang = $this->lang[$to];
|
||||
$spark = new SparkService();
|
||||
$str = $spark->chat("将“{$v}”翻译为{$toLang},不要有多余的描述");
|
||||
$str = preg_replace('/[\x{4e00}-\x{9fa5}]/u', '', $str);
|
||||
$data[$k] =str_replace(['(',')','(',')','"'], '', $str);;
|
||||
if(!empty($str)){
|
||||
$str = preg_replace('/[\x{4e00}-\x{9fa5}]/u', '', $str);
|
||||
$data[$k] =str_replace(['(',')','(',')','"'], '', $str);
|
||||
}else{
|
||||
$data[$k] = '';
|
||||
}
|
||||
}
|
||||
}
|
||||
return $data;
|
||||
|
||||
Reference in New Issue
Block a user