- aggiornati gli argomenti in base a GM
This commit is contained in:
@@ -349,6 +349,7 @@ export const costanti = {
|
||||
VISUTABLE_USER_TABCIRCUIT: -5,
|
||||
VISUTABLE_GROUP_CIRCUIT: -6,
|
||||
VISUTABLE_GRID_ORIZ: -10,
|
||||
VISUTABLE_TABLELIST: -20,
|
||||
|
||||
DIR_UPLOAD: 'upload/',
|
||||
DIR_PRODUCTS: 'products/',
|
||||
|
||||
@@ -133,10 +133,16 @@ export const colTableCatalogList = [
|
||||
isadvanced_field: false,
|
||||
}),
|
||||
AddCol({
|
||||
name: 'idCollane',
|
||||
label_trans: 'cataloglist.collane',
|
||||
name: 'idPageAssigned',
|
||||
label_trans: 'cataloglist.idPageAssigned',
|
||||
fieldtype: costanti.FieldType.select,
|
||||
jointable: 'mypages_id',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'referenti',
|
||||
label_trans: 'cataloglist.referenti',
|
||||
fieldtype: costanti.FieldType.multiselect,
|
||||
jointable: 'collanas',
|
||||
jointable: 'lista_editori',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'argomenti',
|
||||
@@ -144,6 +150,12 @@ export const colTableCatalogList = [
|
||||
fieldtype: costanti.FieldType.multiselect,
|
||||
jointable: 'catprods',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'idCollane',
|
||||
label_trans: 'cataloglist.collane',
|
||||
fieldtype: costanti.FieldType.multiselect,
|
||||
jointable: 'collanas',
|
||||
}),
|
||||
AddCol({
|
||||
name: 'editore',
|
||||
label_trans: 'cataloglist.editore',
|
||||
@@ -151,19 +163,6 @@ export const colTableCatalogList = [
|
||||
jointable: 'publishers',
|
||||
}),
|
||||
|
||||
AddCol({
|
||||
name: 'idPageAssigned',
|
||||
label_trans: 'cataloglist.idPageAssigned',
|
||||
fieldtype: costanti.FieldType.select,
|
||||
jointable: 'mypages_id',
|
||||
}),
|
||||
|
||||
AddCol({
|
||||
name: 'referenti',
|
||||
label_trans: 'cataloglist.referenti',
|
||||
fieldtype: costanti.FieldType.multiselect,
|
||||
jointable: 'lista_editori',
|
||||
}),
|
||||
AddCol({ name: 'descr_introduttiva', label_trans: 'cataloglist.descr_introduttiva', fieldtype: costanti.FieldType.html, maxlength: 1300 }),
|
||||
AddCol({ name: 'pagina_introduttiva_sfondo_nero', label_trans: 'cataloglist.pagina_introduttiva_sfondo_nero', fieldtype: costanti.FieldType.boolean }),
|
||||
|
||||
@@ -360,6 +359,7 @@ export const colmyelems = [
|
||||
AddCol({ name: 'parambool', label_trans: 'myelems.parambool', fieldtype: costanti.FieldType.boolean }),
|
||||
AddCol({ name: 'parambool2', label_trans: 'myelems.parambool2', fieldtype: costanti.FieldType.boolean }),
|
||||
AddCol({ name: 'parambool3', label_trans: 'myelems.parambool3', fieldtype: costanti.FieldType.boolean }),
|
||||
AddCol({ name: 'parambool4', label_trans: 'myelems.parambool4', fieldtype: costanti.FieldType.boolean }),
|
||||
AddCol({ name: 'number', label_trans: 'myelems.number', fieldtype: costanti.FieldType.number }),
|
||||
AddCol({ name: 'num2', label_trans: 'myelems.num2', fieldtype: costanti.FieldType.number }),
|
||||
AddCol({ name: 'imgback', label_trans: 'myelems.imgback' }),
|
||||
@@ -414,7 +414,10 @@ export const colmsg_templates = [
|
||||
]
|
||||
|
||||
export const colmypage = [
|
||||
AddCol({ name: '_id', label_trans: 'index', fieldtype: costanti.FieldType.string }),
|
||||
AddCol({
|
||||
name: '_id', label_trans: 'index', fieldtype: costanti.FieldType.string,
|
||||
showWhen: costanti.showWhen.InPage + costanti.showWhen.InEdit,
|
||||
}),
|
||||
AddCol({ name: 'path', label_trans: 'pages.path' }),
|
||||
AddCol({ name: 'icon', label_trans: 'pages.icon' }),
|
||||
AddCol({ name: 'order', label_trans: 'pages.order', fieldtype: costanti.FieldType.number }),
|
||||
@@ -5079,6 +5082,16 @@ export const func = {
|
||||
return mylist
|
||||
}
|
||||
|
||||
return []
|
||||
},
|
||||
gettablesListByTable(table: string) {
|
||||
const userStore = useUserStore()
|
||||
if (fieldsTable.tablesList) {
|
||||
const mylist = fieldsTable.tablesList.filter((rec: any) => ((rec.onlyAdmin === userStore.isAdmin) || (!rec.onlyAdmin)) && (!rec.noshow) && rec.value === table)
|
||||
|
||||
return mylist
|
||||
}
|
||||
|
||||
return []
|
||||
},
|
||||
}
|
||||
|
||||
@@ -2654,6 +2654,7 @@ export const tools = {
|
||||
|| (elem.onlyNotSoci && !userStore.my.profile.socio)
|
||||
|| (elem.onlyFacilitatore && userStore.isFacilitatore)
|
||||
|| (elem.onlyEditor && userStore.isEditor)
|
||||
|| (elem.onlyGrafico && userStore.isGrafico)
|
||||
|| (elem.onlyDepartment && userStore.isDepartment)
|
||||
|| ((!elem.onlyAdmin) && (!elem.onlyManager) && (!elem.onlyFacilitatore) && (!elem.onlyEditor) && (!elem.onlyDepartment)
|
||||
&& (!elem.onlySocioResidente) && (!elem.onlyConsiglio) && (!elem.onlyNotSoci))) && elem.active
|
||||
@@ -3170,7 +3171,11 @@ export const tools = {
|
||||
|
||||
isEditor() {
|
||||
const userStore = useUserStore()
|
||||
return userStore.isEditor
|
||||
return userStore.isEditor || userStore.isAdmin
|
||||
},
|
||||
isGrafico() {
|
||||
const userStore = useUserStore()
|
||||
return userStore.isGrafico || userStore.isAdmin
|
||||
},
|
||||
|
||||
isTeacher() {
|
||||
@@ -7536,7 +7541,7 @@ export const tools = {
|
||||
// return true
|
||||
|
||||
if (shared_consts.TABLES_PER_EDITORI.includes(tablesel)) {
|
||||
if (userStore.isEditor || userStore.isAdmin) {
|
||||
if (userStore.isEditor || userStore.isGrafico || userStore.isAdmin) {
|
||||
return true
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user