Aggiungere "San Marino" e suoi comuni

Corretto Filtro a mano della ricerca
Creare filtro ricerca per trovare la sottocategoria o categoria -> Skill e SubSkill
This commit is contained in:
paoloar77
2022-02-12 02:19:49 +01:00
parent 7c0c2fef39
commit b21a7d1885
63 changed files with 541 additions and 752 deletions

View File

@@ -316,6 +316,11 @@ export const colTableStorehouse = [
AddCol(DuplicateRec),
]
export const colAdType = [
AddCol({ name: '_id', label_trans: 'index', fieldtype: costanti.FieldType.number }),
AddCol({ name: 'descr', label_trans: 'store.description' }),
]
export const colSectors = [
AddCol({ name: '_id', label_trans: 'index', fieldtype: costanti.FieldType.number }),
AddCol({ name: 'descr', label_trans: 'store.description' }),
@@ -502,7 +507,7 @@ export const colmyUserGroup = [
noshowlabel: true,
icon: 'fas fa-map-marker-alt',
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView,
remote_table: 'comune',
remote_table: 'mycities',
remote_key: '_id',
remote_field: 'comune',
}),
@@ -523,8 +528,18 @@ export const colmySkills = [
}), */
//AddCol({ name: 'name', label_trans: 'reg.name', fieldtype: costanti.FieldType.string }),
//AddCol({ name: 'surname', label_trans: 'reg.surname', fieldtype: costanti.FieldType.string }),
AddCol({ name: 'subTitle', label_trans: 'event.title', fieldtype: costanti.FieldType.string,
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit , maxlength: 70, noshowlabel: true }),
// AddCol({ name: 'subTitle', label_trans: 'event.title', fieldtype: costanti.FieldType.string,
// showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit , maxlength: 70, noshowlabel: true }),
AddCol({
name: 'adTypes',
label_trans: 'adTypes.name',
fieldtype: costanti.FieldType.select,
required: true,
jointable: 'adtypes',
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist,
noshowlabel: true,
icon: 'grading',
}),
AddCol({ name: 'descr', label_trans: 'proj.shortdescr', fieldtype: costanti.FieldType.string,
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist, noshowlabel: true, maxlength: 200 }),
AddCol({
@@ -569,7 +584,7 @@ export const colmySkills = [
filter_field: 'idSkill',
noshowlabel: true,
icon: 'far fa-id-card',
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView,
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist,
allowNewValue: true,
}),
AddCol({
@@ -609,7 +624,10 @@ export const colmySkills = [
tablesel: 'cities',
noshowlabel: true,
icon: 'fas fa-map-marker-alt',
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView,
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist,
remote_table: 'mycities',
remote_key: '_id',
remote_field: 'comune',
}),
AddCol({ name: 'username', label_trans: 'reg.username', foredit: false, tipovisu: costanti.TipoVisu.LINK, link: '/my/username', noshowlabel: true }),
AddCol({ name: 'note', label_trans: 'proj.longdescr', fieldtype: costanti.FieldType.html,
@@ -1984,6 +2002,13 @@ export const fieldsTable = {
colkey: '_id',
collabel: 'descr',
},
{
value: 'adtypes',
label: 'Tipo Annuncio',
columns: colAdType,
colkey: '_id',
collabel: 'descr',
},
{
value: 'cities',
label: 'Comune',

View File

@@ -3124,7 +3124,7 @@ export const tools = {
const msg2 = t('fetch.errore_generico') + userStore.getMsgError(riscode)
this.showNotif(mythisq, msg2)
} else if (riscode === this.OK) {
$router.push('/regok')
$router.push('/')
this.showNotif(mythisq, t('components.authentication.email_verification.link_sent', { botname: t('ws.botname') }), {
color: 'green',
textColor: 'black',
@@ -4856,6 +4856,27 @@ export const tools = {
} else {
return value[keyfunz]
}
},
getValueByRemoteField(col: IColGridTable, row: any, value: any, col_tabfooter: string) {
if (col) {
if (col.remote_table && col.remote_key && col.remote_field && col_tabfooter) {
const myarrremote = row[col.remote_table]
let myarr: any = []
for (const myrec of myarrremote) {
let myval = myrec[col.remote_field]
myarr.push(myval)
}
return myarr ? myarr.join(' - ') : ''
}
}
return ''
}