Merge branch 'develop' of ssh://risosrv:5522/~/repository/newfreeplanet into develop
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL="newfreeplanet"
|
DIRECTORY_LOCAL="newfreeplanet"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL=newfreeplanet
|
DIRECTORY_LOCAL=newfreeplanet
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL=newfreeplanet
|
DIRECTORY_LOCAL=newfreeplanet
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="15"
|
APP_ID="15"
|
||||||
DIRECTORY_LOCAL="newfreeplanet"
|
DIRECTORY_LOCAL="newfreeplanet"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="15"
|
APP_ID="15"
|
||||||
DIRECTORY_LOCAL=newfreeplanet
|
DIRECTORY_LOCAL=newfreeplanet
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL="newfreeplanet"
|
DIRECTORY_LOCAL="newfreeplanet"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL=newfreeplanet
|
DIRECTORY_LOCAL=newfreeplanet
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="13"
|
APP_ID="13"
|
||||||
DIRECTORY_LOCAL=newfreeplanet
|
DIRECTORY_LOCAL=newfreeplanet
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
APP_VERSION="1.0.19"
|
APP_VERSION="1.0.20"
|
||||||
SERVICE_WORKER_FILE="service-worker.js"
|
SERVICE_WORKER_FILE="service-worker.js"
|
||||||
APP_ID="14"
|
APP_ID="14"
|
||||||
DIRECTORY_LOCAL="newfreeplanet"
|
DIRECTORY_LOCAL="newfreeplanet"
|
||||||
|
|||||||
@@ -17,6 +17,23 @@ export const shared_consts = {
|
|||||||
},
|
},
|
||||||
LIMIT_NOTIF_FOR_USER: 200,
|
LIMIT_NOTIF_FOR_USER: 200,
|
||||||
|
|
||||||
|
CallFunz: {
|
||||||
|
SOSTITUISCI: 345,
|
||||||
|
AGGIUNGI_NUOVO_IMBARCO: 380,
|
||||||
|
CANCELLA_IMBARCO: 385,
|
||||||
|
DAMMI_PRIMO_UTENTE_LIBERO: 390,
|
||||||
|
GET_VALBYTABLE: 400,
|
||||||
|
SET_VALBYTABLE: 410,
|
||||||
|
ZOOM_GIA_PARTECIPATO: 510,
|
||||||
|
REGISTRATION: 6,
|
||||||
|
RICHIESTA_GRUPPO: 10,
|
||||||
|
RICHIESTA_AMICIZIA: 15,
|
||||||
|
RICHIESTA_HANDSHAKE: 16,
|
||||||
|
RICHIESTA_CIRCUIT: 20,
|
||||||
|
RICHIESTA_FIDO: 25,
|
||||||
|
ENTRA_RIS_ITALIA: 30,
|
||||||
|
},
|
||||||
|
|
||||||
ELEMTYPE: {
|
ELEMTYPE: {
|
||||||
TITLE: 5,
|
TITLE: 5,
|
||||||
MARGINI: 6,
|
MARGINI: 6,
|
||||||
@@ -221,6 +238,11 @@ export const shared_consts = {
|
|||||||
VISIB_ONLY_MANAGER: 2,
|
VISIB_ONLY_MANAGER: 2,
|
||||||
VISIB_ONLY_ADMIN: 4,
|
VISIB_ONLY_ADMIN: 4,
|
||||||
|
|
||||||
|
CIRCUIT_CFG: {
|
||||||
|
MULT_FIDO_USER: 2.0,
|
||||||
|
MULT_FIDO_GROUP: 2.0,
|
||||||
|
},
|
||||||
|
|
||||||
Visibility_Group: {
|
Visibility_Group: {
|
||||||
PRIVATE: 1,
|
PRIVATE: 1,
|
||||||
HIDDEN: 2,
|
HIDDEN: 2,
|
||||||
@@ -1694,6 +1716,7 @@ export const shared_consts = {
|
|||||||
nome_valuta: 1,
|
nome_valuta: 1,
|
||||||
fido_scoperto_default: 1,
|
fido_scoperto_default: 1,
|
||||||
deperimento: 1,
|
deperimento: 1,
|
||||||
|
showAlways: 1,
|
||||||
status: 1,
|
status: 1,
|
||||||
transactionsEnabled: 1,
|
transactionsEnabled: 1,
|
||||||
qta_max_default: 1,
|
qta_max_default: 1,
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<div class="absolute-bottom text-spacetrans">
|
<div class="absolute-bottom text-spacetrans">
|
||||||
<q-btn rounded :to="discipline.linkpage">
|
<q-btn rounded :to="discipline.linkpage">
|
||||||
<div class="text-h5 disc__title shadow-max">{{ discipline.label }}</div>
|
<div class="text-h5 disc__title shadow-max">{{ discipline.label }}</div>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
</div>
|
</div>
|
||||||
</q-img>
|
</q-img>
|
||||||
|
|
||||||
|
|||||||
42
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.scss
Executable file
42
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.scss
Executable file
@@ -0,0 +1,42 @@
|
|||||||
|
.text-cls{
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.my-text {
|
||||||
|
font-size: 1rem;
|
||||||
|
font-weight: bold;
|
||||||
|
line-height: 1.5rem;
|
||||||
|
letter-spacing: 0.0125em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.my-text_3 {
|
||||||
|
font-size: 1rem;
|
||||||
|
font-weight: bold;
|
||||||
|
line-height: 1.5rem;
|
||||||
|
letter-spacing: 0.0125em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.my-text-small {
|
||||||
|
font-size: 1rem;
|
||||||
|
line-height: 1rem;
|
||||||
|
letter-spacing: 0.0125em;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mybox_3 {
|
||||||
|
min-width: 100px;
|
||||||
|
min-height: 100px;
|
||||||
|
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mybox {
|
||||||
|
min-width: 112px;
|
||||||
|
min-height: 112px;
|
||||||
|
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.mybox_small {
|
||||||
|
min-width: 110px;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
57
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.ts
Executable file
57
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.ts
Executable file
@@ -0,0 +1,57 @@
|
|||||||
|
import { defineComponent, ref, computed, PropType, toRef, onMounted } from 'vue'
|
||||||
|
import { useUserStore } from '@store/UserStore'
|
||||||
|
import { useCircuitStore } from '@store/CircuitStore'
|
||||||
|
import { useRouter } from 'vue-router'
|
||||||
|
import { useGlobalStore } from '@store/globalStore'
|
||||||
|
import { useI18n } from '@/boot/i18n'
|
||||||
|
import { tools } from '@store/Modules/tools'
|
||||||
|
import { IAccount, ICircuit, IMyGroup, IOperators, ISendCoin, ISpecialField, IUserFields } from '../../model'
|
||||||
|
import { useQuasar } from 'quasar'
|
||||||
|
|
||||||
|
export default defineComponent({
|
||||||
|
name: 'CCheckCircuitsEnabled',
|
||||||
|
components: {},
|
||||||
|
props: {
|
||||||
|
to_user: {
|
||||||
|
type: Object as PropType<IUserFields>,
|
||||||
|
required: false,
|
||||||
|
default: null
|
||||||
|
},
|
||||||
|
to_group: {
|
||||||
|
type: Object as PropType<IMyGroup>,
|
||||||
|
required: false,
|
||||||
|
default: null,
|
||||||
|
},
|
||||||
|
to_contocom: {
|
||||||
|
type: String,
|
||||||
|
required: false,
|
||||||
|
default: '',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
setup(props, { emit }) {
|
||||||
|
const $q = useQuasar()
|
||||||
|
const { t } = useI18n()
|
||||||
|
const userStore = useUserStore()
|
||||||
|
const circuitStore = useCircuitStore()
|
||||||
|
const $router = useRouter()
|
||||||
|
const globalStore = useGlobalStore()
|
||||||
|
|
||||||
|
const non_hai_circuito_nazionale = ref(false)
|
||||||
|
const destin_non_ha_circuito_naz = ref(false)
|
||||||
|
|
||||||
|
function load() {
|
||||||
|
non_hai_circuito_nazionale.value = !circuitStore.sonoDentroAlCircuitoNazionale()
|
||||||
|
destin_non_ha_circuito_naz.value = !circuitStore.EDentroAlCircuitoNazionale(props.to_user)
|
||||||
|
}
|
||||||
|
|
||||||
|
onMounted(load)
|
||||||
|
|
||||||
|
return {
|
||||||
|
userStore,
|
||||||
|
tools,
|
||||||
|
non_hai_circuito_nazionale,
|
||||||
|
destin_non_ha_circuito_naz,
|
||||||
|
$q,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
49
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.vue
Executable file
49
src/components/CCheckCircuitsEnabled/CCheckCircuitsEnabled.vue
Executable file
@@ -0,0 +1,49 @@
|
|||||||
|
<template>
|
||||||
|
<div class="q-ma-xs q-pa-xs row">
|
||||||
|
<div v-if="non_hai_circuito_nazionale" class="q-py-sm">
|
||||||
|
<q-banner rounded class="bg-red text-white" style="text-align: center">
|
||||||
|
{{ $t('circuit.non_hai_circuito_nazionale') }}
|
||||||
|
<br />
|
||||||
|
</q-banner>
|
||||||
|
|
||||||
|
<div class="text-center">
|
||||||
|
<q-btn
|
||||||
|
glossy
|
||||||
|
size="md"
|
||||||
|
:label="$t('circuit.ask_italia')"
|
||||||
|
icon="fas fa-key"
|
||||||
|
color="green"
|
||||||
|
text-color="white"
|
||||||
|
rounded
|
||||||
|
:to="tools.updateLink('/circuit/ris_italia')"
|
||||||
|
></q-btn>
|
||||||
|
</div>
|
||||||
|
</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') }}
|
||||||
|
<br />
|
||||||
|
</q-banner>
|
||||||
|
|
||||||
|
<div class="text-center">
|
||||||
|
<q-btn
|
||||||
|
glossy
|
||||||
|
size="md"
|
||||||
|
:label="$t('circuit.invia_msg_dest', {name: to_user.username})"
|
||||||
|
icon="fas fa-paper-plane"
|
||||||
|
color="blue"
|
||||||
|
text-color="white"
|
||||||
|
rounded
|
||||||
|
@click="tools.SendMsgRisItalia($q, to_user.username)"
|
||||||
|
></q-btn>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script lang="ts" src="./CCheckCircuitsEnabled.ts">
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
@import './CCheckCircuitsEnabled.scss';
|
||||||
|
</style>
|
||||||
1
src/components/CCheckCircuitsEnabled/index.ts
Executable file
1
src/components/CCheckCircuitsEnabled/index.ts
Executable file
@@ -0,0 +1 @@
|
|||||||
|
export {default as CCheckCircuitsEnabled} from './CCheckCircuitsEnabled.vue'
|
||||||
@@ -19,6 +19,11 @@ export default defineComponent({
|
|||||||
showBtnActivities: {
|
showBtnActivities: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
required: true,
|
required: true,
|
||||||
|
},
|
||||||
|
sendRIS: {
|
||||||
|
type: Number,
|
||||||
|
required: false,
|
||||||
|
default: 0,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: { CLabel, CSendCoins },
|
components: { CLabel, CSendCoins },
|
||||||
|
|||||||
@@ -68,10 +68,11 @@
|
|||||||
</q-btn>
|
</q-btn>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="showsendCoinTo">
|
<div v-if="showsendCoinTo || sendRIS > 0">
|
||||||
<CSendCoins
|
<CSendCoins
|
||||||
:showprop="showsendCoinTo"
|
:showprop="showsendCoinTo"
|
||||||
:to_user="myuser"
|
:to_user="myuser"
|
||||||
|
:sendRIS="sendRIS"
|
||||||
@close="showsendCoinTo = false"
|
@close="showsendCoinTo = false"
|
||||||
>
|
>
|
||||||
</CSendCoins>
|
</CSendCoins>
|
||||||
|
|||||||
@@ -62,7 +62,7 @@ export default defineComponent({
|
|||||||
|
|
||||||
const globalStore = useGlobalStore()
|
const globalStore = useGlobalStore()
|
||||||
|
|
||||||
const circuit = ref(<ICircuit | IMyCircuit | null>null)
|
const circuit = ref(<IMyCircuit | ICircuit | null>null)
|
||||||
const account = computed(() => circuit.value ? userStore.getAccountByCircuitId(circuit.value._id) : null )
|
const account = computed(() => circuit.value ? userStore.getAccountByCircuitId(circuit.value._id) : null )
|
||||||
|
|
||||||
const qtarem = computed(() => account.value ? circuitStore.getRemainingCoinsToSend(account.value) : 0)
|
const qtarem = computed(() => account.value ? circuitStore.getRemainingCoinsToSend(account.value) : 0)
|
||||||
|
|||||||
@@ -107,7 +107,7 @@
|
|||||||
lines="1"
|
lines="1"
|
||||||
>
|
>
|
||||||
<CSaldo
|
<CSaldo
|
||||||
v-if="tools.isUserOk() && username === myusername()"
|
v-if="tools.isUserOk() && username === myusername() && account"
|
||||||
:account="account"
|
:account="account"
|
||||||
:symbol="circuit.symbol"
|
:symbol="circuit.symbol"
|
||||||
:color="circuit.color"
|
:color="circuit.color"
|
||||||
@@ -115,8 +115,38 @@
|
|||||||
:qtarem="qtarem"
|
:qtarem="qtarem"
|
||||||
>
|
>
|
||||||
</CSaldo>
|
</CSaldo>
|
||||||
|
|
||||||
</q-item-label>
|
</q-item-label>
|
||||||
|
<q-item-label
|
||||||
|
lines="4"
|
||||||
|
v-if="
|
||||||
|
tools.isUserOk() &&
|
||||||
|
username === myusername() &&
|
||||||
|
!account &&
|
||||||
|
visu !== costanti.ENTER_TO_THE_CIRCUIT
|
||||||
|
"
|
||||||
|
>
|
||||||
|
<div class="centermydiv text-center">
|
||||||
|
<q-banner inline-actions class="bg-blue text-white">
|
||||||
|
<span v-html="$t('circuit.non_entrato')"></span>
|
||||||
|
<template v-slot:action>
|
||||||
|
<q-btn
|
||||||
|
v-if="
|
||||||
|
!userStore.IsMyCircuitByName(circuit.name) &&
|
||||||
|
!userStore.IsAskedCircuitByName(circuit.name) &&
|
||||||
|
!userStore.IsRefusedCircuitByName(circuit.name)
|
||||||
|
"
|
||||||
|
color="positive"
|
||||||
|
:label="$t('circuit.apri')"
|
||||||
|
@click="
|
||||||
|
requestToEnterCircuit = true;
|
||||||
|
groupnameSel = null;
|
||||||
|
"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</q-banner>
|
||||||
|
</div>
|
||||||
|
</q-item-label>
|
||||||
|
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
|
|
||||||
<q-item-section
|
<q-item-section
|
||||||
@@ -357,7 +387,7 @@
|
|||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
v-close-popup
|
v-close-popup
|
||||||
v-if="saldo === 0"
|
v-if="saldo === 0 || !saldo"
|
||||||
@click="
|
@click="
|
||||||
tools.removeFromMyCircuits(
|
tools.removeFromMyCircuits(
|
||||||
$q,
|
$q,
|
||||||
|
|||||||
@@ -106,7 +106,7 @@ export default defineComponent({
|
|||||||
try {
|
try {
|
||||||
if (props.modelValue === costanti.CIRCUITS) {
|
if (props.modelValue === costanti.CIRCUITS) {
|
||||||
arr = circuitStore.listcircuits
|
arr = circuitStore.listcircuits
|
||||||
} else if (props.modelValue === costanti.MY_CIRCUITS ) {
|
} else if (props.modelValue === costanti.MY_CIRCUITS) {
|
||||||
arr = circuitStore.listcircuits.filter((circ: any) => userStore.my.profile.mycircuits.findIndex((rec: any) => circ.name === rec.circuitname) >= 0)
|
arr = circuitStore.listcircuits.filter((circ: any) => userStore.my.profile.mycircuits.findIndex((rec: any) => circ.name === rec.circuitname) >= 0)
|
||||||
} else if (props.modelValue === costanti.ASK_SENT_CIRCUIT) {
|
} else if (props.modelValue === costanti.ASK_SENT_CIRCUIT) {
|
||||||
arr = userStore.my.profile.asked_circuits
|
arr = userStore.my.profile.asked_circuits
|
||||||
@@ -115,6 +115,16 @@ export default defineComponent({
|
|||||||
arr = []
|
arr = []
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (props.modelValue === costanti.MY_CIRCUITS) {
|
||||||
|
const arrtoinsert: any = circuitStore.listcircuits.filter((circ: any) => circ.showAlways)
|
||||||
|
for (const rec of arrtoinsert) {
|
||||||
|
if (arr.findIndex(myrec => myrec._id === rec._id) < 0) {
|
||||||
|
// Se non c'è il circuito Nazionale, glielo aggiungo
|
||||||
|
arr.push(rec)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return arr
|
return arr
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -95,9 +95,10 @@ export default defineComponent({
|
|||||||
tools.scrollToTop()
|
tools.scrollToTop()
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((step.value === STEP_CIRCUIT - 1) || (step.value === STEP_CIRCUIT )) {
|
if ((step.value === STEP_CIRCUIT )) {
|
||||||
mycircuit.value = circuitStore.getCircuitByProvince(strProv.value)
|
mycircuit.value = circuitStore.getCircuitByProvince(strProv.value)
|
||||||
userStore.savenoCircuit(isAskedToCircuit())
|
console.log('isAskedToCircuit()', isAskedToCircuit())
|
||||||
|
// userStore.savenoCircuit(isAskedToCircuit())
|
||||||
}
|
}
|
||||||
|
|
||||||
if (step.value === STEP_NAME_SURNAME + 1) {
|
if (step.value === STEP_NAME_SURNAME + 1) {
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import { useQuasar } from 'quasar'
|
|||||||
import { useI18n } from '@/boot/i18n'
|
import { useI18n } from '@/boot/i18n'
|
||||||
import { CMyUserOnlyView } from '@/components/CMyUserOnlyView'
|
import { CMyUserOnlyView } from '@/components/CMyUserOnlyView'
|
||||||
import { CMyGroupOnlyView } from '@/components/CMyGroupOnlyView'
|
import { CMyGroupOnlyView } from '@/components/CMyGroupOnlyView'
|
||||||
|
import { CCheckCircuitsEnabled } from '@/components/CCheckCircuitsEnabled'
|
||||||
import { costanti } from '@costanti'
|
import { costanti } from '@costanti'
|
||||||
|
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
@@ -48,8 +49,13 @@ export default defineComponent({
|
|||||||
required: false,
|
required: false,
|
||||||
default: null,
|
default: null,
|
||||||
},
|
},
|
||||||
|
sendRIS: {
|
||||||
|
type: Number,
|
||||||
|
required: false,
|
||||||
|
default: 1,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
components: { CSaldo, CMyUserOnlyView, CMyGroupOnlyView },
|
components: { CSaldo, CMyUserOnlyView, CMyGroupOnlyView, CCheckCircuitsEnabled },
|
||||||
|
|
||||||
setup(props, { emit }) {
|
setup(props, { emit }) {
|
||||||
const $q = useQuasar()
|
const $q = useQuasar()
|
||||||
@@ -257,7 +263,9 @@ export default defineComponent({
|
|||||||
if (props.circuitname) {
|
if (props.circuitname) {
|
||||||
circuitsel.value = props.circuitname
|
circuitsel.value = props.circuitname
|
||||||
} else {
|
} else {
|
||||||
circuitsel.value = tools.getCookie(tools.CIRCUIT_USE, bothcircuits.value[0])
|
const circcookie = tools.getCookie(tools.CIRCUIT_USE, bothcircuits.value[0])
|
||||||
|
if (circcookie && bothcircuits.value.findIndex((circ: ICircuit) => circ.name === circcookie) >= 0)
|
||||||
|
circuitsel.value = circcookie
|
||||||
}
|
}
|
||||||
if (bothcircuits.value && bothcircuits.value.find((name: any) => name !== circuitsel.value)) {
|
if (bothcircuits.value && bothcircuits.value.find((name: any) => name !== circuitsel.value)) {
|
||||||
circuitsel.value = bothcircuits.value[0]
|
circuitsel.value = bothcircuits.value[0]
|
||||||
@@ -265,6 +273,10 @@ export default defineComponent({
|
|||||||
|
|
||||||
qty.value = props.qtydefault
|
qty.value = props.qtydefault
|
||||||
|
|
||||||
|
if (props.sendRIS) {
|
||||||
|
qty.value = props.sendRIS
|
||||||
|
}
|
||||||
|
|
||||||
await aggiorna()
|
await aggiorna()
|
||||||
|
|
||||||
showpage.value = true
|
showpage.value = true
|
||||||
|
|||||||
@@ -12,6 +12,12 @@
|
|||||||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||||||
</q-bar>
|
</q-bar>
|
||||||
<q-card-section class="q-px-xs inset-shadow">
|
<q-card-section class="q-px-xs inset-shadow">
|
||||||
|
<CCheckCircuitsEnabled
|
||||||
|
:to_user="to_user"
|
||||||
|
:to_group="to_group"
|
||||||
|
>
|
||||||
|
</CCheckCircuitsEnabled>
|
||||||
|
|
||||||
<q-select
|
<q-select
|
||||||
v-if="!circuitname"
|
v-if="!circuitname"
|
||||||
:behavior="$q.platform.is.ios === true ? 'dialog' : 'menu'"
|
:behavior="$q.platform.is.ios === true ? 'dialog' : 'menu'"
|
||||||
@@ -132,7 +138,7 @@
|
|||||||
>
|
>
|
||||||
</CMyGroupOnlyView>
|
</CMyGroupOnlyView>
|
||||||
<CMyGroupOnlyView
|
<CMyGroupOnlyView
|
||||||
v-if="circuitloaded && to_contocom"
|
v-if="circuitloaded && !!circuitloaded._id && to_contocom"
|
||||||
:mygrp="{ groupname: to_contocom }"
|
:mygrp="{ groupname: to_contocom }"
|
||||||
:visu="costanti.USER_GROUPS"
|
:visu="costanti.USER_GROUPS"
|
||||||
:circuitname="circuitloaded.name"
|
:circuitname="circuitloaded.name"
|
||||||
@@ -144,7 +150,7 @@
|
|||||||
<q-spinner-tail size="6em" color="primary" />
|
<q-spinner-tail size="6em" color="primary" />
|
||||||
</q-inner-loading>
|
</q-inner-loading>
|
||||||
|
|
||||||
<div v-if="circuitloaded">
|
<div v-if="circuitloaded && !!circuitloaded._id">
|
||||||
<q-banner
|
<q-banner
|
||||||
v-if="!circuitloaded.transactionsEnabled"
|
v-if="!circuitloaded.transactionsEnabled"
|
||||||
rounded
|
rounded
|
||||||
@@ -230,10 +236,12 @@
|
|||||||
>
|
>
|
||||||
</q-input>
|
</q-input>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
|
|
||||||
<q-card-actions align="center">
|
<q-card-actions align="center">
|
||||||
<q-btn
|
<q-btn
|
||||||
v-if="
|
v-if="
|
||||||
circuitloaded &&
|
circuitloaded &&
|
||||||
|
!!circuitloaded._id &&
|
||||||
(qtyRef
|
(qtyRef
|
||||||
? !(
|
? !(
|
||||||
qtyRef.hasError ||
|
qtyRef.hasError ||
|
||||||
|
|||||||
@@ -1108,6 +1108,7 @@ export interface ICircuit {
|
|||||||
qta_max_default_grp?: number
|
qta_max_default_grp?: number
|
||||||
data_costituz?: Date
|
data_costituz?: Date
|
||||||
deperimento: boolean
|
deperimento: boolean
|
||||||
|
showAlways: boolean
|
||||||
transactionsEnabled: boolean
|
transactionsEnabled: boolean
|
||||||
status: number
|
status: number
|
||||||
freq_deper?: string
|
freq_deper?: string
|
||||||
|
|||||||
@@ -151,6 +151,7 @@ export interface IUserProfile {
|
|||||||
stepTutorial: number
|
stepTutorial: number
|
||||||
noNameSurname: boolean
|
noNameSurname: boolean
|
||||||
noCircuit: boolean
|
noCircuit: boolean
|
||||||
|
noCircIta: boolean
|
||||||
noFoto: boolean
|
noFoto: boolean
|
||||||
reaction: IReaction[]
|
reaction: IReaction[]
|
||||||
// bookmark: IBookmark[]
|
// bookmark: IBookmark[]
|
||||||
|
|||||||
@@ -228,7 +228,7 @@ const msg_it = {
|
|||||||
refusedgroup: 'Rifiutato a {username} la richiesta di entrare nel Gruppo',
|
refusedgroup: 'Rifiutato a {username} la richiesta di entrare nel Gruppo',
|
||||||
youarerefusedgroup: 'Ti è stato rifiutata la richiesta di entrare in questo Gruppo (per info chiedi all\'amministratore del gruppo)',
|
youarerefusedgroup: 'Ti è stato rifiutata la richiesta di entrare in questo Gruppo (per info chiedi all\'amministratore del gruppo)',
|
||||||
youarerefusedcircuit: 'Ti è stato rifiutata la richiesta di entrare in questo Circuito (per info chiedi all\'amministratore del gruppo)',
|
youarerefusedcircuit: 'Ti è stato rifiutata la richiesta di entrare in questo Circuito (per info chiedi all\'amministratore del gruppo)',
|
||||||
insertgoodorservices_to_enter_circuit: 'Per poter inviare RIS è necessario aggiungere almeno un Bene, Servizio o offrire Ospitalità',
|
insertgoodorservices_to_enter_circuit: 'Per poter inviare RIS è consigliato partecipare al circuito, aggiungendo quello che possiamo proporre noi (un Bene, un Servizio, Ospitalità, ecc...)',
|
||||||
deletedgroup: 'Gruppo Eliminato',
|
deletedgroup: 'Gruppo Eliminato',
|
||||||
domanda_addtofriend: 'Aggiungere agli amici {username}?',
|
domanda_addtofriend: 'Aggiungere agli amici {username}?',
|
||||||
domanda_addtohandshake: 'Confermi che hai conosciuto personalmente e dai la tua fiducia a {username} ?',
|
domanda_addtohandshake: 'Confermi che hai conosciuto personalmente e dai la tua fiducia a {username} ?',
|
||||||
@@ -1219,6 +1219,13 @@ const msg_it = {
|
|||||||
preferences: 'Preferenze',
|
preferences: 'Preferenze',
|
||||||
},
|
},
|
||||||
circuit: {
|
circuit: {
|
||||||
|
apri: 'Entra !',
|
||||||
|
invia_msg_dest: 'Invia la richiesta a {name}',
|
||||||
|
non_hai_circuito_nazionale: 'Per poter inviare dei RIS ad una persona di un altro territorio, è necessario entrare sul "Circuito RIS Italia"',
|
||||||
|
destin_non_ha_circuito_naz: 'Il tuo Destinatario non fa parte del tuo territorio, pertanto occorre che acceda al Circuito RIS Italia',
|
||||||
|
|
||||||
|
beforeentertolocalcircuit: 'Prima di entrare nel Circuito Nazionale occorre accedere in quello della tua Provincia',
|
||||||
|
non_entrato: 'Per far parte di questo Circuito devi chiedere di Entrare!',
|
||||||
link_chat: 'Chat {name}',
|
link_chat: 'Chat {name}',
|
||||||
link_group: 'Gruppo Telegram',
|
link_group: 'Gruppo Telegram',
|
||||||
chat_gruppo_telegram_circuito: 'Entra nella chat di Gruppo Telegram dove conoscerai persone della tua provincia',
|
chat_gruppo_telegram_circuito: 'Entra nella chat di Gruppo Telegram dove conoscerai persone della tua provincia',
|
||||||
@@ -1263,6 +1270,7 @@ const msg_it = {
|
|||||||
qta_max_default_tips_grp: 'Rappresenta quanto credito ti è concesso accumulare al gruppo. Incentiviamo così a frequenti scambi tra i partecipanti',
|
qta_max_default_tips_grp: 'Rappresenta quanto credito ti è concesso accumulare al gruppo. Incentiviamo così a frequenti scambi tra i partecipanti',
|
||||||
data_costituz: 'Data Costituzione',
|
data_costituz: 'Data Costituzione',
|
||||||
deperimento: 'Deperimento',
|
deperimento: 'Deperimento',
|
||||||
|
showAlways: 'Mostra Sempre',
|
||||||
freq_deper: 'Frequenza Deperimento',
|
freq_deper: 'Frequenza Deperimento',
|
||||||
minuto_deper: 'Minuto Dep.',
|
minuto_deper: 'Minuto Dep.',
|
||||||
ora_deper: 'Ora Dep.',
|
ora_deper: 'Ora Dep.',
|
||||||
@@ -1288,6 +1296,7 @@ const msg_it = {
|
|||||||
remove_as_admin: 'Rimuovi come Admin del Circuito',
|
remove_as_admin: 'Rimuovi come Admin del Circuito',
|
||||||
remove_from_mycircuit: 'Rimuovi dal Circuito',
|
remove_from_mycircuit: 'Rimuovi dal Circuito',
|
||||||
ask: 'Entra nel Circuito',
|
ask: 'Entra nel Circuito',
|
||||||
|
ask_italia: 'Apri Circuito RIS Italia',
|
||||||
exit: 'Esci dal Circuito',
|
exit: 'Esci dal Circuito',
|
||||||
accept: 'Accetta la richiesta',
|
accept: 'Accetta la richiesta',
|
||||||
exit_circuit: 'Esci dal Circuito',
|
exit_circuit: 'Esci dal Circuito',
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { defineStore } from 'pinia'
|
|||||||
|
|
||||||
import {
|
import {
|
||||||
IAccount,
|
IAccount,
|
||||||
ICircuit, ICircuitState, IGlobalState, IGroupShort, IMyCircuit, IMyGroup,
|
ICircuit, ICircuitState, IGlobalState, IGroupShort, IMyCircuit, IMyGroup, IUserFields
|
||||||
} from '@src/model'
|
} from '@src/model'
|
||||||
import { tools } from '@store/Modules/tools'
|
import { tools } from '@store/Modules/tools'
|
||||||
import translate from '@src/globalroutines/util'
|
import translate from '@src/globalroutines/util'
|
||||||
@@ -52,6 +52,48 @@ export const useCircuitStore = defineStore('CircuitStore', {
|
|||||||
return 0
|
return 0
|
||||||
},
|
},
|
||||||
|
|
||||||
|
sonoDentroAlCircuitoNazionale() {
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
const circNazionali: any = this.listcircuits.filter((circ: any) => circ.showAlways)
|
||||||
|
|
||||||
|
for (const circ of circNazionali) {
|
||||||
|
const trovato = userStore.my.profile.mycircuits.findIndex((mycirc: any) => mycirc.circuitname === circ.name) >= 0
|
||||||
|
if (trovato){
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return false
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
EDentroAlCircuitoNazionale(user: IUserFields) {
|
||||||
|
|
||||||
|
const circNazionali: any = this.listcircuits.filter((circ: any) => circ.showAlways)
|
||||||
|
|
||||||
|
for (const circ of circNazionali) {
|
||||||
|
const trovato = user.profile.mycircuits.findIndex((mycirc: any) => mycirc.circuitname === circ.name) >= 0
|
||||||
|
if (trovato){
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return false
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
isCircuitNational(circuitname: string): boolean {
|
||||||
|
return this.listcircuits.findIndex((rec: ICircuit) => rec.name === circuitname && rec.showAlways) >= 0
|
||||||
|
},
|
||||||
|
|
||||||
|
IsNationalAndNotEnterInLocal(circuitname: string): boolean {
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
return this.isCircuitNational(circuitname) && userStore.my.profile.mycircuits.length <= 0
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
getCircuitClass(circuit: ICircuit) {
|
getCircuitClass(circuit: ICircuit) {
|
||||||
if (circuit.status === shared_consts.CIRCUIT_STATUS.FASE3_MONETA_ABILITATA)
|
if (circuit.status === shared_consts.CIRCUIT_STATUS.FASE3_MONETA_ABILITATA)
|
||||||
return 'circuito_abilitato'
|
return 'circuito_abilitato'
|
||||||
@@ -61,6 +103,7 @@ export const useCircuitStore = defineStore('CircuitStore', {
|
|||||||
return 'circuito_in_creazione'
|
return 'circuito_in_creazione'
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
getColorCircuitClass(circuit: ICircuit) {
|
getColorCircuitClass(circuit: ICircuit) {
|
||||||
if (circuit.status === shared_consts.CIRCUIT_STATUS.FASE3_MONETA_ABILITATA)
|
if (circuit.status === shared_consts.CIRCUIT_STATUS.FASE3_MONETA_ABILITATA)
|
||||||
return 'green'
|
return 'green'
|
||||||
|
|||||||
@@ -3005,6 +3005,7 @@ export const colTableCircuitComplete = [
|
|||||||
AddCol({ name: 'qta_max_default_grp', label_trans: 'circuit.qta_max_default_grp', fieldtype: costanti.FieldType.currency }),
|
AddCol({ name: 'qta_max_default_grp', label_trans: 'circuit.qta_max_default_grp', fieldtype: costanti.FieldType.currency }),
|
||||||
AddCol({ name: 'data_costituz', label_trans: 'circuit.data_costituz', fieldtype: costanti.FieldType.date }),
|
AddCol({ name: 'data_costituz', label_trans: 'circuit.data_costituz', fieldtype: costanti.FieldType.date }),
|
||||||
AddCol({ name: 'deperimento', label_trans: 'circuit.deperimento', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'deperimento', label_trans: 'circuit.deperimento', fieldtype: costanti.FieldType.boolean }),
|
||||||
|
AddCol({ name: 'showAlways', label_trans: 'circuit.showAlways', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'transactionsEnabled', label_trans: 'circuit.transactionsEnabled', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'transactionsEnabled', label_trans: 'circuit.transactionsEnabled', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'freq_deper', label_trans: 'circuit.freq_deper' }),
|
AddCol({ name: 'freq_deper', label_trans: 'circuit.freq_deper' }),
|
||||||
AddCol({ name: 'minuto_deper', label_trans: 'circuit.minuto_deper', fieldtype: costanti.FieldType.number }),
|
AddCol({ name: 'minuto_deper', label_trans: 'circuit.minuto_deper', fieldtype: costanti.FieldType.number }),
|
||||||
@@ -3144,6 +3145,7 @@ export const colTableCircuit = [
|
|||||||
}),
|
}),
|
||||||
AddCol({ name: 'regulation', label_trans: 'circuit.regulation', fieldtype: costanti.FieldType.html, required: false }),
|
AddCol({ name: 'regulation', label_trans: 'circuit.regulation', fieldtype: costanti.FieldType.html, required: false }),
|
||||||
AddCol({ name: 'deperimento', label_trans: 'circuit.deperimento', fieldtype: costanti.FieldType.boolean, disable: true }),
|
AddCol({ name: 'deperimento', label_trans: 'circuit.deperimento', fieldtype: costanti.FieldType.boolean, disable: true }),
|
||||||
|
AddCol({ name: 'showAlways', label_trans: 'circuit.showAlways', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({ name: 'transactionsEnabled', label_trans: 'circuit.transactionsEnabled', fieldtype: costanti.FieldType.boolean }),
|
AddCol({ name: 'transactionsEnabled', label_trans: 'circuit.transactionsEnabled', fieldtype: costanti.FieldType.boolean }),
|
||||||
AddCol({
|
AddCol({
|
||||||
name: 'status', label_trans: 'circuit.status',
|
name: 'status', label_trans: 'circuit.status',
|
||||||
|
|||||||
@@ -6117,6 +6117,22 @@ export const tools = {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
SendMsgRisItalia($q: any, usernameDest: string) {
|
||||||
|
|
||||||
|
const userStore = useUserStore()
|
||||||
|
|
||||||
|
const username = userStore.my.username
|
||||||
|
|
||||||
|
userStore.setSendCmd($q, t, username, usernameDest, shared_consts.CallFunz.ENTRA_RIS_ITALIA, null)
|
||||||
|
.then((res: any) => {
|
||||||
|
if (res && res.result) {
|
||||||
|
this.updateMyData(res)
|
||||||
|
tools.showPositiveNotif($q, res.popupOnApp)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
setRequestGroup($q: any, username: string, groupnameDest: string, value: boolean) {
|
setRequestGroup($q: any, username: string, groupnameDest: string, value: boolean) {
|
||||||
|
|
||||||
const userStore = useUserStore()
|
const userStore = useUserStore()
|
||||||
@@ -7065,6 +7081,7 @@ export const tools = {
|
|||||||
admins: [],
|
admins: [],
|
||||||
color: '#ff5500',
|
color: '#ff5500',
|
||||||
deperimento: false,
|
deperimento: false,
|
||||||
|
showAlways: false,
|
||||||
transactionsEnabled: false,
|
transactionsEnabled: false,
|
||||||
status: shared_consts.CIRCUIT_STATUS.FASE1_CREAZIONE_GRUPPO,
|
status: shared_consts.CIRCUIT_STATUS.FASE1_CREAZIONE_GRUPPO,
|
||||||
symbol: 'RIS',
|
symbol: 'RIS',
|
||||||
|
|||||||
@@ -100,6 +100,7 @@ export const DefaultUser: IUserFields = {
|
|||||||
stepTutorial: 0,
|
stepTutorial: 0,
|
||||||
noNameSurname: false,
|
noNameSurname: false,
|
||||||
noCircuit: false,
|
noCircuit: false,
|
||||||
|
noCircIta: false,
|
||||||
noFoto: false,
|
noFoto: false,
|
||||||
asked_circuits: [],
|
asked_circuits: [],
|
||||||
refused_circuits: [],
|
refused_circuits: [],
|
||||||
@@ -168,6 +169,7 @@ export const DefaultProfile: IUserProfile = {
|
|||||||
stepTutorial: 0,
|
stepTutorial: 0,
|
||||||
noNameSurname: false,
|
noNameSurname: false,
|
||||||
noCircuit: false,
|
noCircuit: false,
|
||||||
|
noCircIta: false,
|
||||||
noFoto: false,
|
noFoto: false,
|
||||||
asked_circuits: [],
|
asked_circuits: [],
|
||||||
refused_circuits: [],
|
refused_circuits: [],
|
||||||
@@ -500,7 +502,7 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// se non ho neanche 1 circuito in comune, metto il mio preferito
|
// se non ho neanche 1 circuito in comune, metto il mio preferito
|
||||||
if (arrfinale.length <= 0) {
|
/*if (arrfinale.length <= 0) {
|
||||||
const circuit = circuitStore.getCircuitByProvince(this.my.profile.resid_province)
|
const circuit = circuitStore.getCircuitByProvince(this.my.profile.resid_province)
|
||||||
if (circuit)
|
if (circuit)
|
||||||
arrfinale.push(circuit.name)
|
arrfinale.push(circuit.name)
|
||||||
@@ -510,7 +512,7 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
}
|
} */
|
||||||
|
|
||||||
console.log('arrout', arrfinale)
|
console.log('arrout', arrfinale)
|
||||||
|
|
||||||
@@ -953,6 +955,17 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
return await this.execDbOpUser({ mydata })
|
return await this.execDbOpUser({ mydata })
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
async savenoCircIta(val: boolean) {
|
||||||
|
const mydata = {
|
||||||
|
_id: this.my._id,
|
||||||
|
dbop: 'noCircIta',
|
||||||
|
value: val,
|
||||||
|
}
|
||||||
|
if (this.my.profile.noCircIta !== val) {
|
||||||
|
this.my.profile.noCircIta = val
|
||||||
|
return await this.execDbOpUser({ mydata })
|
||||||
|
}
|
||||||
|
},
|
||||||
async savenoFoto(val: boolean) {
|
async savenoFoto(val: boolean) {
|
||||||
const mydata = {
|
const mydata = {
|
||||||
_id: this.my._id,
|
_id: this.my._id,
|
||||||
@@ -1626,6 +1639,21 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
async setSendCmd($q: any, t: any, usernameOrig: string, usernameDest: string, cmd: number, value: any) {
|
||||||
|
return Api.SendReq('/users/sendcmd', 'POST', { usernameOrig, usernameDest, cmd, value })
|
||||||
|
.then((res) => {
|
||||||
|
this.updateTables = true
|
||||||
|
// const notifStore = useNotifStore()
|
||||||
|
|
||||||
|
// notifStore.updateNotification = true
|
||||||
|
return res.data
|
||||||
|
}).catch((error) => {
|
||||||
|
tools.showNegativeNotif($q, t('db.recfailed'))
|
||||||
|
return {}
|
||||||
|
})
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
async setCircuitCmd($q: any, t: any, usernameOrig: string, circuitname: string, cmd: number, value: any, extrarec?: any) {
|
async setCircuitCmd($q: any, t: any, usernameOrig: string, circuitname: string, cmd: number, value: any, extrarec?: any) {
|
||||||
return await Api.SendReq('/users/circuits/cmd', 'POST', { usernameOrig, circuitname, cmd, value, extrarec })
|
return await Api.SendReq('/users/circuits/cmd', 'POST', { usernameOrig, circuitname, cmd, value, extrarec })
|
||||||
.then((res) => {
|
.then((res) => {
|
||||||
@@ -1849,12 +1877,15 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
|
|
||||||
let yes = true
|
let yes = true
|
||||||
|
|
||||||
// Check if I have at least 1 Circuit
|
if (this.my.profile && this.my.profile.mycircuits) {
|
||||||
yes = yes && (this.my.profile.mycircuits.length > 0)
|
|
||||||
|
|
||||||
if (myuser && myuser.profile && myuser.profile.mycircuits) {
|
// Check if I have at least 1 Circuit
|
||||||
// Check if myuser has at least 1 Circuit
|
yes = yes && (this.my.profile.mycircuits.length > 0)
|
||||||
yes = yes && (myuser.profile.mycircuits.length > 0)
|
|
||||||
|
if (myuser && myuser.profile && myuser.profile.mycircuits) {
|
||||||
|
// Check if myuser has at least 1 Circuit
|
||||||
|
yes = yes && (myuser.profile.mycircuits.length > 0)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return yes
|
return yes
|
||||||
@@ -1902,7 +1933,7 @@ export const useUserStore = defineStore('UserStore', {
|
|||||||
const dateold = tools.addDays(tools.getDateNow(), -(30 * 6))
|
const dateold = tools.addDays(tools.getDateNow(), -(30 * 6))
|
||||||
if (this.my)
|
if (this.my)
|
||||||
return this.my.date_reg! && new Date(this.my.date_reg).getTime() < dateold.getTime()
|
return this.my.date_reg! && new Date(this.my.date_reg).getTime() < dateold.getTime()
|
||||||
else
|
else
|
||||||
return true
|
return true
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
return false
|
return false
|
||||||
|
|||||||
@@ -107,7 +107,7 @@
|
|||||||
class="fit column no-wrap justify-evenly items-center content-start"
|
class="fit column no-wrap justify-evenly items-center content-start"
|
||||||
>
|
>
|
||||||
<div class="row justify-center">
|
<div class="row justify-center">
|
||||||
<q-avatar size="70px">
|
<q-avatar v-if="getImgCircuit()" size="70px">
|
||||||
<q-img
|
<q-img
|
||||||
:src="getImgCircuit()"
|
:src="getImgCircuit()"
|
||||||
:alt="circuit.name"
|
:alt="circuit.name"
|
||||||
@@ -116,7 +116,7 @@
|
|||||||
@click="showPic = true"
|
@click="showPic = true"
|
||||||
/>
|
/>
|
||||||
</q-avatar>
|
</q-avatar>
|
||||||
<div class="q-mx-sm text-h6" style="align-self: center">
|
<div class="q-mx-xs text-h6" style="align-self: center">
|
||||||
<span v-if="checkifShow('name')"> {{ circuit.name }}</span>
|
<span v-if="checkifShow('name')"> {{ circuit.name }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
@@ -312,6 +312,29 @@
|
|||||||
><br />
|
><br />
|
||||||
</q-banner>
|
</q-banner>
|
||||||
|
|
||||||
|
<q-banner
|
||||||
|
v-if="circuitStore.IsNationalAndNotEnterInLocal(circuit.name)"
|
||||||
|
rounded
|
||||||
|
class="bg-red text-white"
|
||||||
|
style="text-align: center"
|
||||||
|
>
|
||||||
|
<template v-slot:avatar>
|
||||||
|
<q-icon
|
||||||
|
class="vertical-align center"
|
||||||
|
name="fas fa-info"
|
||||||
|
color="red"
|
||||||
|
size="sm"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<em style="font-weight: bold">{{
|
||||||
|
$t('circuit.beforeentertolocalcircuit')
|
||||||
|
}}</em
|
||||||
|
><br />
|
||||||
|
</q-banner>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="centermydiv q-mt-md">
|
<div class="centermydiv q-mt-md">
|
||||||
<q-btn
|
<q-btn
|
||||||
v-if="
|
v-if="
|
||||||
@@ -319,6 +342,7 @@
|
|||||||
!userStore.IsAskedCircuitByName(circuit.name) &&
|
!userStore.IsAskedCircuitByName(circuit.name) &&
|
||||||
!userStore.IsRefusedCircuitByName(circuit.name)
|
!userStore.IsRefusedCircuitByName(circuit.name)
|
||||||
"
|
"
|
||||||
|
:disable="circuitStore.IsNationalAndNotEnterInLocal(circuit.name)"
|
||||||
icon="fas fa-user-plus"
|
icon="fas fa-user-plus"
|
||||||
color="primary"
|
color="primary"
|
||||||
:label="$t('circuit.ask')"
|
:label="$t('circuit.ask')"
|
||||||
@@ -337,7 +361,7 @@
|
|||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
v-close-popup
|
v-close-popup
|
||||||
v-if="saldo === 0"
|
v-if="saldo === 0 || !saldo"
|
||||||
@click="
|
@click="
|
||||||
tools.removeFromMyCircuits(
|
tools.removeFromMyCircuits(
|
||||||
$q,
|
$q,
|
||||||
@@ -449,8 +473,8 @@
|
|||||||
style="max-width: 500px"
|
style="max-width: 500px"
|
||||||
v-if="tools.iCanShowCircuitsMember(circuit)"
|
v-if="tools.iCanShowCircuitsMember(circuit)"
|
||||||
>
|
>
|
||||||
<div class="text-h6">{{ t('circuit.contideigruppi') }}:</div>
|
<div class="text-h7">{{ t('circuit.contideigruppi') }}:</div>
|
||||||
<div class="text-h7 q-mb-sm">
|
<div class="text-h8 q-mb-sm">
|
||||||
<div v-html="$t('circuit.collettivi_info')"></div>
|
<div v-html="$t('circuit.collettivi_info')"></div>
|
||||||
</div>
|
</div>
|
||||||
<q-tabs
|
<q-tabs
|
||||||
@@ -670,22 +694,22 @@
|
|||||||
<div>
|
<div>
|
||||||
<q-card>
|
<q-card>
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="text-h6">{{ t('circuit.info') }}</div>
|
<div class="text-h7">{{ t('circuit.info') }}</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
|
|
||||||
<q-separator />
|
<q-separator />
|
||||||
|
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="text-h7 q-mb-sm">
|
<div class="text-h8 q-mb-sm">
|
||||||
<div v-html="$t('circuit.aggiuntive')"></div>
|
<div v-html="$t('circuit.aggiuntive')"></div>
|
||||||
</div>
|
</div>
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="text-h6">{{ t('circuit.descr') }}:</div>
|
<div class="text-h7">{{ t('circuit.descr') }}:</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
<q-separator />
|
<q-separator />
|
||||||
|
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="col-12 text-h7">
|
<div class="col-12 text-h8">
|
||||||
<span
|
<span
|
||||||
v-if="checkifShow('descr')"
|
v-if="checkifShow('descr')"
|
||||||
v-html="circuit.longdescr"
|
v-html="circuit.longdescr"
|
||||||
@@ -752,7 +776,7 @@
|
|||||||
<div class="sezioni">
|
<div class="sezioni">
|
||||||
<q-icon name="fas fa-coins" class="iconcirc"></q-icon>
|
<q-icon name="fas fa-coins" class="iconcirc"></q-icon>
|
||||||
{{ t('circuit.symbol') }}:
|
{{ t('circuit.symbol') }}:
|
||||||
<span class="text-h5">
|
<span class="text-h7">
|
||||||
<em
|
<em
|
||||||
class="q-px-sm text-black rounded-borders"
|
class="q-px-sm text-black rounded-borders"
|
||||||
:style="
|
:style="
|
||||||
@@ -880,7 +904,7 @@
|
|||||||
|
|
||||||
<q-card v-if="circuit.name">
|
<q-card v-if="circuit.name">
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="text-h6">{{ t('circuit.regulation') }}:</div>
|
<div class="text-h8">{{ t('circuit.regulation') }}:</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
<q-separator />
|
<q-separator />
|
||||||
|
|
||||||
@@ -892,14 +916,14 @@
|
|||||||
>
|
>
|
||||||
</q-btn>
|
</q-btn>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 text-h7">
|
<div class="col-12 text-h8">
|
||||||
<span
|
<span
|
||||||
v-if="checkifShow('descr') && showrules && circuit"
|
v-if="checkifShow('descr') && showrules && circuit"
|
||||||
v-html="getRegulation(circuit.regulation)"
|
v-html="getRegulation(circuit.regulation)"
|
||||||
></span>
|
></span>
|
||||||
</div>
|
</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
<div v-if="circuit.createdBy" class="container">
|
<div v-if="circuit.createdBy" class="container text-h8">
|
||||||
<q-icon name="fas fa-lightbulb" class="iconcirc"></q-icon>
|
<q-icon name="fas fa-lightbulb" class="iconcirc"></q-icon>
|
||||||
{{
|
{{
|
||||||
$t('shared.createddate', {
|
$t('shared.createddate', {
|
||||||
@@ -913,15 +937,17 @@
|
|||||||
tools.getstrDate(circuit.date_updated) !==
|
tools.getstrDate(circuit.date_updated) !==
|
||||||
tools.getstrDate(circuit.date_created)
|
tools.getstrDate(circuit.date_created)
|
||||||
"
|
"
|
||||||
class="container"
|
class="container text-h8"
|
||||||
>
|
>
|
||||||
<q-icon name="fas fa-pencil-alt" class="iconcirc"></q-icon>
|
<q-icon name="fas fa-pencil-alt" class="iconcirc"></q-icon>
|
||||||
<span class="element">{{
|
<span class="element text-h8">{{
|
||||||
$t('shared.lastmodify', {
|
$t('shared.lastmodify', {
|
||||||
date: tools.getstrDateYY(circuit.date_updated),
|
date: tools.getstrDateYY(circuit.date_updated),
|
||||||
})
|
})
|
||||||
}}</span>
|
}}</span>
|
||||||
|
<br>
|
||||||
</div>
|
</div>
|
||||||
|
<br>
|
||||||
</q-card>
|
</q-card>
|
||||||
</q-tab-panel>
|
</q-tab-panel>
|
||||||
|
|
||||||
@@ -1028,15 +1054,15 @@
|
|||||||
<q-tab-panel name="comunitario">
|
<q-tab-panel name="comunitario">
|
||||||
<q-card v-if="circuit.name">
|
<q-card v-if="circuit.name">
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="text-h6">{{ t('circuit.contocomunitario') }}:</div>
|
<div class="text-h7">{{ t('circuit.contocomunitario') }}:</div>
|
||||||
<div class="text-h7 q-mb-sm">
|
<div class="text-h8 q-mb-sm">
|
||||||
{{ $t('circuit.info_contocom') }}
|
{{ $t('circuit.info_contocom') }}
|
||||||
</div>
|
</div>
|
||||||
</q-card-section>
|
</q-card-section>
|
||||||
<q-separator />
|
<q-separator />
|
||||||
|
|
||||||
<q-card-section>
|
<q-card-section>
|
||||||
<div class="col-12 text-h7 text-center">
|
<div class="col-12 text-h8 text-center">
|
||||||
<span v-if="checkifShow('descr')">
|
<span v-if="checkifShow('descr')">
|
||||||
<CSaldo
|
<CSaldo
|
||||||
v-if="tools.isUserOk() && circuit.account"
|
v-if="tools.isUserOk() && circuit.account"
|
||||||
@@ -1120,13 +1146,13 @@
|
|||||||
animation="fade"
|
animation="fade"
|
||||||
/>
|
/>
|
||||||
<q-card flat bordered style="width: 250px">
|
<q-card flat bordered style="width: 250px">
|
||||||
<div class="text-h6">
|
<div class="text-h7">
|
||||||
<q-skeleton :animation="animation" />
|
<q-skeleton :animation="animation" />
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 text-h7 text-grey text-center">
|
<div class="col-12 text-h8 text-grey text-center">
|
||||||
{{ path }}
|
{{ path }}
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 text-h7">
|
<div class="col-12 text-h8">
|
||||||
<q-skeleton :animation="animation" />
|
<q-skeleton :animation="animation" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -58,6 +58,8 @@ export default defineComponent({
|
|||||||
const idnotif = computed(() => $route.query.idnotif ? $route.query.idnotif.toString() : '')
|
const idnotif = computed(() => $route.query.idnotif ? $route.query.idnotif.toString() : '')
|
||||||
const isDebugOn = computed(() => tools.isDebugOn())
|
const isDebugOn = computed(() => tools.isDebugOn())
|
||||||
|
|
||||||
|
const sendRIS = computed(() => !!$route.query.sendris ? $route.query.sendris : 0)
|
||||||
|
|
||||||
const $router = useRouter()
|
const $router = useRouter()
|
||||||
const filtroutente = ref(<any[]>[])
|
const filtroutente = ref(<any[]>[])
|
||||||
const showPic = ref(false)
|
const showPic = ref(false)
|
||||||
@@ -210,6 +212,7 @@ export default defineComponent({
|
|||||||
globalStore,
|
globalStore,
|
||||||
getLinkWebSite,
|
getLinkWebSite,
|
||||||
gotoPage,
|
gotoPage,
|
||||||
|
sendRIS,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -641,6 +641,7 @@
|
|||||||
<CContactUser
|
<CContactUser
|
||||||
:myuser="userStore.userprofile"
|
:myuser="userStore.userprofile"
|
||||||
:showBtnActivities="true"
|
:showBtnActivities="true"
|
||||||
|
:sendRIS="sendRIS"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user