Update dashboard

This commit is contained in:
Mathieu Lagace
2020-07-30 18:42:43 -04:00
parent 4c5d635d5b
commit 65876e5b78
7 changed files with 81 additions and 72 deletions

View File

@@ -3,6 +3,7 @@
namespace App;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Support\Facades\Date;
/**
* App\News
@@ -63,7 +64,10 @@ class News extends Model
{
if($event->use_weekly_msg == 1)
{
$news->push(self::getWeeklyMsg($event));
if (strtotime($event->weekly_msg_publication_time) <= time())
{
$news->push(self::getWeeklyMsg($event));
}
}
}