From fd864ce63704a4bb8008d21e9cfc60e72faef7cf Mon Sep 17 00:00:00 2001 From: Paolo Arena Date: Tue, 5 Mar 2019 23:47:00 +0100 Subject: [PATCH 1/3] Delete .env.development --- .env.development | 16 ---------------- 1 file changed, 16 deletions(-) delete mode 100644 .env.development diff --git a/.env.development b/.env.development deleted file mode 100644 index 211e8d9..0000000 --- a/.env.development +++ /dev/null @@ -1,16 +0,0 @@ -APP_VERSION="0.0.47" -SERVICE_WORKER_FILE='service-worker.js' -APP_ID='1' -APP_URL='https://freeplanet.app' -PROVA_PAOLO='PROVA SVILUPPO' -LANG_DEFAULT='it' -PAO_APP_ID='KKPPAA5KJK435J3KSS9F9D8S9F8SD98F9SDF' -MASTER_KEY='KKPPSS5KJK435J3KSS9F9D8S9F8SD3CR3T' -MONGODB_HOST='http://localhost:3000' -LOGO_REG="freeplanet-logo-full.svg" -TEST_EMAIL='paolo.arena77@gmail.com' -TEST_USERNAME='paoloar77' -TEST_PASSWORD='mypassword@1A' -PUBLICKEY_PUSH='BGxRrFWnPoa_ImUaWXmeEOFVI9VNKVKaAPsvsM1XY6wn24yxp9MyOQ4crNYCJKxSXV65Y1GblW5_VLoamedcZ1I' -IN_CONSTRUCTION='0' -DEBUG='1' From e42ca08c8fdb76f774a1f1e3c0ceda403c11e039 Mon Sep 17 00:00:00 2001 From: Paolo Arena Date: Mon, 23 Sep 2019 21:06:42 +0200 Subject: [PATCH 2/3] Start Booking Events --- cfg_locale | 1 - src/components/CImgText/CImgText.ts | 1 + src/components/CImgText/CImgText.vue | 1 + src/components/Footer/Footer.vue | 4 +- .../FormNewsletter/FormNewsletter.vue | 2 +- src/components/Header/Header.ts | 8 +-- src/components/Header/Header.vue | 6 +- src/model/Calendar.ts | 11 ++++ src/model/GlobalStore.ts | 11 ++++ src/model/index.ts | 3 + src/statics/i18n.js | 19 +++++- src/store/Modules/Projects.ts | 3 +- .../Modules/Store/calendar/CalendarStore.ts | 58 +++++++++++++------ src/store/Modules/Todos.ts | 2 +- src/store/Modules/UserStore.ts | 7 ++- src/store/Modules/index.ts | 1 + 16 files changed, 103 insertions(+), 35 deletions(-) delete mode 120000 cfg_locale diff --git a/cfg_locale b/cfg_locale deleted file mode 120000 index 73cc88f..0000000 --- a/cfg_locale +++ /dev/null @@ -1 +0,0 @@ -cfg_freeplanet.app/ \ No newline at end of file diff --git a/src/components/CImgText/CImgText.ts b/src/components/CImgText/CImgText.ts index cc7dd65..81926c6 100644 --- a/src/components/CImgText/CImgText.ts +++ b/src/components/CImgText/CImgText.ts @@ -25,6 +25,7 @@ import { Screen } from 'quasar' }) export default class CImgText extends Vue { @Prop({ required: false, default: '' }) public src: string + @Prop({ required: false, default: '' }) public src2: string @Prop({ required: false, default: 'myclimg' }) public class1: string @Prop({ required: false, default: '' }) public style1: string } diff --git a/src/components/CImgText/CImgText.vue b/src/components/CImgText/CImgText.vue index bffb077..5d81384 100644 --- a/src/components/CImgText/CImgText.vue +++ b/src/components/CImgText/CImgText.vue @@ -4,6 +4,7 @@
+
diff --git a/src/components/Footer/Footer.vue b/src/components/Footer/Footer.vue index 00effad..f1810d0 100644 --- a/src/components/Footer/Footer.vue +++ b/src/components/Footer/Footer.vue @@ -10,7 +10,7 @@ - @@ -52,7 +52,7 @@

