tango-app-api-client 3.6.5-vms.16 → 3.6.5-vms.18
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
|
@@ -3129,11 +3129,11 @@ export async function createStoreRequest( req, res ) {
|
|
|
3129
3129
|
const upsertRecord = await updateOneUpsertVmsStoreRequest( { storeId: inputData?.storeId, dateString: inputData?.dateString }, record );
|
|
3130
3130
|
logger.info( { upsertRecord } );
|
|
3131
3131
|
if ( upsertRecord?.upsertedCount === 1 ) {
|
|
3132
|
-
return res.
|
|
3132
|
+
return res.sendTemp( 'The Request has been sent Successfully' );
|
|
3133
3133
|
} else if ( upsertRecord?.matchedCount === 1 && upsertRecord?.modifiedCount === 1 ) {
|
|
3134
|
-
return res.
|
|
3134
|
+
return res.sendTemp( 'The Request has been updated Successfully' );
|
|
3135
3135
|
} else if ( upsertRecord?.matchedCount === 1 && upsertRecord?.modifiedCount === 0 ) {
|
|
3136
|
-
return res.
|
|
3136
|
+
return res.sendTemp( 'The Request already exists and nothing to update' );
|
|
3137
3137
|
} else {
|
|
3138
3138
|
return res.sendError( 'Internal Server Error', 500 );
|
|
3139
3139
|
}
|