other components... (2)

This commit is contained in:
Paolo Arena
2021-09-16 21:08:02 +02:00
parent fcc4f61f07
commit f351673917
276 changed files with 17183 additions and 3371 deletions

View File

@@ -0,0 +1,16 @@
.lista {
text-align: left;
font-size: 0.75rem;
}
.step{
font-size: 1.15rem;
font-weight: bold;
color: blue;
line-height: 1.75rem;
letter-spacing: .01em;
}
.grass{
font-weight: bold;
}

View File

@@ -0,0 +1,63 @@
import { defineComponent, ref } from 'vue'
import { useI18n } from '@src/boot/i18n'
import { useUserStore } from '@store/UserStore'
import { useGlobalStore } from '@store/globalStore'
import { useQuasar } from 'quasar'
import { CMyPage } from '@/components/CMyPage'
import { CTitleBanner } from '@/components/CTitleBanner'
import { CVideo } from '@/components/CVideo'
import { CMyFieldDb } from '@/components/CMyFieldDb'
import { CImgText } from '@/components/CImgText'
import { tools } from '@store/Modules/tools'
import { shared_consts } from '@/common/shared_vuejs'
export default defineComponent({
name: 'CVideoPromo',
props: {
showconditions: {
type: Boolean,
required: false,
default: false,
},
},
components: { CMyPage, CTitleBanner, CImgText, CMyFieldDb, CVideo },
setup(props, { emit }) {
const $q = useQuasar()
const { t } = useI18n()
const userStore = useUserStore()
const globalStore = useGlobalStore()
const msg = ref('')
const accetta_saw_video = ref(false)
function created() {
aggiorna()
}
function aggiorna() {
accetta_saw_video.value = tools.isBitActive(userStore.my.profile.saw_and_accepted, shared_consts.Accepted.CHECK_SEE_VIDEO_PRINCIPI.value)
}
function changeval(value: any) {
if (value)
userStore.my.profile.saw_and_accepted = tools.SetBit(userStore.my.profile.saw_and_accepted, shared_consts.Accepted.CHECK_SEE_VIDEO_PRINCIPI.value)
else
userStore.my.profile.saw_and_accepted = tools.UnSetBit(userStore.my.profile.saw_and_accepted, shared_consts.Accepted.CHECK_SEE_VIDEO_PRINCIPI.value)
const mydata = {
'profile.saw_and_accepted': userStore.my.profile.saw_and_accepted
}
tools.saveFieldToServer($q, 'users', userStore.my._id, mydata)
}
created()
return {
msg,
accetta_saw_video,
changeval,
aggiorna,
}
}
})

View File

@@ -0,0 +1,44 @@
<template>
<div>
<CTitleBanner :title="`Video ` + $t('site.sitename')"></CTitleBanner>
<CImgText src="">
<CTitleBanner
class="q-pa-xs" :title="$t('steps.video_intro_1', {sitename: $t('ws.sitename')})"
bgcolor="bg-primary"
clcolor="text-white"
myclass="myshad" canopen="true" :visible="true">
<div v-if="showconditions">
<CVideo myvideokey="DWfQzbOCK3s"></CVideo>
</div>
<div v-else>
<div v-if="toolsext.isLang('it')">
<CVideo myvideokey=""></CVideo>
</div>
</div>
</CTitleBanner>
<div v-if="showconditions">
<q-checkbox
class="bg-grey-4"
v-model="accetta_saw_video"
@input="changeval"
color="primary"
:label="$t('steps.saw_video_intro')">
</q-checkbox>
</div>
</CImgText>
</div>
</template>
<script lang="ts" src="./CVideoPromo.ts">
</script>
<style lang="scss" scoped>
@import './CVideoPromo';
</style>

View File

@@ -0,0 +1 @@
export {default as CVideoPromo} from './CVideoPromo.vue'