Fix #1413 ensure plans always have default pricelists attached (regression*)
*Previously all plans were ensured to have default price_lists attached at app start up, causing significantly slow app start-up times (due to sites with 100s of plan revisions (since plans are immutable, each edit creates a new plan id). The app-startup logic to ensure all plans had price_lists was removed (causing the regression). Resolved by ensuring plans have at least default price lists on-access (a crude len(self.price_lists) > 0 check)
Issue ref: #1413
Fix #1413 ensure plans always have default pricelists attached (regression*)
*Previously all plans were ensured to have default price_lists attached at app start up, causing significantly slow app start-up times (due to sites with 100s of plan revisions (since plans are immutable, each edit creates a new plan id). The app-startup logic to ensure all plans had price_lists was removed (causing the regression). Resolved by ensuring plans have at least default price lists on-access (a crude
len(self.price_lists) > 0
check)Screenshot before:
Screenshot after:
How to run test(s) for this PR see: Testing
TODO: app startup time test?