tango-app-api-audit 3.4.68-beta.10 → 3.4.68-beta.11
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-audit",
|
|
3
|
-
"version": "3.4.68-beta.
|
|
3
|
+
"version": "3.4.68-beta.11",
|
|
4
4
|
"description": "audit & audit metrics apis",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"mongodb": "^6.7.0",
|
|
27
27
|
"nodemon": "^3.1.3",
|
|
28
28
|
"swagger-ui-express": "^5.0.1",
|
|
29
|
-
"tango-api-schema": "^2.2.
|
|
30
|
-
"tango-app-api-middleware": "^3.1.
|
|
29
|
+
"tango-api-schema": "^2.2.98",
|
|
30
|
+
"tango-app-api-middleware": "^3.1.73",
|
|
31
31
|
"winston": "^3.13.0",
|
|
32
32
|
"winston-daily-rotate-file": "^5.0.0"
|
|
33
33
|
},
|
|
@@ -16,7 +16,7 @@ export async function getList( req, res ) {
|
|
|
16
16
|
const limit = inputData.limit || 10;
|
|
17
17
|
const offset = inputData.offset ? ( inputData.offset - 1 ) * limit : 0;
|
|
18
18
|
|
|
19
|
-
const sortBy = inputData?.sortBy ?
|
|
19
|
+
const sortBy = inputData?.sortBy ? inputData.sortBy === 'coveredStepsAI' ? inputData.sortBy :`${inputData.sortBy}.keyword` : 'storeName.keyword';
|
|
20
20
|
const order = inputData?.sortOrder || -1;
|
|
21
21
|
let filter= [
|
|
22
22
|
{
|
|
@@ -174,7 +174,7 @@ export async function getList( req, res ) {
|
|
|
174
174
|
const userName = await findOneUser( { _id: element?._source?.userId }, { _id: 0, userName: 1 } );
|
|
175
175
|
if ( element?._source?.type == 'physical' ) {
|
|
176
176
|
exportData.push( {
|
|
177
|
-
'Date': dayjs( element?._source?.date ).format( '
|
|
177
|
+
'Date': dayjs( element?._source?.date ).format( 'D MMM, YYYY' ),
|
|
178
178
|
'Store Name': element?._source?.storeName,
|
|
179
179
|
'Store ID': element?._source?.storeId || 'Un Assigned',
|
|
180
180
|
'Store Name': element?._source?.storeName ||'Un Assigned',
|
|
@@ -190,7 +190,7 @@ export async function getList( req, res ) {
|
|
|
190
190
|
} );
|
|
191
191
|
} else {
|
|
192
192
|
exportData.push( {
|
|
193
|
-
'Date': dayjs( element?._source?.date ).format( '
|
|
193
|
+
'Date': dayjs( element?._source?.date ).format( 'D MMM, YYYY' ),
|
|
194
194
|
'Store Name': element?._source?.storeName,
|
|
195
195
|
'Store ID': element?._source?.storeId || 'Un Assigned',
|
|
196
196
|
'Store Name': element?._source?.storeName ||'Un Assigned',
|
|
@@ -221,6 +221,7 @@ export async function getList( req, res ) {
|
|
|
221
221
|
searchValue[i]._source.min = minutes;
|
|
222
222
|
searchValue[i]._source.sec = seconds;
|
|
223
223
|
searchValue[i]._source.auditedBy = userName?.userName || '';
|
|
224
|
+
searchValue[i]._source.date = dayjs( searchValue[i]?._source?.date ).format( 'D MMM, YYYY' );
|
|
224
225
|
}
|
|
225
226
|
}
|
|
226
227
|
|