mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-19 16:42:17 +03:00
ce80d250bf
refs e26c977c66
- handles null trial days in admin and API, sets trial days as 0 for null values
20 lines
637 B
JavaScript
20 lines
637 B
JavaScript
import Model, {attr} from '@ember-data/model';
|
|
import ValidationEngine from 'ghost-admin/mixins/validation-engine';
|
|
|
|
export default Model.extend(ValidationEngine, {
|
|
validationType: 'tier',
|
|
|
|
name: attr('string'),
|
|
description: attr('string'),
|
|
active: attr('boolean'),
|
|
slug: attr('string'),
|
|
welcomePageURL: attr('string'),
|
|
visibility: attr('string', {defaultValue: 'none'}),
|
|
type: attr('string', {defaultValue: 'paid'}),
|
|
currency: attr('string'),
|
|
monthlyPrice: attr('number'),
|
|
yearlyPrice: attr('number'),
|
|
trialDays: attr('number', {defaultValue: 0}),
|
|
benefits: attr('tier-benefits')
|
|
});
|