K
K
keishi_wot2022-03-30 13:45:51
Laravel
keishi_wot, 2022-03-30 13:45:51

Laravel 8. How to transfer data from one table to another table with the same structure when clicking on a button?

I just started laravel. I know how to delete a specific entry by id, send change data from the form. But I can't figure out how to move a specific row from a table to another.

<form action="{{route('list.destroy', ['list' => $user->id])}}" method="post" class="p-0">
                        @csrf
                        @method("DELETE")
                        <div class="col-12 d-grid gap-2 p-0 m-0">
                          <button class="btn btn-secondary rounded-0" type="submit">Удалить заявку</button>
                        </div>
                      </form>
                      <form action="{{route('', ['list' => $user->id])}}" method="post" class="p-0">
                        @csrf
                        @method("что-то здесь должно быть?? или использовать метод не надо ")
                        <div class="col-12 d-grid gap-2 p-0 m-0">
                          <button class="btn btn-secondary rounded-0" type="submit">Удалить заявку</button>
                        </div>
                      </form>

Answer the question

In order to leave comments, you need to log in

1 answer(s)
T
TheAndrey7, 2022-03-30
@TheAndrey7

Read documentation:

  • https://laravel.com/docs/8.x
  • https://laravel.su/docs/8.x

to be without it
@method("что-то здесь должно быть?? или использовать метод не надо ")

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question