git add .

git commit "fix: city selection, comment user display, and back button bug"
This commit is contained in:
2026-08-22 09:13:09 +03:30
parent 669dd7cfff
commit 947d2425d9
16 changed files with 114 additions and 63 deletions
+5 -2
View File
@@ -3,11 +3,14 @@
namespace App\Http\Controllers;
use App\Models\City;
use App\Models\Province;
class CityController extends Controller
{
public function byProvince($province)
public function byProvince( Province $province)
{
return City::where('province_id', $province)->get();
return response()->json(
$province->cities()->select('id', 'name')->get()
);
}
}