Subscription plans – system description
Fields of the plan table, cycle protection of inheritance, saving and deletion rules, and the list's data sources and permission keys.
Overview
A plan is master data; its content (functions, limits, prices) comes from the per-plan items of the subscription definition. Table names carry the installation's own prefix in the database.
Data model
| Table | Main fields |
|---|---|
subscription_plan | code, name, description, parent_plan_id (inheritance, cycle-protected), is_addon, is_free, level, price_month, currency, sort_order, status |
subscription_plan_to_store | stores |
subscription_plan_feature | legacy content table; planFeatures() and syncGrants() still read it |
List, save, delete
- List: filter add-on, status, search; sort by code, name, monthly fee; columns include the number of functions (legacy content table) and of subscriptions; icons edit, delete, parent, subscriptions.
- Save: code
[A-Za-z0-9_]{2,32}(error_code), name required (error_name); the parent cannot be the plan itself or a descendant (normalizeParent); the form links to the definition screen (withlist) and shows theDlbtpayment::ANNUAL_DISCOUNT(10%); after savingdlbtentitlement->flush(). - Delete: blocked by a subscription (
error_in_use) or a child plan (error_has_children); otherwise physical deletion with the legacy content rows; nocanBulkfor bulk delete.
Permissions
list:UNMAPPED;edit,add,delete,debug: not classified (projected from the old catalogue). For a new recordcanSaveasks foredit, because there is noaddrow in the master.- No content scope (system master).