From 5f51c231eb11b8dbc742dcc4d230216bc3a6a03e Mon Sep 17 00:00:00 2001 From: paoloar77 Date: Fri, 28 Jan 2022 00:57:28 +0100 Subject: [PATCH] - Add New Record directly by the QSelect --- src/components/CFinder/CFinder.ts | 19 +- src/components/CFinder/CFinder.vue | 6 +- src/components/CGallery/CGallery.ts | 6 +- src/components/CGallery/CGallery.vue | 4 +- src/components/CGridTableRec/CGridTableRec.ts | 26 +- .../CGridTableRec/CGridTableRec.vue | 18 +- src/components/CMyFriends/CMyFriends.ts | 2 +- src/components/CMyPopupEdit/CMyPopupEdit.ts | 61 ++-- src/components/CMyPopupEdit/CMyPopupEdit.vue | 28 +- src/components/CMySelect/CMySelect.ts | 269 ++++++++++++------ src/components/CMySelect/CMySelect.vue | 8 +- src/components/CSkill/CSkill.ts | 3 + src/css/app.scss | 2 +- src/model/GlobalStore.ts | 9 +- src/statics/lang/it.js | 3 +- src/store/Modules/costanti.ts | 8 + src/store/Modules/fieldsTable.ts | 48 ++-- src/store/Modules/tools.ts | 32 ++- src/store/globalStore.ts | 63 ++++ 19 files changed, 434 insertions(+), 181 deletions(-) diff --git a/src/components/CFinder/CFinder.ts b/src/components/CFinder/CFinder.ts index b5e67aaf..19935e5a 100755 --- a/src/components/CFinder/CFinder.ts +++ b/src/components/CFinder/CFinder.ts @@ -1,4 +1,5 @@ import { + computed, defineComponent, onBeforeMount, onBeforeUnmount, onMounted, ref, toRef, toRefs, watch, } from 'vue' @@ -32,6 +33,19 @@ export default defineComponent({ const filtercustom: any = ref([]) const searchList = ref([]) + const idSector = computed(() => { + let myval = 0 + searchList.value.forEach((rec) => { + console.log(' rec', rec) + if (rec.table === 'sectors') { + console.log('trovato') + myval = rec.value + } + }) + console.log('IDSECTOR = ' + myval) + return myval + }) + function mounted() { /*arrfilterand.value = [ { @@ -98,7 +112,7 @@ export default defineComponent({ useinput: true, }, { - label: 'Specializz.', + label: 'Specializzazione', table: 'subskills', key: 'idSubSkill', value: 0, @@ -205,6 +219,7 @@ export default defineComponent({ function getdefaultnewrec(): IMySkill { return { _id: 0, + idSector: 0, idSkill: 0, idSubSkill: [], idStatusSkill: [], @@ -236,6 +251,7 @@ export default defineComponent({ lk_proj: { recSkill: 1, sector: 1, + idSector: 1, idSkill: 1, idSubSkill: 1, idStatusSkill: 1, @@ -292,6 +308,7 @@ export default defineComponent({ arrfilterand, filtercustom, searchList, + idSector, } }, }) diff --git a/src/components/CFinder/CFinder.vue b/src/components/CFinder/CFinder.vue index fa9e8575..9e69e567 100755 --- a/src/components/CFinder/CFinder.vue +++ b/src/components/CFinder/CFinder.vue @@ -1,6 +1,6 @@