From 3240bec9409c838a23f13ff0a4e1c5c6b41dae9f Mon Sep 17 00:00:00 2001 From: solderq35 Date: Fri, 15 Sep 2023 18:31:46 -0700 Subject: [PATCH] remove unused code and fix checking for commas --- .../building_list/building_list.vue | 24 +------------------ 1 file changed, 1 insertion(+), 23 deletions(-) diff --git a/src/components/building_list/building_list.vue b/src/components/building_list/building_list.vue index 48d9d2cd..8e53d1d9 100644 --- a/src/components/building_list/building_list.vue +++ b/src/components/building_list/building_list.vue @@ -115,7 +115,7 @@ export default { console.log( Object.keys( r2 ) ) if ( this.buildingList ) { for ( let i = 0; i < Object.keys( r2 ).length; i++ ) { - if ( Object.keys( r2 )[i] === 'Events & Admin, Solar' ) { + if ( Object.keys( r2 )[i].split( ', ' ).length > 1 ) { console.log( 'gotcha' ) console.log( Object.keys( r2 )[i] ) console.log( Object.keys( r2 )[i].split( ', ' ) ) @@ -154,28 +154,6 @@ export default { }, search: function ( v ) { let groups - /* - console.log(this.groups) - console.log(Object.keys(this.groups)) - if (this.buildingList ) { - for (let i = 0; i < Object.keys(this.groups).length; i++) { - if (Object.keys(this.groups)[i] === 'Events & Admin, Solar') { - console.log('gotcha') - console.log(Object.keys(this.groups)[i]) - console.log(Object.keys(this.groups)[i].split(', ')) - for (let j = 0; j < Object.keys(this.groups)[i].split(', ').length; j++) { - console.log(Object.keys(this.groups)[i].split(', ')[j]) - console.log(this.groups[Object.keys(this.groups)[i].split(', ')[j]]) - console.log(Object.values(this.groups)[i]) - this.groups[Object.keys(this.groups)[i].split(', ')[j]].push(Object.values(this.groups)[i][0]) - console.log(this.groups[Object.keys(this.groups)[i].split(', ')[j]]) - // this.groups[Object.keys(this.groups)[i].split(', ')[j]].push(Object.values(this.groups)[i]) - } - console.log(Object.values(this.groups)[i][0]) - } - } - } - */ if ( this.buildingList ) { groups = Object.values( this.groups ).reduce( ( a, c ) => { for ( let d of c ) a.push( d )