vendredi 27 mars 2020

Laravel creating a pop-up form to create and edit

I am new to Laravel. currently, I am creating a website to show the information of the data, In that page, I hope to make it to pop-up a form to let the user create and also edit the data. But I have no idea about the pop-up form. Anyone can give me some advice? The edit will be beside each of the data and create will be at the bottom of the UI. I already do the controller for the update function. Any idea about it?

HERE IS MY CODE OF INDEX

@section('content')

<div class="panel-body">
  @if(count($areas)>0)
  <table class="table table-striped task-table">
      <thead>
        <tr>
          <th>No.</th>
          <th>Area Name </th>
        </tr>
      </thead>
      <tbody>
        <div class="form-popup" id="myForm">
        @foreach( $areas as $i => $area)
        <tr>
          <td class="table-text">
            <div></div>
          </td>
          <td class="table-text">
            <div></div>
          </td>
          <td class="table-text" >
            <button>edit</button>
          </td>
        </tr>
        @endforeach
      </tbody>
  </table>
  @endif
@endsection

IDK how can I create the form for the edit function. Any suggestion will grateful.



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/3bwukLP
via IFTTT

Aucun commentaire:

Enregistrer un commentaire