diff --git a/app/Http/Controllers/Admin/ManageCustomerController.php b/app/Http/Controllers/Admin/ManageCustomerController.php index 89ff1b0..547e33f 100644 --- a/app/Http/Controllers/Admin/ManageCustomerController.php +++ b/app/Http/Controllers/Admin/ManageCustomerController.php @@ -149,23 +149,7 @@ public function delete_customer($id) return response()->json(['success' => false, 'status' => 500, 'message' => __('auth.something_went_wrong')]); } } -// public function download_pdf($id) -// { -// // try { -// $customers_data = IamPrincipal::findOrFail($id); -// // dd($customers_data); -// $data = [ -// 'customers_data' => $customers_data -// ]; - -// $pdf = PDF::loadView('Admin.pages.manage_users.manage_customer.view_customer_details_pdf', $data); -// return $pdf->download('customer_details.pdf'); -// // } catch (Exception $e) { -// // Log::error("Manage Voucher Page Not Load " . $e->getMessage()); -// // return jsonResponseWithErrorMessage(__('auth.something_went_wrong'), 500); -// // } -// } public function download_pdf($id) { try { @@ -183,23 +167,23 @@ public function download_pdf($id) } -public function exportSelectedCustomer(Request $request) -{ +// public function exportSelectedCustomer(Request $request) +// { + +// try { - try { +// if ($request->has('all_id')) { +// return Excel::download(new customer_export, 'Passport_data.xlsx'); +// } - if ($request->has('all_id')) { - return Excel::download(new customer_export, 'Passport_data.xlsx'); - } +// $ids = $request->selected_id; - $ids = $request->selected_id; - - $fileName = 'selected_customer_data.xlsx'; - return Excel::download(new CustomerExportSelected ($ids), $fileName); - } catch (\Exception $e) { - return response()->json(['error' => 'Export failed. Something went wrong.'], 500); - } -} +// $fileName = 'selected_customer_data.xlsx'; +// return Excel::download(new customer_export_selected($ids), $fileName); +// } catch (\Exception $e) { +// return response()->json(['error' => 'Export failed. Something went wrong.'], 500); +// } +// } diff --git a/resources/views/Admin/pages/manage_users/manage_customer/customer.blade.php b/resources/views/Admin/pages/manage_users/manage_customer/customer.blade.php index f6ba887..05d2626 100644 --- a/resources/views/Admin/pages/manage_users/manage_customer/customer.blade.php +++ b/resources/views/Admin/pages/manage_users/manage_customer/customer.blade.php @@ -279,9 +279,13 @@ $currentPage = 'manage-patient'; --> @endsection \ No newline at end of file