tango-app-api-infra 3.9.5-vms.96 → 3.9.5-vms.97

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tango-app-api-infra",
3
- "version": "3.9.5-vms.96",
3
+ "version": "3.9.5-vms.97",
4
4
  "description": "infra",
5
5
  "main": "index.js",
6
6
  "type": "module",
@@ -3188,15 +3188,12 @@ export async function ticketList( req, res ) {
3188
3188
  'ticketId': item?.ticketId,
3189
3189
  'storeId': item?.storeId,
3190
3190
  'storeName': item?.storeName,
3191
- 'Ticket Raised': item?.mappingInfo?.find( ( f ) => f.type === 'tangoreview' )?.createdAt? dayjs( item?.mappingInfo?.find( ( f ) => f.type === 'tangoreview' )?.createdAt ).format( 'DD MMM, YYYY' ) : '',
3192
- 'Issue Date': item?.dateString ? dayjs( item.dateString ).format( 'DD MMM, YYYY' ) : '',
3193
- 'Due Date': ( () => {
3194
- const dueDate = item?.mappingInfo?.find( ( f ) => f.type === 'tangoreview' )?.dueDate;
3195
- if ( dueDate ) {
3196
- if ( dayjs( dueDate ).isSame( dayjs(), 'day' ) ) {
3197
- return 'Due Today';
3198
- }
3199
- return dayjs( dueDate ).format( 'DD MMM, YYYY' );
3191
+ 'ticketRaised': item?.mappingInfo?.find( ( f ) => f?.type === 'tangoreview' )?.createdAt,
3192
+ 'issueDate': item?.dateString,
3193
+ 'dueDate': ( () => {
3194
+ if ( Array.isArray( item?.mappingInfo ) ) {
3195
+ const filtered = item.mappingInfo.filter( ( f ) => f?.dueDate && f?.type !== 'tangoreview' );
3196
+ return filtered.length > 0 ? filtered[filtered.length - 1].dueDate : '';
3200
3197
  }
3201
3198
  return '';
3202
3199
  } )(),
@@ -3228,13 +3225,13 @@ export async function ticketList( req, res ) {
3228
3225
  'Actual FF': item?.footfallCount,
3229
3226
  // Use the dueDate from the last mappingInfo item whose type is NOT 'finalRevison'
3230
3227
 
3231
- 'Due Date': ( () => {
3232
- if ( Array.isArray( item?.mappingInfo ) ) {
3233
- const filtered = item.mappingInfo.filter( ( f ) => f.dueDate && f.type !== 'finalRevison' );
3234
- return filtered.length > 0 ? filtered[filtered.length - 1].dueDate : '';
3235
- }
3236
- return '';
3237
- } )(),
3228
+ // 'Due Date': ( () => {
3229
+ // if ( Array.isArray( item?.mappingInfo ) ) {
3230
+ // const filtered = item.mappingInfo.filter( ( f ) => f.dueDate && f.type !== 'finalRevison' );
3231
+ // return filtered.length > 0 ? filtered[filtered.length - 1].dueDate : '';
3232
+ // }
3233
+ // return '';
3234
+ // } )(),
3238
3235
  'Due Date (Formatted)': ( () => {
3239
3236
  if ( Array.isArray( item?.mappingInfo ) ) {
3240
3237
  // Find last mappingInfo whose type is NOT 'finalRevison'