This commit is contained in:
@@ -22,7 +22,7 @@ const mimeTypes = {
|
||||
"image/gif": icons.image,
|
||||
"image/jpeg": icons.image,
|
||||
"image/png": icons.image,
|
||||
|
||||
|
||||
"application/pdf": icons.pdf,
|
||||
|
||||
"application/msword": icons.word,
|
||||
@@ -54,6 +54,7 @@ const mimeTypes = {
|
||||
|
||||
"application/gzip": icons.archive,
|
||||
"application/zip": icons.archive,
|
||||
"application/x-tar": icons.archive,
|
||||
|
||||
"text/css": icons.code,
|
||||
"text/html": icons.code,
|
||||
@@ -62,7 +63,9 @@ const mimeTypes = {
|
||||
|
||||
"text/plain": icons.text,
|
||||
"text/richtext": icons.text,
|
||||
"text/rtf": icons.text
|
||||
"text/rtf": icons.text,
|
||||
"application/rtf": icons.text,
|
||||
"application/json": icons.text
|
||||
};
|
||||
|
||||
const extensions = {
|
||||
@@ -95,12 +98,16 @@ const extensions = {
|
||||
|
||||
gz: icons.archive,
|
||||
zip: icons.archive,
|
||||
tar: icons.archive,
|
||||
"7z": icons.archive,
|
||||
|
||||
css: icons.code,
|
||||
html: icons.code,
|
||||
js: icons.code,
|
||||
|
||||
txt: icons.text
|
||||
txt: icons.text,
|
||||
json: icons.text,
|
||||
rtf: icons.text
|
||||
};
|
||||
|
||||
export default {
|
||||
@@ -343,12 +350,17 @@ export default {
|
||||
if (iconFromExtension) {
|
||||
return iconFromExtension;
|
||||
}
|
||||
//debugger;
|
||||
console.log(
|
||||
"gzutil:iconForFile -> No icon for file:" + fileName + " Mime:" + mimeType
|
||||
);
|
||||
|
||||
// console.log(
|
||||
// "gzutil:iconForFile -> No icon for file:" + fileName + " Mime:" + mimeType
|
||||
// );
|
||||
return "fa-file";
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*
|
||||
*/
|
||||
|
||||
//new functions above here
|
||||
};
|
||||
|
||||
@@ -99,8 +99,9 @@ export default {
|
||||
ayaId: this.ayaId,
|
||||
ayaType: this.ayaType,
|
||||
files: this.uploadFiles,
|
||||
notes: this.notes
|
||||
notes: this.notes ? this.notes : ""
|
||||
};
|
||||
|
||||
window.$gz.api.uploadAttachment(at).then(res => {
|
||||
//vm.formState.loading = false;
|
||||
if (res.error) {
|
||||
@@ -164,7 +165,7 @@ export default {
|
||||
languageName,
|
||||
hour12
|
||||
),
|
||||
notes: o.notes,
|
||||
notes: o.notes ? o.notes : "",
|
||||
icon: window.$gz.util.iconForFile(o.displayFileName, o.contentType)
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user