Added unknown file icon IO-525
This commit is contained in:
BIN
client/public/file.png
Normal file
BIN
client/public/file.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.7 KiB |
BIN
client/src/assets/file.png
Normal file
BIN
client/src/assets/file.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.7 KiB |
@@ -25,7 +25,7 @@ export function ChatMediaSelector({
|
|||||||
}) {
|
}) {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
console.log("conversation", conversation);
|
console.log("conversation", conversation);
|
||||||
const { loading, error, data, refetch } = useQuery(GET_DOCUMENTS_BY_JOB, {
|
const { loading, error, data } = useQuery(GET_DOCUMENTS_BY_JOB, {
|
||||||
variables: {
|
variables: {
|
||||||
jobId:
|
jobId:
|
||||||
conversation.job_conversations[0] &&
|
conversation.job_conversations[0] &&
|
||||||
|
|||||||
@@ -50,13 +50,14 @@ function JobsDocumentsComponent({
|
|||||||
thumb = `${process.env.REACT_APP_CLOUDINARY_ENDPOINT}/${fileType}/upload/c_fill,f_png,h_250,w_250/${value.key}`;
|
thumb = `${process.env.REACT_APP_CLOUDINARY_ENDPOINT}/${fileType}/upload/c_fill,f_png,h_250,w_250/${value.key}`;
|
||||||
break;
|
break;
|
||||||
case "raw":
|
case "raw":
|
||||||
thumb = "";
|
thumb = `${window.location.origin}/file.png`;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
thumb = `${process.env.REACT_APP_CLOUDINARY_ENDPOINT}/${fileType}/upload/${process.env.REACT_APP_CLOUDINARY_THUMB_TRANSFORMATIONS}/${value.key}`;
|
thumb = `${process.env.REACT_APP_CLOUDINARY_ENDPOINT}/${fileType}/upload/${process.env.REACT_APP_CLOUDINARY_THUMB_TRANSFORMATIONS}/${value.key}`;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const fileName = value.key.split("/").pop();
|
||||||
acc.other.push({
|
acc.other.push({
|
||||||
src: `${
|
src: `${
|
||||||
process.env.REACT_APP_CLOUDINARY_ENDPOINT
|
process.env.REACT_APP_CLOUDINARY_ENDPOINT
|
||||||
@@ -65,6 +66,11 @@ function JobsDocumentsComponent({
|
|||||||
}${fileType === "raw" ? `.${value.extension}` : ""}`,
|
}${fileType === "raw" ? `.${value.extension}` : ""}`,
|
||||||
thumbnail: thumb,
|
thumbnail: thumb,
|
||||||
tags: [
|
tags: [
|
||||||
|
{
|
||||||
|
value: fileName,
|
||||||
|
title: fileName,
|
||||||
|
},
|
||||||
|
|
||||||
{ value: value.type, title: value.type },
|
{ value: value.type, title: value.type },
|
||||||
...(value.bill
|
...(value.bill
|
||||||
? [
|
? [
|
||||||
|
|||||||
Reference in New Issue
Block a user