idea-php-laravel-plugin icon indicating copy to clipboard operation
idea-php-laravel-plugin copied to clipboard

Feature Request:Add new things to autocomplete

Open vv12131415 opened this issue 7 years ago • 3 comments

First of all I would like to thank you this great plugin!

I found that it will be useful to autocomplete 2 things here.

  1. In migrations Let say we have something like this in migration
Schema::table('balances', function (Blueprint $table) {
            $table->foreign('user_id')->references('id')->on('users');
            $table->foreign('currency_id')->references('id')->on('currencies');
        });

1.1) That will be cool to autocomplete balances (or other table) 1.2) it's nice to autocomplete the methods params (tables and columns) of Blueprint and Fluent like foreign, on, dropForeign, and etc.

  1. In Models Let say we have something like this in model
class Operation extends Model
{
    protected $visible = [
        'id',
        'name',
    ];
    
    protected $fillable = [
        'name',
    ];
}

2.1) That will be cool to autocomplete columns $visible and $fillable

Is there any thing that I can help you with?

vv12131415 avatar Aug 15 '17 02:08 vv12131415

Do you want to use Database tab of Idea or what? I don't want to go directly to database. Sometimes it's not possible(vagrant, etc.) So, we can use Eloquent models... get table names and field names, generated by ide-helper:models.. the only way I see...

adelf avatar Aug 15 '17 11:08 adelf

I was thinking of database tab, I use vagrant you can configure to use it there. But ide-helper way sounds cool too.

vv12131415 avatar Aug 15 '17 11:08 vv12131415

Also a good one is autocomplete in where method of model like Operation::where('name', 'add')

vv12131415 avatar Aug 15 '17 22:08 vv12131415