Hub 2.21.0: install the Church Website; Website storage bought in steps

- New install offers the Church Website: Accounts first when the church has
  none, at accounts.<its address> (www. dropped); the FastPanel email sends a
  www. site's bare domain to www. with a 301.
- Licence.extraStorageSteps (migration): the token sends a Website its limit
  (5 GB + steps, limits.storageBytes, contracts 1.17.0); invoices bill the
  steps bought instead of the storage reported. Edit popup field 0-99.
- A Website/App licence starts on its plan however it's made (New install too).
- Vendored @crosscode/contracts 1.17.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-25 00:03:21 +02:00
co-authored by Claude Opus 5.5
parent 6f8242064f
commit c6f734ab20
21 changed files with 235 additions and 36 deletions
+6
View File
@@ -88,6 +88,12 @@ describe('licences', () => {
await expect(generateLicence(mockDb, { customerId: 'c2', product: 'events', data: {} })).resolves.toBeTruthy();
});
test('2.21.0: a Website licence starts on the Website plan and an App one on the first tier, however it is made', async () => {
expect((await generateLicence(mockDb, { customerId: 'c1', product: 'website' })).licence.plan).toBe('Website');
expect((await generateLicence(mockDb, { customerId: 'c1', product: 'app' })).licence.plan).toBe('Mustard Seed');
expect((await generateLicence(mockDb, { customerId: 'c2', product: 'website', data: { plan: 'Custom' } })).licence.plan).toBe('Custom');
});
test('a revoked licence can be replaced', async () => {
const { licence } = await generateLicence(mockDb, { customerId: 'c1', product: 'events', data: {} });
licence.status = 'revoked';