tango-app-api-payment-subscription 3.0.23-dev → 3.0.24-dev
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/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
3
|
import { paymentSubscriptionRouter } from './src/routes/paymentSubscription.routes.js';
|
|
4
|
-
import {
|
|
4
|
+
import { paymentDocs } from './src/docs/payment.docs.js';
|
|
5
5
|
|
|
6
|
-
export { paymentSubscriptionRouter,
|
|
6
|
+
export { paymentSubscriptionRouter, paymentDocs };
|
|
7
7
|
|
|
8
8
|
|
package/package.json
CHANGED
|
@@ -784,6 +784,8 @@ export const trialApproval = async ( req, res ) => {
|
|
|
784
784
|
}
|
|
785
785
|
requestData.status = 'completed';
|
|
786
786
|
requestData.save().then( async () => {
|
|
787
|
+
req.body.clientId = requestData.clientId;
|
|
788
|
+
updatePricing( req, res, true );
|
|
787
789
|
if ( req.body.type == 'approve' ) {
|
|
788
790
|
let clientProducts = await paymentService.findOne( { clientId: requestData.clientId, status: 'active' }, { planDetails: 1 } );
|
|
789
791
|
if ( clientProducts?.planDetails.subscriptionType == 'free' ) {
|
package/src/docs/payment.docs.js
CHANGED