Se aggiungo un campo nuovo, non viene visualizzato il campo, sistemare il cookie come viene gestito
Aggiungere campo Offro/Cerco Aggiungere HOME con pulsantoni grandi Aggiunto Link per condividere la APP ai propri Amici
BIN
public/images/images/pdnm-android-icon-144x144.png
Normal file
|
After Width: | Height: | Size: 49 KiB |
BIN
public/images/images/pdnm-android-icon-192x192.png
Normal file
|
After Width: | Height: | Size: 86 KiB |
BIN
public/images/images/pdnm-android-icon-48x48.png
Normal file
|
After Width: | Height: | Size: 6.9 KiB |
BIN
public/images/images/pdnm-android-icon-96x96.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
BIN
public/images/images/pdnm-apple-icon-114x114.png
Normal file
|
After Width: | Height: | Size: 32 KiB |
BIN
public/images/images/pdnm-apple-icon-120x120.png
Normal file
|
After Width: | Height: | Size: 35 KiB |
BIN
public/images/images/pdnm-apple-icon-144x144.png
Normal file
|
After Width: | Height: | Size: 49 KiB |
BIN
public/images/images/pdnm-apple-icon-152x152.png
Normal file
|
After Width: | Height: | Size: 54 KiB |
BIN
public/images/images/pdnm-apple-icon-180x180.png
Normal file
|
After Width: | Height: | Size: 74 KiB |
0
src/components/CBigBtn/CBigBtn.scss
Executable file
45
src/components/CBigBtn/CBigBtn.ts
Executable file
@@ -0,0 +1,45 @@
|
||||
import { defineComponent, ref, computed, PropType, toRef } from 'vue'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
import { useI18n } from '@/boot/i18n'
|
||||
import { tools } from '@store/Modules/tools'
|
||||
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CBigBtn',
|
||||
components: {},
|
||||
props: {
|
||||
label: {
|
||||
type: String,
|
||||
required: true
|
||||
},
|
||||
to: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: ''
|
||||
},
|
||||
icon: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: ''
|
||||
},
|
||||
color: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: 'grey'
|
||||
},
|
||||
},
|
||||
setup(props, { emit }) {
|
||||
|
||||
const userStore = useUserStore()
|
||||
const $router = useRouter()
|
||||
const globalStore = useGlobalStore()
|
||||
const { t } = useI18n();
|
||||
|
||||
return {
|
||||
userStore,
|
||||
tools,
|
||||
}
|
||||
}
|
||||
})
|
||||
17
src/components/CBigBtn/CBigBtn.vue
Executable file
@@ -0,0 +1,17 @@
|
||||
<template>
|
||||
<div class="q-pa-xs col-xs-6 col-sm-6 col-md-4 col-lg-2">
|
||||
<div class="q-ma-sm">
|
||||
<q-btn :color="color" rounded :to="to" v-bind="$attrs">
|
||||
<q-icon class="q-ma-sm" size="4em" :name="icon"/>
|
||||
<div class="q-ma-sm text-h5">{{ label }}</div>
|
||||
</q-btn>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./CBigBtn.ts">
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './CBigBtn.scss';
|
||||
</style>
|
||||
1
src/components/CBigBtn/index.ts
Executable file
@@ -0,0 +1 @@
|
||||
export {default as CBigBtn} from './CBigBtn.vue'
|
||||
@@ -343,7 +343,7 @@
|
||||
</q-form>
|
||||
</q-card-section>
|
||||
<q-card-actions align="right">
|
||||
<q-btn flat :label="$t('dialog.ok')" color="primary" @click="saveEvent"></q-btn>
|
||||
<q-btn :label="$t('dialog.ok')" color="primary" @click="saveEvent"></q-btn>
|
||||
<q-btn flat :label="$t('dialog.cancel')" color="primary" v-close-popup></q-btn>
|
||||
</q-card-actions>
|
||||
</q-card>
|
||||
|
||||
@@ -252,6 +252,7 @@ export default defineComponent({
|
||||
let returnedData: any = ref([])
|
||||
let returnedCount = 0
|
||||
const colVisib: any = ref([])
|
||||
const colNotVisib: any = ref([])
|
||||
const colExtra: any = ref([])
|
||||
|
||||
const rowclicksel = ref(<any>null)
|
||||
@@ -816,6 +817,7 @@ export default defineComponent({
|
||||
// console.log('updatedcol')
|
||||
if (mycolumns.value) {
|
||||
colVisib.value = []
|
||||
colNotVisib.value = []
|
||||
colExtra.value = []
|
||||
mycolumns.value.forEach((elem: IColGridTable) => {
|
||||
|
||||
@@ -824,6 +826,8 @@ export default defineComponent({
|
||||
if (elem.field !== costanti.NOFIELD) {
|
||||
if (checkIfColShow(elem.field)) {
|
||||
colVisib.value.push(elem.field + mysub)
|
||||
} else {
|
||||
colNotVisib.value.push(elem.field + mysub)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1041,7 +1045,23 @@ export default defineComponent({
|
||||
function changeCol(newval: any) {
|
||||
// console.log('changecol', mytable.value)
|
||||
if (!!mytable.value) {
|
||||
tools.setCookie(mytable.value, colVisib.value.join('|'))
|
||||
let arrcol = []
|
||||
let col: IColGridTable = {name: ''}
|
||||
for (col of mycolumns.value) {
|
||||
if (col.field !== costanti.NOFIELD) {
|
||||
let obj = {
|
||||
n: col.field + (col.subfield ? col.subfield : ''),
|
||||
v: 0
|
||||
}
|
||||
obj.v = colVisib.value.includes(obj.n) ? 1 : 0
|
||||
if (obj.v === 0) {
|
||||
// scrive solo quelli da nascondere !
|
||||
arrcol.push(obj.n + ',' + obj.v)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
tools.setCookie(mytable.value + '_', arrcol.join('|'))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1100,17 +1120,46 @@ export default defineComponent({
|
||||
updatedcol()
|
||||
|
||||
if (!!mytable.value) {
|
||||
const myselcol = tools.getCookie(mytable.value, '')
|
||||
if (!!myselcol && myselcol.length > 0) {
|
||||
colVisib.value = myselcol.split('|')
|
||||
} else {
|
||||
mycolumns.value.forEach((elem: any) => {
|
||||
// Leggi la lista delle colonne visibili:
|
||||
const myselcol = tools.getCookie(mytable.value + '_', '')
|
||||
|
||||
colVisib.value = []
|
||||
|
||||
let elem: IColGridTable
|
||||
for (elem of mycolumns.value) {
|
||||
if (elem.field !== costanti.NOFIELD) {
|
||||
if (checkIfColShow(elem.field)) {
|
||||
colVisib.value.push(elem.field + elem.subfield)
|
||||
colVisib.value.push(elem.field! + elem.subfield!)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (!!myselcol && myselcol.length > 0) {
|
||||
const arrselcol = myselcol.split('|')
|
||||
|
||||
for (const col of arrselcol) {
|
||||
const arrv = col.split(',')
|
||||
if (arrv.length > 1) {
|
||||
let field = arrv[0]
|
||||
let visib = arrv[1]
|
||||
const rec = mycolumns.value.find((rec: any) => (rec.field + rec.subfield) === field)
|
||||
|
||||
|
||||
if (rec) {
|
||||
if (field) {
|
||||
if (visib === '1') {
|
||||
if (!colVisib.value.includes(field))
|
||||
colVisib.value.push(field) // se non incluso allora lo aggiungi
|
||||
} else if (visib === '0') {
|
||||
// Se da togliere, lo togli
|
||||
if (colVisib.value.includes(field))
|
||||
colVisib.value = colVisib.value.filter((rec: any) => rec !== field)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -349,7 +349,10 @@
|
||||
<q-card :class="props.selected ? 'bg-grey-2 my-card-withshadow no-padding' : 'my-card-withshadow no-padding'"
|
||||
style="background: radial-gradient(circle, #ffffff 0%, #bbddff 100%)">
|
||||
<q-bar v-if="!visuinpage && canModifyThisRec(props.row)" dense class="bg-primary text-white full-height">
|
||||
<span v-if="props.row['username']">{{props.row['username']}}</span>
|
||||
<q-badge v-if="props.row['adType']" :color="props.row['adType'] === 1 ? 'green' : 'red'">
|
||||
{{ fieldsTable.getValByTabAndId(tablesel, 'adType', props.row['adType']) }}<q-icon :name="props.row['adType'] === 1 ? 'fas fa-street-view' : 'fas fa-search'" color="white" class="q-ml-xs" />
|
||||
</q-badge>
|
||||
|
||||
<q-space/>
|
||||
|
||||
<q-btn
|
||||
@@ -464,7 +467,7 @@
|
||||
<div
|
||||
v-for="col in mycolumns" :key="col.name" class="newrec_fields">
|
||||
<div
|
||||
v-if="showColCheck(col, tools.TIPOVIS_NEW_RECORD, true, 0, newRecord) && col.foredit">
|
||||
v-if="showColCheck(col, tools.TIPOVIS_NEW_RECORD, true, 0, newRecord) && col.foredit ">
|
||||
<div class="">
|
||||
<CMyPopupEdit
|
||||
:table="mytable"
|
||||
@@ -490,7 +493,7 @@
|
||||
</div>
|
||||
</q-card-section>
|
||||
<q-card-actions align="center">
|
||||
<q-btn flat :label="$t('dialog.ok')" color="primary" @click="saveNewRecord"></q-btn>
|
||||
<q-btn :label="$t('dialog.ok')" color="primary" @click="saveNewRecord"></q-btn>
|
||||
<q-btn flat :label="$t('dialog.cancel')" color="primary" v-close-popup @click="annulla"></q-btn>
|
||||
</q-card-actions>
|
||||
</q-card>
|
||||
@@ -530,7 +533,7 @@
|
||||
</div>
|
||||
</q-card-section>
|
||||
<q-card-actions align="center">
|
||||
<q-btn flat :label="$t('dialog.ok')" color="primary" @click="saverecModif"></q-btn>
|
||||
<q-btn :label="$t('dialog.ok')" color="primary" @click="saverecModif"></q-btn>
|
||||
<q-btn flat :label="$t('dialog.cancel')" color="primary" @click="cancelrecModif"></q-btn>
|
||||
</q-card-actions>
|
||||
</q-card>
|
||||
|
||||
0
src/components/CMainView/CMainView.scss
Executable file
26
src/components/CMainView/CMainView.ts
Executable file
@@ -0,0 +1,26 @@
|
||||
import { defineComponent, ref, computed, PropType, toRef } from 'vue'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { useRouter } from 'vue-router'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
import { useI18n } from '@/boot/i18n'
|
||||
import { tools } from '@store/Modules/tools'
|
||||
import { CBigBtn } from '@/components/CBigBtn'
|
||||
|
||||
|
||||
export default defineComponent({
|
||||
name: 'CMainView',
|
||||
components: { CBigBtn },
|
||||
props: {},
|
||||
setup(props, { emit }) {
|
||||
|
||||
const userStore = useUserStore()
|
||||
const $router = useRouter()
|
||||
const globalStore = useGlobalStore()
|
||||
const { t } = useI18n()
|
||||
|
||||
return {
|
||||
userStore,
|
||||
tools,
|
||||
}
|
||||
}
|
||||
})
|
||||
34
src/components/CMainView/CMainView.vue
Executable file
@@ -0,0 +1,34 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="row q-ma-sm shadow" style="border-radius: 4px;border: 1px solid rgba(0, 0, 0, 0.12);">
|
||||
<CBigBtn
|
||||
label="Lavoro" to="/work" icon="fas fa-bullhorn" color="blue">
|
||||
</CBigBtn>
|
||||
<CBigBtn
|
||||
label="Scuola" to="/school" icon="fas fa-book-reader" color="orange" disable>
|
||||
</CBigBtn>
|
||||
<CBigBtn
|
||||
label="Luoghi" to="/places" icon="fas fa-map-marker-alt" color="blue-grey" disable>
|
||||
</CBigBtn>
|
||||
<CBigBtn
|
||||
label="Mobilità" to="/mobility" icon="fas fa-car-side" color="red" disable>
|
||||
</CBigBtn>
|
||||
<CBigBtn
|
||||
label="Alimentari" to="/grocery" icon="fas fa-utensils" color="green" disable>
|
||||
</CBigBtn>
|
||||
<CBigBtn
|
||||
label="Socializza" to="/socialising" icon="fas fa-users" color="purple" disable>
|
||||
</CBigBtn>
|
||||
|
||||
</div>
|
||||
<div class="text-center">P.S: Attualmente è attivo solo il bottone <b>Lavoro</b>.<br>
|
||||
Gli altri verranno attivati nei prossimi giorni.</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./CMainView.ts">
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './CMainView.scss';
|
||||
</style>
|
||||
1
src/components/CMainView/index.ts
Executable file
@@ -0,0 +1 @@
|
||||
export {default as CMainView} from './CMainView.vue'
|
||||
@@ -40,7 +40,7 @@
|
||||
</form>
|
||||
</q-card-section>
|
||||
<q-card-actions v-if="showButtons" align="center">
|
||||
<q-btn v-if="canModify" flat :label="$t('dialog.ok')" color="primary" @click="saveval"></q-btn>
|
||||
<q-btn v-if="canModify" :label="$t('dialog.ok')" color="primary" @click="saveval"></q-btn>
|
||||
<q-btn v-if="canModify" flat :label="$t('dialog.cancel')" color="primary" v-close-popup @click="annulla"></q-btn>
|
||||
<q-btn v-if="!canModify" :label="$t('dialog.ok')" color="primary" v-close-popup></q-btn>
|
||||
</q-card-actions>
|
||||
|
||||
@@ -705,6 +705,7 @@ export default defineComponent({
|
||||
noPopupeditByCol,
|
||||
getTitleEditor,
|
||||
getToByCol,
|
||||
t,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -417,9 +417,10 @@
|
||||
</div>
|
||||
<div v-else-if="col.fieldtype === costanti.FieldType.html">
|
||||
<div v-if="isInModif">
|
||||
<p v-if="isInModif" class="text-center">
|
||||
{{ $t('event.testo_di_spiegazione') }}:
|
||||
</p>
|
||||
<q-bar v-if="isInModif" dense class="bg-primary text-white">
|
||||
<span v-if="col.label_trans">{{t(col.label_trans)}}</span><span v-else> {{ $t('event.testo_di_spiegazione') }}: </span>
|
||||
<q-space/>
|
||||
</q-bar>
|
||||
<div v-if="!isFieldDb()">
|
||||
<CMyEditor
|
||||
v-model:value="myvalue" :title="!isInModif ? getTitleEditor(col, row) : ''" @keyup.enter.stop
|
||||
|
||||
@@ -40,4 +40,6 @@ export * from './CVerifyTelegram'
|
||||
export * from './CMyFriends'
|
||||
export * from './CMyGroups'
|
||||
export * from './CDashboard'
|
||||
export * from './CMainView'
|
||||
export * from './CBigBtn'
|
||||
// export * from './CPreloadImages'
|
||||
|
||||
@@ -374,7 +374,8 @@ const baseroutes: IListRoutes[] = [
|
||||
path: '/',
|
||||
materialIcon: 'home',
|
||||
name: 'pages.home',
|
||||
component: () => import('@src/root/home_pdnm/home_pdnm.vue'),
|
||||
//component: () => import('@src/root/home_pdnm/home_pdnm.vue'),
|
||||
component: () => import('@src/root/mainview/mainview.vue'),
|
||||
reqauth: false,
|
||||
inmenu: true,
|
||||
infooter: true,
|
||||
@@ -423,6 +424,17 @@ const baseroutes: IListRoutes[] = [
|
||||
inmenu: true,
|
||||
infooter: true,
|
||||
},
|
||||
{
|
||||
active: true,
|
||||
order: 130,
|
||||
path: '/work',
|
||||
materialIcon: 'fas fa-bullhorn',
|
||||
name: 'mypages.work',
|
||||
component: () => import('@/root/work/work.vue'),
|
||||
meta: { requiresAuth: true },
|
||||
inmenu: true,
|
||||
infooter: true,
|
||||
},
|
||||
{
|
||||
active: functionality.ENABLE_GROUPS,
|
||||
order: 132,
|
||||
|
||||
@@ -193,5 +193,6 @@ export default function () {
|
||||
TelegVerificato,
|
||||
isVerified,
|
||||
paotest,
|
||||
getRefLink,
|
||||
}
|
||||
}
|
||||
|
||||
0
src/root/mainview/mainview.scss
Executable file
70
src/root/mainview/mainview.ts
Executable file
@@ -0,0 +1,70 @@
|
||||
import {
|
||||
defineComponent, ref, computed,
|
||||
} from 'vue'
|
||||
|
||||
import { tools } from '@src/store/Modules/tools'
|
||||
import { CSkill } from '@/components/CSkill'
|
||||
import { CMainView } from '@/components/CMainView'
|
||||
import { CDashboard } from '@/components/CDashboard'
|
||||
import { CChartMap } from '@src/components/CChartMap'
|
||||
import { CUserNonVerif } from '@/components/CUserNonVerif'
|
||||
import { CCopyBtn } from '@/components/CCopyBtn'
|
||||
import { CMapsEsempio } from '@src/components/CMapsEsempio'
|
||||
import { CVerifyEmail } from '@src/components/CVerifyEmail'
|
||||
import { CVerifyTelegram } from '@src/components/CVerifyTelegram'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { static_data } from '@/db/static_data'
|
||||
import MixinBase from '@/mixins/mixin-base'
|
||||
import MixinUsers from '@/mixins/mixin-users'
|
||||
|
||||
|
||||
export default defineComponent({
|
||||
name: 'mainview',
|
||||
components: { CSkill, CChartMap, CMapsEsempio, CVerifyEmail, CVerifyTelegram, CDashboard, CUserNonVerif, CMainView, CCopyBtn },
|
||||
setup() {
|
||||
const globalStore = useGlobalStore()
|
||||
const userStore = useUserStore()
|
||||
const { getValDb } = MixinBase()
|
||||
const { isEmailVerified, TelegVerificato } = MixinUsers()
|
||||
|
||||
const { getRefLink } = MixinUsers()
|
||||
|
||||
function TelegCode() {
|
||||
return userStore.my.profile.teleg_checkcode
|
||||
}
|
||||
|
||||
function openrighttoolbar() {
|
||||
globalStore.rightDrawerOpen = true
|
||||
}
|
||||
|
||||
function isLogged() {
|
||||
return userStore.isLogged
|
||||
}
|
||||
function isUserOk() {
|
||||
return userStore.isUserOk()
|
||||
}
|
||||
|
||||
function getLinkBotTelegram(): string {
|
||||
if ( tools.isTest() && !process.env.DEV) {
|
||||
return getValDb('TELEG_BOT_LINK_TEST', false)
|
||||
} else{
|
||||
return getValDb('TELEG_BOT_LINK', false)
|
||||
}
|
||||
}
|
||||
|
||||
return {
|
||||
tools,
|
||||
static_data,
|
||||
isEmailVerified,
|
||||
TelegCode,
|
||||
TelegVerificato,
|
||||
isLogged,
|
||||
openrighttoolbar,
|
||||
isUserOk,
|
||||
getLinkBotTelegram,
|
||||
getRefLink,
|
||||
userStore,
|
||||
}
|
||||
},
|
||||
})
|
||||
77
src/root/mainview/mainview.vue
Executable file
@@ -0,0 +1,77 @@
|
||||
<template>
|
||||
<q-page class="">
|
||||
|
||||
<!--<CChartMap
|
||||
title="Mappa"
|
||||
subtitle="cartina..."
|
||||
serie1="Serie 1"
|
||||
>
|
||||
|
||||
</CChartMap>-->
|
||||
|
||||
<!--<CMapsEsempio></CMapsEsempio>-->
|
||||
|
||||
|
||||
<div v-if="isLogged()">
|
||||
<CVerifyTelegram v-if="TelegCode() || !TelegVerificato()">
|
||||
|
||||
</CVerifyTelegram>
|
||||
|
||||
<CVerifyEmail v-if="!isEmailVerified()">
|
||||
|
||||
</CVerifyEmail>
|
||||
|
||||
<div v-if="isUserOk()">
|
||||
|
||||
<CMainView></CMainView>
|
||||
|
||||
<CDashboard></CDashboard>
|
||||
|
||||
<CCopyBtn v-if="userStore.my.username" :title="$t('reg.link_reg')" :texttocopy="getRefLink(userStore.my.username)">
|
||||
|
||||
</CCopyBtn>
|
||||
|
||||
</div>
|
||||
<div v-else>
|
||||
<CUserNonVerif></CUserNonVerif>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div v-else>
|
||||
<div class="q-pa-md q-gutter-sm">
|
||||
<q-banner rounded class="bg-primary text-white">
|
||||
<div class="text-h6 text-center">
|
||||
Accedi al menu inserendo le tue credenziali 🔑<br><br>
|
||||
📝 Non sei <strong>Registrato</strong>?<br>
|
||||
👉🏻 Chiedi in chat il link a chi ti ha <strong>invitato</strong>.<br>
|
||||
</div>
|
||||
<template v-slot:action>
|
||||
<q-btn flat color="white" label="Accedi al Login" @click="openrighttoolbar"/>
|
||||
</template>
|
||||
</q-banner>
|
||||
</div>
|
||||
|
||||
<div
|
||||
v-if="!isLogged() && static_data.functionality.ENABLE_REGISTRATION && static_data.functionality.SHOW_REG_BUTTON"
|
||||
style="margin:20px; text-align: center;">
|
||||
<q-btn rounded size="lg" color="primary" @click="openrighttoolbar">{{ $t('login.enter') }}
|
||||
</q-btn>
|
||||
</div>
|
||||
|
||||
<!--
|
||||
<div v-if="!isLogged && static_data.functionality.ENABLE_REGISTRATION" align="center" style="margin:20px;">
|
||||
<q-btn rounded size="lg" color="primary" to="/signup">{{$t('reg.submit')}}
|
||||
</q-btn>
|
||||
</div>
|
||||
-->
|
||||
|
||||
</div>
|
||||
|
||||
</q-page>
|
||||
|
||||
</template>
|
||||
<script lang="ts" src="./mainview.ts">
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@import './mainview.scss';
|
||||
</style>
|
||||
0
src/root/work/work.scss
Executable file
65
src/root/work/work.ts
Executable file
@@ -0,0 +1,65 @@
|
||||
import {
|
||||
defineComponent, ref, computed,
|
||||
} from 'vue'
|
||||
|
||||
import { tools } from '@src/store/Modules/tools'
|
||||
import { CSkill } from '@/components/CSkill'
|
||||
import { CFinder } from '@/components/CFinder'
|
||||
import { CDashboard } from '@/components/CDashboard'
|
||||
import { CChartMap } from '@src/components/CChartMap'
|
||||
import { CUserNonVerif } from '@/components/CUserNonVerif'
|
||||
import { CMapsEsempio } from '@src/components/CMapsEsempio'
|
||||
import { CVerifyEmail } from '@src/components/CVerifyEmail'
|
||||
import { CVerifyTelegram } from '@src/components/CVerifyTelegram'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { static_data } from '@/db/static_data'
|
||||
import MixinBase from '@/mixins/mixin-base'
|
||||
import MixinUsers from '@/mixins/mixin-users'
|
||||
|
||||
|
||||
export default defineComponent({
|
||||
name: 'work',
|
||||
components: { CSkill, CChartMap, CMapsEsempio, CFinder, CVerifyEmail, CVerifyTelegram, CDashboard, CUserNonVerif },
|
||||
setup() {
|
||||
const globalStore = useGlobalStore()
|
||||
const userStore = useUserStore()
|
||||
const { getValDb } = MixinBase()
|
||||
const { isEmailVerified, TelegVerificato } = MixinUsers()
|
||||
|
||||
function TelegCode() {
|
||||
return userStore.my.profile.teleg_checkcode
|
||||
}
|
||||
|
||||
function openrighttoolbar() {
|
||||
globalStore.rightDrawerOpen = true
|
||||
}
|
||||
|
||||
function isLogged() {
|
||||
return userStore.isLogged
|
||||
}
|
||||
function isUserOk() {
|
||||
return userStore.isUserOk()
|
||||
}
|
||||
|
||||
function getLinkBotTelegram(): string {
|
||||
if ( tools.isTest() && !process.env.DEV) {
|
||||
return getValDb('TELEG_BOT_LINK_TEST', false)
|
||||
} else{
|
||||
return getValDb('TELEG_BOT_LINK', false)
|
||||
}
|
||||
}
|
||||
|
||||
return {
|
||||
tools,
|
||||
static_data,
|
||||
isEmailVerified,
|
||||
TelegCode,
|
||||
TelegVerificato,
|
||||
isLogged,
|
||||
openrighttoolbar,
|
||||
isUserOk,
|
||||
getLinkBotTelegram,
|
||||
}
|
||||
},
|
||||
})
|
||||
28
src/root/work/work.vue
Executable file
@@ -0,0 +1,28 @@
|
||||
<template>
|
||||
<q-page class="">
|
||||
|
||||
<div v-if="isLogged()">
|
||||
|
||||
<div v-if="isUserOk()">
|
||||
|
||||
<CFinder>
|
||||
|
||||
</CFinder>
|
||||
|
||||
<CDashboard></CDashboard>
|
||||
|
||||
</div>
|
||||
<div v-else>
|
||||
<CUserNonVerif></CUserNonVerif>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</q-page>
|
||||
|
||||
</template>
|
||||
<script lang="ts" src="./work.ts">
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
@import './work.scss';
|
||||
</style>
|
||||
@@ -431,6 +431,7 @@ const msg_it = {
|
||||
teleg_id_old: 'OLD Tel ID',
|
||||
teleg_auth: 'Codice Autorizzazione',
|
||||
click_per_copiare: 'Cliccaci sopra per copiarlo sugli appunti',
|
||||
link_reg: 'Clicca per copiare il link da condividere agli Amici',
|
||||
copia_messaggio: 'Copia Messaggio',
|
||||
teleg_torna_sul_bot: '1) Copia il codice cliccando sul bottone qui sopra<br>2) torna su {botname} cliccando qui sotto 👇 ed incolla (o scrivi) il codice',
|
||||
teleg_checkcode: 'Codice Telegram',
|
||||
@@ -874,6 +875,7 @@ const msg_it = {
|
||||
follow_groups: 'Gruppi che Seguo',
|
||||
create_group: 'Crea Gruppo',
|
||||
friends: 'Amici',
|
||||
work: 'Lavoro',
|
||||
groups: 'Gruppi',
|
||||
request_friends: 'Rich. Amicizia',
|
||||
request_sent_friends: 'Rich. Inviate',
|
||||
@@ -911,6 +913,9 @@ const msg_it = {
|
||||
finder: {
|
||||
search_skill: 'Cerca una specializzazione'
|
||||
},
|
||||
adTypes: {
|
||||
name: 'Tipo',
|
||||
}
|
||||
},
|
||||
|
||||
};
|
||||
|
||||
@@ -2,6 +2,7 @@ import { IColGridTable } from '@model'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { lists } from './lists'
|
||||
import { costanti } from './costanti'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
|
||||
const DeleteRec = {
|
||||
name: 'deleterec',
|
||||
@@ -531,14 +532,14 @@ export const colmySkills = [
|
||||
// AddCol({ name: 'subTitle', label_trans: 'event.title', fieldtype: costanti.FieldType.string,
|
||||
// showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit , maxlength: 70, noshowlabel: true }),
|
||||
AddCol({
|
||||
name: 'adTypes',
|
||||
name: 'adType',
|
||||
label_trans: 'adTypes.name',
|
||||
fieldtype: costanti.FieldType.select,
|
||||
required: true,
|
||||
jointable: 'adtypes',
|
||||
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist,
|
||||
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit,
|
||||
icon: 'fas fa-bullhorn',
|
||||
noshowlabel: true,
|
||||
icon: 'grading',
|
||||
}),
|
||||
AddCol({ name: 'descr', label_trans: 'proj.shortdescr', fieldtype: costanti.FieldType.string,
|
||||
showWhen: costanti.showWhen.NewRec + costanti.showWhen.InPage + costanti.showWhen.InEdit + costanti.showWhen.InView_OnlyifExist, noshowlabel: true, maxlength: 200 }),
|
||||
@@ -1068,6 +1069,15 @@ export const fieldsTable = {
|
||||
}
|
||||
return 'label'
|
||||
},
|
||||
getValByTabAndId(table: string, field: string, idvalue: any) {
|
||||
const globalStore = useGlobalStore()
|
||||
|
||||
const col = fieldsTable.getColByTable(table, field)
|
||||
if (col) {
|
||||
return globalStore.getValueByTable(col, idvalue)
|
||||
}
|
||||
return ''
|
||||
},
|
||||
getTitleByTable(mytable: string): string {
|
||||
const myrec = this.getrecTableList(mytable)
|
||||
if (myrec) return myrec.label
|
||||
|
||||
@@ -1332,8 +1332,8 @@ export const useGlobalStore = defineStore('GlobalStore', {
|
||||
}
|
||||
|
||||
if (key === 'username') {
|
||||
console.log('key=', key, 'collab', collab, 'val', val)
|
||||
console.log('myris', risultato)
|
||||
// console.log('key=', key, 'collab', collab, 'val', val)
|
||||
// console.log('myris', risultato)
|
||||
}
|
||||
|
||||
return risultato
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import { CMyFieldDb } from '@/components/CMyFieldDb'
|
||||
import { CTitleBanner } from '@/components/CTitleBanner'
|
||||
import { CProfile } from '@/components/CProfile'
|
||||
import { CCopyBtn } from '@/components/CCopyBtn'
|
||||
import { CSkill } from '@/components/CSkill'
|
||||
import { CDateTime } from '@/components/CDateTime'
|
||||
import { tools } from '@store/Modules/tools'
|
||||
@@ -15,11 +16,12 @@ import { costanti } from '@costanti'
|
||||
import { IUserFields } from 'model'
|
||||
import { shared_consts } from '@/common/shared_vuejs'
|
||||
import { static_data } from '@/db/static_data'
|
||||
import MixinUsers from '@/mixins/mixin-users'
|
||||
|
||||
|
||||
export default defineComponent({
|
||||
name: 'myprofile',
|
||||
components: { CProfile, CTitleBanner, CMyFieldDb, CSkill, CDateTime },
|
||||
components: { CProfile, CTitleBanner, CMyFieldDb, CSkill, CDateTime, CCopyBtn },
|
||||
props: {},
|
||||
setup() {
|
||||
const userStore = useUserStore()
|
||||
@@ -27,6 +29,8 @@ export default defineComponent({
|
||||
const $q = useQuasar()
|
||||
const { t } = useI18n()
|
||||
|
||||
const { getRefLink } = MixinUsers()
|
||||
|
||||
const animation = ref('fade')
|
||||
|
||||
const username = computed(() => $route.params.username ? $route.params.username.toString() : userStore.my.username)
|
||||
@@ -114,6 +118,7 @@ export default defineComponent({
|
||||
static_data,
|
||||
animation,
|
||||
isMyRecord,
|
||||
getRefLink,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -81,6 +81,11 @@
|
||||
:href="getLinkWebSite()" target="__blank">
|
||||
</q-btn>
|
||||
</div>
|
||||
|
||||
<CCopyBtn :title="$t('reg.link_reg')" :texttocopy="getRefLink(username)">
|
||||
|
||||
</CCopyBtn>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div v-else class="fit column no-wrap justify-evenly items-center content-start">
|
||||
|
||||