mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-06 22:40:14 -05:00
21 lines
402 B
JavaScript
21 lines
402 B
JavaScript
|
var ghostBookshelf = require('./base'),
|
||
|
Post = require('./post').Post,
|
||
|
AppField,
|
||
|
AppFields;
|
||
|
|
||
|
AppField = ghostBookshelf.Model.extend({
|
||
|
tableName: 'app_fields',
|
||
|
|
||
|
post: function () {
|
||
|
return this.morphOne(Post, 'relatable');
|
||
|
}
|
||
|
});
|
||
|
|
||
|
AppFields = ghostBookshelf.Collection.extend({
|
||
|
model: AppField
|
||
|
});
|
||
|
|
||
|
module.exports = {
|
||
|
AppField: AppField,
|
||
|
AppFields: AppFields
|
||
|
};
|