Fixes #909 - expired licenses showing in email report

This commit is contained in:
snipe
2015-07-13 20:59:02 -07:00
parent f09ee24975
commit 56345b5743
+1
View File
@@ -171,6 +171,7 @@ public function freeSeat()
return License::whereNotNull('expiration_date')
->whereNull('deleted_at')
->whereRaw(DB::raw( 'DATE_SUB(`expiration_date`,INTERVAL '.$days.' DAY) <= DATE(NOW()) ' ))
->where('expiration_date','<',date("Y-m-d"))
->orderBy('expiration_date', 'ASC')
->get();