Project

General

Profile

Support #11522

Updated by Divya Inapakurthi 19 days ago

* Frontend Route Fix: Updated NeedsRescheduleJobsTicker.tsx API URL from plural /jobs/ to singular /job/needs-reschedule-jobs. 
 * Job Schema Update: Added needsReschedule, rescheduleReason, and subscriptionContractId fields to Job-Model.js to prevent schema stripping. 
 * Reschedule Query Controller: Fixed dynamic Client model registration and filtered strictly for active subscribers with past scheduled dates in jobs-controller.js. 
 * Payment Failure Guard: Added checks in invoicePaymentFailed.js to prevent late payment-failure webhooks from resurrecting cancelled or Completed subscriptions back to past_due. 
 * Centralized Settlement Engine: Created reusable computeCancellationSettlement in subscriptionHelper.js to calculate completed job costs, invoice payments, and balances. 
 * Contract Schema Update: Added cancellationSettlement schema definition in subscriptionContract.model.js so settlement records persist cleanly. 
 * Stripe Deletion Handler Refactor: Populated cancellationSettlement, restored customer cancellation emails, and fixed actor attribution (stripe/System vs. customer/Client) in subscriptionDeleted.js. 
 * Scheduled Cancellation Note Precision: Refined action history logging to clearly document scheduled period finalization vs. immediate cancellations. 
 * UI Service Settlement Refactor: Refactored cancelSubscriptionByUser in subscripiton.service.js to use the centralized settlement helper, eliminating duplicated logic. 
 * Comprehensive E2E Testing: Built and executed automated test suites with all 28/28 lifecycle tests passing and 0 ESLint errors.

Back