diff --git a/library/Eagle/Model/CommentHistory.php b/library/Eagle/Model/CommentHistory.php new file mode 100644 index 00000000..518c7011 --- /dev/null +++ b/library/Eagle/Model/CommentHistory.php @@ -0,0 +1,63 @@ +add(new BoolCast([ + 'is_persistent', + 'has_been_removed' + ])); + + $behaviors->add(new Timestamp([ + 'entry_time', + 'expire_time', + 'remove_time' + ])); + } + + public function createRelations(Relations $relations) + { + $relations->belongsTo('endpoint', Endpoint::class); + $relations->belongsTo('environment', Environment::class); + $relations->belongsTo('host', Host::class)->setJoinType('LEFT'); + $relations->belongsTo('service', Service::class)->setJoinType('LEFT'); + } +}