mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-04-15 03:01:37 -05:00
Added new type column for tiers
refs https://github.com/TryGhost/Team/issues/1037 - adds new `type` column for tiers to differentiate between free and paid tiers - all existing tiers are updated to be `paid` tiers
This commit is contained in:
parent
d77948540a
commit
761a330e16
2 changed files with 13 additions and 0 deletions
|
@ -0,0 +1,12 @@
|
|||
const utils = require('../../utils');
|
||||
|
||||
module.exports = utils.createAddColumnMigration(
|
||||
'products',
|
||||
'type',
|
||||
{
|
||||
type: 'string',
|
||||
maxlength: 50,
|
||||
nullable: false,
|
||||
defaultTo: 'paid'
|
||||
}
|
||||
);
|
|
@ -381,6 +381,7 @@ module.exports = {
|
|||
monthly_price_id: {type: 'string', maxlength: 24, nullable: true},
|
||||
yearly_price_id: {type: 'string', maxlength: 24, nullable: true},
|
||||
description: {type: 'string', maxlength: 191, nullable: true},
|
||||
type: {type: 'string', maxlength: 50, nullable: false, defaultTo: 'paid', validations: {isIn: [['paid', 'free']]}},
|
||||
created_at: {type: 'dateTime', nullable: false},
|
||||
updated_at: {type: 'dateTime', nullable: true}
|
||||
},
|
||||
|
|
Loading…
Add table
Reference in a new issue