Example of Laravel relationship where condition.
$users = User::with('account', 'role')->whereHas('role', function ($q) {
$q->where('name', 'Administrator');
})->get();
| { | |
| "recommendations": [ | |
| "alexcvzz.vscode-sqlite", | |
| "amazonwebservices.aws-toolkit-vscode", | |
| "attilabuti.vscode-mjml", | |
| "better-ts-errors.better-ts-errors", | |
| "bierner.color-info", | |
| "bmewburn.vscode-intelephense-client", | |
| "bradlc.vscode-tailwindcss", | |
| "cssho.vscode-svgviewer", |
| <?php | |
| namespace App\Http\Controllers\External; | |
| use Illuminate\Http\Request; | |
| use App\Http\Controllers\Controller; | |
| class DocumentController extends Controller | |
| { | |
| /** |
| <?php | |
| namespace App\Http\Controllers\External; | |
| use Illuminate\Http\Request; | |
| use App\Http\Controllers\Controller; | |
| class AwardsSubmissionController extends Controller | |
| { | |
| /** |
| /** | |
| * The following block of code is to load all JQuery functions and methods | |
| * | |
| * | |
| * | |
| */ | |
| $(document).ready(function () { | |
| // load file upload display text function | |
| fileUpload(); | |
| <?php | |
| namespace App\Helpers; | |
| use App\Account; | |
| use Illuminate\Http\Request; | |
| use Illuminate\Support\Facades\Validator; | |
| class FormHelper | |
| { |
Example of Laravel relationship where condition.
$users = User::with('account', 'role')->whereHas('role', function ($q) {
$q->where('name', 'Administrator');
})->get();
| <?php | |
| use App\Account; | |
| use App\User; | |
| use Illuminate\Database\Seeder; | |
| use Symfony\Component\Console\Helper\ProgressBar; | |
| use Symfony\Component\Console\Output\ConsoleOutput; | |
| class LocalUserSeeder extends Seeder | |
| { |
Pre-requisites:
Please note, registry keys checked for pending reboot:
W2K3 = "SYSTEM\CurrentControlSet\Control\Session Manager\PendingFileRenameOperations"
Set-ExecutionPolicy RemoteSignedYou need to configure this setting only once on your computer, not every time you connect.
$UserCredential = Get-Credential