Move DomainController::NODE* to Address::NODE*, make role mandatory in the database, change logic so that mail generated by the host comes from a node address.

This commit is contained in:
Deon George
2022-01-24 22:56:13 +11:00
parent efa7195633
commit d660d5a6df
15 changed files with 143 additions and 110 deletions

View File

@@ -69,7 +69,7 @@ final class Echomail extends Model implements Packet
}
// Our address
$ftns = Setup::findOrFail(config('app.id'))->system->match($model->fftn->zone);
$ftns = Setup::findOrFail(config('app.id'))->system->match($model->fftn->zone,Address::NODE_ACTIVE|Address::NODE_PVT|Address::NODE_HOLD);
// Add our address to the seenby;
$model->set_seenby = array_merge($model->set_seenby,$ftns->pluck('id')->toArray());