File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -534,29 +534,35 @@ export type Database = {
534534 Row : {
535535 adder : number
536536 created_at : string
537+ formatting : string | null
537538 icon : string | null
538539 id : number
539540 multiplier : number
540541 name : string
541542 notation : string
543+ public_name : string | null
542544 }
543545 Insert : {
544546 adder ?: number
545547 created_at ?: string
548+ formatting ?: string | null
546549 icon ?: string | null
547550 id ?: number
548551 multiplier ?: number
549552 name : string
550553 notation ?: string
554+ public_name ?: string | null
551555 }
552556 Update : {
553557 adder ?: number
554558 created_at ?: string
559+ formatting ?: string | null
555560 icon ?: string | null
556561 id ?: number
557562 multiplier ?: number
558563 name ?: string
559564 notation ?: string
565+ public_name ?: string | null
560566 }
561567 Relationships : [ ]
562568 }
Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ export class DataService {
8989 throw new NotFoundException ( 'Device type not found' ) ;
9090 }
9191 const deviceTypeData = await this . deviceTypeService . findById ( deviceType ) ;
92- if ( ! deviceTypeData || ! deviceTypeData . data_table ) {
92+ if ( ! deviceTypeData || ! deviceTypeData . data_table_v2 ) {
9393 throw new NotFoundException ( 'Device type data or data table not found' ) ;
9494 }
9595 return deviceTypeData ;
Original file line number Diff line number Diff line change @@ -56,7 +56,11 @@ export class ExportService {
5656 const filtered = { } ;
5757 dataMetadata . forEach ( ( meta ) => {
5858 if ( d [ meta . name ] ) {
59- filtered [ meta . name ] = d [ meta . name ] ;
59+ if ( meta . formatting === 'MM/DD/YYYY HH:mm:ss' ) {
60+ filtered [ meta . public_name ] = new Date ( d [ meta . name ] ) . toLocaleString ( ) ;
61+ } else {
62+ filtered [ meta . public_name ] = d [ meta . name ] ;
63+ }
6064 }
6165 } ) ;
6266 return filtered ;
You can’t perform that action at this time.
0 commit comments