agilasadi
237
6
Nova

Fields in Nova for inserting data with child table

Posted 3 months ago by agilasadi

I have quite a little experience with the capabilities of Nova, but recently I started working on a multi-lingual application with Nova. Here is the point where I got stuck.

My table structure is somewhat like below:


        Schema::create('roles', function (Blueprint $table) {
            $table->bigIncrements('auto_id');
            $table->string('id');

            $table->timestamps();
            $table->softDeletes();
        });

        Schema::create('role_translation', function (Blueprint $table) {
            $table->string('role_id');
            $table->string('translation_id');

            $table->string('role_name');
            $table->string('role_description')->nullable();

            $table->string('created_by');
            $table->string('updated_by')->nullable();

            $table->timestamps();
            $table->softDeletes();
        });

Now when I insert into roles I also need to insert into role_translations I don't know how to provide fields for Nova to give me the desired interface.

Please sign in or create an account to participate in this conversation.