Merged in afiqhamzah/chores/add-header-to-disable-caching-cawangan-data (pull request #93)

Add response  header to disable caching cawangan data
This commit is contained in:
Afiq Hamzah
2024-01-15 07:00:57 +00:00
+6 -3
View File
@@ -143,7 +143,12 @@ class TunaiController extends Controller
->where([['kodcaw','=',$kodcaw],['tarikh','=',$current->toDateString()],['kodlaluan','=',$request->kodlaluan]])
->orderBy('tarikh','desc')
->first();
return response()->json($tunai);
return response()->json($tunai)
->withHeaders([
'Pragma' => 'no-cache',
'Cache-Control' => 'no-store',
'Expires' => 'Mon, 01 Jan 1990 00:00:00 GMT',
]);
}
@@ -640,5 +645,3 @@ class TunaiController extends Controller
return response()->json($requestteller);
}
}