- piuchebuono: possiblità di modificare l'immagine dalla scheda direttamente
- migliorata di poco la grafica dell'immagine.
This commit is contained in:
@@ -307,7 +307,7 @@ export const costanti = {
|
||||
VISUTABLE_USER_TABCIRCUIT: -5,
|
||||
VISUTABLE_GROUP_CIRCUIT: -6,
|
||||
|
||||
DIR_UPLOAD: 'upload/', // upload/
|
||||
DIR_UPLOAD: 'upload/',
|
||||
|
||||
FRIENDS: 1,
|
||||
ASK_TRUST: 2,
|
||||
|
||||
@@ -2220,7 +2220,7 @@ export const colTableProductInfos = [
|
||||
AddCol({ name: 'name', label_trans: 'products.name' }),
|
||||
AddCol({ name: 'description', label_trans: 'products.description', fieldtype: costanti.FieldType.html }),
|
||||
AddCol({ name: 'icon', label_trans: 'products.icon' }),
|
||||
AddCol({ name: 'img', label_trans: 'products.img', fieldtype: costanti.FieldType.image_and_filename, path: 'upload/products/' }),
|
||||
AddCol({ name: 'imagefile', label_trans: 'products.img', fieldtype: costanti.FieldType.image_and_filename, path: costanti.DIR_UPLOAD + 'products/' }),
|
||||
AddCol({
|
||||
name: 'department',
|
||||
label_trans: 'products.department',
|
||||
|
||||
@@ -7340,18 +7340,25 @@ export const tools = {
|
||||
// console.log('arrimage', arrimage)
|
||||
|
||||
if (shared_consts.TABLES_DIRECTORY_A_PARTE.includes(table)) {
|
||||
return `upload/${table}/` + groupname + '/' + arrimage[0].imagefile
|
||||
return costanti.DIR_UPLOAD + `${table}/` + groupname + '/' + arrimage[0].imagefile
|
||||
} else if (shared_consts.TABLES_DIRECTORY_SINGLE_IMG.includes(table)) {
|
||||
return `upload/${table}/` + groupname + '/' + arrimage[0].imagefile
|
||||
return costanti.DIR_UPLOAD + `${table}/` + groupname + '/' + arrimage[0].imagefile
|
||||
} else {
|
||||
// console.log('username', username, 'table', table)
|
||||
if (arrimage && arrimage.length > 0) {
|
||||
return `upload/profile/${username}/${table}/` + arrimage[0].imagefile
|
||||
return costanti.DIR_UPLOAD + `profile/${username}/${table}/` + arrimage[0].imagefile
|
||||
} else {
|
||||
return ''
|
||||
}
|
||||
}
|
||||
},
|
||||
getFullFileNameByImageFile(imagefile: string, table: string) {
|
||||
// console.log('arrimage', arrimage)
|
||||
|
||||
if (shared_consts.TABLES_IMAGEFILE_SINGOLO.includes(table)) {
|
||||
return costanti.DIR_UPLOAD + `products/` + imagefile
|
||||
}
|
||||
},
|
||||
canModifyThisRec(rec: any, tablesel: string) {
|
||||
// console.log('rec', rec)
|
||||
|
||||
@@ -7921,7 +7928,7 @@ export const tools = {
|
||||
},
|
||||
|
||||
getImgFileByFilename(elem: IMyElem, filename: string) {
|
||||
return 'upload/pages/' + elem.path + '/' + filename
|
||||
return costanti.DIR_UPLOAD + 'pages/' + elem.path + '/' + filename
|
||||
},
|
||||
|
||||
getImgFileByElem(elem: IMyElem, reccard?: IMyCard) {
|
||||
@@ -7938,13 +7945,13 @@ export const tools = {
|
||||
addtourl = '?v=' + reccard.vers_img
|
||||
}
|
||||
|
||||
return 'upload/pages/' + elem.path + '/' + reccard.imagefile + addtourl
|
||||
return costanti.DIR_UPLOAD + 'pages/' + elem.path + '/' + reccard.imagefile + addtourl
|
||||
} else
|
||||
return ''
|
||||
} else if (elem.type === shared_consts.ELEMTYPE.IMAGE) {
|
||||
return 'upload/pages/' + elem.path + '/' + elem.container + addtourl
|
||||
return costanti.DIR_UPLOAD + 'pages/' + elem.path + '/' + elem.container + addtourl
|
||||
} else {
|
||||
return 'upload/pages/' + elem.path + '/' + elem.image + addtourl
|
||||
return costanti.DIR_UPLOAD + 'pages/' + elem.path + '/' + elem.image + addtourl
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user