Files
NEUP-FleaMarket/app/MessageContact.php
T
Harry Zhou 5361c151e5 Elegantilize contact list
1. Split getContact into getHistoryContact and getNewContact
2. Now contacts with new messages will go on top of the list
2017-06-10 07:59:46 +08:00

15 lines
273 B
PHP

<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class MessageContact extends Model
{
protected $fillable = ['user_id', 'contact_id', 'unread_count'];
public function contact()
{
return $this->belongsTo('App\User', 'contact_id');
}
}