-
+
diff --git a/src/model/Calendar.ts b/src/model/Calendar.ts
new file mode 100644
index 0000000..2ab8870
--- /dev/null
+++ b/src/model/Calendar.ts
@@ -0,0 +1,60 @@
+
+export interface IEvents {
+ _id?: any
+ time?: string
+ duration?: number
+ duration2?: number
+ title?: string
+ details?: string
+ date?: string
+ side?: string
+ bgcolor?: string
+ days?: number
+ icon?: string
+ img?: string
+ where?: string
+ teacher?: string
+ teacher2?: string
+ avatar?: string
+ avatar2?: string
+ infoextra?: string
+ linkpdf?: string
+ nobookable?: boolean
+}
+
+export interface IBookedEvent {
+ id_bookedevent?: any
+ numpeople: number
+ infoevent: string
+ msgbooking: string
+ datebooked?: Date
+ booked: boolean
+}
+
+export interface ICalendarState {
+ editable: boolean
+ eventlist: IEvents[]
+ bookedevent: IBookedEvent[]
+ // ---------------
+ titlebarHeight: number
+ locale: string,
+ maxDays: number,
+ fiveDayWorkWeek: boolean,
+ shortMonthLabel: boolean,
+ showDayOfYearLabel: boolean,
+ shortWeekdayLabel: boolean,
+ shortIntervalLabel: boolean,
+ hour24Format: boolean,
+ hideHeader: boolean,
+ noScroll: boolean,
+ showMonthLabel: boolean,
+ showWorkWeeks: boolean,
+ intervalRange: {min: number, max: number},
+ intervalRangeStep: number,
+ intervalHeight: number,
+ resourceHeight: number,
+ resourceWidth: number,
+ dayHeight: number,
+ enableThemes: boolean,
+ theme: {}
+}
diff --git a/src/model/Estimate.ts b/src/model/Estimate.ts
new file mode 100644
index 0000000..65374b6
--- /dev/null
+++ b/src/model/Estimate.ts
@@ -0,0 +1,18 @@
+import { tools } from '@src/store/Modules/tools'
+import { toolsext } from '@src/store/Modules/toolsext'
+
+export interface IEstimate {
+ id?: number
+ title: string
+ advanced?: boolean
+ description?: string
+ viewlist?: number[]
+ listsel?: number
+ qtaName?: string
+ icon?: string
+ numpag?: number
+ qta?: number
+ price?: number
+ pricebase?: number
+ checksel?: boolean
+}
diff --git a/src/model/GlobalStore.ts b/src/model/GlobalStore.ts
index e547851..5d200a2 100644
--- a/src/model/GlobalStore.ts
+++ b/src/model/GlobalStore.ts
@@ -1,4 +1,5 @@
import { IAction } from '@src/model/Projects'
+import { Component } from 'vue-router/types/router'
export interface IPost {
title: string
@@ -72,12 +73,124 @@ export interface IMenuList {
}
export interface IListRoutes {
- route: string
- faIcon?: string
- materialIcon?: string
+ path: string
name: string
+ materialIcon?: string
+ component?: Component
+ reqauth?: boolean
+ inmenu?: boolean
+ solotitle?: boolean
+ infooter?: boolean
+ submenu?: boolean
+ // ------------------------
+ faIcon?: string
text?: string
routes2?: IListRoutes[]
level_parent?: number
level_child?: number
}
+
+export interface IPerson {
+ index?: number
+ tab?: string
+ name: string
+ sub1: string
+ sub2?: string
+ sub3?: string
+ img: string
+ cell?: string
+ email?: string
+ paginaweb?: string
+ paginafb?: string
+ intro?: string
+ info?: string
+ vario?: string
+}
+
+export interface IPreloadImages {
+ imgname: string
+ mobile: boolean
+}
+
+export interface ILang {
+ label: string
+ icon: string
+ value: string
+ image: string
+ short: string
+}
+
+export interface IAllLang {
+ es?: string
+ enUs?: string
+ fr?: string
+ de?: string
+ it?: string
+}
+
+export interface ITimeLineEntry {
+ date: string
+ title: string
+ description: IAllLang
+ description2?: IAllLang
+ description3?: IAllLang
+ icon: string
+ image: string
+ image2?: string
+ image3?: string
+ image4?: string
+ video?: string
+ side: string
+ link_url?: string
+ link_url_lang?: IAllLang
+ link_text?: IAllLang
+ ingallery?: boolean
+}
+
+export interface ITimeLineMain {
+ titlemain: IAllLang
+ body: ITimeLineEntry[]
+}
+
+export interface IGallery {
+ title: string
+ subtitle?: IAllLang
+ img: string
+ width?: number
+ height?: number
+ ingallery?: boolean
+ inexibitions?: boolean
+}
+
+export interface IColl {
+ title: IAllLang
+ date: string
+ subtitle?: IAllLang
+ img: string
+ img2?: string
+ linkagg?: string
+ linkagg_type?: number
+ width?: number
+ height?: number
+}
+
+export interface ICollaborations {
+ withwhom_title: IAllLang
+ list: IColl[]
+}
+
+export interface IParamDialog {
+ param1?: any
+ param2?: any
+ param3?: any
+}
+
+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/UserStore.ts b/src/model/UserStore.ts
index 2b27028..7c78c76 100644
--- a/src/model/UserStore.ts
+++ b/src/model/UserStore.ts
@@ -3,6 +3,8 @@ import { IToken } from 'model/other'
export const DefaultUser =
{
email: '',
username: '',
+ name: '',
+ surname: '',
password: '',
lang: 'it'
}
@@ -11,6 +13,8 @@ export interface IUserState {
userId?: string
email?: string
username?: string
+ name?: string
+ surname?: string
password?: string
lang?: string
repeatPassword?: string
diff --git a/src/model/index.ts b/src/model/index.ts
index 0f2cd7c..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'
@@ -10,3 +12,5 @@ export * from './Todos'
export * from './Projects'
export * from './Calendar'
+export * from './Estimate'
+export * from './BookingStore'
diff --git a/src/model/signup-option.ts b/src/model/signup-option.ts
index a6501d5..44b9eb8 100644
--- a/src/model/signup-option.ts
+++ b/src/model/signup-option.ts
@@ -2,6 +2,8 @@
export interface ISignupOptions {
email?: string
username: string
+ name?: string
+ surname?: string
password?: string
lang?: string
repeatPassword?: string
diff --git a/src/root/home/home.scss b/src/root/home/home.scss
index 89c1f9f..ae93e28 100644
--- a/src/root/home/home.scss
+++ b/src/root/home/home.scss
@@ -1,13 +1,3 @@
-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;
-}
-
-$grayshadow: #555;
.testo-banda {
//background: -webkit-gradient(linear, left top, left bottom, from(#3144f0), to(transparent));
@@ -15,9 +5,18 @@ $grayshadow: #555;
//background: rgba(0, 0, 0, .6)
}
+$grayshadow: #555;
+
+$textcol: blue;
+$textcol_scuro: darkblue;
+
p {
- margin: 0 0 16px;
- text-shadow: 2px 2px 4px $grayshadow;
+ margin: 0 0 1.25rem;
+ //text-shadow: .125rem .125rem .25rem $grayshadow;
+}
+
+h4 {
+ font-size: 1.25rem;
}
.mycard {
@@ -28,7 +27,7 @@ p {
}
.landing_background {
- background: #000 url(../../statics/images/cover.jpg) no-repeat 50% fixed;
+ background: #000 url(../../statics/images/foto1.jpg) no-repeat 50% fixed;
background-size: cover
}
@@ -42,8 +41,51 @@ p {
//padding: 0 16px
}
+.intro {
+ display: flex;
+ justify-content: space-between;
+ align-items: stretch;
+ /* flex-flow: row nowrap; */
+
+ padding: 1.25rem 0 1.25rem 0;
+ margin: .125rem;
+
+ * {
+ width: 100%;
+ flex: 1;
+ margin-left: auto;
+ margin-right: auto;
+ }
+
+ &__associazione {
+ min-width: 350px;
+ }
+
+ &__comeassociarsi{
+ min-width: 350px;
+ }
+}
+
+.subtitle {
+ font-weight: 600;
+ text-align: center;
+ letter-spacing: 0.125rem;
+ text-transform: uppercase;
+ font-size: 1rem;
+}
+
.landing > section.padding {
- padding: 90px 16px
+ padding: 5.62rem 1rem;
+}
+
+.landing > section.padding_testo {
+ padding-top: 1.25rem;
+ padding-bottom: 1rem;
+}
+
+.landing > section.padding_gallery {
+ padding-top: 3.125rem;
+ padding-bottom: 5.625rem;
}
.landing > section > div {
@@ -59,7 +101,7 @@ p {
}
.landing__toolbar .q-btn {
- border-radius: 0 0 5px 5px;
+ border-radius: 0 0 .315rem .315rem;
-ms-flex-item-align: stretch;
align-self: stretch
}
@@ -73,7 +115,7 @@ p {
}
.landing__arrow {
- bottom: 25px;
+ bottom: 1.5rem;
opacity: .4
}
@@ -83,24 +125,24 @@ p {
}
.landing__logo {
- width: 150px;
- height: 150px;
- margin-top: 21px;
+ width: 9.40rem;
+ height: 9.40rem;
+ margin-top: 1.315rem;
//-webkit-animation: logo-rotate 240s linear infinite;
//animation: logo-rotate 240s linear infinite
}
.landing__features .q-icon {
- font-size: 64px
+ font-size: 4rem
}
h4 {
line-height: 1.5;
- text-shadow: 4px 4px 8px $grayshadow;
+ text-shadow: .25rem .25rem .5rem $grayshadow;
}
.landing__features h4, .landing__features h6 {
- margin: 26px 0
+ margin: 1rem 0
}
.landing__features p {
@@ -111,19 +153,22 @@ h4 {
.landing__footer {
//background: -webkit-gradient(linear, left top, left bottom, color-stop(65%, rgba(0, 0, 0, .1)), to(#000));
- background: linear-gradient(180deg, rgba(0, 0, 0, .8) 75%, #FFF);
- padding-top: 72px !important;
- padding-bottom: 72px !important
+ background: linear-gradient(180deg, rgba(0, 0, 0, .8) 95%, #FFF);
+ padding-top: 4.5rem !important;
+ padding-bottom: 4.5rem !important;
+ padding-left: 1.25rem;
+ padding-right: 1.25rem;
+ color: #9f9f9f;
}
.icon_contact:hover {
color: blue;
border-color: white;
- border-width: 1px;
+ border-width: .0625rem;
}
.landing__footer .doc-link {
- color: #fff
+ color: $textcol;
}
.landing__footer .doc-link:hover {
@@ -147,7 +192,7 @@ h4 {
}
.q-col-gutter-sm {
- padding: 50px 50px;
+ padding: 3.125rem 3.125rem;
//margin-left: -48px
}
@@ -187,7 +232,7 @@ body.mobile .landing:before {
.home {
//background-color: rgb(250, 250, 250);
- padding: 5px;
+ padding: 3.125rem;
display: flex;
//flex-wrap: nowrap;
flex-direction: column;
@@ -196,17 +241,17 @@ body.mobile .landing:before {
}
.btn-start {
- margin: 5px;
+ margin: 3.125rem;
}
.shadow {
//color: white;
- text-shadow: 2px 2px 4px $grayshadow;
+ text-shadow: 0.125rem 0.125rem 0.25rem $grayshadow;
}
.shadow-max {
//color: white;
- text-shadow: 4px 4px 8px $grayshadow;
+ text-shadow: .25rem .25rem .5rem $grayshadow;
}
.text-h1 {
@@ -227,45 +272,26 @@ body.mobile .landing:before {
font-weight: 700;
}
-.text-subtitle1 {
- font-size: 1.35rem;
- font-weight: 400;
- line-height: 1.75rem;
- text-shadow: 4px 4px 8px $grayshadow;
- letter-spacing: .00937em;
- &.big {
- font-size: 1.5rem;
- }
-}
-
-.text-subtitle2 {
- font-size: 1.15rem;
+.text-vers{
+ font-size: 0.75rem;
font-weight: 400;
line-height: 1.75rem;
letter-spacing: .00937em;
- text-shadow: 4px 4px 8px $grayshadow;
-}
-
-.text-subtitle3 {
- font-size: 1rem;
- font-weight: 400;
- line-height: 1.75rem;
- letter-spacing: .00937em;
- text-shadow: 2px 2px 4px $grayshadow;
+ text-shadow: .25rem .25rem .5rem $grayshadow;
}
.homep-cover-img-1 {
- background: #000 url(../../statics/images/cover.jpg) no-repeat 50% fixed;
+ background: #000 url(../../statics/images/foto1.jpg) no-repeat 50% fixed;
//transition: background-image 1s ease-in-out;
}
.homep-cover-img-2 {
- background: #000 url(../../statics/images/hand_people.jpg) no-repeat 50% fixed;
+ background: #000 url(../../statics/images/foto2.jpg) no-repeat 50% fixed;
//transition: background-image 1s ease-in-out;
}
.homep-cover-img-3 {
- background: #000 url(../../statics/images/cibo_sano.jpg) no-repeat 50% fixed;
+ background: #000 url(../../statics/images/foto3.jpg) no-repeat 50% fixed;
//transition: background-image 1s ease-in-out;
}
@@ -274,19 +300,19 @@ body.mobile .landing:before {
}
.landing__footer-icons {
- font-size: 28px
+ font-size: 1.75rem
}
.landing__footer-icons a {
- margin: 0 8px 8px;
+ margin: 0 .5rem .5rem;
text-decoration: none;
outline: 0;
- color: #fff;
+ color: $textcol;
transition: color .28s
}
.landing__footer-icons a:hover {
- color: #e0e0e0
+ color: $textcol_scuro;
}
.doc-img {
@@ -295,12 +321,12 @@ body.mobile .landing:before {
.mylist {
background: #3fdaff;
- padding-left: 20px;
+ padding-left: 1.25rem;
}
.clgutter {
- margin-top: 20px;
- padding: 10px;
+ margin-top: 1.25rem;
+ padding: .62rem;
}
.carousel_img_3 {
@@ -321,35 +347,44 @@ body.mobile .landing:before {
height: 7vh
}
.clgutter {
- margin-top: 0px;
- padding: 0px;
+ margin-top: 0;
+ padding: 0;
}
.landing__hero .text-h1 {
font-size: 3rem;
line-height: 3.05rem;
- margin-bottom: 24px
+ margin-bottom: 1.5rem
}
.landing > section.padding {
- padding: 40px 16px
- //padding-bottom: 90px
+ padding: 2.5rem 1rem;
+ }
+
+ .landing > section.padding_testo {
+ padding-top: 1.25rem;
+ padding-bottom: 1rem;
+ }
+
+ .landing > section.padding_gallery {
+ padding-top: 3.125rem;
+ padding-bottom: 5.625rem;
}
.landing__features h4, .landing__features h6 {
- margin: 20px 0
+ margin: 1.25rem 0
}
h4 {
line-height: 1.4;
- text-shadow: 4px 4px 8px $grayshadow;
+ text-shadow: 0.25rem 0.25rem 0.5rem $grayshadow;
}
.landing .feature-item {
text-align: center;
- margin-top: 20px;
+ margin-top: 1.25rem;
}
.landing__hero-content {
- padding-bottom: 180px
+ padding-bottom: 11.25rem;
}
.landing__hero-btns {
-webkit-box-pack: center;
@@ -358,17 +393,14 @@ body.mobile .landing:before {
}
.q-col-gutter-sm {
- padding: 10px 5px;
+ padding: .625rem .315rem;
}
.text-subtitle1 {
font-size: 1.25rem;
}
- .text-subtitle2 {
- font-size: 1rem;
- }
- .text-subtitle3 {
- font-size: 0.75rem;
+ .text-vers{
+ font-size: 0.6rem;
}
.carousel_img_3 {
@@ -382,8 +414,25 @@ body.mobile .landing:before {
.custom-caption {
text-align: center;
- padding: 12px;
- color: white;
+ padding: .75rem;
+ color: $textcol;
background-color: rgba(0, 0, 0, .3);
}
+.mycontacts {
+ color: gray;
+ letter-spacing: 0.078rem;
+}
+
+.mycontacts_title {
+ text-shadow: 0.125rem 0.125rem 0.125rem #555;
+ font-weight: bold;
+ color: #999;
+ letter-spacing: 0.125rem;
+}
+
+.mycontacts_text {
+ color: #999;
+ letter-spacing: 0.093rem;
+}
+
diff --git a/src/root/home/home.ts b/src/root/home/home.ts
index 08d2738..c054667 100644
--- a/src/root/home/home.ts
+++ b/src/root/home/home.ts
@@ -4,8 +4,12 @@ import { GlobalStore, UserStore } from '@store'
import { Logo } from '../../components/logo'
+import { Footer } from '../../components/Footer'
+
import VueScrollReveal from 'vue-scroll-reveal'
import { tools } from '@src/store/Modules/tools'
+import { toolsext } from '@src/store/Modules/toolsext'
+import { Screen } from 'quasar'
Vue.use(VueScrollReveal, {
class: 'v-scroll-reveal', // A CSS class applied to elements with the v-scroll-reveal directive; useful for animation overrides.
@@ -21,7 +25,7 @@ Vue.use(VueScrollReveal, {
})
@Component({
- components: { Logo }
+ components: { Logo, Footer }
})
export default class Home extends Vue {
public text: string = ''
diff --git a/src/root/home/home.vue b/src/root/home/home.vue
index fdba479..a612117 100644
--- a/src/root/home/home.vue
+++ b/src/root/home/home.vue
@@ -402,6 +402,8 @@
+
+
diff --git a/src/router/index.ts b/src/router/index.ts
index 771eda3..d0c75f8 100644
--- a/src/router/index.ts
+++ b/src/router/index.ts
@@ -7,6 +7,7 @@ import { ProgressBar } from '@src/store/Modules/Interface'
import { isEqual } from 'lodash'
import { UserStore } from '@store'
import { tools } from '@src/store/Modules/tools'
+import { toolsext } from '@src/store/Modules/toolsext'
Vue.use(VueRouter)
/*
@@ -16,7 +17,7 @@ Vue.use(VueRouter)
const Router = new VueRouter({
scrollBehavior: () => ({ x: 0, y: 0 } as PositionResult),
- routes: cfgrouter.routes,
+ routes: cfgrouter.getmenu(),
// Leave these as is and change from quasar.conf.js instead!
// quasar.conf.js -> build -> vueRouterMode
diff --git a/src/router/route-config.ts b/src/router/route-config.ts
index 9f30a1b..e7d95f6 100644
--- a/src/router/route-config.ts
+++ b/src/router/route-config.ts
@@ -1,11 +1,13 @@
import { RouteConfig, Route, RouteRecord } from 'vue-router/types'
import { tools } from '@src/store/Modules/tools'
+import { toolsext } from '@src/store/Modules/toolsext'
import auth from '../middleware/auth'
import { GlobalStore, Projects, Todos, UserStore } from '@store'
import { RouteNames } from '@src/router/route-names'
import { IListRoutes, IMenuList } from '@src/model'
+import { static_data } from '@src/db/static_data'
interface IMyMeta {
title?: string,
@@ -88,6 +90,11 @@ export const cfgrouter = {
name: 'Categories',
component: () => import('@/views/admin/testp1/testp1.vue')
},
+ {
+ path: '/estimate',
+ name: 'Estimate',
+ component: () => import('@/views/pages/estimate/estimate.vue')
+ },
{
path: '/offline',
name: 'Offline',
diff --git a/src/statics/i18n.js b/src/statics/i18n.js
index a70daff..1ecde40 100644
--- a/src/statics/i18n.js
+++ b/src/statics/i18n.js
@@ -1,4 +1,4 @@
-import msg_website from './i18n_website'
+import msg_website from '../db/i18n_website'
const msgglobal = {
it: {
@@ -9,6 +9,7 @@ const msgglobal = {
delete: 'Elimina',
cancel: 'Annulla',
today: 'Oggi',
+ book: 'Prenota',
msg: {
titledeleteTask: 'Elimina Task',
deleteTask: "Vuoi Eliminare {mytodo}?"
@@ -44,10 +45,13 @@ const msgglobal = {
loggati: 'Utente non loggato'
},
reg: {
+ page_title: 'Registrazione',
incorso: 'Registrazione in corso...',
richiesto: 'Campo Richiesto',
email: 'Email',
username: 'Nome Utente',
+ name: 'Nome',
+ surname: 'Cognome',
username_login: 'Nome Utente o email',
password: 'Password',
repeatPassword: 'Ripeti password',
@@ -79,6 +83,7 @@ const msgglobal = {
}
},
login: {
+ page_title: 'Login',
incorso: 'Login in corso',
enter: 'Login',
errato: "Username o password errata. Riprovare",
@@ -149,6 +154,14 @@ const msgglobal = {
themebgcolor: 'Tema Colore Sfondo'
},
cal: {
+ booked: 'Prenotato',
+ booked_error: 'Prenotazione non avvenuta. Riprovare più tardi',
+ booking: 'Prenota Evento',
+ titlebooking: 'Prenotazione',
+ cancelbooking: 'Cancella Prenotazione',
+ canceledbooking: 'Prenotazione Cancellata',
+ cancelederrorbooking: 'Cancellazione non effettuata, Riprovare più tardi',
+ event: 'Evento',
starttime: 'Dalle',
endtime: 'alle',
duration: 'Durata',
@@ -161,11 +174,18 @@ const msgglobal = {
infoextra: 'Date e Ora Extra:',
alldayevent: 'Tutto il giorno',
eventstartdatetime: 'Data e Ora Inizio Evento',
- enterEndDateTime: 'Data e Ora Fine Evento'
+ enterEndDateTime: 'Data e Ora Fine Evento',
+ selnumpeople: 'Partecipanti',
+ msgbooking: 'Messaggio da inviare',
+ bookingtextdefault: 'Mi prenoto all\'evento',
+ bookingtextdefault_of: 'di'
},
newsletter: {
+ title: 'Desideri ricevere la nostra Newsletter?',
name: 'Il tuo Nome',
- namehint: 'Nome e Cognome',
+ surname: 'Il tuo Cognome',
+ namehint: 'Nome',
+ surnamehint: 'Cognome',
email: 'La tua Email',
submit: 'Iscriviti',
reset: 'Cancella',
@@ -173,9 +193,11 @@ const msgglobal = {
acceptlicense: 'Accetto la licenza e i termini',
license: 'Devi prima accettare la licenza e i termini',
submitted: 'Iscritto'
- }
+ },
+ privacy_policy:'Privacy Policy',
+ cookies: 'Usiamo i Cookie per una migliore prestazione web.'
},
- 'es': {
+ es: {
dialog: {
ok: 'Vale',
yes: 'Sí',
@@ -183,6 +205,7 @@ const msgglobal = {
delete: 'Borrar',
cancel: 'Cancelar',
today: 'Hoy',
+ book: 'Reserva',
msg: {
titledeleteTask: 'Borrar Tarea',
deleteTask: 'Quieres borrar {mytodo}?'
@@ -218,10 +241,13 @@ const msgglobal = {
loggati: 'Usuario no ha iniciado sesión'
},
reg: {
+ page_title: 'Registro',
incorso: 'Registro en curso...',
richiesto: 'Campo requerido',
email: 'Email',
username: 'Nombre usuario',
+ name: 'Nombre',
+ surname: 'Apellido',
username_login: 'Nombre usuario o email',
password: 'contraseña',
repeatPassword: 'Repetir contraseña',
@@ -246,6 +272,7 @@ const msgglobal = {
}
},
login: {
+ page_title: 'Login',
incorso: 'Login en curso',
enter: 'Entra',
errato: "Nombre de usuario, correo o contraseña incorrectos. inténtelo de nuevo",
@@ -317,6 +344,14 @@ const msgglobal = {
themebgcolor: 'Tema Colores Fondo'
},
cal: {
+ booked: 'Reservado',
+ booked_error: 'Reserva fallida. Intenta nuevamente más tarde',
+ booking: 'Reserva Evento',
+ titlebooking: 'Reserva',
+ cancelbooking: 'Cancelar Reserva',
+ canceledbooking: 'Reserva Cancelada',
+ cancelederrorbooking: 'Cancelación no realizada, intente nuevamente más tarde',
+ event: 'Evento',
starttime: 'Inicio',
endtime: 'fin',
duration: 'Duración',
@@ -329,11 +364,18 @@ const msgglobal = {
infoextra: 'Fecha y Hora Extras:',
alldayevent: 'Todo el dia',
eventstartdatetime: 'Evento de inicio de fecha y hora',
- enterEndDateTime: 'Fecha y hora del evento final'
+ enterEndDateTime: 'Fecha y hora del evento final',
+ selnumpeople: 'Partecipantes',
+ msgbooking: 'Mensaje para enviar',
+ bookingtextdefault: 'Reservo el evento',
+ bookingtextdefault_of: 'de',
},
newsletter: {
+ title: '¿Desea recibir nuestro boletín informativo?',
name: 'Tu Nombre',
- namehint: 'Nombre y Apellido',
+ surname: 'Tu Apellido',
+ namehint: 'Nombre',
+ surnamehint: 'Apellido',
email: 'tu correo',
submit: 'Subscribete',
reset: 'Reiniciar',
@@ -341,9 +383,200 @@ const msgglobal = {
acceptlicense: 'Acepto la licencia y los términos',
license: 'Necesitas aceptar la licencia y los términos primero',
submitted: 'Subscrito'
- }
+ },
+ privacy_policy:'Política de privacidad',
+ cookies: 'Utilizamos cookies para un mejor rendimiento web.'
},
- 'enUs': {
+ fr: {
+ dialog: {
+ ok: 'Bien',
+ yes: 'Oui',
+ no: 'Non',
+ delete: 'Supprimer',
+ cancel: 'annuler',
+ today: 'Aujourd\'hui',
+ book: 'Réserve',
+ msg: {
+ titledeleteTask: 'Supprimer la tâche',
+ deleteTask: 'Voulez-vous supprimer {mytodo}?'
+ }
+ },
+ comp: {
+ Conta: "Conta",
+ },
+ components: {
+ authentication: {
+ login: {
+ facebook: 'Facebook'
+ },
+ email_verification: {
+ title: 'Créer un compte',
+ introduce_email: 'entrez votre adresse email',
+ email: 'Email',
+ invalid_email: 'Votre email n\'est pas valide',
+ verify_email: 'Vérifiez votre email',
+ go_login: 'Retour à la connexion',
+ incorrect_input: 'Entrée correcte.',
+ link_sent: 'Pour confirmer l’enregistrement, lisez votre boîte aux lettres et cliquez sur "Vérifier le courrier électronique".".\n' + 'Si vous ne le trouvez pas, regardez dans le dossier Spam.'
+ }
+ }
+ },
+ fetch: {
+ errore_generico: 'Erreur générique',
+ errore_server: 'Le serveur n\'est pas accessible. Essayez encore, Merci',
+ error_doppiologin: 'Re-connexion Accès ouvert par un autre appareil.',
+ },
+ user: {
+ notregistered: 'Vous devez vous inscrire auprès du service avant de pouvoir stocker les données.',
+ loggati: 'L\'utilisateur n\'est pas connecté'
+ },
+ reg: {
+ incorso: 'Inscription en cours...',
+ richiesto: 'Champ obligatoire',
+ email: 'Email',
+ username: 'Nom d\'utilisateur',
+ name: 'Nom',
+ surname: 'Prénom',
+ username_login: 'Nom d\'utilisateur ou email',
+ password: 'mot de passe',
+ repeatPassword: 'Répéter le mot de passe',
+ terms: "J'accepte les termes et conditions",
+ submit: "S'inscrire",
+ title_verif_reg: "Vérifier l'inscription",
+ verificato: "Vérifié",
+ non_verificato: "Non vérifié",
+ forgetpassword: "Vous avez oublié votre mot de passe?",
+ err: {
+ required: 'c\'est nécessaire',
+ email: 'Ce doit être un email valide.',
+ errore_generico: 'S\'il vous plaît remplir les champs correctement',
+ atleast: 'ça doit être au moins long',
+ complexity: 'doit contenir au moins 1 minuscule, 1 majuscule et 1 chiffre',
+ notmore: 'il ne doit pas être plus long que',
+ char: 'caractères',
+ terms: 'Vous devez accepter les conditions, pour continuer..',
+ duplicate_email: 'L\'email a déjà été enregistré',
+ duplicate_username: 'Le nom d\'utilisateur a déjà été utilisé',
+ sameaspassword: 'Les mots de passe doivent être identiques',
+ }
+ },
+ login: {
+ page_title: 'Login',
+ incorso: 'Connexion en cours',
+ enter: 'Entrez',
+ errato: "Nom d'utilisateur, email ou mot de passe incorrect. réessayer",
+ completato: 'Connexion faite!',
+ },
+ reset: {
+ title_reset_pwd: "Réinitialiser votre mot de passe",
+ send_reset_pwd: 'Envoyer un mot de passe de réinitialisation',
+ incorso: 'Demander un nouvel email...',
+ email_sent: 'Email envoyé',
+ check_email: 'Vérifiez votre email, vous recevrez un message avec un lien pour réinitialiser votre mot de passe. Ce lien, pour des raisons de sécurité, expirera au bout de 4 heures.',
+ title_update_pwd: 'Mettez à jour votre mot de passe',
+ update_password: 'Mettre à jour le mot de passe',
+ },
+ logout: {
+ uscito: 'Vous êtes déconnecté',
+ },
+ errors: {
+ graphql: {
+ undefined: 'non défini'
+ }
+ },
+ todo: {
+ titleprioritymenu: 'Prioridad:',
+ inserttop: 'Ingrese una nueva Tarea arriba',
+ insertbottom: 'Ingrese una nueva Tarea abajo',
+ edit: 'Descripción Tarea:',
+ completed: 'Ultimos Completados',
+ usernotdefined: 'Atención, debes iniciar sesión para agregar una Tarea',
+ start_date: 'Fecha inicio',
+ status: 'Estado',
+ completed_at: 'Fecha de finalización',
+ expiring_at: 'Fecha de Caducidad',
+ phase: 'Fase',
+ },
+ notification: {
+ status: 'Etat',
+ ask: 'Activer les notifications',
+ waitingconfirm: 'Confirmer la demande de notification.',
+ confirmed: 'Notifications activées!',
+ denied: 'Notifications désactivées! Attention, vous ne verrez pas les messages arriver. Réhabilitez-les pour les voir.',
+ titlegranted: 'Notifications activées activées!',
+ statusnot: 'Notifications d\'état',
+ titledenied: 'Notifications autorisées désactivées!',
+ title_subscribed: 'Abonnement au Site Web!',
+ subscribed: 'Maintenant, vous pouvez recevoir des messages et des notifications.',
+ newVersionAvailable: 'Mise à jour'
+ },
+ connection: 'Connexion',
+ proj: {
+ newproj: 'Título Projecto',
+ newsubproj: 'Título Sub-Projecto',
+ insertbottom: 'Añadir nuevo Proyecto',
+ longdescr: 'Descripción',
+ hoursplanned: 'Horas Estimadas',
+ hoursleft: 'Horas Restantes',
+ hoursadded: 'Horas Adicional',
+ hoursworked: 'Horas Trabajadas',
+ begin_development: 'Comienzo desarrollo',
+ begin_test: 'Comienzo Prueba',
+ progresstask: 'Progresion',
+ actualphase: 'Fase Actual',
+ hoursweeky_plannedtowork: 'Horarios semanales programados',
+ endwork_estimate: 'Fecha estimada de finalización',
+ privacyread: 'Quien puede verlo:',
+ privacywrite: 'Quien puede modificarlo:',
+ totalphases: 'Fases totales',
+ themecolor: 'Tema Colores',
+ themebgcolor: 'Tema Colores Fondo'
+ },
+ cal: {
+ booked: 'Réservé',
+ booked_error: 'La réservation a échoué. Réessayez plus tard',
+ booking: 'Réserver l\'événement',
+ titlebooking: 'Réservation',
+ cancelbooking: 'Annuler la réservation',
+ canceledbooking: 'Réservation annulée',
+ cancelederrorbooking: 'Annulation non effectuée, réessayez plus tard',
+ event: 'événement',
+ starttime: 'Accueil',
+ endtime: 'fin',
+ duration: 'Durée',
+ hours: 'Le temps',
+ when: 'Quand',
+ where: 'Où',
+ teacher: 'Avec',
+ enterdate: 'Entrez la date',
+ details: 'Les détails',
+ infoextra: 'Extras Date et heure:',
+ alldayevent: 'Toute la journée',
+ eventstartdatetime: 'Date de début et heure de l\'événement',
+ enterEndDateTime: 'Date et heure de l\'événement final',
+ selnumpeople: 'Participants',
+ msgbooking: 'Message à envoyer',
+ bookingtextdefault: 'Je réserve l\'événement',
+ bookingtextdefault_of: 'du',
+ },
+ newsletter: {
+ title: 'Souhaitez-vous recevoir notre newsletter?',
+ name: 'Ton nom',
+ surname: 'Tu prénom',
+ namehint: 'Nom',
+ surnamehint: 'Prénom',
+ email: 'votre e-mail',
+ submit: 'S\'abonner',
+ reset: 'Redémarrer',
+ typesomething: 'Remplir le champ',
+ acceptlicense: 'J\'accepte la licence et les termes',
+ license: 'Vous devez d\'abord accepter la licence et les termes',
+ submitted: 'Abonné'
+ },
+ privacy_policy:'Politique de confidentialité',
+ cookies: 'Nous utilisons des cookies pour améliorer les performances Web.'
+ },
+ enUs: {
dialog: {
ok: 'Ok',
yes: 'Yes',
@@ -351,6 +584,7 @@ const msgglobal = {
delete: 'Delete',
cancel: 'Cancel',
today: 'Today',
+ book: 'Book',
msg: {
titledeleteTask: 'Delete Task',
deleteTask: 'Delete Task {mytodo}?'
@@ -391,6 +625,8 @@ const msgglobal = {
email: 'Email',
username_login: 'Username or email',
username: 'Username',
+ name: 'Name',
+ surname: 'Surname',
password: 'Password',
repeatPassword: 'Repeat password',
terms: "I agree with the terms and conditions",
@@ -485,6 +721,14 @@ const msgglobal = {
themebgcolor: 'Theme Color Background'
},
cal: {
+ booked: 'Booked',
+ booked_error: 'Reservation failed. Try again later',
+ booking: 'Book the Event',
+ titlebooking: 'Reservation',
+ cancelbooking: 'Cancel Reservation',
+ canceledbooking: 'Booking cancelled',
+ cancelederrorbooking: 'Cancellation unsuccessfully, try again later',
+ event: 'Event',
starttime: 'From',
endtime: 'to',
duration: 'Duration',
@@ -495,13 +739,20 @@ 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'
+ enterEndDateTime: 'Event end date and time',
+ selnumpeople: 'Participants',
+ msgbooking: 'Message to send',
+ bookingtextdefault: 'I book the event',
+ bookingtextdefault_of: 'of',
},
newsletter: {
+ title: 'Would you like to receive our Newsletter?',
name: 'Your name',
- namehint: 'Name and surname',
+ surname: 'Your surname',
+ namehint: 'Name',
+ surnamehint: 'Surname',
email: 'Your email',
submit: 'Subscribe',
reset: 'Reset',
@@ -509,32 +760,239 @@ const msgglobal = {
acceptlicense: 'I accept the license and terms',
license: 'You need to accept the license and terms first',
submitted: 'Subscribed'
- }
+ },
+ privacy_policy:'Privacy Policy',
+ cookies: 'We use cookies for better web performance.'
+ },
+ de: {
+ dialog: {
+ ok: 'Ok',
+ yes: 'Yes',
+ no: 'No',
+ delete: 'Delete',
+ cancel: 'Cancel',
+ today: 'Today',
+ book: 'Book',
+ msg: {
+ titledeleteTask: 'Delete Task',
+ deleteTask: 'Delete Task {mytodo}?'
+ }
+ },
+ comp: {
+ Conta: "Count",
+ },
+ components: {
+ authentication: {
+ login: {
+ facebook: 'Facebook'
+ },
+ email_verification: {
+ title: 'Begin your registration',
+ introduce_email: 'Enter your email',
+ email: 'Email',
+ invalid_email: 'Your email is invalid',
+ verify_email: 'Verify your email',
+ go_login: 'Back to Login',
+ incorrect_input: 'Incorrect input.',
+ link_sent: 'To confirm the Registration, read your mailbox and click on "Verify email".\nIf you can not find it check your junk mail or spam.'
+ }
+ }
+ },
+ fetch: {
+ errore_generico: 'Generic Error',
+ errore_server: 'Unable to access to the Server. Retry. Thank you.',
+ error_doppiologin: 'Signup again. Another access was made with another device.',
+ },
+ user: {
+ notregistered: 'You need first to SignUp before storing data',
+ loggati: 'User not logged in'
+ },
+ reg: {
+ page_title: 'Registration',
+ incorso: 'Registration please wait...',
+ richiesto: 'Field Required',
+ email: 'Email',
+ username_login: 'Username or email',
+ username: 'Username',
+ name: 'Name',
+ surname: 'Surname',
+ password: 'Password',
+ repeatPassword: 'Repeat password',
+ terms: "I agree with the terms and conditions",
+ submit: "Submit",
+ title_verif_reg: "Verify Registration",
+ verificato: "Verified",
+ non_verificato: "Not Verified",
+ forgetpassword: "Forget Password?",
+ err: {
+ required: 'is required',
+ email: 'must be a valid email',
+ errore_generico: 'Please review fields again',
+ atleast: 'must be at least',
+ complexity: 'must contains at least 1 lowercase letter, 1 uppercase letter, and 1 digit',
+ notmore: 'must not be more than',
+ char: 'characters long',
+ terms: 'You need to agree with the terms & conditions.',
+ duplicate_email: 'Email was already registered',
+ duplicate_username: 'Username is already taken',
+ sameaspassword: 'Passwords must be identical',
+ }
+ },
+ login: {
+ page_title: 'Login',
+ incorso: 'Login...',
+ enter: 'Login',
+ errato: "Username or password wrong. Please retry again",
+ completato: 'Login successfully!',
+ },
+ reset: {
+ title_reset_pwd: "Reset your Password",
+ send_reset_pwd: 'Send password request',
+ incorso: 'Request New Email...',
+ email_sent: 'Email sent',
+ check_email: 'Check your email for a message with a link to update your password. This link will expire in 4 hours for security reasons.',
+ title_update_pwd: 'Update your password',
+ update_password: 'Update Password',
+ },
+ logout: {
+ uscito: 'Logout successfully',
+ },
+ errors: {
+ graphql: {
+ undefined: 'undefined'
+ }
+ },
+ todo: {
+ titleprioritymenu: 'Priority:',
+ inserttop: 'Insert Task at the top',
+ insertbottom: 'Insert Task at the bottom',
+ edit: 'Task Description:',
+ completed: 'Lasts Completed',
+ usernotdefined: 'Attention, you need to be Signed In to add a new Task',
+ start_date: 'Start Date',
+ status: 'Status',
+ completed_at: 'Completition Date',
+ expiring_at: 'Expiring Date',
+ phase: 'Phase',
+ },
+ notification: {
+ status: 'Status',
+ ask: 'Enable Notification',
+ waitingconfirm: 'Confirm the Request Notification',
+ confirmed: 'Notifications Enabled!',
+ denied: 'Notifications Disabled! Attention, you will not see your messages incoming. Reenable it for see it',
+ titlegranted: 'Notification Permission Granted!',
+ statusnot: 'status Notification',
+ titledenied: 'Notification Permission Denied!',
+ title_subscribed: 'Subscribed to FreePlanet.app!',
+ subscribed: 'You can now receive Notification and Messages.',
+ newVersionAvailable: 'Upgrade'
+ },
+ connection: 'Conexión',
+ proj: {
+ newproj: 'Project Title',
+ newsubproj: 'SubProject Title',
+ insertbottom: 'Insert New Project',
+ longdescr: 'Description',
+ hoursplanned: 'Estimated Hours',
+ hoursleft: 'Left Hours',
+ hoursadded: 'Additional Hours',
+ hoursworked: 'Worked Hours',
+ begin_development: 'Start Dev',
+ begin_test: 'Start Test',
+ progresstask: 'Progression',
+ actualphase: 'Actual Phase',
+ hoursweeky_plannedtowork: 'Scheduled weekly hours',
+ endwork_estimate: 'Estimated completion date',
+ privacyread: 'Who can see it:',
+ privacywrite: 'Who can modify if:',
+ totalphases: 'Total Phase',
+ themecolor: 'Theme Color',
+ themebgcolor: 'Theme Color Background'
+ },
+ cal: {
+ booked: 'Booked',
+ booked_error: 'Reservation failed. Try again later',
+ booking: 'Book the Event',
+ titlebooking: 'Reservation',
+ cancelbooking: 'Cancel Reservation',
+ canceledbooking: 'Booking cancelled',
+ cancelederrorbooking: 'Cancellation unsuccessfully, try again later',
+ event: 'Event',
+ starttime: 'From',
+ endtime: 'to',
+ duration: 'Duration',
+ hours: 'Hours',
+ when: 'When',
+ where: 'Where',
+ teacher: 'With',
+ enterdate: 'Enter date',
+ details: 'Details',
+ infoextra: 'Extra Info DateTime',
+ alldayevent: 'All-Day myevent',
+ eventstartdatetime: 'Event start date and time',
+ enterEndDateTime: 'Event end date and time',
+ selnumpeople: 'Participants',
+ msgbooking: 'Message to send',
+ bookingtextdefault: 'I book the event',
+ bookingtextdefault_of: 'of',
+ },
+ newsletter: {
+ title: 'Would you like to receive our Newsletter?',
+ name: 'Your name',
+ surname: 'Your surname',
+ namehint: 'Name',
+ surnamehint: 'Surname',
+ email: 'Your email',
+ submit: 'Subscribe',
+ reset: 'Reset',
+ typesomething: 'Please type something',
+ acceptlicense: 'I accept the license and terms',
+ license: 'You need to accept the license and terms first',
+ submitted: 'Subscribed'
+ },
+ privacy_policy:'Privacy Policy',
+ cookies: 'Wir verwenden Cookies für eine bessere Webleistung.'
},
};
-
const msgit = { ...msg_website.it, ...msgglobal.it }
+const msgde = { ...msg_website.de, ...msgglobal.de }
+const msgfr = { ...msg_website.fr, ...msgglobal.fr }
const msges = { ...msg_website.es, ...msgglobal.es }
const msgenUs = { ...msg_website.enUs, ...msgglobal.enUs }
-
const messages = {
- it: { ...msgit,
+ it: {
+ ...msgit,
pages: { ...msg_website.it.pages, ...msgglobal.it.pages },
msg: { ...msg_website.it.msg, ...msgglobal.it.msg },
- homepage: { ...msg_website.it.homepage, ...msgglobal.it.homepage },
+ homepage: { ...msg_website.it.homepage, ...msgglobal.it.homepage }
},
- es: { ...msges ,
+ es: {
+ ...msges,
pages: { ...msg_website.es.pages, ...msgglobal.es.pages },
msg: { ...msg_website.es.msg, ...msgglobal.es.msg },
homepage: { ...msg_website.es.homepage, ...msgglobal.es.homepage }
},
- enUs: { ...msgenUs ,
+ enUs: {
+ ...msgenUs,
pages: { ...msg_website.enUs.pages, ...msgglobal.enUs.pages },
msg: { ...msg_website.enUs.msg, ...msgglobal.enUs.msg },
homepage: { ...msg_website.enUs.homepage, ...msgglobal.enUs.homepage }
},
+ fr: {
+ ...msgfr,
+ pages: { ...msg_website.fr.pages, ...msgglobal.fr.pages },
+ msg: { ...msg_website.fr.msg, ...msgglobal.fr.msg },
+ homepage: { ...msg_website.fr.homepage, ...msgglobal.fr.homepage },
+ },
+ de: {
+ ...msgde,
+ pages: { ...msg_website.de.pages, ...msgglobal.de.pages },
+ msg: { ...msg_website.de.msg, ...msgglobal.de.msg },
+ homepage: { ...msg_website.de.homepage, ...msgglobal.de.homepage },
+ }
}
export default messages;
diff --git a/src/store/Modules/GlobalStore.ts b/src/store/Modules/GlobalStore.ts
index 349f70a..d90ce31 100644
--- a/src/store/Modules/GlobalStore.ts
+++ b/src/store/Modules/GlobalStore.ts
@@ -341,6 +341,10 @@ namespace Actions {
return
}
+ if (UserStore.state.userId === undefined || UserStore.state.tokens[0] === undefined) {
+ return
+ }
+
// console.log('saveSubscriptionToServer: ', newSub)
// console.log('context', context)
@@ -432,7 +436,7 @@ namespace Actions {
}
async function loadAfterLogin(context) {
- console.log('loadAfterLogin')
+ // console.log('loadAfterLogin')
actions.clearDataAfterLoginOnlyIfActiveConnection()
state.arrConfig = await globalroutines(null, 'readall', 'config', null)
diff --git a/src/store/Modules/Projects.ts b/src/store/Modules/Projects.ts
index 03fd4ee..599b6d3 100644
--- a/src/store/Modules/Projects.ts
+++ b/src/store/Modules/Projects.ts
@@ -14,6 +14,7 @@ import { costanti } from '@src/store/Modules/costanti'
import { RouteNames } from '@src/router/route-names'
import * as Types from '@src/store/Api/ApiTypes'
import { serv_constants } from '@src/store/Modules/serv_constants'
+import { static_data } from '@src/db/static_data'
const nametable = 'projects'
@@ -273,6 +274,9 @@ namespace Actions {
async function dbLoad(context, { checkPending, onlyiffirsttime }) {
+ if (!static_data.functionality.ENABLE_PROJECTS_LOADING)
+ return null
+
if (onlyiffirsttime) {
if (stateglob.projects.length > 0) {
// if already set, then exit.
@@ -438,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
new file mode 100644
index 0000000..80806f0
--- /dev/null
+++ b/src/store/Modules/Store/calendar/CalendarStore.ts
@@ -0,0 +1,189 @@
+import Api from '@api'
+import { IBookedEvent, ICalendarState, IEvents } from 'model'
+import { ILinkReg, IResult, IIdToken, IToken } from 'model/other'
+import { storeBuilder } from '../Store'
+
+import { serv_constants } from '../../serv_constants'
+import { tools } from '../../tools'
+
+import translate from '../../../../globalroutines/util'
+import * as Types from '../../../Api/ApiTypes'
+import { db_data } from '@src/db/db_data'
+import { UserStore } from '@store'
+
+// State
+const state: ICalendarState = {
+ editable: false,
+ eventlist: [],
+ bookedevent: [],
+ // ---------------
+ titlebarHeight: 0,
+ locale: 'it-IT',
+ maxDays: 1,
+ fiveDayWorkWeek: false,
+ shortMonthLabel: false,
+ showDayOfYearLabel: false,
+ shortWeekdayLabel: true,
+ shortIntervalLabel: false,
+ hour24Format: true,
+ hideHeader: false,
+ noScroll: false,
+ showMonthLabel: false,
+ showWorkWeeks: false,
+ intervalRange: { min: 9, max: 23 },
+ intervalRangeStep: 1,
+ intervalHeight: 35,
+ resourceHeight: 60,
+ resourceWidth: 100,
+ dayHeight: 100,
+ enableThemes: false,
+ theme: {}
+}
+
+const b = storeBuilder.module
('CalendarModule', state)
+const stateGetter = b.state()
+
+namespace Getters {
+
+ const findEventBooked = b.read((mystate: ICalendarState) => (myevent: IEvents, isconfirmed: boolean) => {
+ return mystate.bookedevent.find((bookedevent) => (bookedevent.id_bookedevent === myevent._id) && ((isconfirmed && bookedevent.booked) || (!isconfirmed)))
+ }, 'findEventBooked')
+
+ export const getters = {
+ get findEventBooked() {
+ return findEventBooked()
+ }
+ }
+
+}
+
+namespace Mutations {
+ // function authUser(state: ICalendarState, data: ICalendarState) {
+ // state.userId = data.userId
+ // }
+ //
+ // export const mutations = {
+ // authUser: b.commit(authUser),
+ // }
+
+}
+
+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
+
+ // Load local data
+ console.log('CALENDAR loadAfterLogin', 'userid=', UserStore.state.userId)
+
+ let ris = null
+
+ ris = await Api.SendReq('/booking/' + UserStore.state.userId + '/' + process.env.APP_ID, 'GET', null)
+ .then((res) => {
+ if (res.data.bookedevent) {
+ state.bookedevent = res.data.bookedevent
+ } else {
+ state.bookedevent = []
+ }
+ })
+ .catch((error) => {
+ console.log('error dbLoad', error)
+ // UserStore.mutations.setErrorCatch(error)
+ return new Types.AxiosError(serv_constants.RIS_CODE_ERR, null, tools.ERR_GENERICO, error)
+ })
+
+ return ris
+
+ }
+
+ function getparambyevent(bookevent) {
+ return {
+ id_bookedevent: bookevent.id_bookedevent,
+ infoevent: bookevent.infoevent,
+ numpeople: bookevent.numpeople,
+ msgbooking: bookevent.msgbooking,
+ datebooked: bookevent.datebooked,
+ userId: UserStore.state.userId,
+ booked: bookevent.booked,
+ }
+ }
+
+ async function BookEvent(context, bookevent: IBookedEvent) {
+ console.log('BookEvent', bookevent)
+
+ const param = getparambyevent(bookevent)
+
+ return await Api.SendReq('/booking', 'POST', param)
+ .then((res) => {
+ if (res.status === 200) {
+ if (res.data.code === serv_constants.RIS_CODE_OK) {
+ state.bookedevent.push(bookevent)
+ return true
+ }
+ }
+ return false
+ })
+ .catch((error) => {
+ console.error(error)
+ return false
+ })
+
+ }
+
+ async function CancelBookingEvent(context, event: IEvents) {
+ console.log('CALSTORE: CancelBookingEvent', event)
+
+ const myeventtoCancel = state.bookedevent.find((eventbooked) => (eventbooked.id_bookedevent === event._id))
+
+ const param = getparambyevent(myeventtoCancel)
+ param.booked = false // Cancel Booking
+
+ return await Api.SendReq('/booking', 'POST', param)
+ .then((res) => {
+ if (res.status === 200) {
+ if (res.data.code === serv_constants.RIS_CODE_OK) {
+
+ state.bookedevent = state.bookedevent.filter((eventbooked) => (eventbooked.id_bookedevent !== event._id))
+
+ return true
+ }
+ }
+ return false
+
+ })
+ .catch((error) => {
+ console.error(error)
+ // UserStore.mutations.setErrorCatch(error)
+ return false
+ })
+
+
+ }
+
+ export const actions = {
+ loadAfterLogin: b.dispatch(loadAfterLogin),
+ BookEvent: b.dispatch(BookEvent),
+ CancelBookingEvent: b.dispatch(CancelBookingEvent)
+ }
+
+ // async function resetpwd(context, paramquery: ICalendarState) {
+ // }
+ //
+ // export const actions = {
+ // autologin_FromLocalStorage: b.dispatch(autologin_FromLocalStorage)
+ // }
+}
+
+// Module
+const CalendarModule = {
+ get state() {
+ return stateGetter()
+ },
+ actions: Actions.actions,
+ getters: Getters.getters
+ // mutations: Mutations.mutations
+}
+
+export default CalendarModule
diff --git a/src/store/Modules/Todos.ts b/src/store/Modules/Todos.ts
index 1bad772..3335c7b 100644
--- a/src/store/Modules/Todos.ts
+++ b/src/store/Modules/Todos.ts
@@ -15,6 +15,7 @@ import objectId from '@src/js/objectId'
import { costanti } from '@src/store/Modules/costanti'
import { IAction } from '@src/model'
import * as Types from '@src/store/Api/ApiTypes'
+import { static_data } from '@src/db/static_data'
const nametable = 'todos'
@@ -217,7 +218,7 @@ namespace Mutations {
ApiTables.removeitemfromarray(stateparam.todos[indcat], ind)
}
- async function movemyitem(stateparam: ITodosState, { myitemorig, myitemdest } ) {
+ async function movemyitem(stateparam: ITodosState, { myitemorig, myitemdest }) {
const indcat = stateparam.categories.indexOf(myitemorig.category)
const indorig = tools.getIndexById(stateparam.todos[indcat], myitemorig._id)
@@ -251,13 +252,19 @@ namespace Mutations {
namespace Actions {
async function dbLoad(context, { checkPending }) {
+
+ if (!static_data.functionality.ENABLE_PROJECTS_LOADING)
+ return null
+
console.log('dbLoad', nametable, checkPending, 'userid=', UserStore.state.userId)
// if (UserStore.state.userId === '') {
// return new Types.AxiosError(0, null, 0, '')
// }
- const ris = await Api.SendReq('/todos/' + UserStore.state.userId, 'GET', null)
+ let ris = null
+
+ ris = await Api.SendReq('/todos/' + UserStore.state.userId, 'GET', null)
.then((res) => {
if (res.data.todos) { // console.log('RISULTANTE CATEGORIES DAL SERVER = ', res.data.categories)
state.todos = res.data.todos
diff --git a/src/store/Modules/UserStore.ts b/src/store/Modules/UserStore.ts
index 6364554..fdb2f19 100644
--- a/src/store/Modules/UserStore.ts
+++ b/src/store/Modules/UserStore.ts
@@ -7,9 +7,11 @@ 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 { static_data } from '@src/db/static_data'
+
import translate from './../../globalroutines/util'
import * as Types from '@src/store/Api/ApiTypes'
@@ -20,6 +22,8 @@ const state: IUserState = {
userId: '',
email: '',
username: '',
+ name: '',
+ surname: '',
password: '',
lang: process.env.LANG_DEFAULT,
repeatPassword: '',
@@ -108,6 +112,8 @@ namespace Mutations {
function authUser(state: IUserState, data: IUserState) {
state.userId = data.userId
state.username = data.username
+ state.name = data.name
+ state.surname = data.surname
if (data.verified_email) {
state.verified_email = data.verified_email
}
@@ -176,6 +182,8 @@ namespace Mutations {
function clearAuthData(state: IUserState) {
state.userId = ''
state.username = ''
+ state.name = ''
+ state.surname = ''
resetArrToken(state.tokens)
state.x_auth_token = ''
state.verified_email = false
@@ -221,7 +229,6 @@ namespace Mutations {
setErrorCatch: b.commit(setErrorCatch),
getMsgError: b.commit(getMsgError)
}
-
}
namespace Actions {
@@ -318,6 +325,8 @@ namespace Actions {
email: authData.email,
password: String(hashedPassword),
username: authData.username,
+ name: authData.name,
+ surname: authData.surname,
}
console.log(usertosend)
@@ -336,6 +345,8 @@ namespace Actions {
if (res.status === 200) {
const userId = newuser._id
const username = authData.username
+ const name = authData.name
+ const surname = authData.surname
if (process.env.DEV) {
console.log('USERNAME = ' + username)
console.log('IDUSER= ' + userId)
@@ -344,6 +355,8 @@ namespace Actions {
Mutations.mutations.authUser({
userId,
username,
+ name,
+ surname,
verified_email: false
})
@@ -353,6 +366,8 @@ namespace Actions {
localStorage.setItem(tools.localStorage.lang, state.lang)
localStorage.setItem(tools.localStorage.userId, userId)
localStorage.setItem(tools.localStorage.username, username)
+ localStorage.setItem(tools.localStorage.name, name)
+ localStorage.setItem(tools.localStorage.surname, surname)
localStorage.setItem(tools.localStorage.token, state.x_auth_token)
localStorage.setItem(tools.localStorage.expirationDate, expirationDate.toString())
localStorage.setItem(tools.localStorage.verified_email, String(false))
@@ -438,11 +453,15 @@ namespace Actions {
if (myuser) {
const userId = myuser.userId
const username = authData.username
+ const name = myuser.name
+ const surname = myuser.surname
const verified_email = myuser.verified_email
Mutations.mutations.authUser({
userId,
username,
+ name,
+ surname,
verified_email
})
@@ -452,6 +471,8 @@ namespace Actions {
localStorage.setItem(tools.localStorage.lang, state.lang)
localStorage.setItem(tools.localStorage.userId, userId)
localStorage.setItem(tools.localStorage.username, username)
+ localStorage.setItem(tools.localStorage.name, name)
+ localStorage.setItem(tools.localStorage.surname, surname)
localStorage.setItem(tools.localStorage.token, state.x_auth_token)
localStorage.setItem(tools.localStorage.expirationDate, expirationDate.toString())
localStorage.setItem(tools.localStorage.isLogged, String(true))
@@ -486,6 +507,8 @@ namespace Actions {
localStorage.removeItem(tools.localStorage.token)
localStorage.removeItem(tools.localStorage.userId)
localStorage.removeItem(tools.localStorage.username)
+ localStorage.removeItem(tools.localStorage.name)
+ localStorage.removeItem(tools.localStorage.surname)
localStorage.removeItem(tools.localStorage.isLogged)
// localStorage.removeItem(rescodes.localStorage.leftDrawerOpen)
localStorage.removeItem(tools.localStorage.verified_email)
@@ -512,26 +535,33 @@ namespace Actions {
}
async function setGlobal(isLogged: boolean) {
- state.isLogged = true
- console.log('state.isLogged')
+ // console.log('setGlobal')
+ // state.isLogged = true
+ state.isLogged = isLogged
if (isLogged) {
+ console.log('state.isLogged')
GlobalStore.mutations.setleftDrawerOpen(localStorage.getItem(tools.localStorage.leftDrawerOpen) === 'true')
GlobalStore.mutations.setCategorySel(localStorage.getItem(tools.localStorage.categorySel))
GlobalStore.actions.checkUpdates()
}
- return await GlobalStore.actions.loadAfterLogin()
- .then(() => {
- return Todos.actions.dbLoad({ checkPending: true })
- }).then(() => {
- return Projects.actions.dbLoad({ checkPending: true, onlyiffirsttime: true })
- })
+ const p = await BookingStore.actions.loadAfterLogin()
+ const p2 = await CalendarStore.actions.loadAfterLogin()
+
+ const p3 = await GlobalStore.actions.loadAfterLogin()
+
+ if (static_data.functionality.ENABLE_TODOS_LOADING)
+ await Todos.actions.dbLoad({ checkPending: true })
+
+ if (static_data.functionality.ENABLE_PROJECTS_LOADING)
+ await Projects.actions.dbLoad({ checkPending: true, onlyiffirsttime: true })
+
}
async function autologin_FromLocalStorage(context) {
try {
- console.log('*** autologin_FromLocalStorage ***')
+ // console.log('*** autologin_FromLocalStorage ***')
// INIT
let isLogged = false
@@ -546,6 +576,8 @@ namespace Actions {
if (now < expirationDate) {
const userId = String(localStorage.getItem(tools.localStorage.userId))
const username = String(localStorage.getItem(tools.localStorage.username))
+ const name = String(localStorage.getItem(tools.localStorage.name))
+ const surname = String(localStorage.getItem(tools.localStorage.surname))
const verified_email = localStorage.getItem(tools.localStorage.verified_email) === 'true'
GlobalStore.state.wasAlreadySubOnDb = localStorage.getItem(tools.localStorage.wasAlreadySubOnDb) === 'true'
@@ -557,6 +589,8 @@ namespace Actions {
Mutations.mutations.authUser({
userId,
username,
+ name,
+ surname,
verified_email
})
@@ -566,7 +600,7 @@ namespace Actions {
await setGlobal(isLogged)
- console.log('autologin userId STATE ', state.userId)
+ // console.log('autologin userId STATE ', state.userId)
return true
} catch (e) {
diff --git a/src/store/Modules/costanti.ts b/src/store/Modules/costanti.ts
index 4466cac..b471020 100644
--- a/src/store/Modules/costanti.ts
+++ b/src/store/Modules/costanti.ts
@@ -10,5 +10,9 @@ export const costanti = {
CONFIG_ID_STATE_CONN: '2',
CONFIG_ID_SHOW_TYPE_TODOS: '3',
+ FuncDialog: {
+ CANCEL_BOOKING: 1
+ },
+
MAX_PHASES: 5,
}
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'
diff --git a/src/store/Modules/serv_constants.ts b/src/store/Modules/serv_constants.ts
index 2b37d20..ea6f327 100644
--- a/src/store/Modules/serv_constants.ts
+++ b/src/store/Modules/serv_constants.ts
@@ -11,6 +11,10 @@ export const serv_constants = {
RIS_CODE_OK: 1,
RIS_CODE_LOGIN_OK: 1,
- RIS_CODE__HTTP_FORBIDDEN_INVALID_TOKEN: 403
+ RIS_CODE__HTTP_FORBIDDEN_INVALID_TOKEN: 403,
+
+ RIS_SUBSCRIBED_OK: 1,
+ RIS_SUBSCRIBED_ALREADYEXIST: 2,
+ RIS_SUBSCRIBED_ERR: -1
}
diff --git a/src/store/Modules/tools.ts b/src/store/Modules/tools.ts
index 1260fac..d304198 100644
--- a/src/store/Modules/tools.ts
+++ b/src/store/Modules/tools.ts
@@ -1,16 +1,17 @@
-import { Todos, Projects, UserStore } from '@store'
+import { Todos, Projects, UserStore, CalendarStore } from '@store'
import globalroutines from './../../globalroutines/index'
import { costanti } from './costanti'
import { toolsext } from './toolsext'
import { translation } from './translation'
import Quasar, { date, Screen } from 'quasar'
-import { IListRoutes, IMenuList, IProject, ITodo, Privacy } from '@src/model'
+import { ICollaborations, IListRoutes, IMenuList, IParamDialog, IProject, ITodo, Privacy } from '@src/model'
import * as ApiTables from '@src/store/Modules/ApiTables'
import translate from '@src/globalroutines/util'
import { RouteNames } from '@src/router/route-names'
import { lists } from './lists'
-import { shen } from '@src/database/shen'
+import { static_data } from '@src/db/static_data'
+import { IColl, ITimeLineEntry, ITimeLineMain } from '@src/model/GlobalStore'
export interface INotify {
color?: string | 'primary'
@@ -30,6 +31,8 @@ export const tools = {
DUPLICATE_EMAIL_ID: 11000,
DUPLICATE_USERNAME_ID: 11100,
+ TYPE_AUDIO: 1,
+
NUMSEC_CHECKUPDATE: 20000,
FIRST_PROJ: '5ca8f17fcd40dc5012f53346',
@@ -38,7 +41,7 @@ export const tools = {
WHAT_TODO: 1,
WHAT_PROJECT: 2,
- arrLangUsed: ['enUs', 'it', 'es'],
+ languageid: 5,
SERVKEY_VERS: 'vers',
@@ -52,6 +55,8 @@ export const tools = {
userId: 'uid',
token: 'tk',
username: 'uname',
+ name: 'nm',
+ surname: 'sn',
lang: 'lg'
},
@@ -67,6 +72,35 @@ export const tools = {
COMPLETED: 10
},
+ SelectListNumPeople: [
+ {
+ id: 1,
+ label: '1',
+ value: 1
+ },
+ {
+ id: 2,
+ label: '2',
+ value: 2
+ },
+ {
+ id: 3,
+ label: '3',
+ value: 3
+ },
+ {
+ id: 4,
+ label: '4',
+ value: 4
+ },
+ {
+ id: 5,
+ label: '5',
+ value: 5
+ },
+ ]
+ ,
+
selectPhase: {
it: [
{
@@ -1264,8 +1298,48 @@ export const tools = {
result.push(json[key])
})
return result
- }
- ,
+ },
+
+ executefunc(myself: any, myfunc: number, par: IParamDialog) {
+ if (myfunc === costanti.FuncDialog.CANCEL_BOOKING) {
+ console.log(' ENTRATO ! CancelBookingEvent ')
+ CalendarStore.actions.CancelBookingEvent(par.param1).then(ris => {
+ if (ris)
+ tools.showPositiveNotif(myself.$q, myself.$t('cal.canceledbooking') + ' "' + par.param1.title + '"')
+ else
+ tools.showNegativeNotif(myself.$q, myself.$t('cal.cancelederrorbooking'))
+ })
+ }
+ },
+
+ async askConfirm($q: any, mytitle, mytext, ok, cancel, myself: any, funcok: number, funccancel: number, par: IParamDialog) {
+ return $q.dialog({
+ message: mytext,
+ ok: {
+ label: ok,
+ push: true
+ },
+ title: mytitle,
+ cancel: true,
+ persistent: false
+ }).onOk(() => {
+ console.log('OK')
+ tools.executefunc(myself, funcok, par)
+ return true
+ }).onCancel(() => {
+ console.log('CANCEL')
+ tools.executefunc(myself, funccancel, par)
+ return false
+ })
+ },
+
+ showPositiveNotif(q: any, msg) {
+ tools.showNotif(q, msg, { color: 'positive', icon: 'notifications' })
+ },
+
+ showNegativeNotif(q: any, msg) {
+ tools.showNotif(q, msg, { color: 'negative', icon: 'notifications' })
+ },
showNotif(q: any, msg, data ?: INotify | null
) {
@@ -1310,7 +1384,7 @@ export const tools = {
,
checkLangPassed(mylang) {
- console.log('checkLangPassed')
+ // console.log('checkLangPassed')
const mybrowserLang = Quasar.lang.isoName
@@ -1321,10 +1395,16 @@ export const tools = {
if ((mylang.toLowerCase() === 'es') || (mylang.toLowerCase() === 'es-es') || (mylang.toLowerCase() === 'eses')) {
mylang = 'es'
}
+ if ((mylang.toLowerCase() === 'fr') || (mylang.toLowerCase() === 'fr-fr') || (mylang.toLowerCase() === 'frfr')) {
+ mylang = 'fr'
+ }
+ if ((mylang.toLowerCase() === 'it') || (mylang.toLowerCase() === 'it-it') || (mylang.toLowerCase() === 'itit')) {
+ mylang = 'it'
+ }
- if (!(tools.arrLangUsed.includes(mylang))) {
+ if (!(static_data.arrLangUsed.includes(mylang))) {
console.log('non incluso ', mylang)
- mylang = tools.arrLangUsed[0]
+ mylang = static_data.arrLangUsed[0]
// Metti Inglese come default
UserStore.mutations.setlang(mylang)
@@ -1339,7 +1419,7 @@ export const tools = {
UserStore.mutations.setlang(mylang)
}
- console.log('mylang calc : ', mylang)
+ // console.log('mylang calc : ', mylang)
return mylang
},
@@ -1519,6 +1599,14 @@ export const tools = {
return ''
}
,
+ getstrMMMDate(mytimestamp) {
+ // console.log('getstrDate', mytimestamp)
+ if (!!mytimestamp)
+ return date.formatDate(mytimestamp, 'DD MMM YYYY')
+ else
+ return ''
+ }
+ ,
getstrYYMMDDDate(mytimestamp) {
return date.formatDate(mytimestamp, 'YYYY-MM-DD')
}
@@ -1589,26 +1677,26 @@ export const tools = {
return '/' + tipoproj + '/'
},
- convertMenuListInListRoutes(arrlista: IMenuList[]) {
- const lista = []
- if (arrlista === undefined)
- return lista
- for (const elem of arrlista) {
- const item: IListRoutes = {
- faIcon: 'fa fa-list-alt',
- materialIcon: elem.icon,
- name: elem.nametranslate,
- text: elem.description,
- route: tools.getUrlByTipoProj(false, elem.urlroute) + elem.idelem,
- routes2: tools.convertMenuListInListRoutes(elem.routes2),
- level_parent: elem.level_parent,
- level_child: elem.level_child
-
- }
- lista.push(item)
- }
- return lista
- },
+ // convertMenuListInListRoutes(arrlista: IMenuList[]) {
+ // const lista = []
+ // if (arrlista === undefined)
+ // return lista
+ // for (const elem of arrlista) {
+ // const item: IListRoutes = {
+ // faIcon: 'fa fa-list-alt',
+ // materialIcon: elem.icon,
+ // name: elem.nametranslate,
+ // text: elem.description,
+ // path: tools.getUrlByTipoProj(false, elem.urlroute) + elem.idelem,
+ // routes2: tools.convertMenuListInListRoutes(elem.routes2),
+ // level_parent: elem.level_parent,
+ // level_child: elem.level_child
+ //
+ // }
+ // lista.push(item)
+ // }
+ // return lista
+ // },
getprivacyreadbytipoproj(tipoproj) {
if (tipoproj === RouteNames.myprojects)
@@ -1721,14 +1809,51 @@ export const tools = {
}
},
- myheight_imgtitle() {
- if (Screen.width < 400) {
- return '250'
- } else if (Screen.width < 600) {
- return '350'
+ myheight_imgtitle(myheight?, myheightmobile?) {
+ let maxheight = 0
+ if (!!myheight) {
+ maxheight = myheight
+ if (myheight > 0) {
+ if (myheight > 1000) {
+ maxheight = 1000
+ } else {
+ maxheight = parseInt(myheight, 10)
+ }
+ }
} else {
- return '350'
+ maxheight = 500
}
+
+ let maxh2 = 0
+ if (Screen.width < 400) {
+ maxh2 = 350
+ } else if (Screen.width < 600) {
+ maxh2 = 400
+ } else if (Screen.width < 800) {
+ maxh2 = 450
+ } else if (Screen.width < 1000) {
+ maxh2 = 500
+ } else {
+ maxh2 = 500
+ }
+
+ console.log('maxh2', maxh2)
+ console.log('maxheight', maxheight)
+
+ let ris = 0
+
+ if (maxh2 < maxheight)
+ ris = maxh2
+ else
+ ris = maxheight
+
+ if (!!myheightmobile) {
+ if (this.isMobile() && maxh2 > myheightmobile)
+ ris = parseInt(myheightmobile, 10)
+ }
+
+ console.log('ris', ris)
+ return ris
},
myheight_dialog() {
@@ -1741,11 +1866,15 @@ export const tools = {
}
},
- styles_imgtitle() {
- if (Screen.width < 400) {
- return 'max-height: 250px'
+ styles_imgtitle(sized?: string) {
+ if (!!sized) {
+ return sized
} else {
- return 'max-height: 350px'
+ if (Screen.width < 400) {
+ return 'max-height: 250px'
+ } else {
+ return 'max-height: 350px'
+ }
}
},
@@ -1783,6 +1912,10 @@ export const tools = {
}
},
+ isMobile() {
+ return (Screen.width < 400)
+ },
+
mywidth_imgtitle() {
if (Screen.width < 400) {
return '250'
@@ -1829,6 +1962,118 @@ export const tools = {
addDays(mydate, days) {
return date.addToDate(mydate, { days })
+ },
+
+ gettitlemain(datamain: ITimeLineMain) {
+ if (datamain.titlemain[toolsext.getLocale()])
+ return datamain.titlemain[toolsext.getLocale()]
+ else {
+ return datamain.titlemain[static_data.arrLangUsed[0]]
+ }
+
+ },
+ getwwithwhocoll(datamain: ICollaborations) {
+ if (datamain.withwhom_title[toolsext.getLocale()])
+ return datamain.withwhom_title[toolsext.getLocale()]
+ else {
+ return datamain.withwhom_title[static_data.arrLangUsed[0]]
+ }
+
+ },
+ gettextcoll(data: IColl) {
+ if (data.subtitle[toolsext.getLocale()])
+ return data.subtitle[toolsext.getLocale()]
+ else {
+ return data.subtitle[static_data.arrLangUsed[0]]
+ }
+ },
+ gettitlecoll(data: IColl) {
+ if (data.title[toolsext.getLocale()])
+ return data.title[toolsext.getLocale()]
+ else {
+ return data.title[static_data.arrLangUsed[0]]
+ }
+ },
+ gettextdescr(data: ITimeLineEntry, numdescr = 'description') {
+ if (!!data[numdescr]) {
+ if (data[numdescr][toolsext.getLocale()])
+ return data[numdescr][toolsext.getLocale()]
+ else {
+ return data[numdescr][static_data.arrLangUsed[0]]
+ }
+ } else {
+ return ''
+ }
+ },
+
+ getlink(data: ITimeLineEntry) {
+ if (data.link_text[toolsext.getLocale()])
+ return data.link_text[toolsext.getLocale()]
+ else {
+ return data.link_text[static_data.arrLangUsed[0]]
+ }
+
+ },
+
+ getlinkurl(data: ITimeLineEntry) {
+ if (data.link_url_lang) {
+ if (data.link_url_lang[toolsext.getLocale()]) {
+ return data.link_url_lang[toolsext.getLocale()]
+ } else {
+ return data.link_url
+ }
+ } else {
+ return data.link_url
+ }
+
+ },
+
+ appid() {
+ return process.env.APP_ID
+ },
+
+ getLabelByItem(item, mythis) {
+ if (!!item.name)
+ return mythis.$t(item.name)
+ else
+ return item.text
+
+ },
+
+ getimgbysize(dir: string, file: string) {
+ const myimage = dir + file
+ // console.log('includes = ', static_data.preLoadImages.map((a) => a.imgname).includes(myimage), myimage)
+ let ris = ''
+ if (this.isMobile() && (static_data.preLoadImages.map((a) => a.imgname).includes(myimage))) {
+ ris = dir + 'mobile/' + file
+ } else {
+ ris = myimage
+ }
+
+ // console.log('getimgbysize', ris)
+
+ return ris
+ },
+
+ getimgFullpathbysize(fileimg: string) {
+ const ind = fileimg.lastIndexOf('/')
+ if (ind > 0) {
+ return { path: fileimg.substring(0, ind + 1) , file: fileimg.substring(ind + 1) }
+ } else {
+ return { path: '', file: fileimg }
+ }
+
+ },
+
+ convertHTMLtoText(myhtml) {
+ let msg = myhtml
+ msg = msg.replace('"', '"')
+ msg = msg.replace('>', '>')
+ msg = msg.replace('<', '<')
+ msg = msg.replace('&', '&')
+ msg = msg.replace('
', '\n')
+
+ return msg
}
// getLocale() {
diff --git a/src/store/Modules/toolsext.ts b/src/store/Modules/toolsext.ts
new file mode 100644
index 0000000..2e429ce
--- /dev/null
+++ b/src/store/Modules/toolsext.ts
@@ -0,0 +1,52 @@
+import { UserStore } from '@store'
+
+export const toolsext = {
+ getLocale(vero?: boolean) {
+ if (UserStore) {
+ if (UserStore.state) {
+ return UserStore.state.lang
+ }
+ }
+ return process.env.LANG_DEFAULT
+ },
+ isLang(whichlang) {
+ const loc = func_tools.getLocale()
+ return (loc === whichlang)
+ }
+}
+
+export const func_tools = {
+ getLocale(vero?: boolean) {
+ if (UserStore) {
+ if (UserStore.state) {
+ return UserStore.state.lang
+ }
+ }
+ return ''
+ },
+
+ getDateStr(mydate) {
+ const DateFormatter = new Intl.DateTimeFormat(func_tools.getLocale() || void 0, {
+ weekday: 'short',
+ day: 'numeric',
+ month: 'long',
+ year: 'numeric'
+ // timeZone: 'UTC'
+ })
+ if (DateFormatter) {
+ const date = new Date(mydate)
+ return DateFormatter.format(date)
+ }
+ return mydate
+ }
+}
+
+// export const costanti_tools = {
+// DateFormatter: new Intl.DateTimeFormat(func_tools.getLocale() || void 0, {
+// weekday: 'long',
+// day: 'numeric',
+// month: 'long',
+// year: 'numeric'
+// // timeZone: 'UTC'
+// })
+// }
diff --git a/src/store/index.ts b/src/store/index.ts
index b41c4f8..3eec91e 100644
--- a/src/store/index.ts
+++ b/src/store/index.ts
@@ -9,7 +9,7 @@ import { IProgressState } from '@types'
export interface RootState {
GlobalModule: IGlobalState
- route: Route
+ path: Route
}
Vue.use(Vuex)
diff --git a/src/views/login/logoData.ts b/src/views/login/logoData.ts
new file mode 100644
index 0000000..51ba008
--- /dev/null
+++ b/src/views/login/logoData.ts
@@ -0,0 +1,90 @@
+/* eslint-disable */
+export default {
+ Digitalizer: `
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ `,
+ Keytronic:
+ `
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ `,
+ Molectron: `
+
+
+ `
+
+}
diff --git a/src/views/login/signup/signup-validate.ts b/src/views/login/signup/signup-validate.ts
index e1a3d2c..b23a420 100644
--- a/src/views/login/signup/signup-validate.ts
+++ b/src/views/login/signup/signup-validate.ts
@@ -19,6 +19,12 @@ export const validations = {
registereduser,
required
},
+ name: {
+ required
+ },
+ surname: {
+ required
+ },
email: {
email,
registeredemail,
diff --git a/src/views/login/signup/signup.ts b/src/views/login/signup/signup.ts
index 45ac6ca..7d1658c 100644
--- a/src/views/login/signup/signup.ts
+++ b/src/views/login/signup/signup.ts
@@ -30,9 +30,11 @@ export default class Signup extends Vue {
public signup: ISignupOptions = {
email: process.env.TEST_EMAIL || '',
username: process.env.TEST_USERNAME || '',
+ name: process.env.TEST_NAME || '',
+ surname: process.env.TEST_SURNAME || '',
password: process.env.TEST_PASSWORD || '',
repeatPassword: process.env.TEST_PASSWORD || '',
- terms: process.env.PROD ? false : true
+ terms: !process.env.PROD
}
public created() {
@@ -107,6 +109,9 @@ export default class Signup extends Vue {
} else if (cosa === 'username') {
// console.log(item);
if (!item.isUnique) { return this.$t('reg.err.duplicate_username') }
+ } else if ((cosa === 'name') || (cosa === 'surname')) {
+ // console.log(item);
+
}
if (!item.complexity) { return this.$t('reg.err.complexity') }
diff --git a/src/views/login/signup/signup.vue b/src/views/login/signup/signup.vue
index 7dafa8e..aef1438 100644
--- a/src/views/login/signup/signup.vue
+++ b/src/views/login/signup/signup.vue
@@ -41,6 +41,38 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Preventivo Sito Web
+
+
+
+ Funzionalità Incluse
+
+
+
+
+
+
+
+
+
+
+ {{rec.title}}
+
+
+
+
+
+
+
+ Funzionalità Aggiuntive
+
+
+
+
+ Pagine:
+ {{getNumpagTotal()}}
+
+ Totale:
+ {{getTotal()}} €
+
+
+
+
+
+
+
+
+
+ {{rec.title}}
+
+
+ {{getPrice(rec)}} €
+
+
+
+
+
+
+
+
+
+
+ Pagine:
+ {{getNumpagTotal()}}
+
+ Totale:
+ {{getTotal()}} €
+
+
+
+
+
+
+
diff --git a/src/views/pages/estimate/index.ts b/src/views/pages/estimate/index.ts
new file mode 100644
index 0000000..2594d34
--- /dev/null
+++ b/src/views/pages/estimate/index.ts
@@ -0,0 +1 @@
+export {default as estimate} from './estimate.vue'