- Migliorata la Notifica degli Eventi su Telegram
- Gli annunci (beni/servizi/ospitalità) ora possono essere visti anche tramite un link, anche per chi non è dentro alla App. - Aggiunto bottone "Aggiorna" per aggiornare il Saldo attuale. - I "Conti Collettivi" ora vengono chiamati Gruppi (o Conto di Gruppo).
This commit is contained in:
@@ -49,13 +49,18 @@ export default defineComponent({
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
subtitle: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: '',
|
||||
},
|
||||
prop_mytable: {
|
||||
type: String,
|
||||
required: false,
|
||||
default: '',
|
||||
},
|
||||
prop_mycolumns: {
|
||||
type: Object as PropType<[]>,
|
||||
type: Object as PropType<any[]>,
|
||||
required: false,
|
||||
default: null,
|
||||
},
|
||||
@@ -303,9 +308,10 @@ export default defineComponent({
|
||||
const globalStore = useGlobalStore()
|
||||
const isfinishLoading = computed(() => globalStore.finishLoading)
|
||||
|
||||
const pagination = ref({ sortBy: 'desc', descending: false, page: 1, rowsNumber: 10, rowsPerPage: 10 } as IPagination)
|
||||
const pagination = ref({ sortBy: 'desc', descending: false, page: 1, rowsNumber: 0, rowsPerPage: 10 } as IPagination)
|
||||
|
||||
const addRow = ref('Aggiungi')
|
||||
const actmonth = ref('')
|
||||
|
||||
const newRecordBool = ref(false)
|
||||
const newRecordBoolOld = ref(false)
|
||||
@@ -317,7 +323,7 @@ export default defineComponent({
|
||||
|
||||
const mytable = ref('')
|
||||
const mytitle = ref('')
|
||||
const mycolumns = ref([])
|
||||
const mycolumns = ref([] as any[])
|
||||
const colkey = ref('')
|
||||
const search = ref('')
|
||||
|
||||
@@ -326,6 +332,7 @@ export default defineComponent({
|
||||
const showNotification = ref(false)
|
||||
|
||||
const loading = ref(false)
|
||||
const alreadymounting = ref(false)
|
||||
const editOn = computed({
|
||||
get: () => globalStore.editOn,
|
||||
set: val => {
|
||||
@@ -343,13 +350,13 @@ export default defineComponent({
|
||||
|
||||
const myinfscroll = ref(null)
|
||||
|
||||
const serverData: any = ref([])
|
||||
const serverData: any = ref([] as any[])
|
||||
const numRecLoaded = ref(0)
|
||||
const spinner_visible = ref(false)
|
||||
const changetable = ref(false)
|
||||
const searchList = ref([] as ISearchList[])
|
||||
|
||||
const actual = ''
|
||||
const actual = ref(<any>'')
|
||||
|
||||
let idsel = ''
|
||||
const colsel = ref({ name: '', field: '', sortable: false } as IColGridTable | null)
|
||||
@@ -386,11 +393,14 @@ export default defineComponent({
|
||||
const ordinam_desc = ref(false)
|
||||
|
||||
|
||||
const valoriopt = computed(() => (item: any, addall: boolean, addnone: boolean) => {
|
||||
const getNumRecFromQuery = computed(() => () => {
|
||||
return serverData.value.length
|
||||
})
|
||||
const valoriopt = computed(() => (item: any, addall?: boolean, addnone?: boolean) => {
|
||||
// console.log('valoriopt', item.table)
|
||||
return globalStore.getTableJoinByName(item.table, addall, addnone, item.filter)
|
||||
})
|
||||
const lengthopt = computed(() => (item: any, addall: boolean, addnone: boolean) => {
|
||||
const lengthopt = computed(() => (item: any, addall: boolean, addnone?: boolean) => {
|
||||
// console.log('valoriopt', item.table)
|
||||
const valori = globalStore.getTableJoinByName(item.table, addall, addnone, item.filter)
|
||||
return (valori ? valori.length : 0)
|
||||
@@ -1094,6 +1104,7 @@ export default defineComponent({
|
||||
myinfscroll.value.resume()
|
||||
}
|
||||
done()
|
||||
alreadymounting.value = true
|
||||
return
|
||||
}
|
||||
|
||||
@@ -1158,6 +1169,8 @@ export default defineComponent({
|
||||
|
||||
// console.log(' ...DONE ')
|
||||
done(pagination.value.rowsNumber === 0 ? true : false)
|
||||
|
||||
alreadymounting.value = true
|
||||
})
|
||||
} else {
|
||||
startsearch.value = false
|
||||
@@ -1169,7 +1182,6 @@ export default defineComponent({
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function refresh_arr() {
|
||||
const myarr = [...serverData.value]
|
||||
serverData.value = []
|
||||
@@ -1185,7 +1197,7 @@ export default defineComponent({
|
||||
}
|
||||
|
||||
function refresh_infscroll(done: any) {
|
||||
// console.log('refresh_infscroll', 'pag', pagination.value.rowsNumber)
|
||||
console.log('refresh_infscroll', 'pag', pagination.value.rowsNumber, 'done', done)
|
||||
rowclicksel.value = null
|
||||
|
||||
onUpdateData(0,
|
||||
@@ -1197,7 +1209,7 @@ export default defineComponent({
|
||||
|
||||
|
||||
function refresh() {
|
||||
// console.log('refresh', 'startsearch', startsearch.value)
|
||||
console.log('refresh', 'startsearch', startsearch.value)
|
||||
|
||||
clickbuttsearch.value = true
|
||||
// console.log('refresh')
|
||||
@@ -1508,12 +1520,13 @@ export default defineComponent({
|
||||
myvertical.value = props.vertical
|
||||
// myvertical.value = tools.getCookie('myv_' + props.prop_mytable, props.vertical)
|
||||
|
||||
showfilter.value = tools.getCookie('s_adv', '0') !== '0'
|
||||
showfilter.value = props.prop_showfilter || (tools.getCookie('s_adv', '0') !== '0')
|
||||
}
|
||||
|
||||
function mounted() {
|
||||
searchList.value = props.prop_searchList
|
||||
|
||||
|
||||
// console.log('GridTable mounted', tablesel.value)
|
||||
|
||||
// console.log('props.filtercustom', props.filtercustom)
|
||||
@@ -1548,7 +1561,8 @@ export default defineComponent({
|
||||
|
||||
// console.log('2) tablesel', tablesel.value)
|
||||
|
||||
changeTable(tablesel.value)
|
||||
changeTable(tablesel.value, true)
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1696,7 +1710,7 @@ export default defineComponent({
|
||||
}
|
||||
}
|
||||
|
||||
function changeTable(mysel: any) {
|
||||
function changeTable(mysel: any, mounted: boolean) {
|
||||
// console.log('changeTable', tablesel.value)
|
||||
changetable.value = true
|
||||
if (tablesel.value === undefined || tablesel.value === '')
|
||||
@@ -2171,7 +2185,7 @@ export default defineComponent({
|
||||
|
||||
if (index > 1) {
|
||||
// console.log('onLoadScroll', index, 'RECLOAD', numRecLoaded.value, 'ROWS: ', pagination.value.rowsNumber, 'PAGE: ', pagination.value.page)
|
||||
if (numRecLoaded.value < pagination.value.rowsNumber || (pagination.value.rowsNumber <= 0 && clickbuttsearch.value)) {
|
||||
if ((numRecLoaded.value < pagination.value.rowsNumber || (pagination.value.rowsNumber <= 0 && clickbuttsearch.value))) {
|
||||
if (pagination.value.rowsNumber === 0) {
|
||||
pagination.value.page = 0
|
||||
}
|
||||
@@ -2369,6 +2383,9 @@ export default defineComponent({
|
||||
lengthopt,
|
||||
update_col,
|
||||
startsearch,
|
||||
getNumRecFromQuery,
|
||||
actmonth,
|
||||
alreadymounting,
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user