tango-app-api-store-builder 1.0.2 → 1.0.3
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
|
@@ -2864,7 +2864,7 @@ export async function storeFixturesv2( req, res ) {
|
|
|
2864
2864
|
},
|
|
2865
2865
|
];
|
|
2866
2866
|
let complianceStatus = await planoComplianceService.aggregate( complianceQuery );
|
|
2867
|
-
const compliance = complianceStatus?.[0]?.status?.length ? ( complianceStatus?.[0]?.status?.
|
|
2867
|
+
const compliance = complianceStatus?.[0]?.status?.length ? ( ( complianceStatus?.[0]?.status?.length != shelf.productPerShelf ) || complianceStatus?.[0]?.status.includes( 'misplaced' ) ) ? 'improper' : 'proper' : 'improper';
|
|
2868
2868
|
|
|
2869
2869
|
const vmCount = await planoMappingService.count( { fixtureId: fixture._id, shelfId: shelf.toObject(), type: 'vm' } );
|
|
2870
2870
|
|
|
@@ -2994,7 +2994,7 @@ export async function storeFixturesv2( req, res ) {
|
|
|
2994
2994
|
},
|
|
2995
2995
|
];
|
|
2996
2996
|
let complianceStatus = await planoComplianceService.aggregate( complianceQuery );
|
|
2997
|
-
const compliance = complianceStatus?.[0]?.status.length ? ( complianceStatus?.[0]?.status?.
|
|
2997
|
+
const compliance = complianceStatus?.[0]?.status.length ? ( ( complianceStatus?.[0]?.status?.length != shelf.productPerShelf ) || complianceStatus?.[0]?.status?.includes( 'misplaced' ) ) ? 'improper' : 'proper' : 'improper';
|
|
2998
2998
|
|
|
2999
2999
|
|
|
3000
3000
|
const vmCount = await planoMappingService.count( { fixtureId: fixture._id, shelfId: shelf.toObject(), type: 'vm' } );
|
|
@@ -7371,8 +7371,8 @@ export async function updateProductMapping( req, res ) {
|
|
|
7371
7371
|
return res.sendError( 'No data found', 204 );
|
|
7372
7372
|
}
|
|
7373
7373
|
await Promise.all( storeDetails.map( async ( store ) => {
|
|
7374
|
-
let number = Number( store.storeName.replace( /\D/g, '' ) );
|
|
7375
|
-
let getLatestData = await fetch( `${JSON.parse( process.env.LAMBDAURL )?.getRFIDDetails}/${
|
|
7374
|
+
// let number = Number( store.storeName.replace( /\D/g, '' ) );
|
|
7375
|
+
let getLatestData = await fetch( `${JSON.parse( process.env.LAMBDAURL )?.getRFIDDetails}/${store.storeName}`, { method: 'GET' } );
|
|
7376
7376
|
if ( getLatestData.status == 200 ) {
|
|
7377
7377
|
let response = await getLatestData.json();
|
|
7378
7378
|
let data = response.mac_details.flatMap( ( ele ) => ele.body );
|