diff --git a/app/Http/Controllers/Admin/ManageCommissionController.php b/app/Http/Controllers/Admin/ManageCommissionController.php index 3328cd6..7d8a2e1 100644 --- a/app/Http/Controllers/Admin/ManageCommissionController.php +++ b/app/Http/Controllers/Admin/ManageCommissionController.php @@ -117,7 +117,6 @@ class ManageCommissionController extends Controller public function editProduct(Request $request) { // dd($request->all()); - // dd($request->end_of_trail.' 00:00:00.0'); $validator = Validator::make($request->post(), [ 'commission_type' => 'required', // 'profit_sharing' => 'required', @@ -134,6 +133,24 @@ class ManageCommissionController extends Controller if ($validationMessage) { return response()->json(['status' => 400, 'message' => $validationMessage]); } + + $product = Product::where('id', $request->products_id)->first(); + $productpresentation = ''; + + if($request->has('channel_partner_agreement')) { + if($product && $product->channel_partner_aggrement) { + if(\File::exists(public_path('/uploads/product/channel_partner_agreement/'.$product->channel_partner_aggrement))) { + \File::delete(public_path('/uploads/product/channel_partner_agreement/'.$product->channel_partner_aggrement)); + } + } + + $productpresentation .= time().'_partner_agreement'.'.'.$request->channel_partner_agreement->extension(); + // dd($productpresentation); + $request->channel_partner_agreement->move(public_path('/uploads/product/channel_partner_agreement'),$productpresentation); + + } + // dd($productpresentation); + Product::where('id', $request->products_id)->update([ 'commission_type' => $request->commission_type, 'profit_sharing' => $request->profit_sharing, @@ -143,8 +160,12 @@ class ManageCommissionController extends Controller 'gst' => $request->gst, 'tds' => $request->tds, 'end_of_trail' => $request->end_of_trail, + 'channel_partner_aggrement'=> $productpresentation, ]); + + + $returnType = [ 'Monthly' => '1 month', 'Quarterly' => '3 months', diff --git a/public/assets/css/style.bundle.css b/public/assets/css/style.bundle.css index 3d673a3..5954dea 100644 --- a/public/assets/css/style.bundle.css +++ b/public/assets/css/style.bundle.css @@ -57939,3 +57939,15 @@ span.remove-icon { tr.odd td.dataTables_empty:last-child, tr.even td.dataTables_empty:last-child { display: revert; } + +table.dataTable thead th, table.dataTable thead td, table.dataTable tfoot th, table.dataTable tfoot td { + text-align: center !important; +} + +table.dataTable tbody tr { + text-align: center ! important; +} +.dropdown .dropdown-item.active, .dropdown .dropdown-item:active { + background: #eff2f5; + color: #000; +} diff --git a/public/assets/css/style.css b/public/assets/css/style.css index 31447ed..02742e4 100644 --- a/public/assets/css/style.css +++ b/public/assets/css/style.css @@ -1389,3 +1389,7 @@ button.btn.btn-light-primary.me-3 { tr.odd td.dataTables_empty:last-child, tr.even td.dataTables_empty:last-child { display: revert; } +.dropdown .dropdown-item.active, .dropdown .dropdown-item:active { + background: #eff2f5; + color: #000; +} diff --git a/public/assets/css/style1.css b/public/assets/css/style1.css index c519e85..3e34f3b 100644 --- a/public/assets/css/style1.css +++ b/public/assets/css/style1.css @@ -1045,3 +1045,15 @@ table.dataTable thead > tr > td.sorting_desc_disabled:after { width: auto; } } + +table.dataTable thead th, table.dataTable thead td, table.dataTable tfoot th, table.dataTable tfoot td { + text-align: center !important; +} + +table.dataTable tbody tr { + text-align: center ! important; +} +.dropdown .dropdown-item.active, .dropdown .dropdown-item:active { + background: #eff2f5; + color: #000; +} diff --git a/public/assets/css/style2.css b/public/assets/css/style2.css index a09d7f6..709b89c 100644 --- a/public/assets/css/style2.css +++ b/public/assets/css/style2.css @@ -1408,3 +1408,15 @@ a:active { width: auto; } } + +table.dataTable thead th, table.dataTable thead td, table.dataTable tfoot th, table.dataTable tfoot td { + text-align: center !important; +} + +table.dataTable tbody tr { + text-align: center ! important; +} +.dropdown .dropdown-item.active, .dropdown .dropdown-item:active { + background: #eff2f5; + color: #000; +} diff --git a/public/uploads/product/channel_partner_agreement/1717669843_presentation.png b/public/uploads/product/channel_partner_agreement/1717669843_presentation.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717669843_presentation.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717669901_presentation.png b/public/uploads/product/channel_partner_agreement/1717669901_presentation.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717669901_presentation.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717670002_presentation.png b/public/uploads/product/channel_partner_agreement/1717670002_presentation.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717670002_presentation.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717670253_presentation.png b/public/uploads/product/channel_partner_agreement/1717670253_presentation.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717670253_presentation.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717670364_partner_agreement.png b/public/uploads/product/channel_partner_agreement/1717670364_partner_agreement.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717670364_partner_agreement.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717672035_partner_agreement.png b/public/uploads/product/channel_partner_agreement/1717672035_partner_agreement.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717672035_partner_agreement.png differ diff --git a/public/uploads/product/channel_partner_agreement/1717672070_partner_agreement.png b/public/uploads/product/channel_partner_agreement/1717672070_partner_agreement.png new file mode 100644 index 0000000..9b952e6 Binary files /dev/null and b/public/uploads/product/channel_partner_agreement/1717672070_partner_agreement.png differ diff --git a/public/uploads/profile/img/17176578965.png b/public/uploads/profile/img/17176578965.png new file mode 100644 index 0000000..b41654e Binary files /dev/null and b/public/uploads/profile/img/17176578965.png differ diff --git a/resources/views/Admin/Pages/manage_commission/edit_commission.blade.php b/resources/views/Admin/Pages/manage_commission/edit_commission.blade.php index da22ee1..1c8b9f0 100644 --- a/resources/views/Admin/Pages/manage_commission/edit_commission.blade.php +++ b/resources/views/Admin/Pages/manage_commission/edit_commission.blade.php @@ -22,6 +22,7 @@ @csrf @method('patch') + {{-- @dd($product); --}}