- {{$t('privacy_policy')}} + {{$t('privacy_policy')}}

diff --git a/src/components/FormNewsletter/FormNewsletter.vue b/src/components/FormNewsletter/FormNewsletter.vue index cb6bec1..8fbcc2c 100644 --- a/src/components/FormNewsletter/FormNewsletter.vue +++ b/src/components/FormNewsletter/FormNewsletter.vue @@ -41,7 +41,7 @@ - $t('newsletter.acceptlicense') + {{$t('privacy_policy')}} diff --git a/src/components/Header/Header.ts b/src/components/Header/Header.ts index b446300..ff0e50a5 100644 --- a/src/components/Header/Header.ts +++ b/src/components/Header/Header.ts @@ -68,12 +68,12 @@ export default class Header extends Vue { } // ------------------------------------------------------------------------- - // QUASAR Example using event to open drawer from another component or page + // QUASAR Example using myevent to open drawer from another component or page // ------------------------------------------------------------------------- // (1) This code is inside layout file that have a drawer // if this.leftDrawerOpen is true, drawer is displayed - // (2) Listen for an event in created + // (2) Listen for an myevent in created /* created(){ this.$root.$on("openLeftDrawer", this.openLeftDrawercb); }, @@ -85,7 +85,7 @@ export default class Header extends Vue { } } - // (4) In another component or page, emit the event! + // (4) In another component or page, emit the myevent! // Call the method when clicking button etc. methods: { openLeftDrawer() { @@ -160,7 +160,7 @@ export default class Header extends Vue { const color = (value === 'online') ? 'positive' : 'warning' - if (this.static_data.SHOW_IF_IS_SERVER_CONNECTION) { + if (this.static_data.functionality.SHOW_IF_IS_SERVER_CONNECTION) { if (!!oldValue) { tools.showNotif(this.$q, this.$t('connection') + ` ${value}`, { diff --git a/src/components/Header/Header.vue b/src/components/Header/Header.vue index 89e8016..cf005c8 100644 --- a/src/components/Header/Header.vue +++ b/src/components/Header/Header.vue @@ -58,7 +58,7 @@ --> {{ $t('msg.hello') }} ! --> - + @@ -121,7 +121,7 @@ - +
diff --git a/src/model/Calendar.ts b/src/model/Calendar.ts index 9da46e4..79c90cc 100644 --- a/src/model/Calendar.ts +++ b/src/model/Calendar.ts @@ -1,5 +1,6 @@ export interface IEvents { + _id?: any time?: string duration?: number duration2?: number @@ -18,9 +19,19 @@ export interface IEvents { avatar2?: string infoextra?: string linkpdf?: string + nobookable?: boolean +} + +export interface IBookedEvent { + id_bookedevent: any + numpeople: number } export interface ICalendarState { + editable: boolean + eventlist: IEvents[] + bookedevent: IBookedEvent[] + // --------------- titlebarHeight: number locale: string, maxDays: number, diff --git a/src/model/GlobalStore.ts b/src/model/GlobalStore.ts index 6f19060..ad84035 100644 --- a/src/model/GlobalStore.ts +++ b/src/model/GlobalStore.ts @@ -166,6 +166,7 @@ export interface IColl { date: string subtitle?: IAllLang img: string + img2?: string linkagg?: string linkagg_type?: number width?: number @@ -176,3 +177,13 @@ export interface ICollaborations { withwhom_title: IAllLang list: IColl[] } + +export interface IFunctionality { + SHOW_USER_MENU?: boolean + SHOW_IF_IS_SERVER_CONNECTION?: boolean + ENABLE_TODOS_LOADING?: boolean + ENABLE_PROJECTS_LOADING?: boolean + SHOW_NEWSLETTER?: boolean + SHOW_ONLY_POLICY?: boolean + EVENTS_CAN_BOOKING?: false +} diff --git a/src/model/index.ts b/src/model/index.ts index dcb8eb8..57b0309 100644 --- a/src/model/index.ts +++ b/src/model/index.ts @@ -1,3 +1,5 @@ +import { IBookingState } from '@src/model/BookingStore' + export * from './UserStore' export * from './GlobalStore' export * from './signin-option' @@ -11,3 +13,4 @@ export * from './Projects' export * from './Calendar' export * from './Estimate' +export * from './BookingStore' diff --git a/src/statics/i18n.js b/src/statics/i18n.js index e944c0e..5016ec2 100644 --- a/src/statics/i18n.js +++ b/src/statics/i18n.js @@ -151,6 +151,9 @@ const msgglobal = { themebgcolor: 'Tema Colore Sfondo' }, cal: { + booked: 'Prenotato', + booking: 'Prenota Evento', + cancelbooking: 'Cancella Prenotazione', event: 'Evento', starttime: 'Dalle', endtime: 'alle', @@ -327,6 +330,9 @@ const msgglobal = { themebgcolor: 'Tema Colores Fondo' }, cal: { + booked: 'Reservado', + booking: 'Reserva Evento', + cancelbooking: 'Cancelar Reserva', event: 'Evento', starttime: 'Inicio', endtime: 'fin', @@ -502,6 +508,9 @@ const msgglobal = { themebgcolor: 'Tema Colores Fondo' }, cal: { + booked: 'Réservé', + booking: 'Réserver l\'événement', + cancelbooking: 'Annuler la réservation', event: 'événement', starttime: 'Accueil', endtime: 'fin', @@ -676,6 +685,9 @@ const msgglobal = { themebgcolor: 'Theme Color Background' }, cal: { + booked: 'Booked', + booking: 'Book the Event', + cancelbooking: 'Cancel Reservation', event: 'Event', starttime: 'From', endtime: 'to', @@ -687,7 +699,7 @@ const msgglobal = { enterdate: 'Enter date', details: 'Details', infoextra: 'Extra Info DateTime', - alldayevent: 'All-Day event', + alldayevent: 'All-Day myevent', eventstartdatetime: 'Event start date and time', enterEndDateTime: 'Event end date and time' }, @@ -852,6 +864,9 @@ const msgglobal = { themebgcolor: 'Theme Color Background' }, cal: { + booked: 'Booked', + booking: 'Book the Event', + cancelbooking: 'Cancel Reservation', event: 'Event', starttime: 'From', endtime: 'to', @@ -863,7 +878,7 @@ const msgglobal = { enterdate: 'Enter date', details: 'Details', infoextra: 'Extra Info DateTime', - alldayevent: 'All-Day event', + alldayevent: 'All-Day myevent', eventstartdatetime: 'Event start date and time', enterEndDateTime: 'Event end date and time' }, diff --git a/src/store/Modules/Projects.ts b/src/store/Modules/Projects.ts index 4b28255..599b6d3 100644 --- a/src/store/Modules/Projects.ts +++ b/src/store/Modules/Projects.ts @@ -274,7 +274,7 @@ namespace Actions { async function dbLoad(context, { checkPending, onlyiffirsttime }) { - if (!static_data.ENABLE_PROJECTS_LOADING) + if (!static_data.functionality.ENABLE_PROJECTS_LOADING) return null if (onlyiffirsttime) { @@ -442,7 +442,6 @@ namespace Actions { modify: b.dispatch(modify), ActionCutPaste: b.dispatch(ActionCutPaste) } - } // Module diff --git a/src/store/Modules/Store/calendar/CalendarStore.ts b/src/store/Modules/Store/calendar/CalendarStore.ts index 5d25538..f36a6bc 100644 --- a/src/store/Modules/Store/calendar/CalendarStore.ts +++ b/src/store/Modules/Store/calendar/CalendarStore.ts @@ -1,5 +1,5 @@ import Api from '@api' -import { ICalendarState } from 'model' +import { ICalendarState, IEvents } from 'model' import { ILinkReg, IResult, IIdToken, IToken } from 'model/other' import { storeBuilder } from '../Store' @@ -8,9 +8,14 @@ import { tools } from '../../tools' import translate from '../../../../globalroutines/util' import * as Types from '../../../Api/ApiTypes' +import { db_data } from '@src/db/db_data' // State const state: ICalendarState = { + editable: false, + eventlist: [], + bookedevent: [], + // --------------- titlebarHeight: 0, locale: 'it-IT', maxDays: 1, @@ -39,19 +44,15 @@ const stateGetter = b.state() namespace Getters { - // const lang = b.read((state) => { - // if (state.lang !== '') { - // return state.lang - // } else { - // return process.env.LANG_DEFAULT - // } - // }, 'lang') - // - // export const getters = { - // get lang() { - // return lang() - // }, - // } + const findEventBooked = b.read((mystate) => (myevent: IEvents) => { + return mystate.bookedevent.find((bookedevent) => bookedevent.id_bookedevent === myevent._id) + }, 'findEventBooked') + + export const getters = { + get findEventBooked() { + return findEventBooked() + } + } } @@ -67,6 +68,29 @@ namespace Mutations { } namespace Actions { + async function loadAfterLogin(context) { + // Load local data + state.editable = db_data.userdata.calendar_editable + state.eventlist = db_data.events + state.bookedevent = db_data.userdata.bookedevent + } + + async function BookEvent(context, event: IEvents) { + console.log('BookEvent', event) + state.bookedevent.push({id_bookedevent: event._id, numpeople: 1}) + } + + async function CancelBookingEvent(context, event: IEvents) { + console.log('CancelBookingEvent', event) + + state.bookedevent = state.bookedevent.filter((eventbooked) => (eventbooked.id_bookedevent !== event._id) ) + } + + export const actions = { + loadAfterLogin: b.dispatch(loadAfterLogin), + BookEvent: b.dispatch(BookEvent), + CancelBookingEvent: b.dispatch(CancelBookingEvent) + } // async function resetpwd(context, paramquery: ICalendarState) { // } @@ -80,9 +104,9 @@ namespace Actions { const CalendarModule = { get state() { return stateGetter() - } - // actions: Actions.actions, - // getters: Getters.getters, + }, + actions: Actions.actions, + getters: Getters.getters // mutations: Mutations.mutations } diff --git a/src/store/Modules/Todos.ts b/src/store/Modules/Todos.ts index 8fb2d1b..3335c7b 100644 --- a/src/store/Modules/Todos.ts +++ b/src/store/Modules/Todos.ts @@ -253,7 +253,7 @@ namespace Actions { async function dbLoad(context, { checkPending }) { - if (!static_data.ENABLE_PROJECTS_LOADING) + if (!static_data.functionality.ENABLE_PROJECTS_LOADING) return null console.log('dbLoad', nametable, checkPending, 'userid=', UserStore.state.userId) diff --git a/src/store/Modules/UserStore.ts b/src/store/Modules/UserStore.ts index 9be0d9d..0eaf30e 100644 --- a/src/store/Modules/UserStore.ts +++ b/src/store/Modules/UserStore.ts @@ -7,7 +7,7 @@ import router from '@router' import { serv_constants } from '../Modules/serv_constants' import { tools } from '../Modules/tools' import { toolsext } from '@src/store/Modules/toolsext' -import { GlobalStore, UserStore, Todos, Projects } from '@store' +import { GlobalStore, UserStore, Todos, Projects, BookingStore, CalendarStore } from '@store' import globalroutines from './../../globalroutines/index' import translate from './../../globalroutines/util' @@ -221,7 +221,6 @@ namespace Mutations { setErrorCatch: b.commit(setErrorCatch), getMsgError: b.commit(getMsgError) } - } namespace Actions { @@ -512,6 +511,7 @@ namespace Actions { } async function setGlobal(isLogged: boolean) { + // console.log('setGlobal') // state.isLogged = true state.isLogged = isLogged if (isLogged) { @@ -522,6 +522,9 @@ namespace Actions { GlobalStore.actions.checkUpdates() } + const p = await BookingStore.actions.loadAfterLogin() + const p2 = await CalendarStore.actions.loadAfterLogin() + return await GlobalStore.actions.loadAfterLogin() .then(() => { return Todos.actions.dbLoad({ checkPending: true }) diff --git a/src/store/Modules/index.ts b/src/store/Modules/index.ts index 941c962..f31ecf1 100644 --- a/src/store/Modules/index.ts +++ b/src/store/Modules/index.ts @@ -1,5 +1,6 @@ export {storeBuilder} from './Store/Store' export {default as GlobalStore} from './GlobalStore' +export {default as BookingStore} from './BookingStore' export {default as UserStore} from './UserStore' export {default as Todos} from './Todos' export {default as Projects} from './Projects' From 0d6312ecda17b790d076958ee862594e5c03abea Mon Sep 17 00:00:00 2001 From: Paolo Arena Date: Sat, 5 Oct 2019 20:02:25 +0200 Subject: [PATCH 3/3] - Booking Event (with email to user and admin) - Cancel Event (with email to user and admin) - Store into mongodb --- package.json | 7 +- src/App.scss | 259 ++++++++++++++++-- src/App.ts | 16 +- src/App.vue | 5 + src/components/CImgText/CImgText.ts | 1 + src/components/CImgText/CImgText.vue | 1 + src/components/Footer/Footer.vue | 4 +- .../FormNewsletter/FormNewsletter.vue | 2 +- src/components/Header/Header.scss | 9 + src/components/Header/Header.ts | 14 +- src/components/Header/Header.vue | 12 +- src/db/static_data.ts | 9 +- src/model/Calendar.ts | 15 + src/model/GlobalStore.ts | 18 ++ src/model/UserStore.ts | 4 + src/model/index.ts | 3 + src/model/signup-option.ts | 2 + src/root/home/home.scss | 211 ++++++++------ src/root/home/home.ts | 6 +- src/root/home/home.vue | 2 + src/router/index.ts | 3 +- src/router/route-config.ts | 2 + src/statics/i18n.js | 84 +++++- src/store/Modules/Projects.ts | 3 +- .../Modules/Store/calendar/CalendarStore.ts | 136 +++++++-- src/store/Modules/Todos.ts | 2 +- src/store/Modules/UserStore.ts | 49 +++- src/store/Modules/costanti.ts | 4 + src/store/Modules/index.ts | 1 + src/store/Modules/tools.ts | 93 ++++++- src/store/Modules/toolsext.ts | 2 +- src/views/login/signup/signup-validate.ts | 6 + src/views/login/signup/signup.ts | 7 +- src/views/login/signup/signup.vue | 32 +++ 34 files changed, 852 insertions(+), 172 deletions(-) diff --git a/package.json b/package.json index d8e2e18..38e5405 100755 --- a/package.json +++ b/package.json @@ -28,7 +28,7 @@ "dependencies": { "@babel/plugin-transform-runtime": "^7.4.0", "@babel/runtime": "^7.0.0", - "@quasar/extras": "^1.3.1", + "@quasar/extras": "^1.3.2", "@types/vuelidate": "^0.7.0", "@vue/eslint-config-standard": "^4.0.0", "acorn": "^6.0.0", @@ -50,7 +50,7 @@ "normalize.css": "^8.0.0", "npm": "^6.10.1", "nprogress": "^0.2.0", - "quasar": "^1.1.0", + "quasar": "^1.1.6", "quasar-extras": "^2.0.8", "register-service-worker": "^1.0.0", "vee-validate": "^2.1.2", @@ -85,7 +85,8 @@ "@babel/plugin-syntax-dynamic-import": "^7.2.0", "@babel/plugin-syntax-import-meta": "^7.2.0", "@babel/preset-env": "^7.4.2", - "@quasar/app": "^1.0.6", + "@quasar/app": "^1.1.2", + "@quasar/quasar-app-extension-colorize": "^1.0.0-alpha.1", "@quasar/quasar-app-extension-typescript": "^1.0.0-alpha.11", "@types/dotenv": "^4.0.3", "@types/jest": "^23.1.4", diff --git a/src/App.scss b/src/App.scss index 1e94840..11310ea 100644 --- a/src/App.scss +++ b/src/App.scss @@ -1,3 +1,44 @@ +body { + font-family: 'Source Sans Pro', 'Helvetica Neue', Arial, sans-serif; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; + color: #a7a7a7; + line-height: 1.5; + //font-size: 1rem; +} + +html { + font-size: 100%; // default font size (browser 16) -> (10 62.5%) +} + +p { + font-size: 125%; // default font size (browser 16) -> (10 62.5%) + margin: 0 0 8px; +} + +$grayshadow: #555; + +$graytext: #555; + +$textcol: blue; +$textcol_scuro: darkblue; +$heightBtn: 100%; + +.flex-item { + // background-color: #d5e2eb; + display: flex; + padding: 2px; + margin: 2px; + margin-left: 3px; + margin-right: 3px; + color: #000; + font-size: 1rem; + height: $heightBtn; + line-height: $heightBtn; + vertical-align: middle; + //flex: 0 0 100%; +} + .fade-enter-active, .fade-leave-active { transition: opacity .2s; } @@ -40,7 +81,8 @@ } } -.my-notif-class { + +.my-notif-class{ font-weight: bold; } @@ -53,15 +95,14 @@ .lowperc { color: red; } - .medperc { color: blue; } - .highperc { color: green; } + .hide-if-small { @media (max-width: 600px) { display: none; @@ -74,24 +115,200 @@ } } -.tothebottomfixed { - left: 0; - right: 0; - position: fixed; - z-index: 9999; - box-sizing: border-box; - overflow: hidden; - margin: 0 auto; - bottom: 10px; +.links, .links a { + text-shadow: 1px 1px 1px #555 !important; + // font-weight: bold; + color: cornflowerblue !important; +} +.links:hover { + color: white !important; } -.tothetop { - left: 0; - right: 0; - position: fixed; - z-index: 9999; - box-sizing: border-box; - overflow: hidden; - margin: 0 auto; - top: 20px; +.text-subtitle1 { + font-size: 1.35rem; + font-weight: 400; + line-height: 1.75rem; + text-shadow: .25 .25rem .5rem $grayshadow; + letter-spacing: .00937em; + &.big { + font-size: 1.5rem; + } +} + +.text-subtitle2 { + font-size: 1.15rem; + font-weight: 400; + line-height: 1.75rem; + letter-spacing: .00937em; + text-shadow: .25rem .25rem .5rem $grayshadow; +} + +.text-subtitle3 { + font-size: 1rem; + font-weight: 400; + line-height: 1.75rem; + letter-spacing: .00937em; +} + + +@media (max-width: 718px) { + // PER VERSIONE MOBILE + + p { + font-size: 100%; // default font size (browser 16) -> (10 62.5%) + font-family: "Abyssinica SIL", serif; + text-justify: auto; + margin: 0 0 4px; + } + + .text-subtitle1 { + font-size: 1.25rem; + } + .text-subtitle2 { + font-size: 1rem; + } + .text-subtitle3 { + font-size: 0.75rem; + } + + .cltexth3 { + font-size: 1.25rem; + } + + .text-big{ + font-size: 1.25rem; + } + +} + +.my-card { + width: 100%; + max-width: 350px; + min-width: 300px; + padding: 1rem 1rem; + + box-shadow: none; +} + +.text-trans { + opacity: 0.9; + -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=90)"; + filter: alpha(opacity=90); +} + +.text-spacetrans { + padding: 0 !important; + background: rgba(0,0,0,0.3) !important; + border-radius: 30px !important; +} + +.text-shadow { + text-shadow: .15rem .15rem .15rem $grayshadow; +} + +.citazione{ + font-size: 0.75rem; + font-family: "Lucida Calligraphy", serif; +} + +.cltexth3, .cltexth2, .cltexth4 { + font-size: 1.25rem; + font-weight: 400; + line-height: 1.75rem; + letter-spacing: .01em; + text-align: center !important; +} + +.cltexth4 { + font-size: 1rem; +} + +.cltexth2 { + font-size: 1.5rem; +} + +.boldhigh, .boldop, .text-big{ + font-weight: 500; + text-shadow: .05rem .05rem .05rem $grayshadow; +} +.boldop{ + color: darkblue; +} + +.text-big{ + font-size: 1.5rem; +} + + + +.center_to_image{ + position: absolute; + left: 0; + top: 50%; + transform: translateY(-50%); + width: 100%; + text-align: center; +} + + +.center_img { + display: block; + margin-left: auto; + margin-right: auto; +} + +.padding_cell { + padding: 0.75rem 0.5rem; +} + +@media (max-width: 3000px) { + .q-parallax__media > img { + max-height: 550px !important; + min-width:inherit !important; + min-height: inherit !important; + } +} + +@media (max-width: 1000px) { + .q-parallax__media > img { + max-height: 500px !important; + min-width:inherit !important; + min-height: inherit !important; + } +} + +@media (max-width: 800px) { + .q-parallax__media > img { + max-height: 450px !important; + min-width:inherit !important; + min-height: inherit !important; + } +} + + +@media (max-width: 718px) { + .q-parallax__media > img { + max-height: 450px !important; + min-height: inherit !important; + min-width:100% !important; + } +} + +// preloading images: +@media screen { + div#preloader { + position: absolute; + left: -9999px; + top: -9999px; + } + div#preloader img { + display: block; + } +} +@media print { + div#preloader, + div#preloader img { + visibility: hidden; + display: none; + } } diff --git a/src/App.ts b/src/App.ts index 6602178..479254e 100644 --- a/src/App.ts +++ b/src/App.ts @@ -7,10 +7,14 @@ import { Header } from './components/Header' import globalroutines from './globalroutines/index' import { GlobalStore } from './store/Modules' +import { toolsext } from '@src/store/Modules/toolsext' +import { BannerCookies, CPreloadImages } from '@components' +import { static_data } from '@src/db/static_data' @Component({ components: { - appHeader: Header + appHeader: Header, + BannerCookies, CPreloadImages }, router }) @@ -47,7 +51,7 @@ export default class App extends Vue { // console.log('window.location.href', window.location.href) let chiamaautologin = true - this.listaRoutingNoLogin.forEach(mystr => { + this.listaRoutingNoLogin.forEach((mystr) => { if (window.location.href.includes(mystr)) { chiamaautologin = false } @@ -59,9 +63,9 @@ export default class App extends Vue { .then((loadstorage) => { if (loadstorage) { - if (UserStore.state.lang !== '') { + if (toolsext.getLocale() !== '') { // console.log('SETLOCALE :', this.$i18n.locale) - this.$i18n.locale = UserStore.state.lang // Set Lang + this.$i18n.locale = toolsext.getLocale() // Set Lang } else { UserStore.mutations.setlang(this.$i18n.locale) } @@ -81,5 +85,7 @@ export default class App extends Vue { } - + get static_data() { + return static_data + } } diff --git a/src/App.vue b/src/App.vue index d0403c1..68ecb38 100644 --- a/src/App.vue +++ b/src/App.vue @@ -5,6 +5,10 @@ + + + + @@ -12,6 +16,7 @@
+