Add Multilingualism. Closed #145

This commit is contained in:
WispX
2021-07-26 17:58:17 +08:00
parent c09bece154
commit d09d57dbe1
43 changed files with 535 additions and 372 deletions
+3 -3
View File
@@ -28,7 +28,7 @@ class Image extends Base
{
$id = $this->request->post('id');
if (!$image = $this->model->where('id', $id)->find()) {
$this->response('未找到该图片数据', [], 500);
$this->response(lang('The picture data was not found'), [], 500);
}
$this->response('success', $this->parseData($image));
}
@@ -56,9 +56,9 @@ class Image extends Base
$data = explode(',', $data);
}
if ($user->deleteImages($data)) {
$this->response('删除成功!');
$this->response(lang('Delete succeeded!'));
}
$this->response('删除失败!', [], 500);
$this->response(lang('Deletion failed!'), [], 500);
}
private function parseData($data)