This repository has been archived on 2024-12-15. You can view files and clone it, but cannot push or open issues or pull requests.
seepur/app/Models/Call.js

20 lines
445 B
JavaScript

'use strict'
/** @type {typeof import('@adonisjs/lucid/src/Lucid/Model')} */
const Model = use('Model')
const User = use('App/Models/User');
const Book = use('App/Models/Book');
class Call extends Model {
parent() {
return this.belongsTo('App/Models/User', 'parent_id');
}
guest() {
return this.belongsTo('App/Models/User', 'guest_id');
}
child() {
return this.belongsTo('App/Models/Child');
}
}
module.exports = Call