Commit 5ff6948d by Alfiro Pratama

Return route monev anggaran

parent 1a89dfa2
...@@ -303,10 +303,10 @@ class MonevController extends Controller ...@@ -303,10 +303,10 @@ class MonevController extends Controller
]); ]);
DB::commit(); DB::commit();
return redirect()->back()->with('success', 'Data berhasil disimpan'); return redirect()->route('mahasiswa.monev-anggaran', ['id' => encrypt($key['monev_id'])])->with('success', 'Data berhasil disimpan');
} catch (\Exception $e) { } catch (\Exception $e) {
DB::rollback(); DB::rollback();
return redirect()->back()->with('error', 'Gagal menyimpan data: ' . $e->getMessage()); return redirect()->route('mahasiswa.monev-anggaran', ['id' => encrypt($key['monev_id'])])->with('error', 'Gagal menyimpan data: ' . $e->getMessage());
} }
} }
......
...@@ -238,7 +238,7 @@ ...@@ -238,7 +238,7 @@
text: response.message || 'Data berhasil disimpan', text: response.message || 'Data berhasil disimpan',
confirmButtonText: 'OK' confirmButtonText: 'OK'
}).then(() => { }).then(() => {
location.reload(); // Reload data table setelah operasi berhasil location.reload();
}); });
} else { } else {
Swal.fire({ Swal.fire({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment