Primo committ Notevole
This commit is contained in:
481
src/root/home/home.ts
Normal file
481
src/root/home/home.ts
Normal file
@@ -0,0 +1,481 @@
|
||||
import Vue from 'vue'
|
||||
import { Component } from 'vue-property-decorator'
|
||||
import { GlobalStore, UserStore } from '@store'
|
||||
|
||||
import { Logo } from '../../components/logo'
|
||||
|
||||
import { Footer } from '../../components/Footer'
|
||||
import { CMyPage } from '../../components/CMyPage/index'
|
||||
|
||||
import VueScrollReveal from 'vue-scroll-reveal'
|
||||
import { tools } from '@src/store/Modules/tools'
|
||||
import { func_tools, toolsext } from '@src/store/Modules/toolsext'
|
||||
import { Screen } from 'quasar'
|
||||
import MixinMetaTags from '@src/mixins/mixin-metatags'
|
||||
import { CCardCarousel, CEventsCalendar, CImgText, COpenStreetMap, CTitleBanner } from '@components'
|
||||
import MixinBase from '@src/mixins/mixin-base'
|
||||
|
||||
Vue.use(VueScrollReveal, {
|
||||
class: 'v-scroll-reveal', // A CSS class applied to elements with the v-scroll-reveal directive; useful for animation overrides.
|
||||
duration: 1200,
|
||||
scale: 0.95,
|
||||
distance: '10px',
|
||||
rotate: {
|
||||
x: 0,
|
||||
y: 0,
|
||||
z: 0
|
||||
}
|
||||
// mobile: true
|
||||
})
|
||||
|
||||
@Component({
|
||||
mixins: [MixinBase],
|
||||
components: { Logo, Footer, CMyPage, CCardCarousel, CEventsCalendar, COpenStreetMap, CTitleBanner, CImgText }
|
||||
})
|
||||
export default class Home extends MixinBase {
|
||||
public text: string = ''
|
||||
public visibile: boolean = false
|
||||
public cardvisible: string = 'hidden'
|
||||
public displaycard: string = 'block'
|
||||
public $t: any
|
||||
// public firstClassSection: string = 'landing_background fade homep-cover-img animate-fade homep-cover-img-1'
|
||||
public firstClassSection: string = 'fade homep-cover-img animate-fade homep-cover-img-1'
|
||||
public $q
|
||||
public polling
|
||||
public slide = 'first'
|
||||
public slide_video = 'mp4_1'
|
||||
public mysteps = 0
|
||||
public myaudio = 0
|
||||
public mytestimonianze = 0
|
||||
public slide2 = 0
|
||||
public animare: number = 0
|
||||
public endload: boolean = false
|
||||
|
||||
public arrsteps = [
|
||||
{
|
||||
label: '1',
|
||||
value: 0,
|
||||
title: {
|
||||
it: '<strong>Giorno 1 - Contributore Finanziario</strong><br><br>' +
|
||||
'Entro nella chat, dono <strong>33€</strong> e ho già <strong>trovato 2 persone</strong> che vogliono partecipare al gioco.',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
myicon: 'fas fa-donate',
|
||||
},
|
||||
{
|
||||
label: '2',
|
||||
value: 1,
|
||||
title: {
|
||||
it: '<strong>Giorno 2 - Contributore solidale</strong><br><br>' +
|
||||
'Inserisco nella chat le mie 2 persone che verseranno i 33€.',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
myicon: 'fas fa-user-friends',
|
||||
myicon2: 'fas fa-coins'
|
||||
},
|
||||
{
|
||||
label: '3',
|
||||
value: 2,
|
||||
title: {
|
||||
it: '<strong>Giorno 3 - Tesoriere/segretario</strong><br><br>' +
|
||||
'Collaborare, aggiornare doni, fornire informazioni, ma anche conoscersi, condividere esperienze, passioni e sogni.',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
myicon: 'fas fa-piggy-bank',
|
||||
myicon2: 'far fa-laugh',
|
||||
myicon3: 'far fa-comments'
|
||||
},
|
||||
{
|
||||
label: '4',
|
||||
value: 3,
|
||||
title: {
|
||||
it: '<strong>Giorno 4 - Apertura tua Billettera</strong><br>' +
|
||||
'Creo il mio gruppo Whatsapp nel quale entrano i miei 2 ospiti, i 2 ospiti dei miei 2 ospiti, che porteranno altre 8 persone (4x2).<br>' +
|
||||
'<br>Ricevuti i 33€ da queste 8 persone (264€), mi tengo i mei <strong>iniziali 33€</strong> e <strong>dono 231 €</strong> alla Billettera "Mas Antigua".',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
myicon: 'fab fa-whatsapp',
|
||||
myicon2: 'fas fa-wallet'
|
||||
},
|
||||
{
|
||||
label: '5-6-7-8',
|
||||
value: 4,
|
||||
title: {
|
||||
it: '<strong>Giorno 5-6-7-8</strong><br>' +
|
||||
'Aspetto, da parte delle 8 nuove Billettere, le donazioni di 231€, per un totale di <strong>1848€</strong>.<br>' +
|
||||
'<br>Ringrazio l\'<strong>Universo</strong> per il <strong>dono</strong> ricevuto e fornisco <strong>aiuto</strong> a chi ne ha bisogno.<br>' +
|
||||
'Se desidero, posso <strong>ricominciare</strong> il gioco!',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
myicon: 'far fa-clock',
|
||||
myicon2: 'fas fa-euro-sign',
|
||||
myicon3: 'fas fa-praying-hands',
|
||||
myimg: '/' + tools.getimglogo(),
|
||||
}
|
||||
]
|
||||
|
||||
public todownload = {
|
||||
it: [
|
||||
{
|
||||
title: 'Billettera (passi 1-2-3).jpg',
|
||||
file: 'statics/images/it/Billetera_step_1_2_3.jpg'
|
||||
},
|
||||
{
|
||||
title: 'Billettera (passo 4).jpg',
|
||||
file: 'statics/images/it/Billetera_step_4.jpg'
|
||||
},
|
||||
{
|
||||
title: 'Passi semplificati.jpg',
|
||||
file: 'statics/images/it/passi_semplificati.jpg'
|
||||
},
|
||||
{
|
||||
title: 'Spiegazione (PDF)',
|
||||
file: 'statics/files/it/Billetera_spiegazione.pdf'
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
public audiofiles = {
|
||||
it: [
|
||||
{
|
||||
title: 'Chiara (1)',
|
||||
label: '1',
|
||||
value: 0,
|
||||
src: 'statics/audio/it/spiegazione_Billettera.mp3',
|
||||
type: 'audio/mp3'
|
||||
},
|
||||
{
|
||||
title: 'Altro',
|
||||
label: '2',
|
||||
value: 1,
|
||||
src: 'statics/audio/it/spiegazione_Billettera_2.mp3',
|
||||
type: 'audio/mp3'
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
public testimonianze = {
|
||||
it: [
|
||||
{
|
||||
title: '1. Giovanni',
|
||||
label: '1',
|
||||
value: 0,
|
||||
text: '<p>Amici di questa meravigliosa Billettera, mi permetto di dare un mio punto di vista a ' +
|
||||
'questo meraviglioso gruppo di amici che si stanno sostenendo a partecipare <strong>donando e ricevendo</strong> questo dono economico. ' +
|
||||
'In questo progetto bisogna entrarci con il <strong>cuore</strong>, in questo gioco di economia circolare, e non con la mente.</p>' +
|
||||
'<p>L\'ego mentale che ha costruito il giro di denaro sul potere, sul ricevere soldi dal lavoro, sull\'arrivismo, sullo scambiare ore della propria vita con denaro,' +
|
||||
' e solitamente dalla competizione e dalla fatica, non può concepire che <strong>si può donare dei soldi ad amici conosciuti e sconosciuti e ricevere altrettanti doni indietro</strong>, ' +
|
||||
'anche in denaro, da altri amici, che ti permetteranno di gioire di questa ricchezza economica che arriva solo da fatto che si possono utilizzare ' +
|
||||
'i soldi anche con gesti di puro Amore.</p> ' +
|
||||
'<p>Quando lo proponete ad amici è naturale che vi sentirete chiedere : <em>"Una piramide, dov\'è la fregatura?"</em><br>' +
|
||||
'Personalmente io parlo della mia esperienza, che sono felice di fare un dono di 33€ e di riceverne altrettanti e non vedo dove sta il problema.<br> ' +
|
||||
'Forse il sentirsi dire dei no, ci rimanda subito al mentale che si sente rifiutato ed entra subito nel giudizio negativo per se e verso gli altri,' +
|
||||
'questo è un gioco che ci aiuterà a vedere tante facce dell\'ego che boicotterà, che ci depisterà, che ci illuderà, ma dietro a tutto questo ' +
|
||||
'ci sta l\'Amore e la Consapevolezza che ci aiuteranno ad andare oltre e a procedere verso questa nuova esperienza di scambi di doni tra belle ' +
|
||||
'anime che stanno già condividendo e sostenendosi a vicenda per portare una nuova visione sull\'<strong>economia circolare dei soldi</strong>.</p>' +
|
||||
'<p>Insomma questa è una chance, per riprendere anche gli <strong>schemi già visti</strong> di scambi a diversi livelli, ma con tutta la nuova tecnologia che ' +
|
||||
'abbiamo a disposizione, che ci aiuta a <strong>rimanere connessi continuamente</strong>, e con la nuova consapevolezza che finalmente l\'essere umano sta ' +
|
||||
'raggiungendo, e di usarli, i network, per <strong>ridistribuire</strong>, anche se solo in piccola parte, <strong>un po\' di regali, gioia, amore, amicizia e denaro ' +
|
||||
'sul pianeta</strong>.</p>' +
|
||||
'<p>Questa billetera è una vera chance di <strong>cooperazione ad una ottava superiore</strong>, che porta con sé, anche molti <strong>regali</strong> di consapevolezza, ' +
|
||||
'crescita correttezza, precisione, onestà, cooperazione, amore.</p>',
|
||||
},
|
||||
{
|
||||
title: '2. Luca',
|
||||
label: '2',
|
||||
value: 1,
|
||||
text: ''
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
public advise = [
|
||||
{
|
||||
title: {
|
||||
it: 'La forza di questo gioco sono le Persone e la Collaborazione. Non siate timidi e scrivete agli amici su whatsapp, facebook, Telegram',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
color: 'white', icon: 'fas fa-hands-helping',
|
||||
textcolor: 'black'
|
||||
},
|
||||
{
|
||||
title: {
|
||||
it: 'È un lavoro di squadra ma in cui ognuno deve assolutamente fare la sua parte<br>' +
|
||||
'La parte di ognuno in questo gioco è fare il dono e portare due persone<br>' +
|
||||
'Se manca una di queste due parti il gioco si ferma',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
color: 'white',
|
||||
icon: 'fas fa-users',
|
||||
textcolor: 'black'
|
||||
},
|
||||
{
|
||||
title: {
|
||||
it: 'Per me personalmente la sto vivendo anche come una bellissima opportunità di risentire ' +
|
||||
'vecchi amici che non sento da tempo, ed avere un intento comune, anche solo un giochino, ci ' +
|
||||
'da di nuovo la possibilità di sentirci e di riconnetterci.<br>',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
color: 'white',
|
||||
icon: 'fas fa-hand-holding-heart',
|
||||
textcolor: 'black'
|
||||
},
|
||||
{
|
||||
title: {
|
||||
it: 'Dietro ogni amico che anche non sentire da un bel pò, c\'è la possibilità di ' +
|
||||
'riscoprire la gioia ed il motivo che vi ha fatti essere amici, anche molto tempo fa',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
color: 'white',
|
||||
icon: 'far fa-smile-beam',
|
||||
textcolor: 'black'
|
||||
},
|
||||
{
|
||||
title: {
|
||||
it: 'Ieri sera sono entrati nella mia Billettera 1 persona, che ne ha portate subito altre 2, che ' +
|
||||
'non sentivo da secoli, portando una gran gioia ed energia ed entusiasmo.<br> ' +
|
||||
'E\' stato molto bello risentirli 😊 <br>' +
|
||||
'Se non gli avessi scritto, non sarebbe mai successo.<br>',
|
||||
es: '',
|
||||
enUs: ''
|
||||
},
|
||||
color: 'white',
|
||||
icon: 'far fa-sun',
|
||||
textcolor: 'black'
|
||||
},
|
||||
|
||||
]
|
||||
|
||||
|
||||
constructor() {
|
||||
super()
|
||||
// console.log('Home constructor...')
|
||||
this.initprompt()
|
||||
}
|
||||
|
||||
public meta() {
|
||||
return tools.metafunc(this)
|
||||
}
|
||||
|
||||
get isVerified() {
|
||||
return UserStore.state.my.verified_email
|
||||
}
|
||||
|
||||
get tools() {
|
||||
return tools
|
||||
}
|
||||
|
||||
public mounted() {
|
||||
|
||||
let primo = true
|
||||
const mytime = 10000
|
||||
this.polling = setInterval(() => {
|
||||
|
||||
this.firstClassSection = 'landing_background fade homep-cover-img ' + (primo ? 'homep-cover-img-2' : 'homep-cover-img-1')
|
||||
primo = !primo
|
||||
|
||||
// console.log('this.firstClassSection', this.firstClassSection)
|
||||
|
||||
}, mytime)
|
||||
}
|
||||
|
||||
public beforeDestroy() {
|
||||
// console.log('beforeDestroy')
|
||||
clearInterval(this.polling)
|
||||
}
|
||||
|
||||
public created() {
|
||||
this.animare = process.env.DEV ? 0 : 8000
|
||||
|
||||
GlobalStore.actions.prova()
|
||||
|
||||
this.endload = true
|
||||
}
|
||||
|
||||
get isLogged() {
|
||||
return UserStore.state.isLogged
|
||||
}
|
||||
|
||||
public mystilecard() {
|
||||
return {
|
||||
visibility: this.cardvisible,
|
||||
display: this.displaycard
|
||||
}
|
||||
}
|
||||
|
||||
get conta() {
|
||||
return GlobalStore.state.conta
|
||||
}
|
||||
|
||||
public getenv(myvar) {
|
||||
return process.env[myvar]
|
||||
}
|
||||
|
||||
set conta(valore) {
|
||||
GlobalStore.actions.setConta(valore)
|
||||
const my = this.$q.lang.isoName
|
||||
tools.showNotif(this.$q, String(my))
|
||||
}
|
||||
|
||||
public initprompt() {
|
||||
window.addEventListener('beforeinstallprompt', (event) => {
|
||||
// console.log('******************************** beforeinstallprompt fired')
|
||||
event.preventDefault()
|
||||
// console.log('§§§§§§§§§§§§§§§§§§§§ IMPOSTA DEFERRED PROMPT !!!!!!!!!!!!!!!!! ')
|
||||
// #Todo++ IMPOSTA DEFERRED PROMPT
|
||||
return false
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
get isInCostruction() {
|
||||
return process.env.IN_CONSTRUCTION === '1'
|
||||
}
|
||||
|
||||
public getPermission() {
|
||||
return Notification.permission
|
||||
}
|
||||
|
||||
public NotServiceWorker() {
|
||||
return (!('serviceWorker' in navigator))
|
||||
}
|
||||
|
||||
public PagLogin() {
|
||||
this.$router.replace('/signin')
|
||||
}
|
||||
|
||||
public PagReg() {
|
||||
this.$router.replace('/signup')
|
||||
}
|
||||
|
||||
public openCreatePostModal() {
|
||||
console.log('APERTO ! openCreatePostModal')
|
||||
|
||||
this.conta = this.conta + 1
|
||||
|
||||
this.visibile = !this.visibile
|
||||
|
||||
if (this.visibile) {
|
||||
this.displaycard = 'block'
|
||||
this.cardvisible = 'visible'
|
||||
} else {
|
||||
this.displaycard = 'block'
|
||||
this.cardvisible = 'hidden'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
get getappname() {
|
||||
return tools.getappname(this, false)
|
||||
}
|
||||
|
||||
get getArrDisciplines() {
|
||||
return GlobalStore.state.disciplines.filter((rec) => rec.showinhome)
|
||||
}
|
||||
|
||||
public getpath(myvideo) {
|
||||
return 'statics/video/' + func_tools.getLocale() + '/' + myvideo
|
||||
}
|
||||
|
||||
public getkey(youtube, title, isnum) {
|
||||
let mykey = 'MP4'
|
||||
if (youtube)
|
||||
mykey = 'YT'
|
||||
|
||||
if (isnum) {
|
||||
mykey += '_NUM'
|
||||
} else {
|
||||
if (title)
|
||||
mykey += '_TITLE_'
|
||||
else
|
||||
mykey += '_VIDEO_'
|
||||
}
|
||||
|
||||
return mykey
|
||||
}
|
||||
|
||||
public getvideourl(index, youtube) {
|
||||
const myvideo = this.getValDb(this.getkey(youtube, false, false) + index, false)
|
||||
if (myvideo)
|
||||
return this.getpath(myvideo)
|
||||
else
|
||||
return ''
|
||||
}
|
||||
|
||||
public getvideonum(youtube) {
|
||||
return this.getValDb(this.getkey(youtube, false, true), false)
|
||||
}
|
||||
|
||||
public mygetarrValDb(keystr, serv) {
|
||||
const myval = GlobalStore.getters.getValueSettingsByKey(keystr, serv)
|
||||
// console.log('AA: myval', myval)
|
||||
try {
|
||||
if (myval) {
|
||||
// console.log(' Entro')
|
||||
const myrec = JSON.parse(myval)
|
||||
// console.log('*************** getarrValDb')
|
||||
// console.table(myrec)
|
||||
return myrec
|
||||
} else {
|
||||
// console.log('NO MYVAL')
|
||||
return []
|
||||
}
|
||||
} catch (e) {
|
||||
console.log('Errore: ', e)
|
||||
return []
|
||||
}
|
||||
}
|
||||
|
||||
public getvideotitle(index, youtube) {
|
||||
|
||||
const mykey = this.getkey(youtube, true, false) + index
|
||||
const ris = this.mygetarrValDb(mykey, false)
|
||||
|
||||
return tools.getelembylang(ris)
|
||||
}
|
||||
|
||||
public gettitle_advise(rec) {
|
||||
return rec.title[tools.getLocale()]
|
||||
}
|
||||
|
||||
public geticonlist(rec) {
|
||||
if (rec.icon) {
|
||||
return rec.icon
|
||||
} else {
|
||||
return 'fas fa-info'
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public getaudiofiles() {
|
||||
return this.audiofiles[tools.getLocale()]
|
||||
}
|
||||
|
||||
public gettestimonianze() {
|
||||
return this.testimonianze[tools.getLocale()]
|
||||
}
|
||||
|
||||
public getvideomp4src(index) {
|
||||
return [{ src: this.getvideourl(index, false), type: 'video/mp4' }
|
||||
]
|
||||
}
|
||||
|
||||
public getvideoposter(index) {
|
||||
return ''
|
||||
}
|
||||
|
||||
public getfileimgdown(rec) {
|
||||
return rec.file[tools.getLocale()]
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user