diff --git a/app/Exports/V3/SafetyAndPrivacy/Country/AccessRoadReport.php b/app/Exports/V3/SafetyAndPrivacy/Country/AccessRoadReport.php index 37517385..ab5034ab 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Country/AccessRoadReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Country/AccessRoadReport.php @@ -43,7 +43,7 @@ class AccessRoadReport implements FromView, WithEvents, ShouldAutoSize, WithDraw } } - return view('v3.Reports.SafetyAndPrivacy.Country.AccessRoadReport', [ + return view('v3.Reports.SafetyAndPrivacy.Country.AccessRoadActivityReport', [ 'data' => $data, ]); } diff --git a/app/Exports/V3/SafetyAndPrivacy/Country/ConstructionReport.php b/app/Exports/V3/SafetyAndPrivacy/Country/ConstructionReport.php index 3e64d0c8..52f57616 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Country/ConstructionReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Country/ConstructionReport.php @@ -44,7 +44,7 @@ class ConstructionReport implements FromView, WithEvents, ShouldAutoSize, WithDr } } - return view('v3.Reports.SafetyAndPrivacy.Country.ConstructionReport', [ + return view('v3.Reports.SafetyAndPrivacy.Country.ConstructionActivityReport', [ 'data' => $data, ]); } diff --git a/app/Exports/V3/SafetyAndPrivacy/Country/UtilityPassingReport.php b/app/Exports/V3/SafetyAndPrivacy/Country/UtilityPassingReport.php index e44b14ac..1221ca07 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Country/UtilityPassingReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Country/UtilityPassingReport.php @@ -44,7 +44,7 @@ class UtilityPassingReport implements FromView, WithEvents, ShouldAutoSize, With } } - return view('v3.Reports.SafetyAndPrivacy.Country.UtilityPassingReport', [ + return view('v3.Reports.SafetyAndPrivacy.Country.UtilityPassingActivityReport', [ 'data' => $data, ]); } diff --git a/app/Exports/V3/SafetyAndPrivacy/Province/AccessRoadReport.php b/app/Exports/V3/SafetyAndPrivacy/Province/AccessRoadReport.php index bc80b3a4..053de9b4 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Province/AccessRoadReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Province/AccessRoadReport.php @@ -43,7 +43,7 @@ class AccessRoadReport implements FromView, WithEvents, ShouldAutoSize, WithDraw } } - return view('v3.Reports.SafetyAndPrivacy.Province.AccessRoadReport', [ + return view('v3.Reports.SafetyAndPrivacy.Province.AccessRoadActivityReport', [ 'data' => $data, ]); } diff --git a/app/Exports/V3/SafetyAndPrivacy/Province/ConstructionReport.php b/app/Exports/V3/SafetyAndPrivacy/Province/ConstructionReport.php index e6492019..07e2d138 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Province/ConstructionReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Province/ConstructionReport.php @@ -43,7 +43,7 @@ class ConstructionReport implements FromView, WithEvents, ShouldAutoSize, WithDr } } - return view('v3.Reports.SafetyAndPrivacy.Province.ConstructionReport', [ + return view('v3.Reports.SafetyAndPrivacy.Province.ConstructionActivityReport', [ 'data' => $data, ]); } diff --git a/app/Exports/V3/SafetyAndPrivacy/Province/UtilityPassingReport.php b/app/Exports/V3/SafetyAndPrivacy/Province/UtilityPassingReport.php index d0f5f6a4..5c67b160 100644 --- a/app/Exports/V3/SafetyAndPrivacy/Province/UtilityPassingReport.php +++ b/app/Exports/V3/SafetyAndPrivacy/Province/UtilityPassingReport.php @@ -43,7 +43,7 @@ class UtilityPassingReport implements FromView, WithEvents, ShouldAutoSize, With } } - return view('v3.Reports.SafetyAndPrivacy.Province.UtilityPassingReport', [ + return view('v3.Reports.SafetyAndPrivacy.Province.UtilityPassingActivityReport', [ 'data' => $data, ]); } diff --git a/app/Http/Controllers/HomeContentController.php b/app/Http/Controllers/HomeContentController.php index 9df4af59..a42efa07 100644 --- a/app/Http/Controllers/HomeContentController.php +++ b/app/Http/Controllers/HomeContentController.php @@ -64,7 +64,10 @@ class HomeContentController extends Controller public function getAllCitiesByProvince($id) { - $cities = \App\Models\City::where('province_id', $id)->where('type_id', 1)->get(); + $cities = \App\Models\City::query() + ->where('province_id', $id) + ->where('type_id', 1) + ->get(['id', 'name_fa', 'province_id','center_lat','center_lng']); // $cities = \App\Models\City::where('province_id', $id)->get(); return response()->json([ diff --git a/app/Http/Controllers/V3/Dashboard/Accident/AccidentReceiptController.php b/app/Http/Controllers/V3/Dashboard/Accident/AccidentReceiptController.php index f4a5900b..1a5e5555 100644 --- a/app/Http/Controllers/V3/Dashboard/Accident/AccidentReceiptController.php +++ b/app/Http/Controllers/V3/Dashboard/Accident/AccidentReceiptController.php @@ -246,7 +246,6 @@ class AccidentReceiptController extends Controller public function confirmPaymentInfo(ConfirmPaymentInfoRequest $request, Accident $accident): JsonResponse { DB::transaction(function () use ($request, $accident) { - $accident->update([ 'deposit_insurance_image' => $request->has('deposit_insurance_image') ? FileFacade::save($request->deposit_insurance_image, "receipts_files/{$accident->id}/deposit_insurance") : null, 'deposit_insurance_amount' => $request->deposit_insurance_amount ?? 0, diff --git a/database/migrations/2025_08_30_110027_add_paid_driver_to_accidents_table.php b/database/migrations/2025_08_30_110027_add_paid_driver_to_accidents_table.php new file mode 100644 index 00000000..cb903027 --- /dev/null +++ b/database/migrations/2025_08_30_110027_add_paid_driver_to_accidents_table.php @@ -0,0 +1,30 @@ +unsignedBigInteger('driver_share_amount')->nullable(); + $table->unsignedBigInteger('driver_rate')->nullable(); + + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('accidents', function (Blueprint $table) { + $table->dropColumn('driver_share_amount', 'driver_rate'); + }); + } +};