Ghost/ghost/admin/app/models/slack-integration.js
2019-01-21 12:26:21 +00:00

18 lines
484 B
JavaScript

import EmberObject from '@ember/object';
import ValidationEngine from 'ghost-admin/mixins/validation-engine';
import {computed} from '@ember/object';
import {isBlank} from '@ember/utils';
export default EmberObject.extend(ValidationEngine, {
// values entered here will act as defaults
url: '',
username: '',
validationType: 'slackIntegration',
isActive: computed('url', function () {
let url = this.get('url');
return !isBlank(url);
})
});