• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Laravel Nova Dependency Container what are the allowed resource properties other than id in dependsOn

phplaravelpluginslaravel-nova


PHP Snippet 1:

Text::make('Recipient')
    ->hide()
    ->dependsOn(
        ['type'], 
        function (Text $field, NovaRequest $request, FormData $formData) {
            if ($formData->type === 'gift') {
                $field->show()->rules(['required', 'email']);
            }
        }
    ),

Related Snippets

Laravel csrf token mismatch for ajax POST Request

PHP's array_map including keys

Get data from accuweather api url

Convert every two values of an associative array into key-value pairs

"Notice: Undefined variable", "Notice: Undefined index", "Warning: Undefined array key", and "Notice: Undefined offset" using PHP

What is PHP's equivalent of JavaScript's "array.every()"?

how to retrieve the first and last instance of a row in pdo dataset

Testing subscription renewals on Stripe

How to average columns of data from multiple, flat arrays?

Additional price based on cart item count in WooCommerce

Match csv filenames to table names and import

How to keep value of selected value after form submission?

Laravel Nova, route not found

Cross-Origin Resource Sharing (CORS) witth Laravel and Vuejs

How to downgrade or install a specific version of Composer?

About Contact Privacy policy Terms and conditions