- creato editor di Pagine (iniziato)
- fix: mancano i "t," su alcuni componenti...
This commit is contained in:
@@ -39,6 +39,7 @@ export default defineComponent({
|
||||
},
|
||||
|
||||
setup(props) {
|
||||
const { t } = useI18n()
|
||||
|
||||
const nextlesson = ref()
|
||||
const calendarStore = useCalendarStore()
|
||||
@@ -88,6 +89,7 @@ export default defineComponent({
|
||||
getImgTeacherByUsername,
|
||||
getLinkEvent,
|
||||
isValidUsername,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
<div class="absolute-bottom text-spacetrans">
|
||||
<q-btn rounded :to="discipline.linkpage">
|
||||
<div class="text-h5 disc__title shadow-max">{{ discipline.label }}</div>
|
||||
</q-btn>
|
||||
</q-btn>
|
||||
</div>
|
||||
</q-img>
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
</q-card-section>
|
||||
|
||||
<q-card-section v-if="ExistLesson()" class="text-blue">
|
||||
<span v-if="!tools.isMobile()">{{ $t('cal.nextevent') }}:</span>
|
||||
<span v-if="!tools.isMobile()">{{ t('cal.nextevent') }}:</span>
|
||||
<q-btn rounded type="a" :to="getLinkEvent" color="primary" icon="event" :label="NextEventDate()">
|
||||
</q-btn>
|
||||
</q-card-section>
|
||||
|
||||
@@ -147,6 +147,7 @@ export default defineComponent({
|
||||
cart_id: mycart.value._id,
|
||||
status: 0,
|
||||
note: note.value,
|
||||
codice_sconto: '',
|
||||
});
|
||||
}
|
||||
}
|
||||
@@ -309,7 +310,7 @@ export default defineComponent({
|
||||
const productName = itemorder.order.product?.productInfo.name || '';
|
||||
const quantity = itemorder.order.quantity + itemorder.order.quantitypreordered;
|
||||
const price = Number(itemorder.order.price).toFixed(2);
|
||||
const totalPrice = (price * quantity).toFixed(2);
|
||||
const totalPrice = (parseFloat(price) * quantity).toFixed(2);
|
||||
|
||||
const row = `${index}${sep}${productCode}${sep}${productName}${sep}${quantity}${sep}${price}${sep}${totalPrice}\n`;
|
||||
csvRows.push(row);
|
||||
@@ -358,7 +359,7 @@ export default defineComponent({
|
||||
}
|
||||
} catch (error) {
|
||||
console.log('error ApplicaSconto', error);
|
||||
tools.showNegativeNotif($q, `Sconto Non Applicato! ${error.message}`);
|
||||
tools.showNegativeNotif($q, `Sconto Non Applicato! ${error?.message || ''}`);
|
||||
codice_sconto.value = '';
|
||||
descr_sconto.value = '';
|
||||
} finally {
|
||||
@@ -416,6 +417,7 @@ export default defineComponent({
|
||||
confermaCodiceSconto,
|
||||
rimuoviCodiceSconto,
|
||||
caricamentodati,
|
||||
t,
|
||||
};
|
||||
},
|
||||
});
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
<table class="table-price">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="label-price">{{ $t('ecomm.prezzointero') }}:</td>
|
||||
<td class="label-price">{{ t('ecomm.prezzointero') }}:</td>
|
||||
<td
|
||||
class="value-price text-subtitle1"
|
||||
:class="{ 'text-strike': myTotalPrice !== totalPriceIntero }"
|
||||
@@ -45,7 +45,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr v-if="recOrderCart.codice_sconto">
|
||||
<td class="label-price">{{ $t('ecomm.sconto_appl') }}:</td>
|
||||
<td class="label-price">{{ t('ecomm.sconto_appl') }}:</td>
|
||||
<td>
|
||||
<div class="column items-center">
|
||||
<q-chip
|
||||
@@ -70,7 +70,7 @@
|
||||
</tr>
|
||||
|
||||
<tr v-if="!recOrderCart.codice_sconto">
|
||||
<td class="label">{{ $t('ecomm.codice_sconto') }}:</td>
|
||||
<td class="label">{{ t('ecomm.codice_sconto') }}:</td>
|
||||
<td>
|
||||
<q-input
|
||||
v-model="codice_sconto"
|
||||
@@ -92,7 +92,7 @@
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="label">{{ $t('ecomm.totale_scontato') }}:</td>
|
||||
<td class="label">{{ t('ecomm.totale_scontato') }}:</td>
|
||||
<td class="ordine_scontato_nuovo text-center">€ {{ myTotalPrice }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
@@ -165,7 +165,7 @@
|
||||
style="text-align: center"
|
||||
class="text-grey"
|
||||
>
|
||||
{{ $t('ecomm.carrello_vuoto') }}
|
||||
{{ t('ecomm.carrello_vuoto') }}
|
||||
</div>
|
||||
|
||||
<br />
|
||||
|
||||
@@ -58,6 +58,7 @@ export default defineComponent({
|
||||
tools,
|
||||
non_hai_circuito_nazionale,
|
||||
destin_non_ha_circuito_naz,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
v-if="non_hai_circuito_nazionale"
|
||||
>
|
||||
<q-banner rounded class="bg-red text-white" style="text-align: center">
|
||||
{{ $t('circuit.non_hai_circuito_nazionale') }}
|
||||
{{ t('circuit.non_hai_circuito_nazionale') }}
|
||||
<br />
|
||||
</q-banner>
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
</div>
|
||||
<div v-if="destin_non_ha_circuito_naz" class="q-py-sm">
|
||||
<q-banner rounded class="bg-red text-white" style="text-align: center">
|
||||
{{ $t('circuit.destin_non_ha_circuito_naz') }}
|
||||
{{ t('circuit.destin_non_ha_circuito_naz') }}
|
||||
<br />
|
||||
</q-banner>
|
||||
<br />
|
||||
@@ -34,7 +34,7 @@
|
||||
glossy
|
||||
size="md"
|
||||
:label="
|
||||
$t('circuit.invia_msg_dest', {
|
||||
t('circuit.invia_msg_dest', {
|
||||
name: to_user ? to_user.username : '',
|
||||
})
|
||||
"
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
flat
|
||||
color="white"
|
||||
@click="tools.openrighttoolbar()"
|
||||
>{{ $t('login.enter') }}
|
||||
>{{ t('login.enter') }}
|
||||
</q-btn>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<q-card class="dialog_card">
|
||||
<q-toolbar class="bg-primary text-white">
|
||||
<q-toolbar-title class="text-h7">
|
||||
{{ $t('account.settings') }}
|
||||
{{ t('account.settings') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||
</q-toolbar>
|
||||
|
||||
@@ -1030,6 +1030,7 @@ export default defineComponent({
|
||||
site: globalStore.site,
|
||||
condividipag,
|
||||
getNumEvents,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<!--<q-toolbar :class="tools.displayClasses(myevent)"-->
|
||||
<!--:style="tools.displayStyles(myevent) + ` min-width: `+ tools.myheight_dialog() + `px;`">-->
|
||||
<q-toolbar-title>
|
||||
{{ $t('cal.event') }}
|
||||
{{ t('cal.event') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn v-if="editable" flat round color="white" icon="fas fa-copy">
|
||||
<q-menu transition-show="flip-right" transition-hide="flip-left">
|
||||
@@ -88,7 +88,7 @@
|
||||
></div>
|
||||
<div v-if="myevent.teacher" class="cal__teacher">
|
||||
<span class="cal__teacher-title"
|
||||
>{{ $t('cal.teacher') }}: <span class="margin_with"></span
|
||||
>{{ t('cal.teacher') }}: <span class="margin_with"></span
|
||||
></span>
|
||||
<!--<span class="cal__teacher-content">{{myevent.teacher}}</span>-->
|
||||
<CMyTeacher :username="myevent.teacher"></CMyTeacher>
|
||||
@@ -98,7 +98,7 @@
|
||||
</div>
|
||||
<div v-if="myevent.wherecode" class="cal__where">
|
||||
<!--<span v-if="tools.isMobile()"><br/></span>-->
|
||||
<span class="cal__where-title">{{ $t('cal.where') }}: </span>
|
||||
<span class="cal__where-title">{{ t('cal.where') }}: </span>
|
||||
<span class="cal__where-content">
|
||||
<q-chip>
|
||||
<q-avatar v-if="getWhereIcon(myevent.wherecode)">
|
||||
@@ -127,7 +127,7 @@
|
||||
v-if="myevent.price && isShowPrice(myevent)"
|
||||
class="cal__quota"
|
||||
>
|
||||
<span class="cal__quota-title">{{ $t('event.price') }}:</span>
|
||||
<span class="cal__quota-title">{{ t('event.price') }}:</span>
|
||||
<q-chip>
|
||||
<span class="cal__quota-content">{{
|
||||
getPrice(myevent)
|
||||
@@ -136,7 +136,7 @@
|
||||
</div>
|
||||
<div v-if="myevent.dateTimeStart" class="cal__when">
|
||||
<span class="cal__where-title"
|
||||
>{{ $t('cal.when') }}:
|
||||
>{{ t('cal.when') }}:
|
||||
<span
|
||||
v-html="tools.getstrDateTimeEvent($t, myevent, true)"
|
||||
></span>
|
||||
@@ -163,7 +163,7 @@
|
||||
<q-card-actions align="right">
|
||||
<q-btn
|
||||
rounded
|
||||
v-if="!myevent.nobookable && site.confpages.bookingEvents"
|
||||
v-if="!myevent.nobookable && site.confpages?.bookingEvents"
|
||||
color="primary"
|
||||
@click="addBookEventMenu(myevent)"
|
||||
:disable="!isEventEnabled(myevent)"
|
||||
@@ -185,7 +185,7 @@
|
||||
<q-card v-if="addEvent" class="dialog_card">
|
||||
<q-toolbar class="bg-primary text-white">
|
||||
<q-toolbar-title>
|
||||
{{ addOrUpdateEvent() }} {{ $t('cal.event') }}
|
||||
{{ addOrUpdateEvent() }} {{ t('cal.event') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||
</q-toolbar>
|
||||
@@ -224,7 +224,7 @@
|
||||
rounded
|
||||
dense
|
||||
:label="$t('event.title')"
|
||||
:rules="[(v) => (v && v.length > 0) || $t('event.notempty')]"
|
||||
:rules="[(v) => (v && v.length > 0) || t('event.notempty')]"
|
||||
></q-input>
|
||||
</div>
|
||||
|
||||
@@ -526,7 +526,7 @@
|
||||
<q-card v-if="bookEventpage.show" class="dialog_card">
|
||||
<q-toolbar class="bg-primary text-white">
|
||||
<q-toolbar-title>
|
||||
{{ $t('cal.booking') }}
|
||||
{{ t('cal.booking') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||
</q-toolbar>
|
||||
@@ -550,7 +550,7 @@
|
||||
</q-chip>
|
||||
<div v-if="myevent.dateTimeStart" class="cal__when">
|
||||
<span class="cal__where-title"
|
||||
>{{ $t('cal.when') }}:
|
||||
>{{ t('cal.when') }}:
|
||||
<span
|
||||
v-html="tools.getstrDateTimeEvent($t, myevent, true)"
|
||||
></span>
|
||||
@@ -607,7 +607,7 @@
|
||||
class="q-px-xs centermydiv"
|
||||
>
|
||||
<div class="itemprenota">
|
||||
{{ $t('cal.selnumpeopleLunch') }}
|
||||
{{ t('cal.selnumpeopleLunch') }}
|
||||
</div>
|
||||
<div
|
||||
class="q-gutter-xs"
|
||||
@@ -640,7 +640,7 @@
|
||||
class="q-px-xs centermydiv"
|
||||
>
|
||||
<div class="itemprenota">
|
||||
{{ $t('cal.selnumpeopleDinner') }}
|
||||
{{ t('cal.selnumpeopleDinner') }}
|
||||
</div>
|
||||
<div
|
||||
class="q-gutter-xs"
|
||||
@@ -672,7 +672,7 @@
|
||||
class="q-px-xs centermydiv"
|
||||
>
|
||||
<div class="itemprenota">
|
||||
{{ $t('cal.selnumpeopleDinnerShared') }}
|
||||
{{ t('cal.selnumpeopleDinnerShared') }}
|
||||
</div>
|
||||
<div
|
||||
class="q-gutter-xs"
|
||||
@@ -764,7 +764,7 @@
|
||||
<q-card v-if="askInfopage.show" class="dialog_card">
|
||||
<q-toolbar class="bg-primary text-white">
|
||||
<q-toolbar-title>
|
||||
{{ $t('cal.booking') }}
|
||||
{{ t('cal.booking') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||
</q-toolbar>
|
||||
@@ -788,7 +788,7 @@
|
||||
</q-chip>
|
||||
<div v-if="myevent.dateTimeStart" class="cal__when">
|
||||
<span class="cal__where-title"
|
||||
>{{ $t('cal.when') }}:
|
||||
>{{ t('cal.when') }}:
|
||||
<span
|
||||
v-html="tools.getstrDateTimeEvent($t, myevent, true)"
|
||||
></span>
|
||||
@@ -1104,7 +1104,7 @@
|
||||
color="green"
|
||||
text-color="white"
|
||||
icon="event_available"
|
||||
>{{ $t('cal.booked') }}
|
||||
>{{ t('cal.booked') }}
|
||||
</q-chip>
|
||||
|
||||
<q-chip
|
||||
@@ -1183,7 +1183,7 @@
|
||||
dense
|
||||
style=""
|
||||
>
|
||||
{{ $t('event.news') }}
|
||||
{{ t('event.news') }}
|
||||
</q-chip>
|
||||
</div>
|
||||
|
||||
@@ -1256,7 +1256,7 @@
|
||||
></p>
|
||||
<div v-if="event.teacher" class="">
|
||||
<span class="cal__teacher-title"
|
||||
>{{ $t('cal.teacher') }}:
|
||||
>{{ t('cal.teacher') }}:
|
||||
<span class="margin_with"></span
|
||||
></span>
|
||||
|
||||
@@ -1268,7 +1268,7 @@
|
||||
<span v-if="event.wherecode" class="">
|
||||
<span v-if="tools.isMobile()"><br /></span>
|
||||
<span class="cal__where-title"
|
||||
>{{ $t('cal.where') }}:
|
||||
>{{ t('cal.where') }}:
|
||||
</span>
|
||||
|
||||
<q-chip>
|
||||
@@ -1295,7 +1295,7 @@
|
||||
</div>
|
||||
<div v-if="event.contribtype" class="">
|
||||
<span class="cal__quota-title"
|
||||
>{{ $t('event.price') }}:<span
|
||||
>{{ t('event.price') }}:<span
|
||||
class="margin_with"
|
||||
></span
|
||||
></span>
|
||||
@@ -1356,7 +1356,7 @@
|
||||
>
|
||||
</q-btn>
|
||||
<!--<q-btn rounded outline class="q-ma-sm"
|
||||
v-if="!event.nobookable && !isAlreadyBooked(event) && site.confpages.bookingEvents"
|
||||
v-if="!event.nobookable && !isAlreadyBooked(event) && site.confpages?.bookingEvents"
|
||||
color="primary" @click="addBookEventMenu(event)"
|
||||
:label="$t('cal.booking')" :disable="!isEventEnabled(event)">
|
||||
</q-btn>-->
|
||||
@@ -1367,7 +1367,7 @@
|
||||
v-if="
|
||||
!event.nobookable &&
|
||||
isAlreadyBooked(event) &&
|
||||
site.confpages.bookingEvents
|
||||
site.confpages?.bookingEvents
|
||||
"
|
||||
text-color="red"
|
||||
@click="EditBookEvent(event)"
|
||||
|
||||
@@ -515,6 +515,7 @@ export default defineComponent({
|
||||
isPDF,
|
||||
upl,
|
||||
uploadFactory,
|
||||
t,
|
||||
};
|
||||
},
|
||||
});
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
color="primary"
|
||||
@click="apri"
|
||||
icon="fas fa-file-upload"
|
||||
:label="isIMG() ? $t('gallery.load_image') : $t('gallery.load_pdf')"
|
||||
:label="isIMG() ? t('gallery.load_image') : t('gallery.load_pdf')"
|
||||
>
|
||||
</q-btn>
|
||||
</div>
|
||||
|
||||
@@ -1630,7 +1630,7 @@ export default defineComponent({
|
||||
|
||||
|
||||
function showandsave(row: any, col: any, newval: any, valinitial: any) {
|
||||
console.log('showandsave CGridTable', row, col, newval)
|
||||
// console.log('showandsave CGridTable', row, col, newval)
|
||||
rowsel.value = row
|
||||
colsel.value = col
|
||||
idsel = row._id
|
||||
|
||||
@@ -120,7 +120,7 @@
|
||||
color="positive"
|
||||
rounded
|
||||
:icon="!showfilteradv ? 'fas fa-arrow-down' : 'fas fa-arrow-up'"
|
||||
:label="!showfilteradv ? $t('grid.advanced_filters') : $t('grid.hide_advanced_filters')"
|
||||
:label="!showfilteradv ? t('grid.advanced_filters') : t('grid.hide_advanced_filters')"
|
||||
@click="showfilteradv = !showfilteradv"
|
||||
></q-btn>
|
||||
</div>
|
||||
@@ -295,7 +295,7 @@
|
||||
:hint="!hintinbtnsearch ? hint : ''"
|
||||
:error-message="noresultLabel"
|
||||
:error="getNumRecFromQuery() === 0 && !startsearch && myfilter !== ''"
|
||||
:label="hintinbtnsearch ? hint : $t('grid.search')"
|
||||
:label="hintinbtnsearch ? hint : t('grid.search')"
|
||||
@keyup.enter="doSearch"
|
||||
@clear="
|
||||
myfilter = '';
|
||||
@@ -330,11 +330,11 @@
|
||||
toggle-color="secondary"
|
||||
:options="[
|
||||
{
|
||||
label: $t('grid.showmap'),
|
||||
label: t('grid.showmap'),
|
||||
value: true,
|
||||
icon: 'fas fa-map-marked-alt',
|
||||
},
|
||||
{ label: $t('grid.showlist'), value: false, icon: 'fas fa-list' },
|
||||
{ label: t('grid.showlist'), value: false, icon: 'fas fa-list' },
|
||||
]"
|
||||
/>
|
||||
</div>
|
||||
@@ -802,7 +802,7 @@
|
||||
size="sm"
|
||||
color="positive"
|
||||
:icon="!showfilteradv ? 'fas fa-arrow-down' : 'fas fa-arrow-up'"
|
||||
:label="!showfilteradv ? $t('grid.advanced_filters') : $t('grid.hide_advanced_filters')"
|
||||
:label="!showfilteradv ? t('grid.advanced_filters') : t('grid.hide_advanced_filters')"
|
||||
@click="showfilteradv = !showfilteradv"
|
||||
></q-btn>
|
||||
</div>
|
||||
@@ -1255,7 +1255,7 @@
|
||||
debounce="500"
|
||||
:error-message="noresultLabel"
|
||||
:error="getNumRecFromQuery() === 0 && !startsearch"
|
||||
:label="hint ? hint : $t('grid.search')"
|
||||
:label="hint ? hint : t('grid.search')"
|
||||
v-on:keyup.enter="doSearch"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -1446,7 +1446,7 @@
|
||||
dense
|
||||
rounded
|
||||
:icon="!showfilteradv ? 'fas fa-arrow-down' : 'fas fa-arrow-up'"
|
||||
:label="showfilteradv ? $t('grid.hide_campi_avanzati') : $t('grid.show_campi_avanzati')"
|
||||
:label="showfilteradv ? t('grid.hide_campi_avanzati') : t('grid.show_campi_avanzati')"
|
||||
:class="{ 'q-btn--active': showfilteradv }"
|
||||
:aria-expanded="showfilteradv.toString()"
|
||||
@click="showfilteradv = !showfilteradv"
|
||||
@@ -1529,7 +1529,7 @@
|
||||
size="md"
|
||||
dense
|
||||
:icon="!showfilteradv ? 'fas fa-arrow-down' : 'fas fa-arrow-up'"
|
||||
:label="!showfilteradv ? $t('grid.show_campi_avanzati') : $t('grid.hide_campi_avanzati')"
|
||||
:label="!showfilteradv ? t('grid.show_campi_avanzati') : t('grid.hide_campi_avanzati')"
|
||||
@click="showfilteradv = !showfilteradv"
|
||||
></q-btn>
|
||||
</div>
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
<div v-if="myaccount.date_created" class="container">
|
||||
<q-icon name="fas fa-lightbulb" class="iconcirc"></q-icon>
|
||||
{{
|
||||
$t('shared.createddate', {
|
||||
t('shared.createddate', {
|
||||
date: tools.getstrDateYY(myaccount.date_created),
|
||||
})
|
||||
}}
|
||||
@@ -68,7 +68,7 @@
|
||||
>
|
||||
<q-icon name="fas fa-pencil-alt" class="iconcirc"></q-icon>
|
||||
<span class="element">{{
|
||||
$t('shared.lastmodify', {
|
||||
t('shared.lastmodify', {
|
||||
date: tools.getstrDateYY(myaccount.date_updated),
|
||||
})
|
||||
}}</span>
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
</div>
|
||||
|
||||
<div
|
||||
v-if="site && site.confpages && site.confpages.showNameSurname"
|
||||
v-if="site && site.confpages && site.confpages?.showNameSurname"
|
||||
>
|
||||
<div class="text-h6">
|
||||
<span v-if="checkifShow('name') && myuser.name">
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
<div v-else-if="mycol.name === 'dateTimeStart'" class="text-center cal">
|
||||
|
||||
<div v-if="myrec.dateTimeStart" class="cal__when">
|
||||
<span class="cal__where-title">{{ $t('cal.when') }}:</span>
|
||||
<span class="cal__where-title">{{ t('cal.when') }}:</span>
|
||||
<span v-html="tools.getstrDateTimeEvent(t, myrec, true)"></span>
|
||||
</div>
|
||||
<!--
|
||||
@@ -92,11 +92,11 @@
|
||||
|
||||
<br>
|
||||
<div v-if="myrec.date_created" class="row justify-center">
|
||||
<span class="cal__where-title"> {{ $t('reg.pub_created') }}:</span>
|
||||
<span class="cal__where-title"> {{ t('reg.pub_created') }}:</span>
|
||||
<span v-html="tools.getstrDate(myrec.date_created)"></span>
|
||||
</div>
|
||||
<div v-if="tools.getstrDate(myrec.date_updated) !== tools.getstrDate(myrec.date_created)" class="row justify-center">
|
||||
<span class="cal__where-title"> {{ $t('reg.pub_updated') }}:</span>
|
||||
<span class="cal__where-title"> {{ t('reg.pub_updated') }}:</span>
|
||||
<span v-html="tools.getstrDate(myrec.date_updated)"></span>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -139,7 +139,7 @@
|
||||
clicca(
|
||||
costanti.TIPOFAVBOOK.SEEN,
|
||||
false,
|
||||
$t('cmd.seen', {
|
||||
t('cmd.seen', {
|
||||
num: myrec.numseen ? myrec.numseen : 0,
|
||||
})
|
||||
)
|
||||
@@ -164,7 +164,7 @@
|
||||
clicca(
|
||||
costanti.TIPOFAVBOOK.FAVORITE,
|
||||
false,
|
||||
$t('cmd.favorite', {
|
||||
t('cmd.favorite', {
|
||||
num: myrec.numfav ? myrec.numfav : 0,
|
||||
})
|
||||
)
|
||||
@@ -189,7 +189,7 @@
|
||||
clicca(
|
||||
costanti.TIPOFAVBOOK.ATTEND,
|
||||
false,
|
||||
$t('cmd.attend', {
|
||||
t('cmd.attend', {
|
||||
num: numpart,
|
||||
})
|
||||
)
|
||||
@@ -214,7 +214,7 @@
|
||||
clicca(
|
||||
costanti.TIPOFAVBOOK.BOOKMARK,
|
||||
false,
|
||||
$t('cmd.bookmark', {
|
||||
t('cmd.bookmark', {
|
||||
num: myrec.numbook ? myrec.numbook : 0,
|
||||
})
|
||||
)
|
||||
@@ -806,14 +806,14 @@
|
||||
color="primary"
|
||||
:label="
|
||||
numpart
|
||||
? $t('cmd.attend1', { num: numpart })
|
||||
: $t('cmd.attend', { num: numpart })
|
||||
? t('cmd.attend1', { num: numpart })
|
||||
: t('cmd.attend', { num: numpart })
|
||||
"
|
||||
@click="
|
||||
clicca(
|
||||
costanti.TIPOFAVBOOK.ATTEND,
|
||||
false,
|
||||
$t('cmd.attend', { num: numpart })
|
||||
t('cmd.attend', { num: numpart })
|
||||
)
|
||||
"
|
||||
>
|
||||
@@ -944,8 +944,8 @@
|
||||
rounded
|
||||
:label="
|
||||
userStore.isFavorite(myrec._id, table)
|
||||
? $t('reaction.tipiace')
|
||||
: $t('reaction.mipiace')
|
||||
? t('reaction.tipiace')
|
||||
: t('reaction.mipiace')
|
||||
"
|
||||
text-color="red"
|
||||
color="white"
|
||||
@@ -1031,7 +1031,7 @@
|
||||
rounded
|
||||
outline
|
||||
class="q-ma-sm"
|
||||
v-if="isAlreadyBooked() && site.confpages.bookingEvents"
|
||||
v-if="isAlreadyBooked() && site.confpages?.bookingEvents"
|
||||
text-color="red"
|
||||
@click="EditBookEvent(true)"
|
||||
:label="$t('cal.modifybooking')"
|
||||
|
||||
@@ -13,6 +13,7 @@ import { useI18n } from 'vue-i18n';
|
||||
|
||||
import MixinUsers from '../../mixins/mixin-users';
|
||||
import { useQuasar } from 'quasar';
|
||||
import { ICart } from 'app/src/model';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CMyCart',
|
||||
@@ -31,7 +32,7 @@ export default defineComponent({
|
||||
const descr_sconto = ref('')
|
||||
const caricamentodati = ref(false)
|
||||
|
||||
const myCart = computed(() => productStore.cart);
|
||||
const myCart = computed<ICart | null>(() => productStore.cart);
|
||||
const myTotalPrice = computed(() => {
|
||||
if (productStore.cart) {
|
||||
return productStore.cart.totalPrice.toFixed(2);
|
||||
@@ -56,6 +57,14 @@ export default defineComponent({
|
||||
}
|
||||
});
|
||||
|
||||
const idOrdersCart = computed(() => {
|
||||
if (!!productStore.cart) {
|
||||
return productStore.cart._id;
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
});
|
||||
|
||||
const numOrders = computed(() => {
|
||||
if (!!productStore.cart && productStore.cart.items) {
|
||||
return productStore.cart.items.length;
|
||||
@@ -95,12 +104,12 @@ export default defineComponent({
|
||||
codice_sconto.value = '';
|
||||
descr_sconto.value = '';
|
||||
if (rissconto.mycart) {
|
||||
recOrderCart.value = rissconto.mycart
|
||||
myCart.value = rissconto.mycart
|
||||
};
|
||||
}
|
||||
} catch (error) {
|
||||
} catch (error: any) {
|
||||
console.log('error ApplicaSconto', error);
|
||||
tools.showNegativeNotif($q, `Sconto Non Applicato! ${error.message}`);
|
||||
tools.showNegativeNotif($q, `Sconto Non Applicato! ${error?.message || ''}`);
|
||||
codice_sconto.value = '';
|
||||
descr_sconto.value = '';
|
||||
} finally {
|
||||
@@ -130,6 +139,7 @@ export default defineComponent({
|
||||
confermaCodiceSconto,
|
||||
caricamentodati,
|
||||
descr_sconto,
|
||||
idOrdersCart,
|
||||
};
|
||||
},
|
||||
});
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
<table class="table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="label">{{ $t('ecomm.prezzointero') }}:</td>
|
||||
<td class="label">{{ t('ecomm.prezzointero') }}:</td>
|
||||
<td
|
||||
class="value text-subtitle1 text-right"
|
||||
:class="{ 'text-strike': myTotalPrice !== totalPriceIntero }"
|
||||
@@ -36,7 +36,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr v-if="myCart.codice_sconto">
|
||||
<td class="label">{{ $t('ecomm.sconto_appl') }}:</td>
|
||||
<td class="label">{{ t('ecomm.sconto_appl') }}:</td>
|
||||
<td>
|
||||
<div class="column items-center">
|
||||
<q-chip
|
||||
@@ -46,14 +46,14 @@
|
||||
size="md"
|
||||
icon="fas fa-tag"
|
||||
>
|
||||
<span class="sconto-text">{{ myCart.descr_sconto }}</span>
|
||||
<span class="sconto-text">{{ descr_sconto }}</span>
|
||||
</q-chip>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr v-if="!myCart.codice_sconto">
|
||||
<td class="label">{{ $t('ecomm.codice_sconto') }}:</td>
|
||||
<td class="label">{{ t('ecomm.codice_sconto') }}:</td>
|
||||
<td>
|
||||
<q-input
|
||||
v-model="codice_sconto"
|
||||
@@ -75,7 +75,7 @@
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td class="label">{{ $t('ecomm.totale_scontato') }}:</td>
|
||||
<td class="label">{{ t('ecomm.totale_scontato') }}:</td>
|
||||
<td class="ordine_scontato_nuovo text-right">€ {{ myTotalPrice }}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
@@ -92,7 +92,7 @@
|
||||
<CSingleCart
|
||||
:order="rec.order"
|
||||
:showall="false"
|
||||
:idOrdersCart="ordersCart ? ordersCart._id : ''"
|
||||
:idOrdersCart="idOrdersCart ? idOrdersCart : ''"
|
||||
>
|
||||
</CSingleCart>
|
||||
</div>
|
||||
@@ -102,7 +102,7 @@
|
||||
style="text-align: center"
|
||||
class="text-grey"
|
||||
>
|
||||
{{ $t('ecomm.carrello_vuoto') }}
|
||||
{{ t('ecomm.carrello_vuoto') }}
|
||||
</div>
|
||||
<div
|
||||
v-else
|
||||
|
||||
@@ -119,7 +119,7 @@
|
||||
name="fas fa-lock"
|
||||
></q-icon>
|
||||
<span class="text-red text-weight-bold">
|
||||
{{ $t('circuit.transaction_suspended') }}
|
||||
{{ t('circuit.transaction_suspended') }}
|
||||
</span>
|
||||
</q-item-label>
|
||||
|
||||
@@ -169,7 +169,7 @@
|
||||
"
|
||||
color="positive"
|
||||
:label="
|
||||
circuit.askManagerToEnter ? $t('circuit.ask') : $t('circuit.apri')
|
||||
circuit.askManagerToEnter ? t('circuit.ask') : t('circuit.apri')
|
||||
"
|
||||
@click="
|
||||
requestToEnterCircuit = true;
|
||||
@@ -218,7 +218,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
circuit.askManagerToEnter ? $t('circuit.ask') : $t('circuit.enter')
|
||||
circuit.askManagerToEnter ? t('circuit.ask') : t('circuit.enter')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -244,7 +244,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
{{ $t('shared.refuse_ask') }}
|
||||
{{ t('shared.refuse_ask') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -261,7 +261,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
{{ $t('shared.cancel_ask') }}
|
||||
{{ t('shared.cancel_ask') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -284,7 +284,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('circuit.exit') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.exit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -304,7 +304,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('circuit.delete') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.delete') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -348,7 +348,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
{{ $t('circuit.reject_ask') }}
|
||||
{{ t('circuit.reject_ask') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -383,7 +383,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
{{ $t('shared.refuse_ask') }}
|
||||
{{ t('shared.refuse_ask') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -402,7 +402,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
{{ $t('shared.cancel_ask') }}
|
||||
{{ t('shared.cancel_ask') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -424,7 +424,7 @@
|
||||
"
|
||||
icon="fas fa-user-plus"
|
||||
color="primary"
|
||||
:label="circuit.askManagerToEnter ? $t('circuit.ask') : $t('circuit.enter')"
|
||||
:label="circuit.askManagerToEnter ? t('circuit.ask') : t('circuit.enter')"
|
||||
rounded
|
||||
@click="
|
||||
requestToEnterCircuit = true;
|
||||
@@ -459,7 +459,7 @@
|
||||
userStore.my.username,
|
||||
circuit.name,
|
||||
'',
|
||||
$t('circuit.domanda_exit_fromcircuit', {
|
||||
t('circuit.domanda_exit_fromcircuit', {
|
||||
circuitname: circuit.name,
|
||||
})
|
||||
)
|
||||
@@ -472,7 +472,7 @@
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>
|
||||
{{ $t('circuit.exit_circuit') }}
|
||||
{{ t('circuit.exit_circuit') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
|
||||
@@ -499,7 +499,7 @@
|
||||
name="fas fa-trash-alt"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.delete') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.delete') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-list>
|
||||
|
||||
@@ -4,6 +4,7 @@ import { CTitleBanner } from '../CTitleBanner'
|
||||
|
||||
import { defineComponent, onMounted, ref, toRef, watch } from 'vue'
|
||||
import { useQuasar } from 'quasar'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CMyEditor',
|
||||
@@ -47,6 +48,7 @@ export default defineComponent({
|
||||
},
|
||||
setup(props, { emit }) {
|
||||
const $q = useQuasar()
|
||||
const { t } = useI18n();
|
||||
|
||||
const editorRef = ref(<any>null)
|
||||
const editor = ref('')
|
||||
@@ -247,6 +249,7 @@ export default defineComponent({
|
||||
editorRef,
|
||||
showtools,
|
||||
characterCount,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<q-toggle
|
||||
v-if="!hideTools"
|
||||
v-model="showtools"
|
||||
:label="showtools ? $t('editor.hidetool') : $t('editor.showtool')"
|
||||
:label="showtools ? t('editor.hidetool') : t('editor.showtool')"
|
||||
@click="tools.setCookie('showtools', showtools ? '1' : '0')"
|
||||
></q-toggle>
|
||||
<br />
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<q-toggle
|
||||
v-if="!hideTools"
|
||||
v-model="showtools"
|
||||
:label="showtools ? $t('editor.hidetool') : $t('editor.showtool')"
|
||||
:label="showtools ? t('editor.hidetool') : t('editor.showtool')"
|
||||
@click="tools.setCookie('showtools', showtools ? '1' : '0')"
|
||||
></q-toggle>
|
||||
<br />
|
||||
|
||||
@@ -359,6 +359,7 @@ export default defineComponent({
|
||||
tabcatalogo,
|
||||
costanti,
|
||||
naviga,
|
||||
t,
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -848,7 +848,7 @@
|
||||
size="md"
|
||||
rounded
|
||||
:label="
|
||||
$t('dashboard.link_gruppo_telegram', {
|
||||
t('dashboard.link_gruppo_telegram', {
|
||||
prov: tools.getProvincia(),
|
||||
})
|
||||
"
|
||||
@@ -870,7 +870,7 @@
|
||||
v-if="tools.isLogged() && !tools.isVerified()"
|
||||
class="text-verified"
|
||||
>
|
||||
{{ $t('components.authentication.email_verification.link_sent') }}
|
||||
{{ t('components.authentication.email_verification.link_sent') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1094,7 +1094,7 @@
|
||||
color="primary"
|
||||
@click="PagLogin"
|
||||
>
|
||||
{{ $t('login.enter') }}
|
||||
{{ t('login.enter') }}
|
||||
</q-btn>
|
||||
</div>
|
||||
<div v-else-if="myel.type === shared_consts.ELEMTYPE.FOOTER">
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('groups.remove_from_mygroups')
|
||||
t('groups.remove_from_mygroups')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -101,7 +101,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.delete_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.delete_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -120,7 +120,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.block_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.block_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -145,7 +145,7 @@
|
||||
name="img: /images/1ris_rosso_100.png"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.sendcoins') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.sendcoins') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
v-if="tools.iAmAdminGroup(grp.groupname)"
|
||||
@@ -160,7 +160,7 @@
|
||||
name="fas fa-download"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.receive_coins') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.receive_coins') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -170,7 +170,7 @@
|
||||
<q-item-section avatar>
|
||||
<q-icon name="fas fa-info" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('groups.infoaccount') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.infoaccount') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -181,7 +181,7 @@
|
||||
userStore.my.username,
|
||||
circuitname,
|
||||
grp.groupname,
|
||||
$t('circuit.domanda_exit_fromcircuit', {
|
||||
t('circuit.domanda_exit_fromcircuit', {
|
||||
circuitname,
|
||||
})
|
||||
)
|
||||
@@ -193,7 +193,7 @@
|
||||
name="fas fa-user-minus"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.exit_circuit') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.exit_circuit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -230,7 +230,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.ask_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.ask_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -254,7 +254,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -269,7 +269,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.cancel_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.cancel_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -289,7 +289,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.exit_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.exit_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -309,7 +309,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.delete_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.delete_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -337,7 +337,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.reject_ask_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.reject_ask_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -365,7 +365,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -382,7 +382,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.cancel_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.cancel_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -411,7 +411,7 @@
|
||||
name="img: /images/1ris_rosso_100.png"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.sendcoins') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.sendcoins') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -434,7 +434,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.ask_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.ask_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -457,7 +457,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -472,7 +472,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('shared.cancel_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.cancel_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -492,7 +492,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.exit_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.exit_group') }}</q-item-section>
|
||||
</q-item>
|
||||
|
||||
<q-item
|
||||
@@ -504,7 +504,7 @@
|
||||
userStore.my.username,
|
||||
circuitname,
|
||||
grp.groupname,
|
||||
$t('circuit.domanda_exit_fromcircuit', {
|
||||
t('circuit.domanda_exit_fromcircuit', {
|
||||
circuitname,
|
||||
})
|
||||
)
|
||||
@@ -516,7 +516,7 @@
|
||||
name="fas fa-user-minus"
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('circuit.exit_circuit') }}</q-item-section>
|
||||
<q-item-section>{{ t('circuit.exit_circuit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list
|
||||
@@ -536,7 +536,7 @@
|
||||
)
|
||||
"
|
||||
>
|
||||
<q-item-section>{{ $t('groups.delete_group') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.delete_group') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
@@ -564,7 +564,7 @@
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>
|
||||
{{ $t('circuit.accept') }}
|
||||
{{ t('circuit.accept') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -581,7 +581,7 @@
|
||||
/>
|
||||
</q-item-section>
|
||||
<q-item-section>
|
||||
{{ $t('circuit.enablefido') }}
|
||||
{{ t('circuit.enablefido') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -600,7 +600,7 @@
|
||||
/>
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -616,7 +616,7 @@
|
||||
/>
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{ $t('shared.cancel_ask_short') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.cancel_ask_short') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
|
||||
@@ -657,7 +657,7 @@ export default defineComponent({
|
||||
|
||||
loaded.value = true;
|
||||
|
||||
console.log('MOUNTED - myvalue.value', myvalue.value)
|
||||
// console.log('MOUNTED - myvalue.value', myvalue.value)
|
||||
|
||||
// console.log('myvalueprec', myvalueprec)
|
||||
}
|
||||
@@ -801,7 +801,7 @@ export default defineComponent({
|
||||
// console.log('DOPO myvalue', myvalue, newVal, myvalueprec)
|
||||
}
|
||||
|
||||
console.log('Savedb: type', col.value.fieldtype);
|
||||
// console.log('Savedb: type', col.value.fieldtype);
|
||||
|
||||
if (col.value.fieldtype === costanti.FieldType.imagerec) {
|
||||
console.log('newVal.imagefile', newVal);
|
||||
@@ -832,7 +832,7 @@ export default defineComponent({
|
||||
myvalue.value.accomodation = newVal;
|
||||
}
|
||||
|
||||
console.log('Savedb', newVal)
|
||||
// console.log('Savedb', newVal)
|
||||
|
||||
emit('showandsave', props.row, props.mycol, newVal, valinitial);
|
||||
visueditor.value = false;
|
||||
|
||||
@@ -207,8 +207,8 @@
|
||||
v-model="myvalue"
|
||||
:label="t('dialog.condition')"
|
||||
:options="[
|
||||
{ label: $t('dialog.conditionAND'), value: costanti.OP_ANDOR.OP_AND },
|
||||
{ label: $t('dialog.conditionOR'), value: costanti.OP_ANDOR.OP_OR },
|
||||
{ label: t('dialog.conditionAND'), value: costanti.OP_ANDOR.OP_AND },
|
||||
{ label: t('dialog.conditionOR'), value: costanti.OP_ANDOR.OP_OR },
|
||||
]"
|
||||
emit-value
|
||||
map-options
|
||||
@@ -217,7 +217,7 @@
|
||||
</q-select>
|
||||
<span v-else>
|
||||
<div class="text-subtitle2 text-primary text-weight-medium">
|
||||
{{ $t('dialog.condition') }}
|
||||
{{ t('dialog.condition') }}
|
||||
</div>
|
||||
|
||||
<q-chip
|
||||
@@ -231,8 +231,8 @@
|
||||
"
|
||||
:label="
|
||||
myvalue === costanti.OP_ANDOR.OP_AND
|
||||
? $t('dialog.conditionAND')
|
||||
: $t('dialog.conditionOR')
|
||||
? t('dialog.conditionAND')
|
||||
: t('dialog.conditionOR')
|
||||
"
|
||||
></q-chip>
|
||||
</span>
|
||||
@@ -261,10 +261,10 @@
|
||||
"
|
||||
:label="
|
||||
myvalue?.esito === costanti.VALIDATO.NO
|
||||
? $t('validazione.NO')
|
||||
? t('validazione.NO')
|
||||
: myvalue?.esito === costanti.VALIDATO.SI
|
||||
? $t('validazione.SI')
|
||||
: $t('validazione.TO_RESOLV')
|
||||
? t('validazione.SI')
|
||||
: t('validazione.TO_RESOLV')
|
||||
"
|
||||
></q-chip>
|
||||
</div>
|
||||
|
||||
@@ -587,6 +587,7 @@ export default defineComponent({
|
||||
globalStore,
|
||||
prStep,
|
||||
showBanner_utenti_verif,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -9,11 +9,11 @@
|
||||
class="q-pa-none"
|
||||
:title="
|
||||
!progressStep
|
||||
? $t('tutorial.title', { indstep: indstep + 1, numindstep }) +
|
||||
? t('tutorial.title', { indstep: indstep + 1, numindstep }) +
|
||||
` (` +
|
||||
progressLabel +
|
||||
`)`
|
||||
: $t('tutorial.title_completed', {
|
||||
: t('tutorial.title_completed', {
|
||||
indstep: indstep + 1,
|
||||
numindstep,
|
||||
}) +
|
||||
@@ -40,7 +40,7 @@
|
||||
color="white"
|
||||
text-color="accent"
|
||||
:label="
|
||||
$t('tutorial.completed_step', { perc: progressLabel })
|
||||
t('tutorial.completed_step', { perc: progressLabel })
|
||||
"
|
||||
/>
|
||||
</div>
|
||||
@@ -244,10 +244,10 @@
|
||||
:color="isSalta(recstep.step) ? 'negative' : 'primary'"
|
||||
:label="
|
||||
recstep.indstep === numindstep
|
||||
? $t('dialog.finish')
|
||||
? t('dialog.finish')
|
||||
: isSalta(recstep.step)
|
||||
? $t('dialog.salta')
|
||||
: $t('dialog.avanti')
|
||||
? t('dialog.salta')
|
||||
: t('dialog.avanti')
|
||||
"
|
||||
/>
|
||||
</q-stepper-navigation>
|
||||
@@ -279,14 +279,14 @@
|
||||
<template v-slot:action>
|
||||
<q-btn
|
||||
:label="
|
||||
userstoverify.length + ' ' + $t('tutorial.utenti_da_verif_btn')
|
||||
userstoverify.length + ' ' + t('tutorial.utenti_da_verif_btn')
|
||||
"
|
||||
class="q-my-sm"
|
||||
rounded
|
||||
icon="fas fa-users"
|
||||
@click="
|
||||
usersList.show = true;
|
||||
usersList.title = $t('tutorial.utenti_da_verif_btn');
|
||||
usersList.title = t('tutorial.utenti_da_verif_btn');
|
||||
"
|
||||
/>
|
||||
<q-btn
|
||||
|
||||
@@ -312,7 +312,7 @@
|
||||
>
|
||||
<span class="text-bold text-green text-h7">
|
||||
<q-icon name="fas fa-user-check" color="green"></q-icon>
|
||||
{{ $t('event.attend') }}</span
|
||||
{{ t('event.attend') }}</span
|
||||
>
|
||||
</q-item-label>
|
||||
<q-item-label
|
||||
@@ -340,7 +340,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-pencil-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.edit') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.edit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -352,7 +352,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-copy" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('event.duplicate') }}</q-item-section>
|
||||
<q-item-section>{{ t('event.duplicate') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -364,7 +364,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-trash-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.elimina') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.elimina') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
</div>
|
||||
<div class="q-px-md">
|
||||
<div class="text-caption text-h7 text-grey q-pb-xs">
|
||||
<q-icon name="fas fa-list-ol" /> {{ $t('cataloglist.numprodotti') }}:
|
||||
<q-icon name="fas fa-list-ol" /> {{ t('cataloglist.numprodotti') }}:
|
||||
<span :class="`text-` + (numprodottistr === 0 ? 'red' : 'blue')">{{
|
||||
numprodottistr
|
||||
}}</span>
|
||||
@@ -56,7 +56,7 @@
|
||||
v-if="!tools.isUtente() && dettagli"
|
||||
class="text-caption text-h7 text-grey q-pb-xs"
|
||||
>
|
||||
<q-icon name="fas fa-user" /> {{ $t('cataloglist.referenti') }}:
|
||||
<q-icon name="fas fa-user" /> {{ t('cataloglist.referenti') }}:
|
||||
<span
|
||||
v-if="myrec.referenti && myrec.referenti.length > 0"
|
||||
:class="
|
||||
@@ -82,21 +82,21 @@
|
||||
v-if="!tools.isUtente() && argomentistr && dettagli"
|
||||
class="text-caption text-h7 text-grey q-pb-xs"
|
||||
>
|
||||
<q-icon name="fas fa-book" /> {{ $t('cataloglist.argomenti') }}:
|
||||
<q-icon name="fas fa-book" /> {{ t('cataloglist.argomenti') }}:
|
||||
<span class="text-blue">{{ argomentistr + ` (${numprodtot})` }}</span>
|
||||
</div>
|
||||
<div
|
||||
v-if="!tools.isUtente() && editorestr && dettagli"
|
||||
class="text-caption text-h7 text-grey q-pb-xs"
|
||||
>
|
||||
<q-icon name="fas fa-book-open" /> {{ $t('cataloglist.casaeditrice') }}:
|
||||
<q-icon name="fas fa-book-open" /> {{ t('cataloglist.casaeditrice') }}:
|
||||
<span class="text-blue">{{ editorestr }}</span>
|
||||
</div>
|
||||
<div
|
||||
v-if="!tools.isUtente() && editorestr_escludi && dettagli"
|
||||
class="text-caption text-h7 text-grey q-pb-xs"
|
||||
>
|
||||
<q-icon name="fas fa-book-open" /> {{ $t('cataloglist.editore_escludi') }}:
|
||||
<q-icon name="fas fa-book-open" /> {{ t('cataloglist.editore_escludi') }}:
|
||||
<span class="text-blue">{{ editorestr_escludi }}</span>
|
||||
</div>
|
||||
<div
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
<q-icon v-if="!circuit.transactionsEnabled" name="fas fa-lock">
|
||||
</q-icon>
|
||||
<span class="text-red text-weight-bold">{{
|
||||
$t('circuit.transaction_suspended')
|
||||
t('circuit.transaction_suspended')
|
||||
}}</span>
|
||||
</q-item-label>
|
||||
|
||||
@@ -138,7 +138,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-pencil-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.edit') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.edit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -150,7 +150,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-copy" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('event.duplicate') }}</q-item-section>
|
||||
<q-item-section>{{ t('event.duplicate') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -162,7 +162,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-trash-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.elimina') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.elimina') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
|
||||
@@ -121,7 +121,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-pencil-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.edit') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.edit') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
<q-list style="min-width: 150px">
|
||||
@@ -133,7 +133,7 @@
|
||||
<q-item-section side>
|
||||
<q-icon name="fas fa-trash-alt" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('reg.elimina') }}</q-item-section>
|
||||
<q-item-section>{{ t('reg.elimina') }}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
</div>
|
||||
<div class="q-px-md">
|
||||
<div class="text-caption text-h7 text-grey q-pb-xs">
|
||||
<q-icon name="fas fa-list-ol" /> {{ $t('racccat.numcataloghi') }}:
|
||||
<q-icon name="fas fa-list-ol" /> {{ t('racccat.numcataloghi') }}:
|
||||
<span :class="`text-` + (numcataloghistr === 0 ? 'red' : 'blue')">{{ numcataloghistr }}</span>
|
||||
</div>
|
||||
<div
|
||||
|
||||
@@ -18,6 +18,7 @@ import type { IEvents} from '@src/model';
|
||||
import { IOperators } from '@src/model'
|
||||
import MixinEvents from '@src/mixins/mixin-events'
|
||||
import { useGlobalStore } from '@src/store/globalStore'
|
||||
import { useI18n } from 'vue-i18n';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CMySingleEvent',
|
||||
@@ -33,6 +34,7 @@ export default defineComponent({
|
||||
|
||||
const selected = ref(false)
|
||||
const globalStore = useGlobalStore()
|
||||
const { t } = useI18n()
|
||||
|
||||
const site = ref(globalStore.site)
|
||||
|
||||
@@ -101,6 +103,7 @@ export default defineComponent({
|
||||
UpdateDbByFields,
|
||||
selected,
|
||||
site,
|
||||
t,
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<q-chip
|
||||
dense v-if="isAlreadyBooked(myevent)" class="cltexth4 chipbooked shadow-5 q-mb-md"
|
||||
color="green" text-color="white"
|
||||
icon="event_available">{{ $t('cal.booked') }}
|
||||
icon="event_available">{{ t('cal.booked') }}
|
||||
</q-chip>
|
||||
<div v-if="selected">
|
||||
<q-chip v-if="editable" class="text-center shadow-5 glossy bg-blue chipmodif">
|
||||
@@ -52,7 +52,7 @@
|
||||
v-if="myevent.news" class="cltexth4 chipnews shadow-5 glossy text-right" color="red"
|
||||
text-color="white" icon-right="star" icon="star" dense
|
||||
style="">
|
||||
{{ $t('event.news') }}
|
||||
{{ t('event.news') }}
|
||||
</q-chip>
|
||||
|
||||
</div>
|
||||
@@ -101,7 +101,7 @@
|
||||
</div>
|
||||
|
||||
<div v-if="myevent.teacher" class="">
|
||||
<span class="cal__teacher-title">{{ $t('cal.teacher') }}: <span
|
||||
<span class="cal__teacher-title">{{ t('cal.teacher') }}: <span
|
||||
class="margin_with"></span></span>
|
||||
|
||||
<CMyTeacher :username="myevent.teacher"></CMyTeacher>
|
||||
@@ -111,7 +111,7 @@
|
||||
|
||||
<span v-if="myevent.wherecode" class="q-ma-md">
|
||||
<span v-if="tools.isMobile()"><br/></span>
|
||||
<span class="cal__where-title">{{ $t('cal.where') }}: </span>
|
||||
<span class="cal__where-title">{{ t('cal.where') }}: </span>
|
||||
|
||||
<q-chip>
|
||||
<q-avatar v-if="getWhereIcon(myevent.wherecode)">
|
||||
@@ -129,7 +129,7 @@
|
||||
</span>
|
||||
</div>
|
||||
<div v-if="myevent.contribtype" class="q-ma-sm">
|
||||
<span class="cal__quota-title">{{ $t('event.price') }}:<span
|
||||
<span class="cal__quota-title">{{ t('event.price') }}:<span
|
||||
class="margin_with"></span></span>
|
||||
<span v-if="!isShowPrice(myevent)" class="">
|
||||
<q-chip class="glossy" color="orange" text-color="white">
|
||||
@@ -171,13 +171,13 @@
|
||||
</q-btn>
|
||||
<q-btn
|
||||
rounded class="q-mx-sm"
|
||||
v-if="!myevent.nobookable && !isAlreadyBooked(myevent) && site.confpages.bookingEvents"
|
||||
v-if="!myevent.nobookable && !isAlreadyBooked(myevent) && site.confpages?.bookingEvents"
|
||||
color="primary" @click="addBookEventMenu(myevent)"
|
||||
:label="$t('cal.booking')" :disable="!isEventEnabled(myevent)">
|
||||
</q-btn>
|
||||
<q-btn
|
||||
rounded outline class="q-mx-sm"
|
||||
v-if="!myevent.nobookable && isAlreadyBooked(myevent) && site.confpages.bookingEvents"
|
||||
v-if="!myevent.nobookable && isAlreadyBooked(myevent) && site.confpages?.bookingEvents"
|
||||
text-color="red"
|
||||
@click="EditBookEvent(myevent)"
|
||||
:label="$t('cal.modifybooking')">
|
||||
|
||||
@@ -119,6 +119,7 @@ export default defineComponent({
|
||||
shared_consts,
|
||||
userStore,
|
||||
tools,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
</q-item-label>
|
||||
<q-item-label v-if="contact.reported" caption lines="1"
|
||||
><em style="color: red; font-weight: bold">{{
|
||||
$t('db.reporteduser', {
|
||||
t('db.reporteduser', {
|
||||
date_report: tools.getstrDateTimeShort(contact.date_report),
|
||||
})
|
||||
}}</em></q-item-label
|
||||
@@ -65,7 +65,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.remove_from_myfriends')
|
||||
t('friends.remove_from_myfriends')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -85,7 +85,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.block_user')
|
||||
t('friends.block_user')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -112,7 +112,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.accept_friend')
|
||||
t('friends.accept_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -133,7 +133,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.reject_ask_friend')
|
||||
t('friends.reject_ask_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -155,7 +155,7 @@
|
||||
<q-icon color="positive" name="fas fa-user-plus" />
|
||||
</q-item-section>
|
||||
<q-item-section>
|
||||
{{ $t('groups.accept_group') }}
|
||||
{{ t('groups.accept_group') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -169,7 +169,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -183,7 +183,7 @@
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{
|
||||
$t('shared.cancel_ask_short')
|
||||
t('shared.cancel_ask_short')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -210,7 +210,7 @@
|
||||
<q-item-section avatar>
|
||||
<q-icon color="positive" name="fas fa-user-shield" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{ $t('groups.addasadmin') }}</q-item-section>
|
||||
<q-item-section>{{ t('groups.addasadmin') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -227,7 +227,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-times" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('groups.remove_as_admin')
|
||||
t('groups.remove_as_admin')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -247,7 +247,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('groups.remove_from_mygroups')
|
||||
t('groups.remove_from_mygroups')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -265,7 +265,7 @@
|
||||
<q-icon color="negative" name="fas fa-flag" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('friends.report_user')
|
||||
t('friends.report_user')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -292,7 +292,7 @@
|
||||
<q-icon color="positive" name="fas fa-user-plus" />
|
||||
</q-item-section>
|
||||
<q-item-section>
|
||||
{{ $t('circuit.accept') }}
|
||||
{{ t('circuit.accept') }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -308,7 +308,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||||
<q-item-section>{{ t('shared.refuse_ask') }}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
clickable
|
||||
@@ -322,7 +322,7 @@
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>{{
|
||||
$t('shared.cancel_ask_short')
|
||||
t('shared.cancel_ask_short')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -339,7 +339,7 @@
|
||||
<q-icon color="positive" name="fas fa-user-shield" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('circuit.addasadmin')
|
||||
t('circuit.addasadmin')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -361,7 +361,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-times" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('circuit.remove_as_admin')
|
||||
t('circuit.remove_as_admin')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -386,7 +386,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('circuit.remove_from_mycircuit')
|
||||
t('circuit.remove_from_mycircuit')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -415,7 +415,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.cancel_ask_friend')
|
||||
t('friends.cancel_ask_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -478,7 +478,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.ask_friend')
|
||||
t('friends.ask_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -498,7 +498,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.reject_trust')
|
||||
t('friends.reject_trust')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -536,7 +536,7 @@
|
||||
<q-icon color="positive" name="fas fa-user-plus" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('friends.ask_friend')
|
||||
t('friends.ask_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -560,7 +560,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('friends.cancel_ask_friend')
|
||||
t('friends.cancel_ask_friend')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -582,7 +582,7 @@
|
||||
<q-icon color="negative" name="fas fa-user-minus" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('friends.remove_from_myfriends')
|
||||
t('friends.remove_from_myfriends')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
<q-item
|
||||
@@ -600,7 +600,7 @@
|
||||
<q-icon color="negative" name="fas fa-flag" />
|
||||
</q-item-section>
|
||||
<q-item-section>{{
|
||||
$t('friends.report_user')
|
||||
t('friends.report_user')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
@@ -628,7 +628,7 @@
|
||||
"
|
||||
>
|
||||
<q-item-section>{{
|
||||
$t('friends.accept_trust')
|
||||
t('friends.accept_trust')
|
||||
}}</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
|
||||
@@ -171,7 +171,7 @@ export default defineComponent({
|
||||
const { setValDb, getValDb } = MixinBase()
|
||||
|
||||
async function showandsave(row: any, col: any, newval: any, valinitial: any) {
|
||||
console.log('showandsave CMyFieldDb', row, col, newval)
|
||||
// console.log('showandsave CMyFieldDb', row, col, newval)
|
||||
|
||||
if (newval !== valinitial) {
|
||||
const ris = tools.saveInDBForTypes($q, props.mykey, newval, props.type, props.serv, props.table, props.mysubkey, props.id, props.indrec, props.mysubsubkey, props.specialField)
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
:disable="notif.disablecoinclick"
|
||||
color="positive"
|
||||
:label="
|
||||
$t('circuit.accept_coins_qty', {
|
||||
t('circuit.accept_coins_qty', {
|
||||
qty: notif.extrarec.qty,
|
||||
symbol: notif.extrarec.symbol,
|
||||
})
|
||||
@@ -83,7 +83,7 @@
|
||||
:disable="notif.disablecoinclick"
|
||||
color="negative"
|
||||
:label="
|
||||
$t('circuit.refuse_coins_qty', {
|
||||
t('circuit.refuse_coins_qty', {
|
||||
qty: notif.extrarec.qty,
|
||||
symbol: notif.extrarec.symbol,
|
||||
})
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { tools } from '@tools'
|
||||
import { useQuasar } from 'quasar'
|
||||
import { defineComponent } from 'vue'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'COpenStreetMap',
|
||||
@@ -32,6 +33,7 @@ export default defineComponent({
|
||||
},
|
||||
setup(props, { emit }) {
|
||||
const $q = useQuasar()
|
||||
const { t } = useI18n()
|
||||
|
||||
function mywidth() {
|
||||
return tools.getwidth($q) - 20
|
||||
@@ -45,6 +47,7 @@ export default defineComponent({
|
||||
return {
|
||||
mywidth,
|
||||
myheight,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<div class="">
|
||||
<span class="text-subtitle2" v-html="title"></span> - (<a
|
||||
:href="`https://www.openstreetmap.org/?` + coord_big + `&layers=N`"
|
||||
target="_blank">{{ $t('showbigmap') }}</a>)
|
||||
target="_blank">{{ t('showbigmap') }}</a>)
|
||||
</div>
|
||||
<div>
|
||||
<iframe
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { defineComponent, ref, onMounted } from 'vue';
|
||||
import { tools } from '@tools';
|
||||
import { Api } from 'app/src/store/Api';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
|
||||
interface WeeklyStat {
|
||||
year: number;
|
||||
@@ -13,6 +14,9 @@ export default defineComponent({
|
||||
props: {},
|
||||
emits: [],
|
||||
setup() {
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
// Stati
|
||||
const stats = ref({
|
||||
total: 0,
|
||||
@@ -115,6 +119,7 @@ export default defineComponent({
|
||||
weeks,
|
||||
selectedYear,
|
||||
selectedWeek,
|
||||
t,
|
||||
};
|
||||
},
|
||||
});
|
||||
|
||||
@@ -145,6 +145,7 @@
|
||||
row-key="url"
|
||||
flat
|
||||
bordered
|
||||
:rows-per-page-options="[20]"
|
||||
/>
|
||||
</div>
|
||||
</q-page>
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
<div>
|
||||
<div v-if="!tools.isLogged()" style="margin: 5px; padding: 5px;" class="home">
|
||||
<q-btn rounded size="lg" color="primary" @click="PagLogin" class="btn-start">
|
||||
{{ $t('login.enter') }}
|
||||
{{ t('login.enter') }}
|
||||
</q-btn>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -114,6 +114,7 @@ export default defineComponent({
|
||||
costanti,
|
||||
listlinksreg,
|
||||
actionType,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<div
|
||||
v-if="site.confpages.enableReg"
|
||||
v-if="site.confpages?.enableReg"
|
||||
class="row q-ma-sm centermydiv2 q-pa-sm justify-center align-center"
|
||||
>
|
||||
<div v-if="!start">
|
||||
@@ -36,7 +36,7 @@
|
||||
size="56px"
|
||||
/>
|
||||
<div class="q-mt-md text-center">
|
||||
<span class="text-h6 text-white"> {{ $t('reg.invitante') }}</span>
|
||||
<span class="text-h6 text-white"> {{ t('reg.invitante') }}</span>
|
||||
<q-card class="dialog_card q-mb-lg">
|
||||
<q-card-section class="column q-ma-sm q-pa-sm q-col-gutter-sm">
|
||||
<q-btn
|
||||
@@ -72,7 +72,7 @@
|
||||
</q-carousel-slide>
|
||||
<q-carousel-slide name="sceglilink">
|
||||
<q-card class="dialog_card q-mb-lg">
|
||||
<div class="q-ma-sm q-pa-sm text-h6 text-blue text-bold">{{ $t('reg.title_reg_con_link') }}</div>
|
||||
<div class="q-ma-sm q-pa-sm text-h6 text-blue text-bold">{{ t('reg.title_reg_con_link') }}</div>
|
||||
<q-card-section class="column q-ma-sm q-pa-sm q-col-gutter-sm text-black">
|
||||
<div
|
||||
v-for="(rec, i) in listlinksreg"
|
||||
@@ -100,7 +100,7 @@
|
||||
<a
|
||||
href="/registrati"
|
||||
target="_blank"
|
||||
>👉🏻 {{ $t('reg.scelgo_l_invitante') }}</a
|
||||
>👉🏻 {{ t('reg.scelgo_l_invitante') }}</a
|
||||
>
|
||||
</div>
|
||||
|
||||
@@ -152,11 +152,11 @@
|
||||
size="27px"
|
||||
class="q-mx-md"
|
||||
/>
|
||||
<span class="text-h6 text-white"> {{ $t('reg.page_title') }}</span>
|
||||
<span class="text-h6 text-white"> {{ t('reg.page_title') }}</span>
|
||||
<q-card class="q-mt-sm dialog_card q-mb-sm">
|
||||
<q-card-section>
|
||||
<div
|
||||
v-if="site.confpages.enableRegMultiChoice"
|
||||
v-if="site.confpages?.enableRegMultiChoice"
|
||||
style=""
|
||||
class="column q-ma-sm centermydiv2 q-pa-sm justify-center"
|
||||
>
|
||||
|
||||
@@ -54,7 +54,7 @@
|
||||
<q-card class="dialog_card">
|
||||
<q-toolbar class="bg-primary text-white">
|
||||
<q-toolbar-title class="text-h7">
|
||||
{{ $t('movement.pendingtransaction') }}
|
||||
{{ t('movement.pendingtransaction') }}
|
||||
</q-toolbar-title>
|
||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||
</q-toolbar>
|
||||
|
||||
@@ -282,7 +282,7 @@
|
||||
</div>
|
||||
|
||||
<!--<q-banner v-if="visubanner" rounded class="text-center text-bold">
|
||||
{{ $t('circuit.descr_casuale') }}
|
||||
{{ t('circuit.descr_casuale') }}
|
||||
<template v-slot:action>
|
||||
<q-btn label="Chiudi" flat @click="visubanner = false"></q-btn>
|
||||
</template>
|
||||
@@ -349,8 +349,8 @@
|
||||
:disable="!ifNextCheck(step)"
|
||||
:label="
|
||||
step === 0 || step === 1
|
||||
? $t('dialog.avanti')
|
||||
: $t('circuit.sendcoins', {
|
||||
? t('dialog.avanti')
|
||||
: t('circuit.sendcoins', {
|
||||
qty,
|
||||
coin: circuitloaded.symbol,
|
||||
dest: to_group
|
||||
|
||||
@@ -32,7 +32,7 @@ export default defineComponent({
|
||||
const $router = useRouter()
|
||||
const globalStore = useGlobalStore()
|
||||
|
||||
const enablePwa = computed(() => globalStore.site.confpages.enablePwa)
|
||||
const enablePwa = computed(() => globalStore.site.confpages?.enablePwa)
|
||||
|
||||
const refUsername = ref(<any>null)
|
||||
const refPassword = ref(null)
|
||||
@@ -190,6 +190,7 @@ export default defineComponent({
|
||||
enablePwa,
|
||||
checkAutoCompletion,
|
||||
autoCompleteTriggered,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -18,10 +18,10 @@
|
||||
lazy-rules
|
||||
:label="$t('reg.username_login')"
|
||||
:rules="[
|
||||
(val) => !!val || $t('reg.err.required'),
|
||||
(val) => !!val || t('reg.err.required'),
|
||||
(val) =>
|
||||
val.length >= 4 ||
|
||||
$t('reg.err.atleast') + ' 4 ' + $t('reg.err.char'),
|
||||
t('reg.err.atleast') + ' 4 ' + t('reg.err.char'),
|
||||
]"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -40,10 +40,10 @@
|
||||
v-on:keyup.enter="onSubmit()"
|
||||
:label="$t('reg.password')"
|
||||
:rules="[
|
||||
(val) => !!val || $t('reg.err.required'),
|
||||
(val) => !!val || t('reg.err.required'),
|
||||
(val) =>
|
||||
val.length >= 8 ||
|
||||
$t('reg.err.atleast') + ' 8 ' + $t('reg.err.char'),
|
||||
t('reg.err.atleast') + ' 8 ' + t('reg.err.char'),
|
||||
]"
|
||||
>
|
||||
<template v-slot:append>
|
||||
@@ -77,16 +77,16 @@
|
||||
|
||||
<div class="text-center" style="margin-bottom: 10px">
|
||||
<a :href="getlinkforgetpwd()" style="color: gray">{{
|
||||
$t('reg.forgetpassword')
|
||||
t('reg.forgetpassword')
|
||||
}}</a>
|
||||
</div>
|
||||
|
||||
<div
|
||||
v-if="
|
||||
site.confpages &&
|
||||
site.confpages.enableReg &&
|
||||
site.confpages?.enableReg &&
|
||||
showregbutt &&
|
||||
site.confpages.enableRegByBot
|
||||
site.confpages?.enableRegByBot
|
||||
"
|
||||
style="margin-top: 10px; text-align: center"
|
||||
>
|
||||
@@ -102,7 +102,7 @@
|
||||
</q-btn>
|
||||
</div>
|
||||
<div
|
||||
v-else-if="site.confpages && site.confpages.enableReg && showregbutt"
|
||||
v-else-if="site.confpages && site.confpages?.enableReg && showregbutt"
|
||||
style="margin-top: 10px; text-align: center"
|
||||
>
|
||||
Se non sei ancora Registrato:<br />
|
||||
|
||||
@@ -102,8 +102,8 @@
|
||||
debounce="1000"
|
||||
:label="
|
||||
collettivo
|
||||
? $t('reg.username_admin_collettivo')
|
||||
: $t('reg.aportador_solidario')
|
||||
? t('reg.username_admin_collettivo')
|
||||
: t('reg.aportador_solidario')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -124,8 +124,8 @@
|
||||
:rules="[myRuleEmail]"
|
||||
:label="
|
||||
collettivo
|
||||
? $t('reg.email_reg_collettivo')
|
||||
: $t('reg.email_reg')
|
||||
? t('reg.email_reg_collettivo')
|
||||
: t('reg.email_reg')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -159,8 +159,8 @@
|
||||
tools.getConfSiteOptionEnabled(
|
||||
shared_consts.ConfSite.askUSernameTelegramToTheReg
|
||||
)
|
||||
? $t('reg.username_telegram')
|
||||
: $t('reg.username_reg')
|
||||
? t('reg.username_telegram')
|
||||
: t('reg.username_reg')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -206,8 +206,8 @@
|
||||
tools.getConfSiteOptionEnabled(
|
||||
shared_consts.ConfSite.regNameSurnameMandatory
|
||||
)
|
||||
? $t('reg.name')
|
||||
: $t('reg.name_opt')
|
||||
? t('reg.name')
|
||||
: t('reg.name_opt')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -380,8 +380,8 @@
|
||||
debounce="1000"
|
||||
:label="
|
||||
collettivo
|
||||
? $t('reg.username_admin_collettivo')
|
||||
: $t('reg.aportador_solidario')
|
||||
? t('reg.username_admin_collettivo')
|
||||
: t('reg.aportador_solidario')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -404,8 +404,8 @@
|
||||
:rules="[myRuleEmail]"
|
||||
:label="
|
||||
collettivo
|
||||
? $t('reg.email_reg_collettivo')
|
||||
: $t('reg.email_reg')
|
||||
? t('reg.email_reg_collettivo')
|
||||
: t('reg.email_reg')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -415,7 +415,7 @@
|
||||
</div>
|
||||
</q-carousel-slide>
|
||||
<q-carousel-slide name="2">
|
||||
<div class="cosa_chiedere">{{ $t('reg.scegli_username') }}</div>
|
||||
<div class="cosa_chiedere">{{ t('reg.scegli_username') }}</div>
|
||||
<q-input
|
||||
ref="inputUsername"
|
||||
v-model="signup.username"
|
||||
@@ -440,12 +440,12 @@
|
||||
"
|
||||
:label="
|
||||
collettivo
|
||||
? $t('reg.username_reg_collettivo')
|
||||
? t('reg.username_reg_collettivo')
|
||||
: tools.getConfSiteOptionEnabled(
|
||||
shared_consts.ConfSite.askUSernameTelegramToTheReg
|
||||
)
|
||||
? $t('reg.username_telegram')
|
||||
: $t('reg.username_reg')
|
||||
? t('reg.username_telegram')
|
||||
: t('reg.username_reg')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -491,8 +491,8 @@
|
||||
tools.getConfSiteOptionEnabled(
|
||||
shared_consts.ConfSite.regNameSurnameMandatory
|
||||
)
|
||||
? $t('reg.name')
|
||||
: $t('reg.name_opt')
|
||||
? t('reg.name')
|
||||
: t('reg.name_opt')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -517,8 +517,8 @@
|
||||
tools.getConfSiteOptionEnabled(
|
||||
shared_consts.ConfSite.regNameSurnameMandatory
|
||||
)
|
||||
? $t('reg.surname')
|
||||
: $t('reg.surname_opt')
|
||||
? t('reg.surname')
|
||||
: t('reg.surname_opt')
|
||||
"
|
||||
>
|
||||
<template v-slot:prepend>
|
||||
@@ -528,7 +528,7 @@
|
||||
</div>
|
||||
</q-carousel-slide>
|
||||
<q-carousel-slide name="3">
|
||||
<div class="cosa_chiedere">{{ $t('reg.scegli_password') }}</div>
|
||||
<div class="cosa_chiedere">{{ t('reg.scegli_password') }}</div>
|
||||
<q-input
|
||||
ref="inputPassword"
|
||||
v-model="signup.password"
|
||||
|
||||
@@ -234,7 +234,7 @@
|
||||
v-if="isApplicatoSconto && !editmode && showall"
|
||||
class="ordine_scritta_sconto"
|
||||
v-html="
|
||||
$t('ecomm.sconto_applicato', {
|
||||
t('ecomm.sconto_applicato', {
|
||||
risparmio: getRisparmio,
|
||||
perc: getRispPerc,
|
||||
})
|
||||
|
||||
@@ -194,6 +194,7 @@ export default defineComponent({
|
||||
getcolorpeople,
|
||||
getcolor,
|
||||
tools,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<q-item-section>
|
||||
<q-item-label><span v-if="user.name">{{ user.name }} {{ user.surname }}</span> {{ getindorder(user) }}<br>
|
||||
<span class="text-grey">({{ getusername(user) }}) <strong>{{ getquanti(user)}}</strong></span>
|
||||
<br><!--<span v-if="isextralist(user)" class="notreg">{{ $t('dashboard.notreg') }}</span>-->
|
||||
<br><!--<span v-if="isextralist(user)" class="notreg">{{ t('dashboard.notreg') }}</span>-->
|
||||
</q-item-label>
|
||||
<!--<q-item-label caption lines="1">{{ user.email }}</q-item-label>-->
|
||||
</q-item-section>
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
|
||||
<div v-if="onlysaldo" class="q-ma-sm">
|
||||
<div v-if="circuitsnational.length === 0">
|
||||
|
||||
|
||||
</div>
|
||||
<div v-else v-for="(circnaz, ind) of circuitsnational" :key="ind">
|
||||
<q-avatar v-if="userStore.getImgByCircuit(circnaz)" size="30px">
|
||||
@@ -87,7 +87,7 @@
|
||||
<div v-if="myaccount.date_created" class="container">
|
||||
<q-icon name="fas fa-lightbulb" class="iconcirc"></q-icon>
|
||||
{{
|
||||
$t('shared.createddate', {
|
||||
t('shared.createddate', {
|
||||
date: tools.getstrDateYY(myaccount.date_created),
|
||||
})
|
||||
}}
|
||||
@@ -102,7 +102,7 @@
|
||||
>
|
||||
<q-icon name="fas fa-pencil-alt" class="iconcirc"></q-icon>
|
||||
<span class="element">{{
|
||||
$t('shared.lastmodify', {
|
||||
t('shared.lastmodify', {
|
||||
date: tools.getstrDateYY(myaccount.date_updated),
|
||||
})
|
||||
}}</span>
|
||||
|
||||
@@ -3,15 +3,18 @@ import { defineComponent } from 'vue'
|
||||
import { CCopyBtn } from '../CCopyBtn'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { tools } from '@tools'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CVerifyEmail',
|
||||
components: { CCopyBtn },
|
||||
props: {},
|
||||
setup() {
|
||||
const { t } = useI18n()
|
||||
|
||||
return {
|
||||
tools,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
<template>
|
||||
<div class="text-center q-gutter-sm q-ma-sm clBorderWarning">
|
||||
<q-chip v-if="tools.isEmailVerified()" color="positive" text-color="white" icon="email">
|
||||
{{ `Email ` + $t('statusreg.verified') }}
|
||||
{{ `Email ` + t('statusreg.verified') }}
|
||||
</q-chip>
|
||||
<q-chip v-else color="negative" text-color="white" icon="email">
|
||||
{{ `Email ` + $t('statusreg.nonverified') }}
|
||||
{{ `Email ` + t('statusreg.nonverified') }}
|
||||
</q-chip>
|
||||
<div v-if="!tools.isEmailVerified()" v-html="$t('components.authentication.email_verification.link_sent', {botname: tools.getBotName() })">
|
||||
|
||||
|
||||
@@ -72,6 +72,7 @@ export default defineComponent({
|
||||
|
||||
return {
|
||||
tools,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div class="text-center q-gutter-sm q-ma-sm clBorderWarning">
|
||||
<div v-if="tools.TelegCode() > 0">
|
||||
<div class="text-h5 text-center text-red">
|
||||
{{ $t('reg.teleg_auth') }} Telegram:
|
||||
{{ t('reg.teleg_auth') }} Telegram:
|
||||
</div>
|
||||
|
||||
<CCopyBtn :title="$t('reg.click_per_copiare')" :texttocopy="tools.TelegCode()">
|
||||
@@ -14,14 +14,14 @@
|
||||
</div>
|
||||
|
||||
<div v-if="!tools.TelegVerificato()" class="q-pa-sm q-gutter-sm">
|
||||
<div v-if="!tools.TelegCode()"><strong>{{ $t('components.authentication.telegram.open') }}</strong></div>
|
||||
<div v-if="!tools.TelegCode()"><strong>{{ t('components.authentication.telegram.open') }}</strong></div>
|
||||
<div class="q-ma-md">
|
||||
<q-btn rounded color="primary" icon="fab fa-telegram"
|
||||
:label="$t('components.authentication.telegram.openbot', { botname: tools.getBotName() })" type="a"
|
||||
:href="tools.getLinkBotTelegram('', '')" target="_blank"></q-btn>
|
||||
<br>
|
||||
</div>
|
||||
<strong v-if="!tools.TelegCode()">{{ $t('components.authentication.telegram.ifclose', {
|
||||
<strong v-if="!tools.TelegCode()">{{ t('components.authentication.telegram.ifclose', {
|
||||
botname: tools.getBotName()
|
||||
})}}</strong>
|
||||
<div class="q-my-sm">
|
||||
|
||||
@@ -58,6 +58,7 @@ export default defineComponent({
|
||||
accetta_saw_video,
|
||||
changeval,
|
||||
aggiorna,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<template>
|
||||
<div>
|
||||
|
||||
<CTitleBanner :title="`Video ` + $t('site.sitename')"></CTitleBanner>
|
||||
<CTitleBanner :title="`Video ` + t('site.sitename')"></CTitleBanner>
|
||||
<CImgText src="">
|
||||
|
||||
<CTitleBanner
|
||||
class="q-pa-xs" :title="$t('steps.video_intro_1', {sitename: $t('ws.sitename')})"
|
||||
class="q-pa-xs" :title="$t('steps.video_intro_1', {sitename: t('ws.sitename')})"
|
||||
bgcolor="bg-primary"
|
||||
clcolor="text-white"
|
||||
myclass="myshad" :canopen="true" :visible="true">
|
||||
|
||||
@@ -134,6 +134,7 @@ export default defineComponent({
|
||||
onSubmit,
|
||||
onReset,
|
||||
optionsDest,
|
||||
t,
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="q-pa-md q-gutter-sm text-white">
|
||||
<p class="news_title">{{ $t('newsletter.title') }}</p>
|
||||
<p class="news_title">{{ t('newsletter.title') }}</p>
|
||||
<q-form
|
||||
@submit="onSubmit"
|
||||
@reset="onReset"
|
||||
@@ -17,7 +17,7 @@
|
||||
:label="t('newsletter.name') + `*`"
|
||||
:hint="t('newsletter.namehint')"
|
||||
lazy-rules
|
||||
:rules="[(val) => (val && val.length > 0) || $t('newsletter.typesomething')]"
|
||||
:rules="[(val) => (val && val.length > 0) || t('newsletter.typesomething')]"
|
||||
>
|
||||
</q-input>
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
:label="t('newsletter.surname') + `*`"
|
||||
:hint="t('newsletter.surnamehint')"
|
||||
lazy-rules
|
||||
:rules="[(val) => (val && val.length > 0) || $t('newsletter.typesomething')]"
|
||||
:rules="[(val) => (val && val.length > 0) || t('newsletter.typesomething')]"
|
||||
>
|
||||
</q-input>
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
v-model="email"
|
||||
:label="t('newsletter.email') + `*`"
|
||||
lazy-rules
|
||||
:rules="[(val) => (val && val.length > 6) || $t('newsletter.typesomething')]"
|
||||
:rules="[(val) => (val && val.length > 6) || t('newsletter.typesomething')]"
|
||||
>
|
||||
</q-input>
|
||||
|
||||
@@ -60,7 +60,7 @@
|
||||
map-options
|
||||
option-value="value"
|
||||
option-label="label"
|
||||
:rules="[(val) => (val && val.length > 0) || $t('newsletter.typesomething')]"
|
||||
:rules="[(val) => (val && val.length > 0) || t('newsletter.typesomething')]"
|
||||
>
|
||||
</q-select>
|
||||
|
||||
@@ -74,7 +74,7 @@
|
||||
@click="navigate"
|
||||
@keypress.enter="navigate"
|
||||
role="link"
|
||||
>{{ $t('privacy_policy') }}</span
|
||||
>{{ t('privacy_policy') }}</span
|
||||
></router-link
|
||||
>
|
||||
|
||||
|
||||
0
src/components/IconPicker/IconPicker.scss
Normal file
0
src/components/IconPicker/IconPicker.scss
Normal file
60
src/components/IconPicker/IconPicker.ts
Normal file
60
src/components/IconPicker/IconPicker.ts
Normal file
@@ -0,0 +1,60 @@
|
||||
import { defineComponent, ref, computed, onMounted, watch, onBeforeUnmount } from 'vue'
|
||||
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { useQuasar } from 'quasar'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { tools } from '@tools'
|
||||
import { useRouter } from 'vue-router'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'IconPicker',
|
||||
props: {
|
||||
modelValue: { type: String, default: '' },
|
||||
icons: {
|
||||
type: Array as () => string[],
|
||||
default: () => ([
|
||||
// Estendi pure questo set
|
||||
'fas fa-house',
|
||||
'fas fa-book',
|
||||
'fas fa-star',
|
||||
'fas fa-heart',
|
||||
'fas fa-user',
|
||||
'fas fa-gear',
|
||||
'fas fa-circle-info',
|
||||
'fas fa-newspaper',
|
||||
'fas fa-list',
|
||||
'fas fa-tags',
|
||||
'fas fa-chart-line',
|
||||
'fas fa-briefcase',
|
||||
'fas fa-envelope',
|
||||
'fas fa-phone',
|
||||
'fas fa-earth-europe',
|
||||
])
|
||||
}
|
||||
},
|
||||
emits: ['update:modelValue', 'change'],
|
||||
setup (props, { emit }) {
|
||||
const keyword = ref('')
|
||||
const local = ref(props.modelValue)
|
||||
|
||||
watch(() => props.modelValue, v => { local.value = v })
|
||||
|
||||
const filteredIcons = computed(() => {
|
||||
const k = keyword.value.trim().toLowerCase()
|
||||
if (!k) return props.icons
|
||||
return props.icons.filter(i => i.toLowerCase().includes(k))
|
||||
})
|
||||
|
||||
function select (val: string) {
|
||||
local.value = val
|
||||
emit('update:modelValue', val)
|
||||
emit('change', val)
|
||||
}
|
||||
|
||||
function onKeyword () {
|
||||
// solo aggiorna la lista; il pulsante "Usa testo" applica
|
||||
}
|
||||
|
||||
return { keyword, local, filteredIcons, select, onKeyword }
|
||||
}
|
||||
})
|
||||
67
src/components/IconPicker/IconPicker.vue
Normal file
67
src/components/IconPicker/IconPicker.vue
Normal file
@@ -0,0 +1,67 @@
|
||||
<template>
|
||||
<div class="q-gutter-sm">
|
||||
<div class="row items-center q-col-gutter-sm">
|
||||
<div class="col">
|
||||
<q-input
|
||||
v-model="keyword"
|
||||
dense
|
||||
clearable
|
||||
label="Cerca icona (es: fas fa-house)"
|
||||
@update:model-value="onKeyword"
|
||||
>
|
||||
<template #prepend>
|
||||
<q-icon :name="modelValue || 'fa-regular fa-face-smile'" />
|
||||
</template>
|
||||
</q-input>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-btn
|
||||
dense
|
||||
outline
|
||||
:disable="!keyword"
|
||||
label="Usa testo"
|
||||
@click="select(keyword)"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<q-separator spaced />
|
||||
|
||||
<div class="row q-col-gutter-sm">
|
||||
<div
|
||||
v-for="ic in filteredIcons"
|
||||
:key="ic"
|
||||
class="col-3 col-sm-2 col-md-1"
|
||||
>
|
||||
<q-btn
|
||||
outline
|
||||
class="full-width"
|
||||
:icon="ic"
|
||||
@click="select(ic)"
|
||||
:color="ic === modelValue ? 'primary' : 'grey-7'"
|
||||
>
|
||||
<q-tooltip>{{ ic }}</q-tooltip>
|
||||
</q-btn>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="q-mt-md">
|
||||
<q-input
|
||||
v-model="local"
|
||||
dense
|
||||
label="Valore attuale icona"
|
||||
@update:model-value="select(local)"
|
||||
>
|
||||
<template #append>
|
||||
<q-icon :name="local || 'fa-regular fa-circle-question'" />
|
||||
</template>
|
||||
</q-input>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./IconPicker.ts"></script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './IconPicker.scss';
|
||||
</style>
|
||||
1
src/components/IconPicker/index.ts
Executable file
1
src/components/IconPicker/index.ts
Executable file
@@ -0,0 +1 @@
|
||||
export {default as IconPicker} from './IconPicker.vue'
|
||||
@@ -22,6 +22,7 @@ export default defineComponent({
|
||||
|
||||
setup() {
|
||||
const $q = useQuasar()
|
||||
const { t } = useI18n()
|
||||
const globalStore = useGlobalStore()
|
||||
|
||||
const { getarrValDb, getValDb } = MixinBase()
|
||||
@@ -88,6 +89,7 @@ export default defineComponent({
|
||||
getValDb,
|
||||
site,
|
||||
getBackColorText,
|
||||
t,
|
||||
}
|
||||
},
|
||||
})
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<div class="">
|
||||
<div v-if="!!site.contacts && !!site.contacts.address">
|
||||
<p class="mycontacts_title q-mt-sm">
|
||||
{{ $t('footer.titleaddress') }}
|
||||
{{ t('footer.titleaddress') }}
|
||||
</p>
|
||||
<p class="mycontacts_address">
|
||||
{{ site.contacts.address }}
|
||||
@@ -112,7 +112,7 @@
|
||||
<!--</div>-->
|
||||
</div>
|
||||
<div class="col-12 col-sm-4">
|
||||
<p class="mycontacts_title q-mt-sm">{{ $t('homepage.titlecontatti') }}:</p>
|
||||
<p class="mycontacts_title q-mt-sm">{{ t('homepage.titlecontatti') }}:</p>
|
||||
<div class="text-center q-my-sm">
|
||||
<div class="q-mt-xs mycontacts">
|
||||
<div class="mycontacts_text">
|
||||
@@ -227,7 +227,7 @@
|
||||
</div>
|
||||
|
||||
<FormNewsletter
|
||||
v-if="site.confpages.showNL"
|
||||
v-if="site.confpages?.showNL"
|
||||
:idwebsite="tools.appid()"
|
||||
:locale="toolsext.getLocale()"
|
||||
>
|
||||
@@ -245,7 +245,7 @@
|
||||
@click="navigate"
|
||||
@keypress.enter="navigate"
|
||||
role="link"
|
||||
>{{ $t('privacy_policy') }}</span
|
||||
>{{ t('privacy_policy') }}</span
|
||||
></router-link
|
||||
>
|
||||
</p>
|
||||
|
||||
@@ -8,29 +8,29 @@
|
||||
: `text-grey-10 bg-white`) + ` mylabfooter mysmalltabs`
|
||||
" style="padding: 0px !important" content-class="mysmalltabs" active-color="white" active-bg-color="blue"
|
||||
no-caps indicator-color="transparent">
|
||||
<q-route-tab v-if="site.confpages.showButtHome" to="/" class="mylabfooter" :label="$t('tabdown.home')"
|
||||
<q-route-tab v-if="site.confpages?.showButtHome" to="/" class="mylabfooter" :label="$t('tabdown.home')"
|
||||
icon="fas fa-home" />
|
||||
<!--<q-route-tab
|
||||
v-if="site.confpages.showViewGroups"
|
||||
v-if="site.confpages?.showViewGroups"
|
||||
class="mylabfooter"
|
||||
:label="$t('tabdown.groups')"
|
||||
to="/groups"
|
||||
icon="fas fa-users"
|
||||
/>-->
|
||||
<q-route-tab v-if="site.confpages.showViewEventi" class="mylabfooter" :label="$t('tabdown.eventi')"
|
||||
<q-route-tab v-if="site.confpages?.showViewEventi" class="mylabfooter" :label="$t('tabdown.eventi')"
|
||||
to="/events" icon="fas fa-calendar-week" />
|
||||
<q-img v-if="site.confpages.showViewCircuits" src="/images/1ris_rosso_100.png" round flat
|
||||
<q-img v-if="site.confpages?.showViewCircuits" src="/images/1ris_rosso_100.png" round flat
|
||||
:style="currentPath === '/circuits' ? `background-color: lightblue` : ''" class="img_in_tab"
|
||||
@click="naviga(tools.updateLink('/circuits'))"></q-img>
|
||||
<q-route-tab v-if="site.confpages.showViewUsers" class="mylabfooter" :label="$t('tabdown.friends')"
|
||||
<q-route-tab v-if="site.confpages?.showViewUsers" class="mylabfooter" :label="$t('tabdown.friends')"
|
||||
to="/friends" icon="fas fa-user-friends" />
|
||||
<q-route-tab v-if="site.confpages.showViewBooking" class="mylabfooter" :label="$t('tabdown.bookings')"
|
||||
<q-route-tab v-if="site.confpages?.showViewBooking" class="mylabfooter" :label="$t('tabdown.bookings')"
|
||||
to="/admin/eventlist" icon="fas fa-calendar-plus" />
|
||||
<q-route-tab v-if="site.confpages.showViewCart" class="mylabfooter" :label="$t('tabdown.showViewCart')"
|
||||
<q-route-tab v-if="site.confpages?.showViewCart" class="mylabfooter" :label="$t('tabdown.showViewCart')"
|
||||
to="/checkout" icon="fas fa-shopping-cart" />
|
||||
<q-route-tab v-if="site.confpages.showViewOrders" class="mylabfooter" :label="$t('tabdown.showViewOrders')"
|
||||
<q-route-tab v-if="site.confpages?.showViewOrders" class="mylabfooter" :label="$t('tabdown.showViewOrders')"
|
||||
to="/orderinfo" icon="fas fa-clipboard-list" />
|
||||
<q-route-tab v-if="site.confpages.showViewProfile" class="mylabfooter" :label="$t('tabdown.profile')"
|
||||
<q-route-tab v-if="site.confpages?.showViewProfile" class="mylabfooter" :label="$t('tabdown.profile')"
|
||||
@click="globalStore.rightDrawerOpen = true" :icon="getMyImg() ? `img: ` + getMyImg() : `fas fa-user`" />
|
||||
</q-tabs>
|
||||
</q-toolbar-title>
|
||||
|
||||
@@ -386,7 +386,7 @@ export default defineComponent({
|
||||
const color = (value === 'online') ? 'positive' : 'warning'
|
||||
const statoconn = t('connection.conn') + ' ' + ((value === 'online') ? t('connection.online') : t('connection.offline'))
|
||||
|
||||
if (site.confpages.showConnected) {
|
||||
if (site.confpages?.showConnected) {
|
||||
|
||||
if (!!oldValue) {
|
||||
tools.showNotif($q, statoconn, {
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
</div>
|
||||
-->
|
||||
|
||||
<div v-if="site.confpages && site.confpages.show_darkopt" class="text-h7">
|
||||
<div v-if="site.confpages && site.confpages?.show_darkopt" class="text-h7">
|
||||
<q-toggle :icon="'fas fa-moon'" v-model="dark"> </q-toggle>
|
||||
</div>
|
||||
<div v-if="
|
||||
@@ -54,7 +54,7 @@
|
||||
" class="text-h7">
|
||||
<q-toggle :icon="'fas fa-pencil-alt'" v-model="editOn"> </q-toggle>
|
||||
</div>
|
||||
<q-btn v-if="!isonline() && site.confpages && site.confpages.showConnected" flat dense round
|
||||
<q-btn v-if="!isonline() && site.confpages && site.confpages?.showConnected" flat dense round
|
||||
aria-label="Connection">
|
||||
<q-icon :name="iconConn" :class="clIconConn"></q-icon>
|
||||
<q-icon v-if="isUserNotAuth" name="device_unknown"></q-icon>
|
||||
@@ -75,13 +75,13 @@
|
||||
</q-list>
|
||||
</q-btn-dropdown>
|
||||
|
||||
<div v-if="site.confpages && site.confpages.showMsgs">
|
||||
<div v-if="site.confpages && site.confpages?.showMsgs">
|
||||
<message-popover></message-popover>
|
||||
</div>
|
||||
<div v-if="site.confpages?.showCoins || site.confpages?.showRIS">
|
||||
<coinsPopover v-model="rightCoinsOpen"></coinsPopover>
|
||||
</div>
|
||||
<div v-if="site.confpages && site.confpages.showNotif">
|
||||
<div v-if="site.confpages && site.confpages?.showNotif">
|
||||
<notifPopover v-model="rightNotifOpen"></notifPopover>
|
||||
</div>
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
<!-- BUTTON USER BAR -->
|
||||
|
||||
<q-btn class="q-mx-xs" v-if="
|
||||
site.confpages && site.confpages.enableEcommerce && tools.isLogged()
|
||||
site.confpages && site.confpages?.enableEcommerce && tools.isLogged()
|
||||
" round dense flat @click="rightCartOpen = !rightCartOpen" icon="fas fa-shopping-cart">
|
||||
<q-badge v-if="getnumItemsCart() > 0" color="red" floating transparent>
|
||||
{{ getnumItemsCart() }}
|
||||
@@ -102,7 +102,7 @@
|
||||
|
||||
<q-btn class="q-mx-xs" v-if="
|
||||
site.confpages &&
|
||||
site.confpages.enableEcommerce &&
|
||||
site.confpages?.enableEcommerce &&
|
||||
tools.isLogged() &&
|
||||
getnumOrdersCart() > 0
|
||||
" round dense flat to="/orderinfo" icon="fas fa-list-ol">
|
||||
@@ -112,12 +112,12 @@
|
||||
</q-btn>
|
||||
|
||||
<q-btn class="q-mx-xs" v-if="
|
||||
site.confpages && site.confpages.showUserMenu && !tools.isLogged()
|
||||
site.confpages && site.confpages?.showUserMenu && !tools.isLogged()
|
||||
" dense flat round icon="fas fa-user" @click="rightDrawerOpen = !rightDrawerOpen">
|
||||
</q-btn>
|
||||
<q-avatar v-else-if="
|
||||
site.confpages &&
|
||||
site.confpages.showUserMenu &&
|
||||
site.confpages?.showUserMenu &&
|
||||
tools.isLogged() &&
|
||||
getMyImg() &&
|
||||
$q.screen.gt.sm
|
||||
@@ -137,7 +137,7 @@
|
||||
</q-drawer>
|
||||
|
||||
<!-- USER BAR -->
|
||||
<q-drawer v-if="site.confpages && site.confpages.enableEcommerce" v-model="rightCartOpen" class="q-drawer-cart"
|
||||
<q-drawer v-if="site.confpages && site.confpages?.enableEcommerce" v-model="rightCartOpen" class="q-drawer-cart"
|
||||
side="right" elevated>
|
||||
<q-btn class="absolute-top-right" :style="`margin-right: 10px; color:` + getColorText + `;`" dense flat round
|
||||
icon="close" @click="rightCartOpen = !rightCartOpen">
|
||||
@@ -153,7 +153,7 @@
|
||||
<CMyCart v-if="isfinishLoading"></CMyCart>
|
||||
</q-drawer>
|
||||
<!-- USER BAR -->
|
||||
<q-drawer v-if="site.confpages && site.confpages.showUserMenu" v-model="rightDrawerOpen" side="right" elevated>
|
||||
<q-drawer v-if="site.confpages && site.confpages?.showUserMenu" v-model="rightDrawerOpen" side="right" elevated>
|
||||
<div id="profile">
|
||||
<q-img class="absolute-top" src="/images/landing_first_section.png" style="height: 150px" alt="section page">
|
||||
</q-img>
|
||||
@@ -163,15 +163,11 @@
|
||||
{{ t("header.area_personale") }}
|
||||
</div>
|
||||
|
||||
<q-avatar size="80px" class="center_img q-ma-md">
|
||||
<q-img fit="cover" :src="getMyImg()" :alt="Username()" img-class="imgprofile" height="80px" />
|
||||
</q-avatar>
|
||||
|
||||
<!--<CMyAvatar :myimg="getMyImg()"></CMyAvatar>-->
|
||||
|
||||
<q-btn class="absolute-top-right" :style="`margin-right: 10px; color: ` + getColorText + `;`" dense flat round
|
||||
icon="close" @click="rightDrawerOpen = !rightDrawerOpen">
|
||||
</q-btn>
|
||||
<div v-if="getMyImg()" class="row justify-center q-pa-md">
|
||||
<q-avatar size="80px" class="center_img q-ma-md">
|
||||
<q-img fit="cover" :src="getMyImg()" :alt="Username()" img-class="imgprofile" height="80px" />
|
||||
</q-avatar>
|
||||
</div>
|
||||
|
||||
<div v-if="tools.isLogged()" class="text-weight-bold text-user">
|
||||
{{ Username() }}<span v-if="myName()"> - {{ myName() }}</span>
|
||||
@@ -230,8 +226,8 @@
|
||||
</div>
|
||||
<div style="margin-top: 120px"></div>
|
||||
<div v-show="!tools.isLogged()">
|
||||
<div v-if="site.confpages && site.confpages.showRegButton" class="q-ma-md" style="">
|
||||
<CSigninNoreg :showregbutt="site.confpages && site.confpages.showRegButton">
|
||||
<div v-if="site.confpages && site.confpages?.showRegButton" class="q-ma-md" style="">
|
||||
<CSigninNoreg :showregbutt="site.confpages && site.confpages?.showRegButton">
|
||||
</CSigninNoreg>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
0
src/components/PageEditor/PageEditor.scss
Normal file
0
src/components/PageEditor/PageEditor.scss
Normal file
194
src/components/PageEditor/PageEditor.ts
Normal file
194
src/components/PageEditor/PageEditor.ts
Normal file
@@ -0,0 +1,194 @@
|
||||
import {
|
||||
defineComponent,
|
||||
ref,
|
||||
computed,
|
||||
onMounted,
|
||||
watch,
|
||||
onBeforeUnmount,
|
||||
toRaw,
|
||||
nextTick,
|
||||
} from 'vue';
|
||||
|
||||
import { useUserStore } from '@store/UserStore';
|
||||
import { useQuasar } from 'quasar';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
import { tools } from '@tools';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { reactive } from 'vue';
|
||||
import { IMyPage } from 'app/src/model';
|
||||
import IconPicker from '../IconPicker/IconPicker.vue';
|
||||
import { useGlobalStore } from 'app/src/store';
|
||||
import { storeToRefs } from 'pinia';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'PageEditor',
|
||||
components: { IconPicker },
|
||||
props: {
|
||||
modelValue: {
|
||||
type: Object as () => IMyPage,
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
emits: ['update:modelValue', 'apply'],
|
||||
setup(props, { emit }) {
|
||||
const $q = useQuasar();
|
||||
const globalStore = useGlobalStore();
|
||||
const { mypage } = storeToRefs(globalStore);
|
||||
|
||||
// DRaft locale
|
||||
const draft = reactive<IMyPage>({ ...props.modelValue });
|
||||
|
||||
// UI helper: path mostrato con "/" iniziale
|
||||
const ui = reactive({
|
||||
pathText: toUiPath(draft.path),
|
||||
});
|
||||
|
||||
const saving = ref(false)
|
||||
const syncingFromProps = ref(false) // <-- FLAG anti-loop
|
||||
|
||||
// --- Watch input esterno: ricarica draft e UI path
|
||||
// --- Watch input esterno: ricarica draft e UI path (NO scritture nello store qui!)
|
||||
watch(
|
||||
() => props.modelValue,
|
||||
async (v) => {
|
||||
syncingFromProps.value = true;
|
||||
Object.assign(draft, v || {});
|
||||
ui.pathText = toUiPath(draft.path);
|
||||
await nextTick();
|
||||
syncingFromProps.value = false;
|
||||
},
|
||||
{ deep: false }
|
||||
);
|
||||
|
||||
// --- Ogni modifica del draft: aggiorna store.mypage e emetti update:modelValue (solo se modifica nasce da UI)
|
||||
watch(
|
||||
draft,
|
||||
(val) => {
|
||||
if (syncingFromProps.value) return; // evita ricorsione
|
||||
upsertIntoStore(val, mypage.value);
|
||||
emit('update:modelValue', { ...val });
|
||||
},
|
||||
{ deep: true }
|
||||
);
|
||||
|
||||
// --- Helpers path
|
||||
function toUiPath(storePath?: string) {
|
||||
const p = (storePath || '').trim();
|
||||
if (!p) return '/';
|
||||
return p.startsWith('/') ? p : `/${p}`;
|
||||
}
|
||||
function toStorePath(uiPath?: string) {
|
||||
const p = (uiPath || '').trim();
|
||||
if (!p) return '';
|
||||
return p.startsWith('/') ? p.slice(1) : p;
|
||||
}
|
||||
|
||||
function normalizeAndApplyPath() {
|
||||
// normalizza: niente spazi, minuscole, trattini
|
||||
let p = (ui.pathText || '/').trim();
|
||||
p = p.replace(/\s+/g, '-');
|
||||
if (!p.startsWith('/')) p = '/' + p;
|
||||
ui.pathText = p;
|
||||
draft.path = toStorePath(p);
|
||||
}
|
||||
|
||||
function pathRule(v: string) {
|
||||
if (!v) return 'Percorso richiesto';
|
||||
if (!v.startsWith('/')) return 'Deve iniziare con /';
|
||||
if (/\s/.test(v)) return 'Nessuno spazio nel path';
|
||||
return true;
|
||||
}
|
||||
|
||||
// --- Upsert nello store.mypage
|
||||
function upsertIntoStore(page: IMyPage, arr: IMyPage[]) {
|
||||
if (!page) return;
|
||||
// chiave di matching: prima _id, altrimenti path
|
||||
const keyId = page._id;
|
||||
const keyPath = page.path || '';
|
||||
let idx = -1;
|
||||
if (keyId) {
|
||||
idx = arr.findIndex((p) => p._id === keyId);
|
||||
}
|
||||
if (idx < 0 && keyPath) {
|
||||
idx = arr.findIndex((p) => (p.path || '') === keyPath);
|
||||
}
|
||||
if (idx >= 0) {
|
||||
// merge preservando reattività
|
||||
arr[idx] = { ...arr[idx], ...toRaw(page) };
|
||||
} else {
|
||||
arr.push({ ...toRaw(page) });
|
||||
}
|
||||
}
|
||||
async function save () {
|
||||
try {
|
||||
saving.value = true
|
||||
normalizeAndApplyPath() // assicura path coerente
|
||||
|
||||
const payload: IMyPage = { ...toRaw(draft), path: draft.path || '' }
|
||||
const saved = await globalStore.savePage(payload)
|
||||
if (saved && typeof saved === 'object') {
|
||||
syncingFromProps.value = true
|
||||
Object.assign(draft, saved)
|
||||
upsertIntoStore(draft, mypage.value)
|
||||
await nextTick()
|
||||
syncingFromProps.value = false
|
||||
}
|
||||
emit('apply', { ...draft })
|
||||
$q.notify({ type: 'positive', message: 'Pagina salvata' })
|
||||
} catch (err: any) {
|
||||
console.error(err)
|
||||
$q.notify({ type: 'negative', message: 'Errore nel salvataggio' })
|
||||
} finally {
|
||||
saving.value = false
|
||||
}
|
||||
}
|
||||
|
||||
// --- Ricarica da sorgente
|
||||
async function reloadFromStore () {
|
||||
try {
|
||||
const absolute = ui.pathText || '/'
|
||||
const page = await globalStore.loadPage(absolute, '', true)
|
||||
if (page) {
|
||||
syncingFromProps.value = true
|
||||
Object.assign(draft, page)
|
||||
ui.pathText = toUiPath(draft.path)
|
||||
upsertIntoStore(draft, mypage.value)
|
||||
console.log('page', draft)
|
||||
emit('update:modelValue', { ...draft })
|
||||
await nextTick()
|
||||
syncingFromProps.value = false
|
||||
$q.notify({ type: 'info', message: 'Pagina ricaricata' })
|
||||
} else {
|
||||
$q.notify({ type: 'warning', message: 'Pagina non trovata' })
|
||||
}
|
||||
} catch (err) {
|
||||
console.error(err)
|
||||
$q.notify({ type: 'negative', message: 'Errore nel ricaricare la pagina' })
|
||||
}
|
||||
}
|
||||
|
||||
function resetDraft() {
|
||||
console.log('resetDraft')
|
||||
syncingFromProps.value = true
|
||||
Object.assign(draft, props.modelValue || {})
|
||||
ui.pathText = toUiPath(draft.path)
|
||||
// aggiorna i componenti
|
||||
emit('update:modelValue', { ...draft })
|
||||
nextTick(() => { syncingFromProps.value = false })
|
||||
}
|
||||
|
||||
const absolutePath = computed(() => toUiPath(draft.path))
|
||||
|
||||
return {
|
||||
draft,
|
||||
ui,
|
||||
saving,
|
||||
pathRule,
|
||||
normalizeAndApplyPath,
|
||||
save,
|
||||
reloadFromStore,
|
||||
resetDraft,
|
||||
absolutePath,
|
||||
};
|
||||
},
|
||||
});
|
||||
73
src/components/PageEditor/PageEditor.vue
Normal file
73
src/components/PageEditor/PageEditor.vue
Normal file
@@ -0,0 +1,73 @@
|
||||
<template>
|
||||
<q-card flat bordered class="q-pa-md">
|
||||
<div class="row q-col-gutter-md">
|
||||
<div class="col-12 col-md-6">
|
||||
<q-input
|
||||
v-model="ui.pathText"
|
||||
label="Percorso (relativo, es: /about)"
|
||||
dense
|
||||
:rules="[pathRule]"
|
||||
@blur="normalizeAndApplyPath"
|
||||
>
|
||||
<template #prepend>
|
||||
<q-icon name="fas fa-link" />
|
||||
</template>
|
||||
</q-input>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md-6">
|
||||
<q-input
|
||||
v-model="draft.title"
|
||||
label="Titolo"
|
||||
dense
|
||||
:rules="[v => !!v || 'Titolo richiesto']"
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md-6">
|
||||
<icon-picker v-model="draft.icon" />
|
||||
</div>
|
||||
|
||||
<div class="col-12 col-md-6">
|
||||
<q-input v-model="draft.iconsize" label="Dimensione icona (es: 24px)" dense />
|
||||
</div>
|
||||
|
||||
<div class="col-12">
|
||||
<q-separator spaced />
|
||||
<div class="row items-center q-col-gutter-md">
|
||||
<div class="col-auto">
|
||||
<q-toggle v-model="draft.active" label="Attivo" />
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-toggle v-model="draft.inmenu" label="Presente nel menu" />
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-toggle v-model="draft.onlyif_logged" label="Solo se loggati" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row q-col-gutter-sm q-mt-md">
|
||||
<div class="col-auto">
|
||||
<q-btn color="primary" label="Salva" :loading="saving" @click="save" />
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-btn outline label="Ricarica" @click="reloadFromStore" />
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-btn color="grey-7" label="Chiudi" @click="$emit('close', draft.path)" />
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<q-btn flat color="grey-7" label="Reset draft" @click="resetDraft" />
|
||||
</div>
|
||||
</div>
|
||||
</q-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./PageEditor.ts">
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './PageEditor.scss';
|
||||
</style>
|
||||
1
src/components/PageEditor/index.ts
Executable file
1
src/components/PageEditor/index.ts
Executable file
@@ -0,0 +1 @@
|
||||
export {default as PageEditor} from './PageEditor.vue'
|
||||
160
src/components/PagesConfigurator/PagesConfigurator.ts
Normal file
160
src/components/PagesConfigurator/PagesConfigurator.ts
Normal file
@@ -0,0 +1,160 @@
|
||||
import { defineComponent, ref, computed, onMounted, watch, onBeforeUnmount } from 'vue';
|
||||
import { IMyPage } from 'app/src/model';
|
||||
import { PageEditor } from '../PageEditor';
|
||||
|
||||
export default defineComponent({
|
||||
name: 'PagesConfigurator',
|
||||
components: { PageEditor },
|
||||
props: {
|
||||
modelValue: {
|
||||
type: Array as () => IMyPage[],
|
||||
required: true,
|
||||
},
|
||||
},
|
||||
emits: ['update:modelValue', 'save', 'change-order'],
|
||||
setup(props, { emit }) {
|
||||
const pages = ref<IMyPage[]>(props.modelValue ? [...props.modelValue] : []);
|
||||
const selectedIndex = ref<number>(-1);
|
||||
|
||||
watch(
|
||||
() => props.modelValue,
|
||||
(v) => {
|
||||
pages.value = v ? [...v] : [];
|
||||
if (selectedIndex.value >= pages.value.length) selectedIndex.value = -1;
|
||||
}
|
||||
);
|
||||
|
||||
const localPagesSorted = computed(() => {
|
||||
return [...pages.value].sort((a, b) => (a.order || 0) - (b.order || 0));
|
||||
});
|
||||
|
||||
function originalIndex(sortedIdx: number) {
|
||||
// mappa l’indice sortato all’indice reale in pages
|
||||
const item = localPagesSorted.value[sortedIdx];
|
||||
return pages.value.indexOf(item);
|
||||
}
|
||||
|
||||
const current = computed(() => pages.value[selectedIndex.value]);
|
||||
|
||||
// Removed automatic order reindexing to preserve original order values
|
||||
|
||||
// Duplicate outer function removed, keeping the inner implementation
|
||||
function addPage() {
|
||||
const newOrder =
|
||||
pages.value.reduce((max: number, p: IMyPage) => Math.max(max, p.order ?? 0), 0) +
|
||||
1;
|
||||
const np: IMyPage = {
|
||||
title: '',
|
||||
path: '/nuova-pagina-' + (Math.floor(Math.random() * 8999) + 1000).toString(),
|
||||
icon: 'fa-regular fa-file-lines',
|
||||
iconsize: '24px',
|
||||
active: true,
|
||||
inmenu: true,
|
||||
onlyif_logged: false,
|
||||
order: newOrder,
|
||||
};
|
||||
pages.value.push(np);
|
||||
selectedIndex.value = pages.value.length - 1;
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
}
|
||||
|
||||
function removePage(idx: number) {
|
||||
if (idx < 0) return;
|
||||
const page = pages.value[idx];
|
||||
if (!page) return;
|
||||
pages.value.splice(idx, 1);
|
||||
if (selectedIndex.value === idx) selectedIndex.value = -1;
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
// Add cleanup logic for page deletion
|
||||
if (page._id) {
|
||||
// Mark for deletion in backend
|
||||
void deletePageFromServer(page);
|
||||
}
|
||||
}
|
||||
|
||||
async function deletePageFromServer(page: IMyPage) {
|
||||
if (!page._id) return;
|
||||
|
||||
try {
|
||||
const response = await fetch(`/api/pages/${page._id}`, {
|
||||
method: 'DELETE',
|
||||
headers: {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
});
|
||||
if (!response.ok) {
|
||||
throw new Error('Failed to delete page from server');
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('Error deleting page:', error);
|
||||
// Revert changes if deletion fails
|
||||
pages.value.splice(originalIndex, 0, page);
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
}
|
||||
}
|
||||
|
||||
function select(idx: number) {
|
||||
selectedIndex.value = idx;
|
||||
}
|
||||
|
||||
function swap(i: number, j: number) {
|
||||
const a = pages.value[i];
|
||||
const b = pages.value[j];
|
||||
if (!a || !b) return;
|
||||
const ao = a.order ?? i;
|
||||
const bo = b.order ?? j;
|
||||
a.order = bo;
|
||||
b.order = ao;
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
}
|
||||
|
||||
function moveUp(idx: number) {
|
||||
if (idx <= 0) return;
|
||||
const prev = idx - 1;
|
||||
const a = pages.value[idx];
|
||||
const b = pages.value[prev];
|
||||
if (!a || !b) return;
|
||||
const ao = a.order ?? idx;
|
||||
const bo = b.order ?? prev;
|
||||
a.order = bo;
|
||||
b.order = ao;
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
}
|
||||
|
||||
function moveDown(idx: number) {
|
||||
if (idx >= pages.value.length - 1) return;
|
||||
const next = idx + 1;
|
||||
const a = pages.value[idx];
|
||||
const b = pages.value[next];
|
||||
if (!a || !b) return;
|
||||
const ao = a.order ?? idx;
|
||||
const bo = b.order ?? next;
|
||||
a.order = bo;
|
||||
b.order = ao;
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
}
|
||||
|
||||
function onApply() {
|
||||
emit('update:modelValue', [...pages.value]);
|
||||
emit('save', current.value);
|
||||
}
|
||||
function onClose() {
|
||||
selectedIndex.value = -1;
|
||||
}
|
||||
|
||||
return {
|
||||
pages,
|
||||
selectedIndex,
|
||||
localPagesSorted,
|
||||
current,
|
||||
select,
|
||||
addPage,
|
||||
removePage,
|
||||
moveUp,
|
||||
moveDown,
|
||||
originalIndex,
|
||||
onApply,
|
||||
onClose,
|
||||
};
|
||||
},
|
||||
});
|
||||
67
src/components/PagesConfigurator/PagesConfigurator.vue
Normal file
67
src/components/PagesConfigurator/PagesConfigurator.vue
Normal file
@@ -0,0 +1,67 @@
|
||||
<template>
|
||||
<div class="row q-col-gutter-md">
|
||||
<!-- Lista pagine -->
|
||||
<div class="col-12 col-md-5">
|
||||
<q-card flat bordered>
|
||||
<q-toolbar>
|
||||
<q-toolbar-title>Pagine</q-toolbar-title>
|
||||
<q-btn dense icon="fas fa-plus" label="Aggiungi" @click="addPage" />
|
||||
</q-toolbar>
|
||||
|
||||
<q-list separator>
|
||||
<q-item
|
||||
v-for="(p, idx) in localPagesSorted"
|
||||
:key="p._id || idx"
|
||||
clickable
|
||||
:active="selectedIndex === originalIndex(idx)"
|
||||
@click="select(originalIndex(idx))"
|
||||
>
|
||||
<q-item-section avatar>
|
||||
<q-icon :name="p.icon || 'fa-regular fa-file-lines'" />
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section>
|
||||
<q-item-label>{{ p.title || '(senza titolo)' }}</q-item-label>
|
||||
<q-item-label caption>{{ p.path || '-' }}</q-item-label>
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section side top>
|
||||
<div class="row items-center q-gutter-xs">
|
||||
<q-badge :color="p.active ? 'positive' : 'grey'">{{ p.active ? 'attiva' : 'spenta' }}</q-badge>
|
||||
<q-badge :color="p.inmenu ? 'primary' : 'grey'">menu</q-badge>
|
||||
</div>
|
||||
</q-item-section>
|
||||
|
||||
<q-item-section side>
|
||||
<div class="column q-gutter-xs">
|
||||
<!--<q-btn dense round icon="fas fa-chevron-up" @click.stop="moveUp(originalIndex(idx))" />
|
||||
<q-btn dense round icon="fas fa-chevron-down" @click.stop="moveDown(originalIndex(idx))" />-->
|
||||
<q-btn dense round color="negative" icon="fas fa-trash" @click.stop="removePage(originalIndex(idx))" />
|
||||
</div>
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-card>
|
||||
</div>
|
||||
|
||||
<!-- Editor pagina selezionata -->
|
||||
<div class="col-12 col-md-7">
|
||||
<page-editor
|
||||
v-if="current"
|
||||
v-model="pages[selectedIndex]"
|
||||
@apply="onApply"
|
||||
@close="onClose"
|
||||
/>
|
||||
<q-card v-else flat bordered class="q-pa-lg flex flex-center text-grey">
|
||||
Seleziona o aggiungi una pagina.
|
||||
</q-card>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./PagesConfigurator.ts">
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './PagesConfigurator.scss';
|
||||
</style>
|
||||
1
src/components/PagesConfigurator/index.ts
Executable file
1
src/components/PagesConfigurator/index.ts
Executable file
@@ -0,0 +1 @@
|
||||
export {default as PagesConfigurator} from './PagesConfigurator.vue'
|
||||
Reference in New Issue
Block a user