<?php
namespace app\model;

class Announcements extends base
{
    protected $table = 'announcements';

    public function adminInfo() {
        return $this->belongsTo(Admins::class, 'admin_id')->visible(['name','username','avatar']);
    }
}