Circuit table...
This commit is contained in:
0
src/views/user/mycircuits/mycircuits.scss
Normal file
0
src/views/user/mycircuits/mycircuits.scss
Normal file
50
src/views/user/mycircuits/mycircuits.ts
Executable file
50
src/views/user/mycircuits/mycircuits.ts
Executable file
@@ -0,0 +1,50 @@
|
||||
import { CMyCircuits } from '@/components/CMyCircuits'
|
||||
import { CFinder } from '@/components/CFinder'
|
||||
import { CGridTableRec } from '@/components/CGridTableRec'
|
||||
import { tools } from '@store/Modules/tools'
|
||||
import { toolsext } from '@store/Modules/toolsext'
|
||||
import { computed, defineComponent, onMounted, ref, watch } from 'vue'
|
||||
import { useUserStore } from '@store/UserStore'
|
||||
import { useRoute, useRouter } from 'vue-router'
|
||||
import { useGlobalStore } from '@store/globalStore'
|
||||
import { useI18n } from '@/boot/i18n'
|
||||
import { colmyUserCircuit } from '@store/Modules/fieldsTable'
|
||||
import { costanti } from '@costanti'
|
||||
import { shared_consts } from '@/common/shared_vuejs'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'mycircuits',
|
||||
components: { CMyCircuits, CGridTableRec, CFinder },
|
||||
props: {},
|
||||
setup() {
|
||||
const userStore = useUserStore()
|
||||
const globalStore = useGlobalStore()
|
||||
const { t } = useI18n()
|
||||
|
||||
const filter = ref(costanti.FIND_CIRCUIT)
|
||||
|
||||
const isfinishLoading = computed(() => globalStore.finishLoading)
|
||||
|
||||
function mounted() {
|
||||
|
||||
const filt_loaded = tools.getCookie(tools.COOK_SEARCH + tools.CIRCUIT_SEARCH, costanti.FIND_CIRCUIT, true)
|
||||
console.log('filt_loaded', filt_loaded)
|
||||
filter.value = filt_loaded ? filt_loaded : costanti.FIND_CIRCUIT
|
||||
}
|
||||
|
||||
watch(() => filter.value, (newval: any, oldval) => {
|
||||
tools.setCookie(tools.COOK_SEARCH + tools.CIRCUIT_SEARCH, newval)
|
||||
|
||||
})
|
||||
onMounted(mounted)
|
||||
|
||||
return {
|
||||
filter,
|
||||
costanti,
|
||||
shared_consts,
|
||||
colmyUserCircuit,
|
||||
toolsext,
|
||||
isfinishLoading,
|
||||
}
|
||||
}
|
||||
})
|
||||
27
src/views/user/mycircuits/mycircuits.vue
Executable file
27
src/views/user/mycircuits/mycircuits.vue
Executable file
@@ -0,0 +1,27 @@
|
||||
<template>
|
||||
<div v-if="isfinishLoading" class="">
|
||||
<CMyCircuits
|
||||
v-model="filter"
|
||||
:finder="true"
|
||||
>
|
||||
|
||||
<CFinder
|
||||
:table="toolsext.TABCIRCUITS"
|
||||
:showFilterPersonal="true"
|
||||
/>
|
||||
|
||||
</CMyCircuits>
|
||||
|
||||
<div v-if="filter === costanti.CREATE_CIRCUIT">
|
||||
Nuovo Circuito:
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" src="./mycircuits.ts">
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import './mycircuits.scss';
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user