hypothetical/app/Models/Contact.php

17 lines
337 B
PHP
Raw Normal View History

<?php namespace App\Models;
2016-01-03 19:08:53 -05:00
use Illuminate\Database\Eloquent\Model;
2016-08-02 22:43:15 -04:00
class Contact extends Model {
// The contact table
2016-01-03 19:08:53 -05:00
protected $table = 'contact';
2016-08-02 22:43:15 -04:00
// Returns the list of all contact submissions
public static function getContactSubmissions()
{
return self::orderBy('created_at', 'desc')->get();
}
2016-08-02 22:43:15 -04:00
2016-01-03 19:08:53 -05:00
}