title: exception: "Symfony\Component\HttpKernel\Exception\NotFoundHttpException",…}
body: <p>I have this script in my php model:</p>
  <pre><code>private function getAcciones() : array
  {
      $base_url = url(config('backpack.base.route_prefix'));
      $todas_las_acciones = [
          [
              'condition' =&gt; $this-&gt;isDeletable(),
              'action'    =&gt; '
                              &lt;script type=&quot;text/javascript&quot;&gt;
                                     function deleteComplementoPago( id ){
                                         Swal.fire({
                                              title: \'¿Esta segura/o de eliminar este complemento de pago?\',
                                              type: \'warning\',
                                              showCancelButton: true,
                                              confirmButtonColor: \'#3085d6\',
                                              cancelButtonColor: \'#d33\',
                                              confirmButtonText: \'Si, confirmar\',
                                              showLoaderOnConfirm: true,
                                              
                                              }).then((result) =&gt; {
                                                  if( result.value ){
                                                      $.ajax({
                                                      type: &quot;POST&quot;,
                                                      url: &quot;/webapi/finanzas/complemento/pago/&quot; + id + &quot;/delete&quot;,
                                                      data: { pago_id: id },
                                                      success: function(data){
                                                          console.log(data)
                                                          window.location.replace(&quot;' . $base_url . '/finanzas/complemento/pago&quot;);
                                                      }
                                                      })                                          
                                                  }
                                              });
                                     }
                              &lt;/script&gt;
                              &lt;li&gt;&lt;a onclick=&quot;deleteComplementoPago(\''.$this-&gt;id.'\')&quot;&gt;&lt;i class=&quot;fa fa-times&quot;&gt;&lt;/i&gt; Borrar &lt;/a&gt;&lt;/li&gt;'
          ]
      ];
  
      $result = [];
  
      foreach ($todas_las_acciones as $accion){
          if($accion['condition']){
              $result[] = $accion['action'];
          }
      }
  
      return $result;
  }
  </code></pre>
  <p>And I have this in my web.php</p>
  <pre><code>Route::get('finanzas/complemento/pago/{pago}/delete', 'PagoCrudController@deletePago');
  </code></pre>
  <p>I just want to make the swal.fire to appear and ask the customer if he/she really wants to delete the item, however im getting this error:</p>
  <p><strong>{message: &quot;&quot;, exception: &quot;Symfony\Component\HttpKernel\Exception\NotFoundHttpException&quot;,…}
  exception: &quot;Symfony\Component\HttpKernel\Exception\NotFoundHttpException&quot;
  file: &quot;/Users/rodri6uez/Documents/LARAVEL/HIPO/vendor/laravel/framework/src/Illuminate/Routing/RouteCollection.php&quot;
  line: 179
  message: &quot;&quot;
  trace: [{,…}, {,…}, {,…}, {,…}, {,…},…]</strong></p>
  <p>This is what I have on my controller:</p>
  <pre><code>public function deletePago(Pago $pago){
      try{
          \DB::beginTransaction();
          $pagos_factura = $pago-&gt;pago_facturas()-&gt;get();
          foreach ($pagos_factura as $pago_factura){
              $abono = Abono::withTrashed()-&gt;where('origen_id', $pago_factura-&gt;id)
                  -&gt;where('tipo', 'Complemento pago')
                  -&gt;first();
              if( isset($abono) ) $this-&gt;borrar_abono($abono);
              $pago_factura-&gt;delete();
          }
  
          $pago-&gt;delete();
          \DB::commit();
          \Alert::success(trans(&quot;Complemento de pago borrado con exito&quot;))-&gt;flash();
          return redirect('admin/finanzas/complemento/pago');
      }catch (\Exception $e){
          \DB::rollBack();
          \Alert::error(trans($e-&gt;getMessage()))-&gt;flash();
          return redirect('admin/finanzas/complemento/pago');
      }
  }
  </code></pre>
  <p>Could you help me please? I cannot see what my error is.</p>